..3f70e5dfac39 100644
--- a/drivers/staging/comedi/comedi_fops.c
+++ b/drivers/staging/comedi/comedi_fops.c
comedi moved out of "drivers/staging" in the 5.13 kernel.
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Re
break
userspace, so we are changing the parameters passed to request_irq()
Suggested-by: Ian Abbott
Signed-off-by: Tong Zhang
---
drivers/staging/comedi/drivers/das800.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/comedi/drivers/das800.c
b/drivers/st
e argument of request_irq(), but that is "cio-das802/16" for one
of the boards supported by the driver.
On Mon, Mar 15, 2021 at 6:48 AM Ian Abbott wrote:
On 15/03/2021 10:44, Ian Abbott wrote:
On 14/03/2021 03:57, Tong Zhang wrote:
request_irq() wont accept a name which contains slash s
:
[1.574722] proc_mkdir+0x18/0x20
[1.576629] request_threaded_irq+0xfe/0x160
[1.576859] auto_attach+0x60a/0xc40 [cb_pcidas64]
Suggested-by: Ian Abbott
Signed-off-by: Tong Zhang
---
v2: revert changes to .name field so that we dont break userspace
drivers/staging/comedi/drivers/cb
:
[1.639976] proc_mkdir+0x18/0x20
[1.641946] request_threaded_irq+0xfe/0x160
[1.642186] cb_pcidas_auto_attach+0xf4/0x610 [cb_pcidas]
Suggested-by: Ian Abbott
Signed-off-by: Tong Zhang
---
v2: revert changes to .name field so that we dont break userspace
drivers/staging/comedi/drivers/
.name = "pci-das1602/16/jr",
> + .name = "pci-das1602-16-jr",
> .ai_speed = 5000,
> .fifo_size = 512,
> .is_16bit = 1,
>
As for cb_pcidas64, the board n
On 15/03/2021 10:44, Ian Abbott wrote:
> On 14/03/2021 03:57, Tong Zhang wrote:
>> request_irq() wont accept a name which contains slash so we need to
>> repalce it with something else -- otherwise it will trigger a warning
>> and the entry in /proc/irq/ will not be create
static const struct pcidas64_board pcidas64_boards[] = {
> .has_8255 = 0,
> },
> [BOARD_PCIDAS4020_12] = {
> - .name = "pci-das4020/12",
> + .name = "pci-das4020-12",
> .
h" handler `dt2814_detach()` to do that if an interrupt handler
has been set up. (There is no need to do it if no interrupt handler was
set up because Comedi asynchronous command support is disabled in that
case.)
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2814.c | 15 +
and remove the definition of `struct
dt2814_private` since they are no longer needed.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2814.c | 12
1 file changed, 12 deletions(-)
diff --git a/drivers/staging/comedi/drivers/dt2814.c
b/drivers/staging/comedi/drivers/dt281
n the
Control register, leaving the current channel selected.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2814.c | 72 ++---
1 file changed, 65 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/comedi/drivers/dt2814.c
b/drivers/staging/comedi/
nish and then clears any unread data or error
condition. A non-zero return value from `dt2814_ai_clear()` indicates a
time-out while waiting for the A/D converter to become non-busy. Return
an error in that case.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2814.c | 5 +---
functions for handling Comedi read instructions and for setting up
asynchronous commands now call `dt2814_ai_clear()` to wait for and
discard any spurious A/D conversion, let's remove that code from the
interrupt handler.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2814.c
r the stale data.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2814.c | 39 +
1 file changed, 39 insertions(+)
diff --git a/drivers/staging/comedi/drivers/dt2814.c
b/drivers/staging/comedi/drivers/dt2814.c
index bd329d7b4893..7e73aa094eea 100644
--- a/dr
The DT2814 board is an old analog-to-digital ISA card supported by the
Comedi "dt2814" driver. The board has a timed acquisition mode, and an
end-of-conversion interrupt. The interrupt can be disabled by removing
the jumper that sets the IRQ level. In Comedi, the board is a manually
configured "
ess of a 32-bit integer `&s->state`. On bigendian machines, this
will copy 2 bytes from the wrong end of the 32-bit integer. This isn't
really a problem since `s->state` will always be 0 for this subdevice,
but clean it up by using a 16-bit variable initialized to 0 to pass the
val
ess of a 32-bit integer `&s->state`. On bigendian machines, this
will copy 2 bytes from the wrong end of the 32-bit integer. This isn't
really a problem since `s->state` will always be 0 for this subdevice,
but clean it up by using a 16-bit variable initialized to 0 to pass the
val
ess of a 32-bit integer `&s->state`. On bigendian machines, this
will copy 2 bytes from the wrong end of the 32-bit integer. This isn't
really a problem since `s->state` will always be 0 for this subdevice,
but clean it up by using a 16-bit variable initialized to 0 to pass the
val
address of a 32-bit integer `&s->state`. On bigendian machines, this
will copy 2 bytes from the wrong end of the 32-bit integer. This isn't
really a problem since `s->state` will always be 0 for this subdevice,
but clean it up by using a 16-bit variable initialized to 0 to pass
o 0 to pass the value.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/amplc_pc236_common.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/comedi/drivers/amplc_pc236_common.c
b/drivers/staging/comedi/drivers/amplc_pc236_common.c
index 043752663
i: pcl818: introduce
pcl818_ai_write_sample()").]
Fixes: d615416de615 ("staging: comedi: pcl818: introduce
pcl818_ai_write_sample()")
Cc: # 4.0+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/pcl818.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/driv
value. Fix it by changing the type of the variable
holding the sample value to `unsigned short`.
Fixes: 1f44c034de2e ("staging: comedi: pcl711: use comedi_buf_write_samples()")
Cc: # 3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/pcl711.c | 2 +-
1 file changed, 1
value. Fix it by changing the type of the variable
holding the sample value to `unsigned short`.
Fixes: de88924f67d ("staging: comedi: me4000: use comedi_buf_write_samples()")
Cc: # 3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/me4000.c | 2 +-
1 file changed, 1
t 0c0eadadcbe6e
("staging: comedi: dmm32at: introduce dmm32_ai_get_sample()").]
Fixes: 0c0eadadcbe6e ("staging: comedi: dmm32at: introduce
dmm32_ai_get_sample()")
Cc: # 3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dmm32at.c | 2 +-
1 file changed, 1 inse
value. Fix it by changing the type of the variable
holding the sample value to `unsigned short`.
Fixes: d1d24cb65ee3 ("staging: comedi: das6402: read analog input samples in
interrupt handler")
Cc: # 3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/das6402.c | 2 +-
1
Cc: #4.0+
Signed-off-by: Ian Abbott
---
.../staging/comedi/drivers/addi_apci_1500.c| 18 +-
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/drivers/staging/comedi/drivers/addi_apci_1500.c
b/drivers/staging/comedi/drivers/addi_apci_1500.c
index 11efb21555e3..b04c15dcf
value. Fix it by changing the type of the variable
holding the sample value to `unsigned short`.
Fixes: ad9eb43c93d8 ("staging: comedi: das800: use comedi_buf_write_samples()"
Cc: # 3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/das800.c | 2 +-
1 file changed, 1
short` since its address is passed to
`pci1710_ai_read_sample()`.
Fixes: a9c3a015c12f ("staging: comedi: adv_pci1710: use
comedi_buf_write_samples()")
Cc: # 4.0+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/adv_pci1710.c | 10 +-
1 file changed, 5 insertions(
rom the wrong end of the 32-bit integer. Fix it by transferring
the value via a 16-bit integer.
Fixes: 6bb45f2b0c86 ("staging: comedi: addi_apci_1032: use
comedi_buf_write_samples()"
Cc: # 3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/addi_apci_1032.c | 4 +++-
The `comedi_buf_read_samples()` and `comedi_buf_write_samples()`
functions can read/write either 16-bit or 32-bit values from/to the
Comedi buffer used for Comedi asynchonous command data. The width of
the value depends on whether the subdevice sets the `SDF_LSAMPL` flag
(indicating 32-bit samples
mmands in this driver has always been broken. I'm
tempted to remove the code for handling asynchronous commands in this
driver altogether for that reason. (The naive fix of writing the data
to the Comedi buffer is insufficient without an additional check that
the command is running. The end-
ically typed
members, which would look a bit odd. The union also kind of hides the
problem.
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Regd. addr.: S11 & 12 Building 67, Europa Business Pa
EN);
> + strscpy(devinfo.driver_name, dev->driver->driver_name, COMEDI_NAMELEN);
> + strscpy(devinfo.board_name, dev->board_name, COMEDI_NAMELEN);
>
> s = comedi_file_read_subdevice(file);
> if (s)
>
Thanks, but you are too late. It has already been fixe
the removal of the unused
`data` and `data_len` members (which need to be kept in the user version
of the struct for compatibility reasons).
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Regd. addr.: S11 & 12 Building
e3 ("staging: comedi: comedi_fops.c: added casts to get rid of
sparse warnings") by B K Karthik.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=9d5d041eebe3dcf7591ff7004896c329eb841ca6
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in
acros in constant expressions.
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Regd. addr.: S11 & 12 Building 67, Europa Business Park, )=-
-=( Bird Hall Lane, STOCKPORT, SK3
of the asynchronous command for the subdevice, using
the `CR_INVERT` bit of `scan_begin_arg` to indicate falling edge when
set, or rising edge when clear. Also allow the `CR_EDGE` bit to be set,
but ignore it. All other bits of `scan_begin_arg` must be zero.
Signed-off-by: Ian Abbott
---
drivers
lated digital inputs. For IDI0 and IDI1, use the 16 isolated
digital inputs.)
Currently, only rising edge triggers are supported. Support could be
added for the PCI-1733 and PCI-1736.
Signed-off-by: Bernd Harries
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/adv_pci_dio.c
from
myself (Ian Abbott). My changes have bene tested by Bernd.
The second patch allows the comedi asynchronous command to choose either
the rising edge or the falling edge of the external digital input as the
trigger source.
1) staging: comedi: adv_pci_dio: Add interrupt handling for PCI-1
They all have two interrupt sources, although for PCI-7233
each interrupt source is triggered by a change of state of 16 digital
inputs (0-15 and 16-31). The "clear IRQ" register is at a different
offset for some boards.
Signed-off-by: Bernd Harries
Signed-off-by: Ian Abbott
--
: 04b565021a83 ("comedi: Humusoft MF634 and MF624 DAQ cards driver")
Cc: # v4.4+
Cc: Rostislav Lisovy
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/mf6x4.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/comedi/drivers/mf6x4.c
b/drive
On 02/11/2020 11:16, Ian Abbott wrote:
On 02/11/2020 10:25, Ian Abbott wrote:
On 29/10/2020 14:18, Ian Abbott wrote:
Commit eddd2a4c675c ("staging: comedi: cb_pcidas: refactor
write_calibration_bitstream()") inadvertently removed one of the
`udelay(1)` calls when writing to the c
On 02/11/2020 10:25, Ian Abbott wrote:
On 29/10/2020 14:18, Ian Abbott wrote:
Commit eddd2a4c675c ("staging: comedi: cb_pcidas: refactor
write_calibration_bitstream()") inadvertently removed one of the
`udelay(1)` calls when writing to the calibration register in
`cb_pcidas_c
On 29/10/2020 14:18, Ian Abbott wrote:
Commit eddd2a4c675c ("staging: comedi: cb_pcidas: refactor
write_calibration_bitstream()") inadvertently removed one of the
`udelay(1)` calls when writing to the calibration register in
`cb_pcidas_calib_write()`. Reinstate the delay. It may se
oked
like the most likely culprit.
Fixes: eddd2a4c675c ("staging: comedi: cb_pcidas: refactor
write_calibration_bitstream()")
Cc:
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/cb_pcidas.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/staging/comedi/drivers/cb
d to set it. This limits commands to use a single
channel (either channel 0 or 1), but the limit should be two channels.
Set the AO subdevice's `len_chanlist` member to be the same value as the
`n_chan` member, which will be 2.
Cc:
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/dri
---
Changes since v1:
- Corrected wrongly inverted tests. Feedback from Ian Abbott.
- Note:
This patch was sent earlier as part of a patch set containing 2
patches. The second patch of the patch set is dropped. Hence
sending this standalone patch as v2 version. This is based
On 19/10/2020 12:49, Deepak R Varma wrote:
On Mon, Oct 19, 2020 at 12:34:15PM +0100, Ian Abbott wrote:
On 19/10/2020 11:57, Deepak R Varma wrote:
On Mon, Oct 19, 2020 at 12:41:14PM +0200, Julia Lawall wrote:
On Mon, 19 Oct 2020, Ian Abbott wrote:
On 18/10/2020 20:49, Deepak R Varma wrote
On 19/10/2020 11:57, Deepak R Varma wrote:
On Mon, Oct 19, 2020 at 12:41:14PM +0200, Julia Lawall wrote:
On Mon, 19 Oct 2020, Ian Abbott wrote:
On 18/10/2020 20:49, Deepak R Varma wrote:
Instructions split on multiple lines can be combined on a single line
for improved readability of the
nittest(!route_register_is_valid(9, O(8), T), "find last source");
}
void test_ni_check_trigger_arg(void)
Is it worth breaking the 80-column limit for this?
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Regd. add
),
"find last source");
}
NAK.
It looks like you have inadvertently inverted some of the tests.
--
-=( Ian Abbott || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Regd. addr.: S11 & 12 Building 67, Europa Busine
* require multiple reads on the status register to achieve this).
+* multiple reads on the status register to achieve this).
*/
while (--loops) {
status = inb(dev->iobase + DAQP_STATUS_REG);
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is
code to deal with this.
Fixes: 1e15687ea472 ("staging: comedi: addi_apci_1564: add Change-of-State
interrupt subdevice and required functions"
Cc: #3.17+
Signed-off-by: Ian Abbott
---
.../staging/comedi/drivers/addi_apci_1564.c | 20 +--
1 file changed, 14 insert
e less than that and everything from bit 24 upwards is
ignored by `ni6527_set_edge_detection()` anyway.
Fixes: 110f9e687c1a8 ("staging: comedi: ni_6527: support
INSN_CONFIG_DIGITAL_TRIG")
Cc: # 3.17+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ni_6527.c | 2 +-
1 file chang
code to deal with this.
Fixes: 33cdce6293dcc ("staging: comedi: addi_apci_1032: conform to new
INSN_CONFIG_DIGITAL_TRIG"
Cc: #3.8+
Signed-off-by: Ian Abbott
---
.../staging/comedi/drivers/addi_apci_1032.c | 20 +--
1 file changed, 14 insertions(+), 6 deletions(-)
di
")
Cc: #4.0+: ef75e14a6c93: staging: comedi: verify array
index is correct before using it
Cc: #4.0+
Signed-off-by: Ian Abbott
---
.../staging/comedi/drivers/addi_apci_1500.c | 24 +++
1 file changed, 19 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/come
These patches correct problems with INSN_CONFIG_DIGITAL_TRIG comedi
configuration instructions in various comedi drivers, in particular the
use of unconstrained bit shift amounts from userspace leading to
undefined behaviour (although hopefully not the kernel crashy sort).
The patches have been ma
t((unsigned int __user *)cmd->chanlist);
v32.chanlist_len = cmd->chanlist_len;
v32.data = ptr_to_compat(cmd->data);
v32.data_len = cmd->data_len;
Still looks good.
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a
ser *)cmd->chanlist);
v32.chanlist_len = cmd->chanlist_len;
v32.data = ptr_to_compat(cmd->data);
v32.data_len = cmd->data_len;
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=(
chanlist);
Those changes will get rid of the sparse warnings.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15 West Park Road
, S626_DMABUF_SIZE,
+ devpriv->ana_buf.logical_base,
+ devpriv->ana_buf.physical_base);
}
static int s626_initialize(struct comedi_device *dev)
Looks good to me.
Reviewed-by: Ian Abbott
--
-=( Ian Abbott ||
could be done as a
follow-up patch, or done in a v2 of this patch with a mention in the
patch description.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15 West Park R
e '} else {' part that follows
this part.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15 West Park Road, Bramhall, STOCKPORT, SK7 3JZ, UK. )=-
_
pt = devpriv->pt[trig] & old_mask;
+ pp = devpriv->pp[trig] & old_mask;
+
switch (data[2]) {
case COMEDI_DIGITAL_TRIG_DISABLE:
/* clear trigger configuration */
Nice catch!
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk
*file)
}
cfp = kzalloc(sizeof(*cfp), GFP_KERNEL);
- if (!cfp)
+ if (!cfp) {
+ comedi_dev_put(dev);
return -ENOMEM;
+ }
cfp->dev = dev;
Thanks for spotting that!
Signed-off-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.u
river.
Also add a "FIXME" comment about setting bit 0 of the low byte of the
command. Supposedly, it is used to choose between voltage output and
current output, but the current driver always sets it to 1.
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt2815.c | 3 +++
it has never written the 'hi' value to the hardware!
I think I know how to fix it. I'll send a patch.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15 West
ively.
Cc: Éric Piel
Cc: Spencer E. Olson
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ni_pcimio.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/staging/comedi/drivers/ni_pcimio.c
b/drivers/staging/comedi/drivers/ni_pcimio.c
index 14b26fffe049..7c82d5f9778f 10
on
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ni_660x.c | 2 +-
.../staging/comedi/drivers/ni_mio_common.c| 2 +-
drivers/staging/comedi/drivers/ni_routes.c| 21 +--
drivers/staging/comedi/drivers/ni_routes.h| 1 +
4 files changed, 22 insert
We do not have or provide routing information for all supported NI
boards. Some of the boards for which we currently provide routing
information actually have identical routes to similar boards for which
we do provide routing information. Rather than duplicating the routing
data for such boards (
ions above return `NULL` if the information is not found (as we
do not currently have the routing information available for all
supported boards).
Cc: Éric Piel
Cc: Spencer E. Olson
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ni_routes.c | 44 +-
1 file c
`alt_route_name` member value to `ni_assign_device_routes()` as the
`alt_board_name` parameter, which it will use if no routing information
could be found for the actual board name.
Cc: Éric Piel
Cc: Spencer E. Olson
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ni_mio_common.c | 3
ssing routing
information.
Fixes: 347e244884c3 ("staging: comedi: tio: implement global tio/ctr routing")
Fixes: 56d0b826d39f ("staging: comedi: ni_mio_common: implement new routing for
TRIG_EXT").
Cc: # 4.20+
Cc: Spencer E. Olson
Signed-off-by: Ian Abbott
---
drivers/
addressed by another patch.
Fixes: 4bb90c87abbe ("staging: comedi: add interface to ni routing table
information")
Cc: # 4.20+
Cc: Spencer E. Olson
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ni_routes.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/
Fix some regressions resulting from the routing functionality
implemented for the National Instruments comedi drivers in kernel 4.20
when board-specific routing information is absent.
Patch 1 fixes a null pointer dereference, but the set-up of asynchronous
commands that use external triggers on bo
channel numbers will have been range checked already,
so the bit-mask isn't really needed.
Fixes: 92c65e5553ed ("staging: comedi: adv_pci1710: define the mux control
register bits")
Reported-by: Dmytro Fil
Cc: # v4.5+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/ad
#4.6+
Signed-off-by: Ian Abbott
---
Note: Bug is also present in kernel 4.5 and earlier, but the patch will
not apply cleanly to those (the gsc_hpdi driver used to call
`pci_alloc_consistent()` instead of `dma_alloc_coherent()`).
---
drivers/staging/comedi/drivers/gsc_hpdi.c | 10 ++
does not check whether any
of the calls to dma_alloc_coherent() returned NULL. If any of the calls
to dma_alloc_coherent() returns NULL, gsc_hpdi_auto_attach() needs to
return an error (-ENOMEM). The subsequent call to gsc_hpdi_detach()
will then free whatever DMA coherent buffers where allocat
egacy_minors" parameter defaults
to zero.
I'm happy with the change of behaviour, but would suggest changing the
'pr_warn()' calls to 'pr_err()' to match this change.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=
t rounding error" can therefore be dropped.
I guess this can be applied to stable to fix problems with round-trip
rounding. If so, the following can be added:
Cc: # 4.4+
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a
mp;cmd->stop_arg, 1);
The actual patch looks good. A 'Cc:' line for "stable" kernel versions
4.4 and later could be added:
Cc: # 4.4+
Please mark the updated patch as '[PATCH v2]' in the subject. Tha
er uapi headers (mainly
in netfilter stuff), so I guess it's OK. However, it does mean that
user code that uses these macros will no longer compile unless GNU
extensions are enabled.
Does anyone know any "best practices" regarding use of GNU extensions in
user header file
(lo >> 4);
+ inb(dev->iobase + DT2814_DATA);
+ inb(dev->iobase + DT2814_DATA);
if (!(--devpriv->ntrig)) {
int i;
Those variables are currently unused due to a bug that I need to fix.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( ME
Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15 West Park Road, Bramhall, STOCKPORT, SK7 3JZ, UK. )=-
___
devel mai
t; insn->n; i++)
data[i] = dt3k_readsingle(dev, DPR_SUBSYS_AI, chan, gain);
--
2.7.4
That looks fine, thanks.
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862
i = (data[i] & 0xff0) >> 4;
ret = comedi_timeout(dev, s, insn, dt2815_ao_status, 0x00);
if (ret)
--
2.7.4
There is something fishy going on in this one too. It should be writing
the 'hi' value to the card registers.
Please could you omit this pa
the data to a buffer.
Can I suggest omitting this patch from the series so I can investigate
and supply a proper fix?
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered addr
(driv->module);
1002 }
1003 /* On success, the driver module count has been incremented. */
Yes, everything should be freed properly by comedi_device_detach().
From comedi_device_detach(), some of the stuff is freed by
dev->driver->detach(), and the remainde
x2delay = 255;
+ int fx2delay;
if (period < MIN_PWM_PERIOD)
return -EAGAIN;
Looks fine, thanks!
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268.
"improvement".
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/dt3000.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/comedi/drivers/dt3000.c
b/drivers/staging/comedi/drivers/dt3000.c
index 2edf3ee91300..8621e3833ad5 100644
--- a
f this calculation in the same
function.
Reported-by: David Binderman
Cc:
Signed-off-by: Ian Abbott
---
N.B. Greg: The original report suggested an actual build error, so
may be prudent to queue this on your 'staging-linus' queue.
drivers/staging/comedi/drivers/dt3000.c | 2 +-
1 file chan
o use longs.
It wouldn't do any harm to change the `int` variables to `unsigned int`.
Regards
David Binderman
time-_Base seems to be 50 or 100.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 028
file changed, 10 insertions(+), 17 deletions(-)
And this one looks good too, thanks!
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15 West
.
drivers/staging/comedi/drivers/amplc_dio200_common.c | 8 +---
1 file changed, 1 insertion(+), 7 deletions(-)
This one looks good too, thanks!
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Regist
/staging/comedi/drivers/amplc_dio200_common.c | 8 +---
1 file changed, 1 insertion(+), 7 deletions(-)
Looks good, thanks!
Reviewed-by: Ian Abbott
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 0286
staging: comedi: dt282x: use comedi_handle_events()")
Cc: # v3.19+
Signed-off-by: Ian Abbott
---
Note: A similar patch will be required for stable v3.16.x, but that
calls cfc_handle_events() instead of comedi_handle_events().
---
drivers/staging/comedi/drivers/dt282x.c | 3 ++-
1 file changed, 2 i
and `pci230_handle_ao_fifo(dev,
s_ao);` will never be reached for a PCI260, so they are safe.
Fixes: 39064f23284c ("staging: comedi: amplc_pci230: use
comedi_handle_events()")
Cc: # v3.19+
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/drivers/amplc_pci230.c | 3 ++-
1 file changed, 2 insertions(+
which case it doesn't need to be
marked as Reserved.
Thanks for the hint. I'll take a look at that.
--
-=( Ian Abbott || Web: www.mev.co.uk )=-
-=( MEV Ltd. is a company registered in England & Wales. )=-
-=( Registered number: 02862268. Registered address:)=-
-=( 15
On 25/06/2019 12:47, Dan Carpenter wrote:
On Tue, Jun 25, 2019 at 12:26:59PM +0100, Ian Abbott wrote:
drivers/staging/comedi/comedi_buf.c | 150 ++-
drivers/staging/comedi/comedi_fops.c | 39 ---
2 files changed, 125 insertions(+), 64 deletions(-)
diff --git a
reserved, and no longer vmap's
the DMA coherent memory pages (since they are contiguous anyway).
Cc: Christoph Hellwig
Signed-off-by: Ian Abbott
---
drivers/staging/comedi/comedi_buf.c | 150 ++-
drivers/staging/comedi/comedi_fops.c | 39 ---
2 files chang
1 - 100 of 2388 matches
Mail list logo