Skip to content

Commit 30ac2cf

Browse files
committed
Debug len more than free_entries
1 parent fe49c29 commit 30ac2cf

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

virtio-snd.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -741,7 +741,7 @@ static void __virtio_snd_frame_enqueue(void *payload,
741741

742742
/* Move prod_head. */
743743
if (n > free_entries)
744-
fprintf(stderr, "payload length larger than free_entries\n");
744+
fprintf(stderr, "payload length %" PRIu32 " larger than free_entries %" PRIu32 "\n", n, free_entries);
745745
prod_next = prod_head + n;
746746
props->ring.prod.head = prod_next;
747747

@@ -835,8 +835,9 @@ static int virtio_snd_tx_desc_handler(virtio_snd_state_t *vsnd,
835835
/* TODO: ring buffer copy here */
836836
void *payload = (void *) (base + addr);
837837
__virtio_snd_frame_enqueue(payload, len, stream_id);
838-
fprintf(stderr, "prod tail: %" PRIu32 "\n",
839-
vsnd_props[stream_id].ring.prod.tail); /* XXX: test only */
838+
/* XXX: test only */
839+
/*fprintf(stderr, "prod tail: %" PRIu32 "\n",
840+
vsnd_props[stream_id].ring.prod.tail);*/
840841
ret_len += len;
841842

842843
early_continue:

0 commit comments

Comments
 (0)