[PATCH v4 11/14] staging: comedi: daqboard2000: rename trigger control register macros

2016-05-19 Thread Ian Abbott
Rename the macros that define values for the trigger control register to avoid CamelCase, and to make it clearer which register they are associated with. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. v3, v4: No change

[PATCH v4 01/14] staging: comedi: daqboard2000: remove commented out code

2016-05-19 Thread Ian Abbott
Remove some commented out code. Some of it uses constructs that don't exist in the driver, and probably come from the source code for the MS Windows driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Added comments to offset and gain values that should be read from E

[PATCH v4 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-19 Thread Ian Abbott
s series of patches to the daqboard2000 driver is mostly to fix the checkpatch.pl warnings. There is one warning remaining about one of the `udelay` calls with a parameter of 10 microseconds, but I decided to leave it alone, as converting it to `usleep_range` could increase firmware loading time.

[PATCH v4 03/14] staging: comedi: daqboard2000: CHECK: spaces preferred around that '*'

2016-05-19 Thread Ian Abbott
Fix checkpatch issues of the form "CHECK: spaces preferred around that '*' (ctx:VxV)". Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- CamelCase issues in this patch will be dealt with by later patches. v2, v3, v4: No change. --- drivers/staging/comedi/driver

[PATCH v4 07/14] staging: comedi: daqboard2000: rename acquisition control register macros

2016-05-19 Thread Ian Abbott
Rename the macros defining values for the acquisition control register to avoid CamelCase, and to make it clearer which register they are associated with. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. v3: Rebased due to v3

[PATCH v4 13/14] staging: comedi: daqboard2000: rename CamelCase functions

2016-05-19 Thread Ian Abbott
Rename functions to avoid CamelCase warnings from checkpatch, and to use namespace associated with the driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Rebased due to v2 changes in previous patches. v3, v4: No change. --- drivers/staging/comedi/drivers/daqboard2000.c

Re: [PATCH v2 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-19 Thread Ian Abbott
On 19/05/16 11:16, Ian Abbott wrote: On 19/05/16 11:02, Ian Abbott wrote: On 18/05/16 13:36, Ian Abbott wrote: Patches 03 and 06 have checkpatch warnings themselves about CamelCase issues, but they are not "new" issues, and are resolved by the later patches in the series. 01) stagi

Re: [PATCH v3 06/14] staging: comedi: daqboard2000: rename register offset macros

2016-05-19 Thread Ian Abbott
On 19/05/16 17:49, Hartley Sweeten wrote: On Thursday, May 19, 2016 2:56 AM, Ian Abbott wrote: Rename the macros defining register offsets to avoid CamelCase, and to use namespace associated with the driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- Other CamelCase issues

Re: [PATCH v2 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-19 Thread Ian Abbott
On 19/05/16 11:02, Ian Abbott wrote: On 18/05/16 13:36, Ian Abbott wrote: Patches 03 and 06 have checkpatch warnings themselves about CamelCase issues, but they are not "new" issues, and are resolved by the later patches in the series. 01) staging: comedi: daqboard2000: remove com

[PATCH v4 12/14] staging: comedi: daqboard2000: rename reference DACs register macros

2016-05-19 Thread Ian Abbott
Rename the macros that define values for the reference DACs register to avoid CamelCase, and to make it clearer which register they are associated with. Add a macro `DB2K_REG_DACS_SET` for the value `0x0080` that triggers setting one of the references. Signed-off-by: Ian Abbott Reviewed-by: H

Re: [PATCH v3 12/14] staging: comedi: daqboard2000: rename reference DACs register macros

2016-05-19 Thread Ian Abbott
On 19/05/16 10:58, Ian Abbott wrote: Rename the macros that define values for the reference DACs register to avoid CamelCase, and to make it clearer which register they are associated with. Add a macro `DAQBOARD2000_REF_DACS_SET` for the value `0x0080` that triggers setting one of the

Re: [PATCH v2 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-19 Thread Ian Abbott
On 18/05/16 13:36, Ian Abbott wrote: Patches 03 and 06 have checkpatch warnings themselves about CamelCase issues, but they are not "new" issues, and are resolved by the later patches in the series. 01) staging: comedi: daqboard2000: remove commented out code 02) staging: comedi: da

[PATCH v3 12/14] staging: comedi: daqboard2000: rename reference DACs register macros

2016-05-19 Thread Ian Abbott
Rename the macros that define values for the reference DACs register to avoid CamelCase, and to make it clearer which register they are associated with. Add a macro `DAQBOARD2000_REF_DACS_SET` for the value `0x0080` that triggers setting one of the references. Signed-off-by: Ian Abbott Reviewed

[PATCH v3 06/14] staging: comedi: daqboard2000: rename register offset macros

2016-05-19 Thread Ian Abbott
Rename the macros defining register offsets to avoid CamelCase, and to use namespace associated with the driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- Other CamelCase issues in this patch will be dealt with by later patches in the series. v2: Shortened prefix from

[PATCH v2 01/14] staging: comedi: daqboard2000: remove commented out code

2016-05-18 Thread Ian Abbott
Remove some commented out code. Some of it uses constructs that don't exist in the driver, and probably come from the source code for the MS Windows driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: added comments to offset and gain values that should be read from E

[PATCH v2 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-18 Thread Ian Abbott
Patches 03 and 06 have checkpatch warnings themselves about CamelCase issues, but they are not "new" issues, and are resolved by the later patches in the series. 01) staging: comedi: daqboard2000: remove commented out code 02) staging: comedi: daqboard2000: use usual block comment style 03) stagin

[PATCH v2 05/14] staging: comedi: daqboard2000: rename serial EEPROM register macros

2016-05-18 Thread Ian Abbott
Rename the macros defining values for the Serial EEPROM Control Register to avoid CamelCase. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. --- drivers/staging/comedi/drivers/daqboard2000.c | 26 +- 1

[PATCH v2 03/14] staging: comedi: daqboard2000: CHECK: spaces preferred around that '*'

2016-05-18 Thread Ian Abbott
Fix checkpatch issues of the form "CHECK: spaces preferred around that '*' (ctx:VxV)". Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- CamelCase issues in this patch will be dealt with by later patches. v2: No change. --- drivers/staging/comedi/driver

[PATCH v2 11/14] staging: comedi: daqboard2000: rename trigger control register macros

2016-05-18 Thread Ian Abbott
Rename the macros that define values for the trigger control register to avoid CamelCase, and to make it clearer which register they are associated with. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. --- drivers/staging

[PATCH v2 08/14] staging: comedi: daqboard2000: rename acq status register macros

2016-05-18 Thread Ian Abbott
ch is write-only. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. --- drivers/staging/comedi/drivers/daqboard2000.c | 39 ++- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/drivers/staging/c

[PATCH v2 09/14] staging: comedi: daqboard2000: redo DAC control register macros

2016-05-18 Thread Ian Abbott
currently used by the driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. --- drivers/staging/comedi/drivers/daqboard2000.c | 21 +++-- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/drivers

[PATCH v2 13/14] staging: comedi: daqboard2000: rename CamelCase functions

2016-05-18 Thread Ian Abbott
Rename functions to avoid CamelCase warnings from checkpatch, and to use namespace associated with the driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: No change, except to some diff context lines from previous patches. --- drivers/staging/comedi/drivers/daqboard2000.c

[PATCH v2 14/14] staging: comedi: daqboard2000: prefer usleep_range()

2016-05-18 Thread Ian Abbott
microseconds one is called as each 16-bit word of firmware data is written. Replace it with a fairly tight `usleep_range(10, 20)` to avoid slowing down firmware loading too much. The firmware is fairly short, so this would only slow it down firmware loading by about 20 milliseconds or so. Signed-off-by: Ian

[PATCH v2 10/14] staging: comedi: daqboard2000: redo DAC status macros and fix busy

2016-05-18 Thread Ian Abbott
el, but the existing code only works for channels 0 and 1. The driver only supports two DAC channels at the moment, so the bug is currently harmless, but fix it so we can support four DAC channels on some board models. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: S

[PATCH v2 02/14] staging: comedi: daqboard2000: use usual block comment style

2016-05-18 Thread Ian Abbott
Reformat one of the block comments to conform to the usual style (it's the only one that doesn't). Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: No change. --- drivers/staging/comedi/drivers/daqboard2000.c | 6 -- 1 file changed, 4 insertions(+), 2 deletion

[PATCH v2 06/14] staging: comedi: daqboard2000: rename register offset macros

2016-05-18 Thread Ian Abbott
Rename the macros defining register offsets to avoid CamelCase, and to use namespace associated with the driver. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- Other CamelCase issues in this patch will be dealt with by later patches in the series. v2: Shortened prefix from

[PATCH v2 12/14] staging: comedi: daqboard2000: rename reference DACs register macros

2016-05-18 Thread Ian Abbott
Rename the macros that define values for the reference DACs register to avoid CamelCase, and to make it clearer which register they are associated with. Add a macro `DAQBOARD2000_REF_DACS_SET` for the value `0x80` that triggers setting one of the references. Signed-off-by: Ian Abbott Reviewed

[PATCH v2 04/14] staging: comedi: daqboard2000: add blank line after struct declaration

2016-05-18 Thread Ian Abbott
Fix checkpatch issue: "CHECK: Please use a blank line after function/struct/union/enum declarations". Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Fixed typo in patch description: `black line` --> `blank line`. --- drivers/staging/comedi/drivers/daqboard2000.c

[PATCH v2 07/14] staging: comedi: daqboard2000: rename acquisition control register macros

2016-05-18 Thread Ian Abbott
Rename the macros defining values for the acquisition control register to avoid CamelCase, and to make it clearer which register they are associated with. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: Shortened prefix from `DAQBOARD2000_` to `DB2K_`. --- drivers/staging

