[PATCH] Staging: ft1000: ft1000-pcmcia: Fix whitespace issues
This patch fixes the following errors and warnings identified by checkpatch.pl: WARNING: please, no spaces at the start of a line 814: FILE: ft1000_hw.c:814: tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL);$ WARNING: please, no spaces at the start of a line 815: FILE: ft1000_hw.c:815: i=0;$ ERROR: spaces required around that '=' (ctx:VxV) 815: FILE: ft1000_hw.c:815: i=0; WARNING: please, no spaces at the start of a line 816: FILE: ft1000_hw.c:816: while (tempword & FT1000_DB_DPRAM_TX) {$ ERROR: code indent should use tabs where possible 817: FILE: ft1000_hw.c:817: mdelay(10);$ WARNING: please, no spaces at the start of a line 817: FILE: ft1000_hw.c:817: mdelay(10);$ ERROR: code indent should use tabs where possible 818: FILE: ft1000_hw.c:818: i++;$ WARNING: please, no spaces at the start of a line 818: FILE: ft1000_hw.c:818: i++;$ ERROR: code indent should use tabs where possible 819: FILE: ft1000_hw.c:819: if (i==10) {$ WARNING: please, no spaces at the start of a line 819: FILE: ft1000_hw.c:819: if (i==10) {$ WARNING: suspect code indent for conditional statements (8, 12) 819: FILE: ft1000_hw.c:819: if (i==10) { spin_unlock_irqrestore(&info->dpram_lock, flags); ERROR: spaces required around that '==' (ctx:VxV) 819: FILE: ft1000_hw.c:819: if (i==10) { ERROR: code indent should use tabs where possible 820: FILE: ft1000_hw.c:820: spin_unlock_irqrestore(&info->dpram_lock, flags);$ WARNING: please, no spaces at the start of a line 820: FILE: ft1000_hw.c:820: spin_unlock_irqrestore(&info->dpram_lock, flags);$ ERROR: code indent should use tabs where possible 821: FILE: ft1000_hw.c:821: return;$ WARNING: please, no spaces at the start of a line 821: FILE: ft1000_hw.c:821: return;$ ERROR: code indent should use tabs where possible 822: FILE: ft1000_hw.c:822: }$ WARNING: please, no spaces at the start of a line 822: FILE: ft1000_hw.c:822: }$ ERROR: code indent should use tabs where possible 823: FILE: ft1000_hw.c:823: tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL);$ WARNING: please, no spaces at the start of a line 823: FILE: ft1000_hw.c:823: tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL);$ WARNING: please, no spaces at the start of a line 824: FILE: ft1000_hw.c:824: }$ Signed-off-by: Nicky Chorley --- drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c b/drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c index a9bcb9e..9de3089 100644 --- a/drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c +++ b/drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c @@ -810,18 +810,18 @@ static void ft1000_send_cmd (struct net_device *dev, u16 *ptempbuffer, int size, */ spin_lock_irqsave(&info->dpram_lock, flags); -/* Make sure SLOWQ doorbell is clear */ -tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL); -i=0; -while (tempword & FT1000_DB_DPRAM_TX) { -mdelay(10); -i++; -if (i==10) { -spin_unlock_irqrestore(&info->dpram_lock, flags); -return; -} -tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL); -} + /* Make sure SLOWQ doorbell is clear */ + tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL); + i = 0; + while (tempword & FT1000_DB_DPRAM_TX) { + mdelay(10); + i++; + if (i == 10) { + spin_unlock_irqrestore(&info->dpram_lock, flags); + return; + } + tempword = ft1000_read_reg(dev, FT1000_REG_DOORBELL); + } if (info->AsicID == ELECTRABUZZ_ID) { ft1000_write_reg(dev, FT1000_REG_DPRAM_ADDR, -- 1.8.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging: vt6655: Remove C99 comments
This patch fixes the following errors identified by checkpatch.pl: ERROR: do not use C99 // comments 36: FILE: card.h:36: // ERROR: do not use C99 // comments 37: FILE: card.h:37: // Loopback mode ERROR: do not use C99 // comments 38: FILE: card.h:38: // ERROR: do not use C99 // comments 39: FILE: card.h:39: // LOBYTE is MAC LB mode, HIBYTE is MII LB mode ERROR: do not use C99 // comments 41: FILE: card.h:41: #define CARD_LB_MAC MAKEWORD(MAC_LB_INTERNAL, 0) // PHY must ISO, avoid MAC loopback packet go out ERROR: do not use C99 // comments 44: FILE: card.h:44: #define DEFAULT_MSDU_LIFETIME 512 // ms ERROR: do not use C99 // comments 45: FILE: card.h:45: #define DEFAULT_MSDU_LIFETIME_RES_64us 8000 // 64us ERROR: do not use C99 // comments 47: FILE: card.h:47: #define DEFAULT_MGN_LIFETIME8// ms ERROR: do not use C99 // comments 48: FILE: card.h:48: #define DEFAULT_MGN_LIFETIME_RES_64us 125 // 64us ERROR: do not use C99 // comments 175: FILE: card.h:175: #endif // __CARD_H__ Signed-off-by: Nicky Chorley --- drivers/staging/vt6655/card.h | 21 +++-- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/drivers/staging/vt6655/card.h b/drivers/staging/vt6655/card.h index 96f5b6c..e5bde09 100644 --- a/drivers/staging/vt6655/card.h +++ b/drivers/staging/vt6655/card.h @@ -33,19 +33,20 @@ #include #include -// -// Loopback mode -// -// LOBYTE is MAC LB mode, HIBYTE is MII LB mode +/* + * Loopback mode + * + * LOBYTE is MAC LB mode, HIBYTE is MII LB mode + */ #define CARD_LB_NONEMAKEWORD(MAC_LB_NONE, 0) -#define CARD_LB_MAC MAKEWORD(MAC_LB_INTERNAL, 0) // PHY must ISO, avoid MAC loopback packet go out +#define CARD_LB_MAC MAKEWORD(MAC_LB_INTERNAL, 0) /* PHY must ISO, avoid MAC loopback packet go out */ #define CARD_LB_PHY MAKEWORD(MAC_LB_EXT, 0) -#define DEFAULT_MSDU_LIFETIME 512 // ms -#define DEFAULT_MSDU_LIFETIME_RES_64us 8000 // 64us +#define DEFAULT_MSDU_LIFETIME 512 /* ms */ +#define DEFAULT_MSDU_LIFETIME_RES_64us 8000 /* 64us */ -#define DEFAULT_MGN_LIFETIME8// ms -#define DEFAULT_MGN_LIFETIME_RES_64us 125 // 64us +#define DEFAULT_MGN_LIFETIME8/* ms */ +#define DEFAULT_MGN_LIFETIME_RES_64us 125 /* 64us */ #define CB_MAX_CHANNEL_24G 14 #define CB_MAX_CHANNEL_5G 42 @@ -172,4 +173,4 @@ CARDbyGetTransmitPower( struct vnt_private * ); -#endif // __CARD_H__ +#endif /* __CARD_H__ */ -- 1.8.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging: vt6655: Fix a typo in card.c
The word "force" was spelt incorrectly. Signed-off-by: Nicky Chorley --- The C99 comments will be fixed in another patch, when I get round to it! drivers/staging/vt6655/card.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6655/card.c b/drivers/staging/vt6655/card.c index f2a33a9..ce496b1 100644 --- a/drivers/staging/vt6655/card.c +++ b/drivers/staging/vt6655/card.c @@ -819,7 +819,7 @@ CARDbPowerDown( if (MACbIsRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PS)) return true; - // Froce PSEN on + // Force PSEN on MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PSEN); // check if all TD are empty, -- 1.8.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH] Staging: vt6655: Fix a typo in card.c
On Wed, Oct 29, 2014 at 05:20:30PM +0800, Greg Kroah-Hartman wrote: > On Sun, Oct 26, 2014 at 06:57:37AM +0000, Nicky Chorley wrote: > > The word "force" was spelt incorrectly. > > > > Signed-off-by: Nicky Chorley > > --- > > > > The C99 comments will be fixed in another patch, when I get round to it! > > > > drivers/staging/vt6655/card.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/staging/vt6655/card.c b/drivers/staging/vt6655/card.c > > index f2a33a9..ce496b1 100644 > > --- a/drivers/staging/vt6655/card.c > > +++ b/drivers/staging/vt6655/card.c > > @@ -819,7 +819,7 @@ CARDbPowerDown( > > if (MACbIsRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PS)) > > return true; > > > > - // Froce PSEN on > > + // Force PSEN on > > MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PSEN); > > > > // check if all TD are empty, > > -- > > 1.8.4 > > This doesn't apply to my tree :( I guess that's because of the following commit: 77b6a6a staging: vt6655: card.c: Comments fixes That fixed the C99 comments, but not the typo. I'll make a new patch. Thanks! ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] Staging: vt6655: Fix typo in card.c
The word "force" was spelt incorrectly. Signed-off-by: Nicky Chorley --- drivers/staging/vt6655/card.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6655/card.c b/drivers/staging/vt6655/card.c index eae6789..abb4710 100644 --- a/drivers/staging/vt6655/card.c +++ b/drivers/staging/vt6655/card.c @@ -808,7 +808,7 @@ CARDbPowerDown( if (MACbIsRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PS)) return true; - /* Froce PSEN on */ + /* Force PSEN on */ MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PSEN); /* check if all TD are empty */ -- 1.8.4 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel