]> git.sur5r.net Git - u-boot/commitdiff
usb: composite convert __set_bit to generic_set_bit
authorBryan O'Donoghue <pure.logic@nexus-software.ie>
Mon, 30 Apr 2018 14:56:10 +0000 (15:56 +0100)
committerTom Rini <trini@konsulko.com>
Wed, 16 May 2018 01:44:05 +0000 (21:44 -0400)
Compiling the f_mass_storage driver for an x86 target results in a
compilation error as set_bit and clear_bit are provided by bitops.h

To address that situation we discussed on the list moving to
genetic_set_bit() instead.

Doing a quick grep for similar situations in drivers/usb shows that the
composite device is using __set_bit().

This patch switches over to generic_set_bit to maintain consistency between
the two gadget drivers.

Signed-off-by: Bryan O'Donoghue <pure.logic@nexus-software.ie>
Cc: Lukasz Majewski <lukma@denx.de>
Cc: Marek Vasut <marex@denx.de>
drivers/usb/gadget/composite.c

index e307c738fd7e94974a981807706f2d0e7828bfc6..5106cc56cb6f59b76835fee903fd0cc32109e14a 100644 (file)
@@ -378,7 +378,7 @@ static int set_config(struct usb_composite_dev *cdev,
                        ep = (struct usb_endpoint_descriptor *)*descriptors;
                        addr = ((ep->bEndpointAddress & 0x80) >> 3)
                             |  (ep->bEndpointAddress & 0x0f);
-                       __set_bit(addr, f->endpoints);
+                       generic_set_bit(addr, f->endpoints);
                }
 
                result = f->set_alt(f, tmp, 0);