Re: [PATCH 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-18 Thread Ian Abbott
On 17/05/16 18:46, Hartley Sweeten wrote: On Tuesday, May 17, 2016 2:53 AM, Ian Abbott wrote: This series of patches to the daqboard2000 driver is mostly to fix the checkpatch.pl warnings. There is one warning remaining about one of the `udelay` calls with a parameter of 10 microseconds, but I

Re: [PATCH 06/14] staging: comedi: daqboard2000: rename register offset macros

2016-05-18 Thread Ian Abbott
On 17/05/16 18:27, Hartley Sweeten wrote: On Tuesday, May 17, 2016 2:53 AM, Ian Abbott wrote: Rename the macros defining register offsets to avoid CamelCase, and to use namespace associated with the driver. Signed-off-by: Ian Abbott --- Other CamelCase issues in this patch will be dealt with

Re: [PATCH 14/14] staging: comedi: daqboard2000: prefer usleep_range()

2016-05-18 Thread Ian Abbott
On 17/05/16 18:42, Hartley Sweeten wrote: On Tuesday, May 17, 2016 2:53 AM, Ian Abbott wrote: The checkpatch.pl warns about two `udelay(x)` calls, one of 100 microseconds, and one of 10 microseconds. The 100 microseconds one is used when waiting for FPGA to become ready to accept firmware, and

Re: [PATCH 05/14] staging: comedi: daqboard2000: rename serial EEPROM register macros

2016-05-18 Thread Ian Abbott
On 17/05/16 18:22, Hartley Sweeten wrote: On Tuesday, May 17, 2016 2:53 AM, Ian Abbott wrote: Rename the macros defining values for the Serial EEPROM Control Register to avoid CamelCase. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 26

Re: [PATCH 01/14] staging: comedi: daqboard2000: remove commented out code

2016-05-18 Thread Ian Abbott
On 17/05/16 18:14, Hartley Sweeten wrote: On Tuesday, May 17, 2016 2:53 AM, Ian Abbott wrote: Remove some commented out code. Some of it uses constructs that don't exist in the driver, and probably come from the source code for the MS Windows driver. Signed-off-by: Ian Abbott --- dr

Re: [PATCH 1/1] Staging: comedi: fix CHECK: Prefer using the BIT macro issues in pcmmio.c

2016-05-18 Thread Ian Abbott
On 18/05/16 05:57, Ravishankar Karkala Mallikarjunayya wrote: This patch Replace all occurences of (1< --- drivers/staging/comedi/drivers/pcmmio.c | 40 - 1 file changed, 20 insertions(+), 20 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abb

Re: [PATCH 2/2] Staging: comedi: fix type issue in s626.c

2016-05-18 Thread Ian Abbott
patch already changed some of the types of the structure members. At this point, it's probably best if you start again, and repost an updated, and self-consistent, version 2 of your original series of 4 patches, tagged as "[PATCH v2 1/4]" etc. At the moment, everything is too messed up. -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 1/2] Staging: comedi: Fix WARNING issue in s626.c

2016-05-18 Thread Ian Abbott
mething weird going on above. In addition to reformatting the comments, it's also replacing the type descriptors of some of the members (using `u32` instead of `uint32_t` etc.). It looks like bits of the patches from your earlier series have crept into this one. -- -=( Ian Abbott @ MEV Ltd.E

Re: [PATCH] Staging: comedi: quatech_daqp_cs.c: Fix a unsigned warning issue

2016-05-18 Thread Ian Abbott
data[i]; int ret; /* D/A transfer rate is about 8ms */ Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 1/1] Staging: comedi: Fix WARNING issue in dt2801.c

2016-05-18 Thread Ian Abbott
/staging/comedi/drivers/dt2801.c | 95 + 1 file changed, 50 insertions(+), 45 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

[PATCH 01/14] staging: comedi: daqboard2000: remove commented out code

2016-05-17 Thread Ian Abbott
Remove some commented out code. Some of it uses constructs that don't exist in the driver, and probably come from the source code for the MS Windows driver. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 6 -- 1 file changed, 6 deletions(-) diff --

[PATCH 03/14] staging: comedi: daqboard2000: CHECK: spaces preferred around that '*'

2016-05-17 Thread Ian Abbott
Fix checkpatch issues of the form "CHECK: spaces preferred around that '*' (ctx:VxV)". Signed-off-by: Ian Abbott --- CamelCase issues in this patch will be dealt with by later patches. --- drivers/staging/comedi/drivers/daqboard2000.c | 8 1 file changed, 4 insert

[PATCH 07/14] staging: comedi: daqboard2000: rename acquisition control register macros

2016-05-17 Thread Ian Abbott
Rename the macros defining values for the acquisition control register to avoid CamelCase, and to make it clearer which register they are associated with. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 50 --- 1 file changed, 23 insertions

[PATCH 08/14] staging: comedi: daqboard2000: rename acq status register macros

2016-05-17 Thread Ian Abbott
ch is write-only. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 39 ++- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/drivers/staging/comedi/drivers/daqboard2000.c b/drivers/staging/comedi/drivers/daqboard2000.c index 36

[PATCH 09/14] staging: comedi: daqboard2000: redo DAC control register macros

2016-05-17 Thread Ian Abbott
currently used by the driver. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 21 +++-- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/drivers/staging/comedi/drivers/daqboard2000.c b/drivers/staging/comedi/drivers/daqboard2000.c index

[PATCH 06/14] staging: comedi: daqboard2000: rename register offset macros

2016-05-17 Thread Ian Abbott
Rename the macros defining register offsets to avoid CamelCase, and to use namespace associated with the driver. Signed-off-by: Ian Abbott --- Other CamelCase issues in this patch will be dealt with by later patches in the series. --- drivers/staging/comedi/drivers/daqboard2000.c | 112

[PATCH 11/14] staging: comedi: daqboard2000: rename trigger control register macros

2016-05-17 Thread Ian Abbott
Rename the macros that define values for the trigger control register to avoid CamelCase, and to make it clearer which register they are associated with. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 26 ++ 1 file changed, 14 insertions

[PATCH 10/14] staging: comedi: daqboard2000: redo DAC status macros and fix busy

2016-05-17 Thread Ian Abbott
el, but the existing code only works for channels 0 and 1. The driver only supports two DAC channels at the moment, so the bug is currently harmless, but fix it so we can support four DAC channels on some board models. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers

[PATCH 12/14] staging: comedi: daqboard2000: rename reference DACs register macros

2016-05-17 Thread Ian Abbott
Rename the macros that define values for the reference DACs register to avoid CamelCase, and to make it clearer which register they are associated with. Add a macro `DAQBOARD2000_REF_DACS_SET` for the value `0x80` that triggers setting one of the references. Signed-off-by: Ian Abbott

[PATCH 05/14] staging: comedi: daqboard2000: rename serial EEPROM register macros

2016-05-17 Thread Ian Abbott
Rename the macros defining values for the Serial EEPROM Control Register to avoid CamelCase. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 26 +- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/drivers/staging/comedi

[PATCH 14/14] staging: comedi: daqboard2000: prefer usleep_range()

2016-05-17 Thread Ian Abbott
microseconds one is called as each 16-bit word of firmware data is written. A longer sleep would slow down firmware loading, so leave it alone. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging

[PATCH 13/14] staging: comedi: daqboard2000: rename CamelCase functions

2016-05-17 Thread Ian Abbott
Rename functions to avoid CamelCase warnings from checkpatch, and to use namespace associated with the driver. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 80 ++- 1 file changed, 41 insertions(+), 39 deletions(-) diff --git a/drivers

[PATCH 02/14] staging: comedi: daqboard2000: use usual block comment style

2016-05-17 Thread Ian Abbott
Reformat one of the block comments to conform to the usual style (it's the only one that doesn't). Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/staging/comedi/drivers/daqb

[PATCH 00/14] staging: comedi: daqboard2000: checkpatch clean-ups

2016-05-17 Thread Ian Abbott
This series of patches to the daqboard2000 driver is mostly to fix the checkpatch.pl warnings. There is one warning remaining about one of the `udelay` calls with a parameter of 10 microseconds, but I decided to leave it alone, as converting it to `usleep_range` could increase firmware loading tim

[PATCH 04/14] staging: comedi: daqboard2000: add blank line after struct declaration

2016-05-17 Thread Ian Abbott
Fix checkpatch issue: "CHECK: Please use a black line after function/struct/union/enum declarations". Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/daqboard2000.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/comedi/drivers/daqboard2000.c b/drive

Re: [PATCH 6/6] Staging: comedi: Fix CHECK:Avoid CamelCase issue in daqboard2000.c

2016-05-16 Thread Ian Abbott
veral other CamelCase issues in this driver, although probably too many to deal with in a single patch. I'll have a shot at a slightly more extensive clean-up. -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 5/6] Staging: comedi: Fix WARNING issue in dt2801.c

2016-05-16 Thread Ian Abbott
omments to conform to that style, that would be great! -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH] Staging: comedi: quatech_daqp_cs.c: fixed a warning added missing 'int' in 'unsigned'.

2016-05-16 Thread Ian Abbott
->n; i++) { - unsigned val = data[i]; + unsigned int val = data[i]; int ret; /* D/A transfer rate is about 8ms */ Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 4/4] Staging: comedi: fix line over 80 characters issue in s626.c

2016-05-16 Thread Ian Abbott
ret = comedi_timeout(dev, NULL, NULL, s626_i2c_handshake_eoc, +0); if (ret) return ret; } Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web

Re: [PATCH 3/4] Staging: comedi: fix type issue in s626.c

2016-05-16 Thread Ian Abbott
dependent) */ }; The patch is reasonable, but messes up the alignment of those comments, especially the multi-line comments. -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 2/4] Staging: comedi:Fix checkpatch issue in s626.c

2016-05-16 Thread Ian Abbott
vate; uint16_t cra; uint16_t crb; - unsigned cntsrc, clkmult, clkpol; + unsigned int cntsrc, clkmult, clkpol; /* Initialize CRA and CRB images. */ /* IndexSrc is passed through. */ Thanks! Reviewed-by: Ian Abbott -- -=( Ian A

Re: [PATCH 1/4] Staging: comedi: Fix WARNING issue in s626.c

2016-05-16 Thread Ian Abbott
val); } Thanks! That's not our usual commenting style, but it will do for now. (Our usual style for "end of line" comments that don't fit on the line is to convert them to comments on the preceding lines.) Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mai

Re: [PATCH 1/1] Staging: comedi: comedi_fops.c: Fixed coding style issue

