]> sigrok.org Git - libsigrokdecode.git/commitdiff
srd_inst_decode(): Improve comments and log messages.
authorUwe Hermann <redacted>
Thu, 25 Aug 2016 20:01:04 +0000 (22:01 +0200)
committerUwe Hermann <redacted>
Thu, 25 Aug 2016 20:30:09 +0000 (22:30 +0200)
Also, drop @since tag (as the function is not public).

instance.c

index 53a8d9258b6560c728b1d0be50aa115af7ea670a..b4f9cfd67638dbc54ac214641e64b31976bb4d1d 100644 (file)
@@ -522,7 +522,7 @@ SRD_PRIV int srd_inst_start(struct srd_decoder_inst *di)
 }
 
 /**
- * Run the specified decoder function.
+ * Decode a chunk of samples.
  *
  * @param di The decoder instance to call. Must not be NULL.
  * @param start_samplenum The starting sample number for the buffer's sample
@@ -531,13 +531,11 @@ SRD_PRIV int srd_inst_start(struct srd_decoder_inst *di)
  *                       set, relative to the start of capture.
  * @param inbuf The buffer to decode. Must not be NULL.
  * @param inbuflen Length of the buffer. Must be > 0.
- * @param unitsize The number of bytes per sample.
+ * @param unitsize The number of bytes per sample. Must be > 0.
  *
  * @return SRD_OK upon success, a (negative) error code otherwise.
  *
  * @private
- *
- * @since 0.4.0
  */
 SRD_PRIV int srd_inst_decode(const struct srd_decoder_inst *di,
                uint64_t start_samplenum, uint64_t end_samplenum,
@@ -562,7 +560,7 @@ SRD_PRIV int srd_inst_decode(const struct srd_decoder_inst *di,
 
        ((struct srd_decoder_inst *)di)->data_unitsize = unitsize;
 
-       srd_dbg("Calling decode(), start sample %" PRIu64 ", end sample %"
+       srd_dbg("Decoding: start sample %" PRIu64 ", end sample %"
                PRIu64 " (%" PRIu64 " samples, %" PRIu64 " bytes, unitsize = "
                "%d), instance %s.", start_samplenum, end_samplenum,
                end_samplenum - start_samplenum, inbuflen, di->data_unitsize,