Re: [PATCH] USB: gadget: fix EEM gadget CRC usage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

Brian Niebuhr wrote:

I wanted to resubmit this patch.  I submitted it back in October, but
I think it got lost...

  You should put such remarks under --- tearline.

eem_wrap() is sending a sentinel CRC, but it didn't indicate that to
the host, it should zero bit 14 (bmCRC) in the EEM packet header,
instead of setting it.

Also remove a redundant crc calculation in eem_unwrap().


Signed-off-by: Steve Longerbeam <stevel@xxxxxxxxxxxxxxx>
Acked-by: Brian Niebuhr <bniebuhr@xxxxxxxxxxxxx>
Acked-by: David Brownell<dbrownell@xxxxxxxxxxxxxxxxxxxxx>

---
 drivers/usb/gadget/f_eem.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/gadget/f_eem.c b/drivers/usb/gadget/f_eem.c
index 0a577d5..d4f0db5 100644
--- a/drivers/usb/gadget/f_eem.c
+++ b/drivers/usb/gadget/f_eem.c
@@ -358,7 +358,7 @@ done:
        * b15:         bmType (0 == data)
        */
       len = skb->len;
-       put_unaligned_le16((len & 0x3FFF) | BIT(14), skb_push(skb, 2));
+       put_unaligned_le16(len & 0x3FFF, skb_push(skb, 2));

  Time to change spaces there to tab.

WBR, Sergei


--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux