Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-18 Thread Dan Carpenter
On Wed, Nov 18, 2015 at 04:26:52PM +, Ian Abbott wrote: > >+#define DMM32AT_AI_CFG_SCINT_10US (BIT(5) & ~BIT(4)) > >+#define DMM32AT_AI_CFG_SCINT_5US(BIT(5) | BIT(4)) > > The values of DMM32AT_AI_CFG_SCINT_20US etc. are numerically > correct, but look a bit strange. The `(BIT(5) &

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-18 Thread Ian Abbott
On 18/11/15 16:26, Ian Abbott wrote: On 14/11/15 17:10, Ranjith Thangavel wrote: BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Those two things should be done in separate patches. Sorry, I didn't see

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-18 Thread Ian Abbott
On 14/11/15 17:10, Ranjith Thangavel wrote: BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Those two things should be done in separate patches. Signed-off-by: Ranjith Thangavel ---

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-18 Thread Ian Abbott
On 14/11/15 17:10, Ranjith Thangavel wrote: BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Those two things should be done in separate patches. Signed-off-by: Ranjith Thangavel ---

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-18 Thread Ian Abbott
On 18/11/15 16:26, Ian Abbott wrote: On 14/11/15 17:10, Ranjith Thangavel wrote: BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Those two things should be done in separate patches. Sorry, I didn't see

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-18 Thread Dan Carpenter
On Wed, Nov 18, 2015 at 04:26:52PM +, Ian Abbott wrote: > >+#define DMM32AT_AI_CFG_SCINT_10US (BIT(5) & ~BIT(4)) > >+#define DMM32AT_AI_CFG_SCINT_5US(BIT(5) | BIT(4)) > > The values of DMM32AT_AI_CFG_SCINT_20US etc. are numerically > correct, but look a bit strange. The `(BIT(5) &

RE: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-16 Thread Hartley Sweeten
On Monday, November 16, 2015 10:09 AM, Ranjith Thangavel wrote: > BIT macro is used for defining BIT location instead of > shifting operator, usleep_range is preferred over > udelay - coding style issue > > Signed-off-by: Ranjith Thangavel > --- > drivers/staging/comedi/drivers/dmm32at.c |4

[PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-16 Thread Ranjith Thangavel
BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Signed-off-by: Ranjith Thangavel --- drivers/staging/comedi/drivers/dmm32at.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-16 Thread Dan Carpenter
This one is buggy. For example: > -#define DMM32AT_FIFO_STATUS_PAGE_MASK(3 << 0) > +#define DMM32AT_FIFO_STATUS_PAGE_MASK0 There are other bugs as well. Please, be more careful. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-kernel"

Re: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-16 Thread Dan Carpenter
This one is buggy. For example: > -#define DMM32AT_FIFO_STATUS_PAGE_MASK(3 << 0) > +#define DMM32AT_FIFO_STATUS_PAGE_MASK0 There are other bugs as well. Please, be more careful. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-kernel"

[PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-16 Thread Ranjith Thangavel
BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Signed-off-by: Ranjith Thangavel --- drivers/staging/comedi/drivers/dmm32at.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

RE: [PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-16 Thread Hartley Sweeten
On Monday, November 16, 2015 10:09 AM, Ranjith Thangavel wrote: > BIT macro is used for defining BIT location instead of > shifting operator, usleep_range is preferred over > udelay - coding style issue > > Signed-off-by: Ranjith Thangavel > --- >

[PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-14 Thread Ranjith Thangavel
BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Signed-off-by: Ranjith Thangavel --- drivers/staging/comedi/drivers/dmm32at.c | 104 +++--- 1 file changed, 52 insertions(+), 52

[PATCH] comedi: dmm32at: Fix coding style - use BIT macro

2015-11-14 Thread Ranjith Thangavel
BIT macro is used for defining BIT location instead of shifting operator, usleep_range is preferred over udelay - coding style issue Signed-off-by: Ranjith Thangavel --- drivers/staging/comedi/drivers/dmm32at.c | 104 +++--- 1 file changed, 52