2016-05-10 Thread Ian Abbott
, unsigned long arg, (s_old->async->cmd.flags & CMDF_WRITE)) return -EBUSY; - ACCESS_ONCE(cfp->write_subdev) = s_new; + WRITE_ONCE(cfp->write_subdev, s_new); return 0; } Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

[PATCH] idr: fix kernel-doc header for idr_for_each_entry_continue

2016-04-25 Thread Ian Abbott
In the kernel-doc comment for the `idr_for_each_entry_continue`, it is called `idr_for_each_entry`. Correct the name in the comment. Signed-off-by: Ian Abbott Cc: Andreas Gruenbacher Cc: Jens Axboe Cc: Philipp Reisner Cc: Randy Dunlap --- include/linux/idr.h | 3 ++- 1 file changed, 2

Re: [PATCH] staging: comedi: das1800: remove unused variable

2016-04-06 Thread Ian Abbott
On 06/04/16 10:41, Ian Abbott wrote: On 06/04/16 02:21, Hartley Sweeten wrote: On Tuesday, April 05, 2016 7:23 AM, Sudip Mukherjee wrote: The variable unipolar was never used. Signed-off-by: Sudip Mukherjee --- There may be a chance that reading from DAS1800_CONTROL_C is necessary before

Re: [PATCH] staging: comedi: das1800: remove unused variable

2016-04-06 Thread Ian Abbott
patch series? Thanks. -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH] Staging: comedi: Fix 'unsigned' warning style

2016-03-29 Thread Ian Abbott
_put(struct comedi_device *dev); bool comedi_is_subdevice_running(struct comedi_subdevice *s); Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

[PATCH] staging: comedi: drivers: remove bogus ni_mio_c_common.c

2016-03-23 Thread Ian Abbott
The zero-length file "ni_mio_c_common.c" was inadvertantly created by commit e563637b5fef ("staging: comedi: Use ARRAY_SIZE for sizes of arrays"). Remove it. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/ni_mio_c_common.c | 0 1 file changed, 0 insert

Re: [PATCH v2] staging/comedi/dt282x: avoid integer overflow warning

2016-03-19 Thread Ian Abbott
gt;> 8) /* always 0? */ The patch is fine, thanks. Just a note on that dodgy-looking '>>' in the DT2821_CHANCSR_PRESLA macro I seems to be a typo in 0f8e8c5ab67a ("staging: comedi: dt282x: tidy up the register map and bit defines"). It s

Re: [PATCH 1/5] Staging: comedi: Fix type issues in s626.c

2016-03-14 Thread Ian Abbott
- 1 file changed, 156 insertions(+), 156 deletions(-) The patch would be okay, but it doesn't apply to the "staging-next" branch of Greg's staging.git on git.kernel.org. (It doesn't apply to the "master" branch of linux-next.git either.) -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 5/5] Staging: comedi: fix type issue in ni_tio.c

2016-03-10 Thread Ian Abbott
aging/comedi/drivers/ni_tio.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 4/5] Staging: comedi: fix CHECK issue in ni_tio.c

2016-03-10 Thread Ian Abbott
kala Mallikarjunayya --- drivers/staging/comedi/drivers/ni_tio.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 2/5] Staging: comedi: fix WARNING issue in s626.c

2016-03-10 Thread Ian Abbott
/staging/comedi/drivers/s626.c | 38 ++- 1 file changed, 24 insertions(+), 14 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 3/5] Staging: comedi: fix WARNING issue in s626.c

2016-03-10 Thread Ian Abbott
ret = comedi_timeout(dev, NULL, NULL, s626_i2c_handshake_eoc, +0); if (ret) return ret; } Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web

Re: [PATCH 1/5] Staging: comedi: fix type issue in s626.c

2016-03-10 Thread Ian Abbott
+++++----- 1 file changed, 156 insertions(+), 156 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 1/1] Staging: comedi: fix CHECK issue in ni_tio.c

2016-03-09 Thread Ian Abbott
space on that line. Ideally, the 'NITIO_INPUT_SEL_REG(cidx)' should line up with 'counter' on the previous line, but that would take the line over 80 characters. The current amount of whitespace is a compromise, but there is no need to change it. -- -=( Ian Abbott @ MEV Ltd.

Re: [PATCH 3/3] Staging: comedi: fix WARNING issue in s626.c

2016-03-09 Thread Ian Abbott
(+), 1 deletion(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 2/3] Staging: comedi: fix WARNING issue in s626.c

2016-03-09 Thread Ian Abbott
/s626.c | 34 ++ 1 file changed, 22 insertions(+), 12 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH 1/3] Staging: comedi: fix type issue in s626.c

2016-03-09 Thread Ian Abbott
1 file changed, 153 insertions(+), 153 deletions(-) Thanks! Just a minor niggle: there are a couple of unconverted 'int16_t' left behind by this patch, but those could be fixed in a subsequent patch. Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

[PATCH 2/2] staging: comedi: comedi.h: Fix comment for struct comedi_krange

2016-03-02 Thread Ian Abbott
value. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/comedi/comedi.h b/drivers/staging/comedi/comedi.h index 9547324..ad5297f 100644 --- a/drivers/staging/comedi/comedi.h +++ b/drivers/staging/comedi/co

[PATCH 0/2] staging: comedi: comedi.h: Avoid BIT macro

2016-03-02 Thread Ian Abbott
Patch 1 effectively reverts commit 72315cdaba9d on linux-next "Staging: comedi: Prefer using the BIT macro"), but I replaced the use of the BIT macro with hexadecimal constants instead of the original left bit-shift expressions. We shouldn't use the BIT macro in "comedi.h" as it is intended to be

[PATCH 1/2] staging: comedi: comedi.h: Do not use BIT macro

2016-03-02 Thread Ian Abbott
e same value. The `BIT` macro replaced expressions of the form `(1 << N)` in this file originally, but reverting back to that form would encourage patches changing them back to use the `BIT` macro. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi.h | 10 +- 1 file changed, 5

Re: [PATCH] Staging: comedi: mite: added spaces around | and *

2016-02-23 Thread Ian Abbott
l_in_range(struct mite_struct *mite, struct mite_dma_descriptor_ring *ring, unsigned min_channel, unsigned max_channel) -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: [PATCH] Staging: comedi: mite: added spaces around | and *

2016-02-23 Thread Ian Abbott
On 23/02/16 12:38, Philippe Loctaux wrote: On Tue, Feb 23, 2016 at 11:07:15AM +, Ian Abbott wrote: Even better: just remove the macro, as it isn't used. How can I do that? I'm asking that because my C knowledge isn't very good :P Are you sure you should be writing kernel

Re: [PATCH] Staging: comedi: mite: added spaces around | and *

2016-02-23 Thread Ian Abbott
ite.h" -#define TOP_OF_PAGE(x) ((x)|(~(PAGE_MASK))) +#define TOP_OF_PAGE(x) ((x) | (~(PAGE_MASK))) It'd be nice to remove superfluous parentheses here too +#define TOP_OF_PAGE(x) ((x) | ~PAGE_MASK) Even better: just remove the macro, as it isn't used. -- -=( Ian Abbott

Re: [PATCH] Staging: comedi: contec_pci_dio: fixed comment blocks coding style issues

2016-02-23 Thread Ian Abbott
+ 1 file changed, 24 insertions(+), 23 deletions(-) Thanks! Reviewed-by: Ian Abbott -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

Re: staging: comedi: COMEDI_BUFINFO: some behavioural changes

2016-02-19 Thread Ian Abbott
On 19/02/16 16:13, Ian Abbott wrote: ...stuff... Sorry, I forgot to tag that email as "[PATCH 0/8]". -- -=( Ian Abbott @ MEV Ltd.E-mail: )=- -=( Web: http://www.mev.co.uk/ )=-

[PATCH 1/8] staging: comedi: COMEDI_BUFINFO: get amount freed, not amount allocated

2016-02-19 Thread Ian Abbott
rom limiting how much can be freed in the second step. Change it to ignore how much it managed to allocate in the first step and just use the amount that was actually freed in the second step, which is the amount the current buffer position was actually moved by this ioctl call. Signed-

staging: comedi: COMEDI_BUFINFO: some behavioural changes

2016-02-19 Thread Ian Abbott
These patches change the behavior of the `COMEDI_BUFINFO` ioctl, which is used to manage buffer positions for a previously set up asynchronous acquisition command. It is used instead of the read and write file operations when the buffer has been mmapped. Patches 1 to 4 are fairly innocuous. Patc

[PATCH 2/8] staging: comedi: COMEDI_BUFINFO: force bytes_read or bytes_written to 0

2016-02-19 Thread Ian Abbott
lue to 0 before copying the values back to the user. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 30 ++ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.

[PATCH 4/8] staging: comedi: COMEDI_BUFINFO: force bytes_written to 0 if stopped

2016-02-19 Thread Ian Abbott
t successfully written to 0 in that case. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c index e625ef2..b7c9270 100644 --- a/drivers/staging/co

[PATCH 8/8] staging: comedi: COMEDI_BUFINFO: terminate "write" command when stopped

2016-02-19 Thread Ian Abbott
e just report the final buffer position back to the user. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c index 7cb1d06

[PATCH 5/8] staging: comedi: COMEDI_BUFINFO: return error if no active command

2016-02-19 Thread Ian Abbott
case. Prior to this change, if a command was started via a different file object, the ioctl returned `-EACCES`, but now it will return `-EINVAL`, which is consistent with the current behavior of the "read" and "write" file operation handlers. Signed-off-by: Ian Abbott --- dr

[PATCH 7/8] staging: comedi: COMEDI_BUFINFO: return -EPIPE for abnormal read

2016-02-19 Thread Ian Abbott
;read" position reported back to the user has been advanced to the end of all available data. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 27 ++- 1 file changed, 18 insertions(+), 9 deletions(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/dr

[PATCH 3/8] staging: comedi: COMEDI_BUFINFO: update buffer before becoming non-busy

2016-02-19 Thread Ian Abbott
t gets the updated buffer position. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c index 04d6040..e625ef2 100644 --- a/drivers/stag

[PATCH 6/8] staging: comedi: COMEDI_BUFINFO: become non-busy even if bytes_read is 0

2016-02-19 Thread Ian Abbott
without error is when it has been set up to read a finite amount of data. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c in

[PATCH 1/5] staging: comedi: comedi.h: tweak start of header comment

2016-02-09 Thread Ian Abbott
The wording at the start of the header comment is a bit misleading, particularly the part in parentheses: "(installed as /usr/include/comedi.h)". This version of "comedi.h" certainly won't be installed as that pathname. Fix it. Signed-off-by: Ian Abbott --- drivers/st

[PATCH 5/5] staging: comedi: comedi.h: remove SDF_MODE0 etc.

2016-02-09 Thread Ian Abbott
`SDF_MODE0` etc. flags to display the fact that they are set, but COMEDILIB uses and installs its own, compatible version of "comedi.h" anyway so isn't affected by their removal from the kernel copy. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi.h | 22 -

[PATCH 4/5] staging: comedi: comedi.h: remove struct comedi_trig

2016-02-09 Thread Ian Abbott
these, but it uses its own, compatible version of "comedi.h", so isn't affected by their removal from the kernel copy. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi.h | 24 +--- 1 file changed, 1 insertion(+), 23 deletions(-) diff --git a/drivers

[PATCH 3/5] staging: comedi: comedi.h: add kernel-doc comments to struct types

2016-02-09 Thread Ian Abbott
Add "kernel-doc"-formatted comments to the COMEDI `struct` declarations used with ioctls. Don't bother documenting `struct comedi_trig` as it is obsolete and not supported. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi.h | 332 +

[PATCH 0/5] staging: comedi: comedi.h: kernel-doc and remove cruft

2016-02-09 Thread Ian Abbott
Add some kernel-doc comments to the common enums and structs in "comedi.h", and remove the cruft related to the non-functional and obsolete COMEDI_TRIG ioctl. 1) staging: comedi: comedi.h: tweak start of header comment 2) staging: comedi: comedi.h: add kernel-doc to common enums 3) staging: comedi

<    1   2   3   4   5   6   7   8   9   10   >