[PATCH 15/15] staging: comedi: amplc_dio200_common: use 8255 module
Ian Abbott
abbotti at mev.co.uk
Mon Aug 4 18:32:40 UTC 2014
On 04/08/14 17:53, Hartley Sweeten wrote:
> On Monday, August 04, 2014 6:05 AM, Ian Abbott wrote:
>> On 2014-08-01 22:18, H Hartley Sweeten wrote:
>>> This driver currently duplicates the functionality of the 8255 module.
>>> The only difference is in how the i/o access is handled.
>>>
>>> Provide a private (*io) callback for the 8255 module to handle the
>>> differences. We can then use that module and initialize the subdevice
>>> with subdev_8255_init().
>>>
>>> Update the Kconfig to select the COMEDI_8255 module.
>>>
>>> Signed-off-by: H Hartley Sweeten <hsweeten at visionengravers.com>
>>> Cc: Ian Abbott <abbotti at mev.co.uk>
>>> Cc: Greg Kroah-Hartman <gregkh at linuxfoundation.org>
>>
>> I have plans to support some of the enhancements in the PCIe cards,
>> which would mean I can't use the 8255 module. That's one of the reasons
>> I implemented the 8255 functionality directly in the driver (there's not
>> very much anyway). The other was it would have been a bit of a pain as
>> the comedi 'dev' parameter wasn't passed through.
>
> Well, the comedi 'dev' parameter will be passed through after this series
> is applied. Can the additional functionality be handled with just a custom
> (*insn_config)? The pcm2734 does this in order to configure the external
> buffers that are tied to the 8255 device.
I'll probably need to use subdevice private data. Besides, pcm2734 uses
hardly any of the 8255 module. It overrides the insn_config handler, so
about the only part of the 8255 module it uses is the insn_bits handler
- and it has to pass a callback function to use that. Hardly worth it.
>> So I'd prefer to drop this patch so I don't have to undo it later.
>
> Not a problem. I'll drop this one.
Cheers!
--
-=( Ian Abbott @ MEV Ltd. E-mail: <abbotti at mev.co.uk> )=-
-=( Tel: +44 (0)161 477 1898 FAX: +44 (0)161 718 3587 )=-
More information about the devel
mailing list