Message ID | 20190509090106.9065-1-oneukum@suse.com |
---|---|
State | Deferred |
Delegated to: | David Miller |
Headers | show |
Series | rtl8150: switch to BIT macro | expand |
On 19-05-09 11:01:06, Oliver Neukum wrote: > A bit of housekeeping switching the driver to the BIT() > macro. Looks good. I hope you've at least compiled the driver? :) Acked-by: Petko Manolov <petkan@nucleusys.com> cheers, Petko > Signed-off-by: Oliver Neukum <oneukum@suse.com> > --- > drivers/net/usb/rtl8150.c | 20 ++++++++++---------- > 1 file changed, 10 insertions(+), 10 deletions(-) > > diff --git a/drivers/net/usb/rtl8150.c b/drivers/net/usb/rtl8150.c > index 59dbdbb5feff..1ed85fba1a7c 100644 > --- a/drivers/net/usb/rtl8150.c > +++ b/drivers/net/usb/rtl8150.c > @@ -41,7 +41,7 @@ > #define ANLP 0x0146 > #define AER 0x0148 > #define CSCR 0x014C /* This one has the link status */ > -#define CSCR_LINK_STATUS (1 << 3) > +#define CSCR_LINK_STATUS BIT(3) > > #define IDR_EEPROM 0x1202 > > @@ -59,20 +59,20 @@ > > > /* Transmit status register errors */ > -#define TSR_ECOL (1<<5) > -#define TSR_LCOL (1<<4) > -#define TSR_LOSS_CRS (1<<3) > -#define TSR_JBR (1<<2) > +#define TSR_ECOL BIT(5) > +#define TSR_LCOL BIT(4) > +#define TSR_LOSS_CRS BIT(3) > +#define TSR_JBR BIT(2) > #define TSR_ERRORS (TSR_ECOL | TSR_LCOL | TSR_LOSS_CRS | TSR_JBR) > /* Receive status register errors */ > -#define RSR_CRC (1<<2) > -#define RSR_FAE (1<<1) > +#define RSR_CRC BIT(2) > +#define RSR_FAE BIT(1) > #define RSR_ERRORS (RSR_CRC | RSR_FAE) > > /* Media status register definitions */ > -#define MSR_DUPLEX (1<<4) > -#define MSR_SPEED (1<<3) > -#define MSR_LINK (1<<2) > +#define MSR_DUPLEX BIT(4) > +#define MSR_SPEED BIT(3) > +#define MSR_LINK BIT(2) > > /* Interrupt pipe data */ > #define INT_TSR 0x00 > -- > 2.16.4 > >
From: Petko Manolov <petkan@nucleusys.com> Date: Thu, 9 May 2019 17:34:41 +0300 > On 19-05-09 11:01:06, Oliver Neukum wrote: >> A bit of housekeeping switching the driver to the BIT() >> macro. > > Looks good. I hope you've at least compiled the driver? :) > > Acked-by: Petko Manolov <petkan@nucleusys.com> net-next is closed for cleanups like this, please resubmit when it opens back up. Thank you.
diff --git a/drivers/net/usb/rtl8150.c b/drivers/net/usb/rtl8150.c index 59dbdbb5feff..1ed85fba1a7c 100644 --- a/drivers/net/usb/rtl8150.c +++ b/drivers/net/usb/rtl8150.c @@ -41,7 +41,7 @@ #define ANLP 0x0146 #define AER 0x0148 #define CSCR 0x014C /* This one has the link status */ -#define CSCR_LINK_STATUS (1 << 3) +#define CSCR_LINK_STATUS BIT(3) #define IDR_EEPROM 0x1202 @@ -59,20 +59,20 @@ /* Transmit status register errors */ -#define TSR_ECOL (1<<5) -#define TSR_LCOL (1<<4) -#define TSR_LOSS_CRS (1<<3) -#define TSR_JBR (1<<2) +#define TSR_ECOL BIT(5) +#define TSR_LCOL BIT(4) +#define TSR_LOSS_CRS BIT(3) +#define TSR_JBR BIT(2) #define TSR_ERRORS (TSR_ECOL | TSR_LCOL | TSR_LOSS_CRS | TSR_JBR) /* Receive status register errors */ -#define RSR_CRC (1<<2) -#define RSR_FAE (1<<1) +#define RSR_CRC BIT(2) +#define RSR_FAE BIT(1) #define RSR_ERRORS (RSR_CRC | RSR_FAE) /* Media status register definitions */ -#define MSR_DUPLEX (1<<4) -#define MSR_SPEED (1<<3) -#define MSR_LINK (1<<2) +#define MSR_DUPLEX BIT(4) +#define MSR_SPEED BIT(3) +#define MSR_LINK BIT(2) /* Interrupt pipe data */ #define INT_TSR 0x00
A bit of housekeeping switching the driver to the BIT() macro. Signed-off-by: Oliver Neukum <oneukum@suse.com> --- drivers/net/usb/rtl8150.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-)