From: Alon Levy <alevy@redhat.com>
To: Blue Swirl <blauwirbel@gmail.com>
Cc: Jes Sorensen <Jes.Sorensen@redhat.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v23 03/11] usb-ccid: add CCID bus
Date: Mon, 28 Mar 2011 20:00:30 +0200 [thread overview]
Message-ID: <20110328180030.GK2741@playa.redhat.com> (raw)
In-Reply-To: <AANLkTimmu0+W-ncmsuvrAuJHMZJ_XHGmQWA1D2q6ToY0@mail.gmail.com>
On Mon, Mar 28, 2011 at 08:44:59PM +0300, Blue Swirl wrote:
> On Mon, Mar 28, 2011 at 5:31 PM, Jes Sorensen <Jes.Sorensen@redhat.com> wrote:
> > On 03/28/11 16:28, Alon Levy wrote:
> >> On Mon, Mar 28, 2011 at 02:01:01PM +0200, Jes Sorensen wrote:
> >>> > On 03/23/11 14:19, Alon Levy wrote:
> >>>> > > A CCID device is a smart card reader. It is a USB device, defined at [1].
> >>>> > > This patch introduces the usb-ccid device that is a ccid bus. Next patches will
> >>>> > > introduce two card types to use it, a passthru card and an emulated card.
> >>>> > >
> >>>> > > [1] http://www.usb.org/developers/devclass_docs/DWG_Smart-Card_CCID_Rev110.
> >>>> > >
> >>>> > > Signed-off-by: Alon Levy <alevy@redhat.com>
> >>> >
> >>> > This looks ok to me now - I noticed that the comments in the header file
> >>> > refers to u8/u16/u32 for types, even though the code uses
> >>> > uint{8,16,32}_t, but I don't think that warrants a fix.
> >> You mean the comments in hw/usb-ccid.c in the descriptor? that's just shorter.
> >
> > I wasn't sure if it was a leftover from some of the headers being used
> > in the kernel. However I am fine with it - no need to change it, and it
> > makes it shorter as you say.
>
> No, u8/u16 etc are only available for Linux. Please use standard
> uint8_t etc. See also HACKING 2.1.
They are just in the comments, like I said above. Just did a git grep to verify,
here is the output (snipped because there are many comments):
U playa:qemu alon (usb_ccid.v24)$ git grep "\<u8\>" hw/ccid.h
U playa:qemu alon (usb_ccid.v24)$ git grep "\<u16\>" hw/ccid.h
U playa:qemu alon (usb_ccid.v24)$ git grep "\<u16\>" hw/usb-ccid.c
hw/usb-ccid.c: 0x10, 0x01, /* u16 bcdUSB; v1.1 */
hw/usb-ccid.c: /* u16 idVendor */
hw/usb-ccid.c: /* u16 idProduct */
hw/usb-ccid.c: /* u16 bcdDevice */
hw/usb-ccid.c: 0x5d, 0x00, /* u16 wTotalLength; 9+9+54+7+7+7 */
hw/usb-ccid.c: 0x10, 0x01, /* u16 bcdCCID; CCID Specification Release Number.
hw/usb-ccid.c: * u16 wLcdLayout; XXYY Number of lines (XX) and ch
hw/usb-ccid.c: /* u16 ep_wMaxPacketSize; */
hw/usb-ccid.c: 0x40, 0x00, /* u16 ep_wMaxPacketSize; */
hw/usb-ccid.c: 0x40, 0x00, /* u16 ep_wMaxPacketSize; */
U playa:qemu alon (usb_ccid.v24)$ git grep "\<u8\>" hw/usb-ccid.c
hw/usb-ccid.c: 0x12, /* u8 bLength; */
hw/usb-ccid.c: USB_DT_DEVICE, /* u8 bDescriptorType; Device */
hw/usb-ccid.c: 0x00, /* u8 bDeviceClass; */
hw/usb-ccid.c: 0x00, /* u8 bDeviceSubClass; */
hw/usb-ccid.c: 0x00, /* u8 bDeviceProtocol; [ low/full speeds only ] *
[snip 46 more lines with comments]
next prev parent reply other threads:[~2011-03-28 18:00 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-23 13:19 [Qemu-devel] [PATCH v23 00/11] usb-ccid Alon Levy
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 01/11] trace: move trace objects from Makefile to Makefile.objs Alon Levy
2011-03-28 11:59 ` Jes Sorensen
2011-03-28 14:26 ` Alon Levy
2011-03-28 14:30 ` Jes Sorensen
2011-03-28 16:00 ` Alon Levy
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 02/11] qemu-thread.h: include inttypes.h Alon Levy
2011-03-28 11:59 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 03/11] usb-ccid: add CCID bus Alon Levy
2011-03-28 12:01 ` Jes Sorensen
2011-03-28 12:13 ` Alon Levy
2011-03-28 14:28 ` Alon Levy
2011-03-28 14:31 ` Jes Sorensen
2011-03-28 17:44 ` Blue Swirl
2011-03-28 18:00 ` Alon Levy [this message]
2011-03-28 18:08 ` Blue Swirl
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 04/11] introduce libcacard/vscard_common.h Alon Levy
2011-03-28 12:04 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 05/11] ccid: add passthru card device Alon Levy
2011-03-28 12:08 ` Jes Sorensen
2011-03-28 12:14 ` Alon Levy
2011-03-28 13:45 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 06/11] libcacard: initial commit Alon Levy
2011-03-28 12:35 ` Jes Sorensen
2011-03-28 12:42 ` Alon Levy
2011-03-28 13:52 ` Jes Sorensen
2011-03-28 14:43 ` Alon Levy
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 07/11] libcacard: add vscclient Alon Levy
2011-03-28 12:43 ` Jes Sorensen
2011-03-28 12:51 ` Alon Levy
2011-03-28 13:55 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 08/11] libcacard: add passthru Alon Levy
2011-03-28 13:27 ` Jes Sorensen
2011-03-28 14:24 ` Alon Levy
2011-03-28 15:21 ` Alon Levy
2011-03-28 15:25 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 09/11] libcacard: add docs Alon Levy
2011-03-28 13:31 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 10/11] ccid: add ccid-card-emulated device Alon Levy
2011-03-28 13:39 ` Jes Sorensen
2011-03-23 13:19 ` [Qemu-devel] [PATCH v23 11/11] ccid: add docs Alon Levy
2011-03-28 13:41 ` Jes Sorensen
2011-03-23 15:32 ` [Qemu-devel] [PATCH v23 00/11] usb-ccid Hans de Goede
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110328180030.GK2741@playa.redhat.com \
--to=alevy@redhat.com \
--cc=Jes.Sorensen@redhat.com \
--cc=blauwirbel@gmail.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).