lkml.org 
[lkml]   [2014]   [Oct]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 3.16 108/357] usb: gadget: f_rndis: fix interface id for OS descriptors
    Date
    3.16-stable review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Andrzej Pietrasiewicz <andrzej.p@samsung.com>

    commit 4546527350c3c508554dff53e9086e9d3de0b97b upstream.

    f->os_desc_table[0].if_id is zero by default. If the actual id happens
    to be different then no Feature Descriptors will be returned to the host
    for this interface, so assign if_id as soon as it is known.

    Acked-by: Michal Nazarewicz <mina86@mina86.com>
    Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
    Signed-off-by: Felipe Balbi <balbi@ti.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


    ---
    drivers/usb/gadget/f_rndis.c | 4 ++++
    1 file changed, 4 insertions(+)

    --- a/drivers/usb/gadget/f_rndis.c
    +++ b/drivers/usb/gadget/f_rndis.c
    @@ -727,6 +727,10 @@ rndis_bind(struct usb_configuration *c,
    rndis_control_intf.bInterfaceNumber = status;
    rndis_union_desc.bMasterInterface0 = status;

    + if (cdev->use_os_string)
    + f->os_desc_table[0].if_id =
    + rndis_iad_descriptor.bFirstInterface;
    +
    status = usb_interface_id(c, f);
    if (status < 0)
    goto fail;



    \
     
     \ /
      Last update: 2014-10-04 00:21    [W:4.087 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site