[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/6] hw/usb: Add CanoKey Implementation
|
From: |
Gerd Hoffmann |
|
Subject: |
Re: [PATCH 1/6] hw/usb: Add CanoKey Implementation |
|
Date: |
Mon, 3 Jan 2022 09:19:26 +0100 |
Hi,
> +#ifdef DEBUG_CANOKEY
> +#define DPRINTF(fmt, ...) \
> +do { printf("canokey: " fmt "\n", ## __VA_ARGS__); } while (0)
Better use tracepoints instead (see docs/devel/tracing.rst).
> +int canokey_emu_transmit(
> + void *base, uint8_t ep, const uint8_t *pbuf, uint16_t size)
> +{
> + DPRINTF("transmit ep %d size %d", ep, size);
> + DPRINTF_DATA(pbuf, size, "transmit");
Did you know all usb devices have a pcap property for writing out usb
packet traces? i.e. use '-device canokey,pcap=test.pcap', then look
at the traces using wireshark.
take care,
Gerd
| [Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH 1/6] hw/usb: Add CanoKey Implementation,
Gerd Hoffmann <=