On 2014-04-15 06:53, Chase Southwood wrote:
devpriv->iobase is currently being used to hold the iobase address used to
read/write the board's registers. The same address is stored in the
comedi_device dev->iobase. We use that instead. The eventual goal is to
decrease the driver's use of the st
On Mon, Apr 14, 2014 at 03:17:19PM -0400, Mark Hounschell wrote:
> On 04/14/2014 11:49 AM, Greg Kroah-Hartman wrote:
> > On Tue, Mar 25, 2014 at 04:38:14PM -0400, Mark Hounschell wrote:
> >> The config file is currently read for each board found.
> >> It only needs to be read one time. The buffer i
Add __user to binder_version to correct sparse warning.
Reduce line size to fit to coding style.
Signed-off-by: Mathieu Maret
---
drivers/staging/android/binder.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/android/binder.c b/drivers/staging/androi
On 2014-04-15 06:54, Chase Southwood wrote:
We can remove this function from the boardinfo and move the code from
hwdrv_apci1564.c into addi_apci_1564.c since it is the only reset function
used by the driver. The function was also messy and failed to reset a few
registers, these issues were fixe
Remove duplicate code
Signed-off-by: Mathieu Maret
---
drivers/staging/android/binder.c | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/android/binder.c b/drivers/staging/android/binder.c
index 3dca577..c29c3c7 100644
--- a/drivers/staging/android/binde
This is the first time you have sent it to the list, it's not a RESEND.
Patch looks ok.
regards,
dan carpenter
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
On Tue, Apr 15, 2014 at 12:03:06PM +0200, Mathieu Maret wrote:
> Remove duplicate code
>
The original code is simpler actually.
regards,
dan carpenter
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/
On 04/15/2014 06:01 AM, Dan Carpenter wrote:
> On Mon, Apr 14, 2014 at 03:17:19PM -0400, Mark Hounschell wrote:
>> On 04/14/2014 11:49 AM, Greg Kroah-Hartman wrote:
>>> On Tue, Mar 25, 2014 at 04:38:14PM -0400, Mark Hounschell wrote:
The config file is currently read for each board found.
Dan Carpenter wrote:
> This is the first time you have sent it to the list, it's not a RESEND.
>
The first one was only on the linux-kernel mailing list.
May be, that's why you did not get it.
As it was just before the 3.14 release, I was asked to resend latter.
Is it the expected meaning of the
On Tue, Apr 15, 2014 at 02:04:50PM +0200, Mathieu Maret wrote:
> Dan Carpenter wrote:
> > This is the first time you have sent it to the list, it's not a RESEND.
> >
> The first one was only on the linux-kernel mailing list.
Oh. No one reads lkml. It's just for the google archive.
regards,
dan
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
Async commands are passed from user space to the drivers by the comedi core.
The triggers and arguments for the command is passed in a struct comedi_cmd
that is initially validated by the core then validated by the drivers in the
subdevice (*do_cmdtest) function. If the validation succeeds, the com
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
The comedi core checks if the (cmd->chanlist_len > s->len_chanlist) when the
comedi_cmd is copied from user to kernel space by __comedi_get_user_cmd().
If so, the core returns -EINVAL and will not call the subdevice (*do_cmdtest)
and (*do_cmd).
Remove the unnecessary "max" checks in the comedi dri
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
The async command 'arguments' should be trivially validated in Step 3 of
the (*do_cmdtest) not Step 2b. Move the validataion in this driver to the
proper place.
This driver supports two cmd->start_src values, TRIG_NOW and TRIG_EXT.
TRIG_NOW sources should always have an arg of 0. The arg for TRIG_
This driver supports two cmd->start_src values, TRIG_NOW and TRIG_INT. TRIG_NOW
sources should always have an arg of 0. For TRIG_INT sources, the cmd->start_arg
is actually the valid trig_num that is passed to the async (*inttrig) callback.
This driver trivially validates the arg for both sources t
When the async command 'scan_end_src' is TRIG_COUNT the 'scan_end_arg' is
the cmd->chanlist_len.
The core will initialize the s->len_chanlist to 1 if the driver does not
set it. Fix a couple open-coded drivers and make sure they have the
s->len_chanlist initialized.
Add the necessary check to the
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
The comedi_subdevices array is kzalloc()'d so the async command callbacks do
not need to be set to NULL when the analog output subdevice is initialized.
Also, remove the initialzation of the subdevice 'len_chanlist' since this
value is only used by the async commands. The core will default it to 1
The cmd->start_arg should be trivially validated in Step 3 of the
(*do_cmdtest) functions. Add the necessary code.
For the analog output, a cmd->start_src of TRIG_NOW and TRIG_INT is
supported. For both sources the cmd->start_arg is validated to be 0.
For a TRIG_INT source, the cmd->start_Arg is a
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
This is the Step 5 helper function of the (*do_cmdtest). It validates that
the chanlist, chan/range/aref/etc, is compatible with the actual hardware.
At this point in the (*do_cmdtest) the chanlist is valid, due to checks in
the core, so any sanity checks are not needed.
For aesthetics, rename thi
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
This is the Step 5 helper function of the (*do_cmdtest). It validates that
the chanlist, chan/range/aref/etc, is compatible with the actual hardware.
At this point in the (*do_cmdtest) the chanlist is valid, due to checks in
the core, so any sanity checks are not needed.
For aesthetics, rename thi
Due to a driver limitation, the (*do_cmdtest) for the analog input subdevice
overrides the cmd->chanlist_len to force single channel chanlists. But, the
cmd->scan_end_arg was already validated before this happens. Instead of
fixing the (*do_cmdtest) just set the subdevice len_chanlist to 1 to limit
This step of the (*do_cmdtest) verifies that the selected trigger sources
are mutually compatible.
For this driver the scan_begin_src must be TRIG_FOLLOW or the same source
as the convert_src.
Simplify the logic to clarify this.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Ha
This driver supports a cmd->start_src of TRIG_NOW or TRIG_INT. The
cmd->start_arg is trivially validated for both sources to be 0.
For a TRIG_INT source, the cmd->start_arg is actually the valid
trig_num that is used by the async (*inttrig) callback.
Refactor the (*inttrig) function so that the c
This function is just a wrapper around i8253_cascade_ns_to_timer().
Remove it.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/amplc_pci224.c | 24 +++-
1 file changed, 7 insertions(+), 17 deletions(-)
diff --git a/
Clarify the cmd->start_arg validation in Step 3 of the (*do_cmdtest)
functions.
For a TRIG_INT source, the cmd->start_arg is actually the valid
trig_num that is used by the async (*inttrig) callbacks.
Refactor the (*inttrig) functions so that the cmd->start_arg is used
to check the trig_num inste
To clarify the analog output (*do_cmd) function, factor out the
code that starts the pacer.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/amplc_pci224.c | 142 +-
1 file changed, 73 insertions(+), 69 deletions(
The only time the chanlist can be NULL and chanlist_len < 1 is when a
COMEDI_CMDTEST ioctl is done, usually for the comedilib function
comedi_get_cmd_src_mask(). This comedilib function sets all the command
sources to TRIG_ANY and Step 1 of the (*do_cmdtest) will fail returning
a the mask of valid
For all cmd->start_src values this driver trivially validates that the
cmd->start_arg is 0.
For a TRIG_INT source, the cmd->start_arg is actually the valid trig_num
that is used by the async (*inttrig) callback.
Refactor the (*inttrig) functions so that the cmd->start_arg is used to
check the tri
This driver supports cmd->start_src values of TRIG_NOW, TRIG_EXT, and
TRIG_INT. Currently the cmd->start_arg is only validated for TRIG_NOW.
For TRIG_EXT sources, the cmd->start_src is driver specific. For a
TRIG_INT source, the cmd->start_arg is actually the valid trig_num
that is used by the asy
This driver supports a cmd->start_src of TRIG_NOW, TRIG_INT or TRIG_EXT.
Clarify the cmd->start_arg validation in Step 3 of the (*do_cmdtest).
For a TRIG_INT source, the cmd->start_arg is actually the valid
trig_num that is used by the async (*inttrig) callback.
Refactor the (*inttrig) function
This driver trivially validates the cmd->start_arg for all cmd->start_src values
to be 0. For TRIG_INT source, the cmd->start_arg is actually the valid trig_num
that is passed to the async (*inttrig) callback.
Refactor the (*inttrig) functions so that the cmd->start_arg is used to check
the
trig_
This test is unnecessary. It covers all the possible combinations of the
scan_end_src and stop_src triggers so the final else can never be reached.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/me4000.c | 11 ---
1 file change
The 8254 timers are only used in this driver to generate the analog
output pacer. To simplify the driver, always cascade the timers.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/amplc_pci224.c | 123 ++
1 file
For aesthetics, rename the local variable 'error' to 'err'. This is the
normal name for this local variable in (*do_cmdtest) functions.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/adl_pci9111.c | 59 +---
1 f
This driver supports a cmd->start_src of TRIG_NOW or TRIG_INT. The
cmd->start_arg is trivially validated for both sources to be 0.
For a TRIG_INT source, the cmd->start_arg is actually the valid
trig_num that is used by the async (*inttrig) callback.
Refactor the (*inttrig) function so that the c
The cmd->start_arg should be trivially validated in Step 3 of the
(*do_cmdtest) functions. Add the necessary code.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/gsc_hpdi.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/st
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
For both ai and ao commands this driver supports a cmd->start_src of
TRIG_NOW or TRIG_INT. The cmd->start_arg is trivially validated for
both sources to be 0.
For a TRIG_INT source, the cmd->start_arg is actually the valid
trig_num that is used by the async (*inttrig) callback.
Refactor the (*int
This test is unnecessary. The cfc_check_trigger_src() in Step 1 ensures that
the trigger source is one of these values and Step 2 makes sure it's only one
of these values.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/cb_pcidas64.c |
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
This driver only supports a cmd->start_src of TRIG_INT for ao commands. The
cmd->start_arg is trivially validated to be 0. For TRIG_INT source, the
cmd->start_arg is actually the valid trig_num that is passed to the async
(*inttrig) callback.
Refactor the (*inttrig) function so that the cmd->start
The cmd->start_arg should be trivially validated in Step 3 of the
(*do_cmdtest) functions. Add the necessary code.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/me4000.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/st
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
This driver supports three cmd->start_src values, TRIG_NOW, TRIG_EXT, and
TRIG_INT. TRIG_NOW sources should always have an arg of 0 and arg for TRIG_EXT
sources is driver specific. This driver does not use the cmd->start_arg with
the TRIG_EXT source so a trivial value of 0 is good.
When the cmd->s
This driver only supports a cmd->start_src of TRIG_INT for ai commands. The
cmd->start_arg is trivially validated to be 0. For TRIG_INT source, the
cmd->start_arg is actually the valid trig_num that is passed to the async
(*inttrig) callback.
Refactor the (*inttrig) function so that the cmd->start
Step 5 of the (*do_cmdtest) validates that the chanlist, chan/range/aref/etc,
is compatible with the actual hardware. At this point in the (*do_cmdtest)
the chanlist is valid, due to checks in the core, so the sanity check is not
needed.
For aesthetics, factor the step 5 code into a helper functio
This driver supports two cmd->start_src values, TRIG_NOW and TRIG_EXT.
For aesthetics, replace the default case when validating the cmd->start_arg
with the proper case statement.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/cb_pcida
When the cmd->scan_begin_src == TRIG_TIMER the divisors needed to
generate the pacer time are calculated in the (*do_cmdtest) to
validate the cmd->scan_begin_arg. The core always does the
(*do_cmdtest) before the (*do_cmd) so there is no reason to recalc
the divisors.
Signed-off-by: H Hartley Swee
This driver supportes cmd->start_src sources of TRIG_NOW, TRIG_INT, TRIG_OTHER,
and TRIG_EXT. Refactor the (*do_cmdtest) to clarify the trivial validation of
the cmd->start_arg. For a TRIG_INT source, the cmd->start_arg is actually the
valid trig_num that is passed to the async (*inttrig) callback.
This driver only a cmd->start_src of TRIG_NOW or TRIG_INT. The cmd->start_arg
is trivially validated for both sources to be 0. For a TRIG_INT source, the
cmd->start_arg is actually the valid trig_num that is passed to the async
(*inttrig) callback.
Refactor the (*inttrig) function so that the cmd-
This driver supports two cmd->start_src values, TRIG_INT and TRIG_EXT. For
TRIG_INT sources, the cmd->start_arg is actually the valid trig_num that is
passed to the async (*inttrig) callback. This driver trivially validates the
arg for this source to be 0.
Refactor the (*inttrig) so that the cmd->
This driver supports cmd->start_src sources of TRIG_NOW and TRIG_EXT. Refactor
the (*do_cmdtest) to clarify the trivial validation of the cmd->start_arg.
Signed-off-by: H Hartley Sweeten
Cc: Ian Abbott
Cc: Greg Kroah-Hartman
---
drivers/staging/comedi/drivers/ni_labpc.c | 8 +++-
1 file ch
Signed-off-by: Pascal COMBES
---
Description in subject.
diff --git a/drivers/staging/crystalhd/crystalhd_lnx.c
b/drivers/staging/crystalhd/crystalhd_lnx.c
index 20be957..fd7f08a 100644
--- a/drivers/staging/crystalhd/crystalhd_lnx.c
+++ b/drivers/staging/crystalhd/crystalhd_lnx.c
@@ -112,7 +112
Removed useless (because automatic) cast from void * in crystalhd_lnx.c
Signed-off-by: Pascal COMBES
---
diff --git a/drivers/staging/crystalhd/crystalhd_lnx.c
b/drivers/staging/crystalhd/crystalhd_lnx.c
index fd7f08a..0e432bc 100644
--- a/drivers/staging/crystalhd/crystalhd_lnx.c
+++ b/drivers/
Replace sizeof(type) by sizeof(variable) in crystalhd_lnx.c.
Signed-off-by: Pascal COMBES
---
diff --git a/drivers/staging/crystalhd/crystalhd_lnx.c
b/drivers/staging/crystalhd/crystalhd_lnx.c
index 0e432bc..e6fb331 100644
--- a/drivers/staging/crystalhd/crystalhd_lnx.c
+++ b/drivers/staging/cry
All three look great now.
regards,
dan carpenter
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Fixed line width > 80
Signed-off-by: Thomas Tanaka
---
drivers/staging/dgrp/dgrp_sysfs.c |4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/dgrp/dgrp_sysfs.c
b/drivers/staging/dgrp/dgrp_sysfs.c
index 2f9345f..93803e0c 100644
--- a/drivers/staging/dgrp/dgr
From: Micky Ching
To avoid dead lock, we need make sure host->lock is always acquire
before pcr->lock. But in irq handler, we acquired pcr->lock in rtsx mfd
driver, and sd_isr_done_transfer() is called during pcr->lock already
acquired. Since in sd_isr_done_transfer() the only work we do is schdu
On 04/10/2014 07:56 PM, Greg KH wrote:
> On Thu, Apr 10, 2014 at 07:27:27PM -0400, Marcos A. Di Pietro wrote:
>>> That's pretty obviously not going to apply properly, you have line-wrapp
>>> on. You can't cut-and-paste patches into gmail, see
>>> Documentation/email_clients.txt for details.
>>>
>>
On 04/11/2014 06:36 PM, Oliver Neukum wrote:
On Fri, 2014-04-11 at 11:28 +0100, Lee Jones wrote:
From: Roger Tseng
This patchset adds modules to support Realtek USB vendor specific class flash
card reader: one base module in MFD subsystem and two host modules in both mmc
and memstick subsystem
>On Tuesday, April 15, 2014 5:03 AM, Ian Abbott wrote:
>>On 2014-04-15 06:54, Chase Southwood wrote:
>>We can remove this function from the boardinfo and move the code from
>>hwdrv_apci1564.c into addi_apci_1564.c since it is the only reset function
>>used by the driver. The function was also me
We can remove this function from the boardinfo and move the code from
hwdrv_apci1564.c into addi_apci_1564.c since it is the only reset function
used by the driver. The function was also messy and failed to reset a few
registers, these issues were fixed on the move.
Signed-off-by: Chase Southwood
70 matches
Mail list logo