summaryrefslogtreecommitdiff
path: root/drivers/staging/comedi/drivers/adl_pci9111.c
AgeCommit message (Collapse)Author
2017-11-28staging: comedi: drivers: Remove redundant license textGreg Kroah-Hartman
Now that the SPDX tag is in all comedi files, that identifies the license in a specific and legally-defined manner. So the extra GPL text wording can be removed as it is no longer needed at all. This is done on a quest to remove the 700+ different ways that files in the kernel describe the GPL license text. And there's unneeded stuff like the address (sometimes incorrect) for the FSF which is never needed. No copyright headers or other non-license-description text was removed. Cc: Ian Abbott <abbotti@mev.co.uk> Cc: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-28staging: comedi: add SPDX identifiers to all greybus driver filesGreg Kroah-Hartman
It's good to have SPDX identifiers in all files to make it easier to audit the kernel tree for correct licenses. Update the drivers/staging/comedi files files with the correct SPDX license identifier based on the license text in the file itself. The SPDX identifier is a legally binding shorthand, which can be used instead of the full boiler plate text. This work is based on a script and data from Thomas Gleixner, Philippe Ombredanne, and Kate Stewart. Cc: Ian Abbott <abbotti@mev.co.uk> Cc: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Kate Stewart <kstewart@linuxfoundation.org> Cc: Philippe Ombredanne <pombredanne@nexb.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13staging: comedi: adl_pci9111: fix alignment issueH Hartley Sweeten
Use a local variable for the 'devpriv->ai_bounce_buffer' to shorten the lines in pci9111_handle_fifo_half_full() and gix the checkpath.pl issue about: CHECK: Alignment should match open parenthesis Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13staging: comedi: adl_pci9111: rename CamelCase parametersH Hartley Sweeten
Rename the CamelCase parameters of plx9050_interrupt_control(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13staging: comedi: adl_pci9111: tidy up multi-line commentsH Hartley Sweeten
Reformat the multi-line comments in the kernel CodingStyle. Remove the unnecessary CHANGELOG information, git provided this better. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13staging: comedi: adl_pci9111: define a macro for the ai range bitsH Hartley Sweeten
For aesthetics, define a macro to set the analog input range bits. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-13staging: comedi: adl_pci9111: prefer using the BIT macroH Hartley Sweeten
As suggested by checkpatch.pl, use the BIT macro to define the register bits. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-04-03staging: comedi: adl_pci9111: remove #include "comedi_fc.h"Ian Abbott
As preparation for removal of "comedi_fc.h", replace calls to the `cfc_check_trigger_...` functions from "comedi_fc.h" with the replacement `comedi_check_trigger_...` functions from "../comedidev.h" and remove the inclusion of "comedi_fc.h". Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20staging: comedi: adl_pci9111: include new "comedi_pci.h" headerIan Abbott
Include the new "../comedi_pci.h" header instead of <linux/pci.h> and "../comedidev.h", which will now get included indirectly. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06staging: comedi: drivers/*.c: remove unnecessary blank linesH Hartley Sweeten
Blank lines are not needed before a close brace '}' or after an open brace '{'. Also remove any multiple blank lines. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06staging: comedi: drivers/*.c: alignment should match open parenthesisH Hartley Sweeten
Fix the alignment issues in all the comedi drivers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-01staging: comedi: adl_pci9111: convert driver to use the comedi_8254 moduleH Hartley Sweeten
This driver uses an 8254 timer to generate the pacer clock used for analog input data acquisition. Convert it to use the comedi_8254 module to provide support for the 8254 timer. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-25staging: comedi: drivers: remove inappropriate COMEDI_CB_EOA eventsH Hartley Sweeten
Hardware errors should be reported with the COMEDI_CB_ERROR event. This event will cause the async command to cancel. It's not necessary to also set the COMEDI_CB_EOA event. Remove these events. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: comedi: drivers: have core hook up default (*insn_read) for readbackH Hartley Sweeten
Most of the comedi drivers that provide readback for write only subdevices now use the comedi core comedi_alloc_subdev_readback() helper to allocate the subdevice 'reaback' member instead of using some member in their private data. These drivers also hook up the (*insn_read) callback to the comedi_readback_insn_read() helper to provide the readback. Have the core automatically hook up the (*insn_read) callback after allocating the memory if the driver has not already hooked it up to a private function. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26staging: comedi: adl_pci9111: use comedi_async 'scans_done' to detect EOAH Hartley Sweeten
The comedi core now counts the number of samples added to the async buffer and detects the end-of-scan and increments the comedi_async 'scans_done' counter. Remove the private data member 'stop_counter' and use the 'scans_done' member to detect the end-of-acquisition. This fixes a possible interger overflow when calculating the value of the 'stop_counter' and removes the need to accumulate the 'total' number of samples added to the async buffer in pci9111_handle_fifo_half_full(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-03staging: comedi: adl_pci9111: use sample manipulation helpersH Hartley Sweeten
Use the recently added sample manipulation helpers to remove the hardcoded assumption of the sample size. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-03staging: comedi: drivers: digital output subdevices do not need SDF_READABLEH Hartley Sweeten
The SDF_READABLE flag is not necessary for digital output subdevices. For consistency, remove this flag from the comedi drivers that set it. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-29staging: comedi: adl_pci9111: use comedi_buf_write_samples()H Hartley Sweeten
Use comedi_buf_write_samples() to add the samples to the async buffer. The number of bytes to add is determined automatically based on the number of samples and the bytes_per_sample(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-20staging: comedi: adl_pci9111: use comedi_handle_events()H Hartley Sweeten
cfc_handle_events() is just a wrapper around comedi_handle_events(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-30staging: comedi: comedi_pci: introduce comedi_pci_detach()H Hartley Sweeten
Introduce a generic (*detach) function for comedi PCI drivers to handle the boilerplate code needed to detach a PCI driver. This function works similar to comedi_legacy_detach() where it will: * free the dev->irq if it has been requested * iounmap the dev->mmio addres if it has been ioremap'ed The helper then calls comedi_pci_disable() to release the regions and disable the PCI device. Use the new helper directly for the (*detach) in the following cases: * where comedi_pci_disable() is used directly for the (*detach) * where the detach function is just boilerplate Use the new helper in the (*detach) of the simpler PCI drivers. Call the helper after disabling interrupts (reset) and before any additional cleanup (kfree) to avoid any race conditions with the interrupt handler. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-30staging: comedi: adl_pci9111: use comedi_subdevice 'readback'H Hartley Sweeten
Use the new comedi_subdevice 'readback' member and the core provided (*insn_read) for the readback of the analog output subdevice channels. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-18staging: comedi: adl_pci9111: simplify A/D trigger selection codeH Hartley Sweeten
The functions pci9111_trigger_source_set(), pci9111_pretrigger_set(), and pci9111_autoscan_set() are all used to select the A/D trigger type. They all do a read/mask/set/write of the A/D Trigger Mode Control register. Simplify the code by removing these helper functions and combining all the trigger bits so that a single write can be used to set the register. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-18staging: comedi: adl_pci9111: remove PCI9111_HR_DEVICE_ID defineH Hartley Sweeten
This define is only used in the pci_device_id table and doesn't add any additional clarity to the code. Remove the define and just open code the value. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-18staging: comedi: adl_pci9111: remove PCI9111_DRIVER_NAME defineH Hartley Sweeten
This define is only used in a comedi_error() message. The addition of the driver name to the message is not necessary. Remove the define. For aesthetics, convert the comedi_error() into a dev_dbg(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-28staging: comedi: adl_pci9111: factor fifo handling out of pci9111_interrupt()H Hartley Sweeten
Factor the fifo half-full handling out of the interrupt function to reduce the indent level of the code. Tidy up the factored out code. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-28staging: comedi: adl_pci9111: use comedi_fc helpers to validate timer argsH Hartley Sweeten
Use the comedi_fc helper, cfc_check_trigger_arg_is(), to validate the cmd->convert_arg for the convert_src TRIG_TIMER. Pass the local variable to i8253_cascade_ns_to_timer() instead of the cmd argument. This value is modified by that function to return the actual time (in nanoseconds) that the timer will be programmed with based on the calculated divisors. The cfc_check_trigger_arg_is() helper will then validate that the cmd->convert_arg is that value and modify it if not. Also use cfc_check_trigger_arg_is() to validate that the cmd->scan_begin_arg is the calculate value and modify it if not. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23staging: comedi: adl_pc19111: remove 'chanlist_len' from private dataH Hartley Sweeten
This member of the private data is a copy of the cmd->chanlist_len. Use that instead. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23staging: comedi: adl_pc19111: rename 'async_cmd' variable in (*do_cmd)H Hartley Sweeten
The comedi_cmd pointer is typically just called 'cmd'. Rename the local variable in pci9111_ai_do_cmd(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23staging: comedi: adl_pc19111: remove 'stop_is_none' from private dataH Hartley Sweeten
This member of the private data can be determined by checking the cmd->stop_src. Do that instead. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-03staging: comedi: adl_pci9111: tidy up (*do_cmdtest) Step 4H Hartley Sweeten
This step in the (*do_cmdtest) fixes the comedi_cmd arguments, usually for TRIG_TIMER sources. Tidy up this step to clarify the code and remove the extra local variables. All the arguments are unsigned long so change the 'tmp' local variable type and rename it for aesthetics. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-25staging: comedi: adl_pci9111: clarify Step 2b of the (*do_cmdtest)H Hartley Sweeten
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 <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-22staging: comedi: adl_pci9111: rename local var in pci9111_ai_do_cmd_test()H Hartley Sweeten
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 <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-22staging: comedi: adl_pci9111: factor out chanlist checking from (*do_cmdtest)H Hartley Sweeten
Step 5 of the (*do_cmdtest) validates that the cmd->chanlist is compatible with the hardware. For aesthetics, factor out the step 5 code for the analog input async command support. Tidy up the factored out code. To minimize the noise, change the comedi_err(), which is a wrapper around dev_err(), to dev_dbg(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17staging: comedi: adl_pci9111: use cfc_handle_events()H Hartley Sweeten
Use the comedi_fc helper function to automatically call the subdevice (*cancel) function when needed and call comedi_event(). In the Kconfig, COMEDI_ADL_PCI9111 already selects COMEDI_FC. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-14staging: comedi: adl_pci9111: trigger sources are validated in (*do_cmdtest)H Hartley Sweeten
The trigger sources were already validataed in the (*do_cmdtest) before the (*do_cmd) is called. Refactor the code in pci9111_ai_do_cmd() to use if/else instead of the switch since the default cases can never be reached. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-14staging: comedi: don't clear 'data' on (*insn_read) timeoutH Hartley Sweeten
It's not necessary to clear the returned data pointer when an (*insn_read) times out. For aesthetics, remove all of these in the drivers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-14staging: comedi: move (*insn_{read, write}) timeout debug messages to coreH Hartley Sweeten
Have the comedi core display a standard dev_dbg() message when a timeout occurs and remove all the driver specific messages. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-14staging: comedi: adl_pci9111: use comedi_timeout()H Hartley Sweeten
Use comedi_timeout() to wait for the analog input end-of-conversion. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-07staging: comedi: drivers: remove final 'attach' messagesH Hartley Sweeten
These messages are just added noise. Remove them. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-17staging: comedi: adl_pci9111: tidy up comedi_lrange tablesH Hartley Sweeten
Tidy up the format of the comedi_lrange table. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-06staging: comedi: adl_pci9111: the irq is only needed for async command supportH Hartley Sweeten
An irq is only needed for async command support, modify the attach of the subdevices so that the command support is only hooked up if the irq request was successful. Remove the then unnecessary sanity check in pci9111_ai_do_cmd(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-06staging: comedi: adl_pci9111: fix incorrect irq passed to request_irq()H Hartley Sweeten
The dev->irq passed to request_irq() will always be 0 when the auto_attach function is called. The pcidev->irq should be used instead to get the correct irq number. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02staging: remove DEFINE_PCI_DEVICE_TABLE macroJingoo Han
Don't use DEFINE_PCI_DEVICE_TABLE macro, because this macro is not preferred. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-10-16staging: comedi: adl_pci9111: sample types are unsignedIan Abbott
Sample values in comedi are generally represented as unsigned values. Change the element type of the `ai_bounce_buffer[]` member of `struct pci9111_private_data` from `short` to `unsigned short` for consistency. Also change the type of the `array` variable in `pci9111_ai_munge()` from `short *` to `unsigned short *`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-09-26staging: comedi: 8253.h: tidy up the i8253_cascade_ns_to_timer*() usersH Hartley Sweeten
Introduce a couple defines for the common 8254 oscillator base values used in the comedi drivers and remove the custom defines and open coded values. Change the i8253_cascade_ns_to_timer_2div() calls in the drivers to the more generic i8253_cascade_ns_to_timer(). They are identical due to the #define in the 8253.h header. Remove the extra mask by TRIG_ROUND_MASK of the 'round_mode' parameter to i8253_cascade_ns_to_timer(). That function already handles the mask. Tidy up all the calls to i8253_cascade_ns_to_timer(). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-09-17staging: comedi: drivers: use comedi_dio_update_state() for simple casesH Hartley Sweeten
Use comedi_dio_update_state() to handle the boilerplate code to update the subdevice s->state for simple cases where the hardware is updated when any channel is modified. Also, fix a bug in the amplc_pc263 and amplc_pci263 drivers where the current state is not returned in data[1]. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-07-23staging: comedi: don't rely on comedidev.h to include headersH Hartley Sweeten
comedidev.h is the main kernel header for comedi. Every comedi driver includes this header which then includes a number of <linux/*> headers. All the drivers need <linux/module.h> and some of them need <linux/delay.h>. The rest are not needed by any of the drivers. Remove all the includes in comedidev.h except for <linux/dma-mapping.h>, which is needed to pick up the enum dma_data_direction for the comedi_subdevice definition, and "comedi.h", which is the uapi header for comedi. Add <linux/module.h> to all the comedi drivers and <linux/delay.h> to the couple that need it. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-07-23staging: comedi: use comedi_alloc_devpriv()H Hartley Sweeten
Use the helper function to allocate memory and set the comedi_device private data pointer. This removes the dependency on slab.h from most of the drivers so remove the global #include in comedidev.h and the local #include in some of the drivers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-05-13staging: comedi: remove FSF address from boilerplate textH Hartley Sweeten
Addresses change... Remove the paragraph with the FSF address from all the comedi source files. Also, remove the paragraph about the finding the complete GPL in the COPYING file since it's unnecessary. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-15staging: comedi: adl_pci9111: use plx9052.h definesH Hartley Sweeten
Use the PLX 9052 register defines in plx9052.h instead of duplicating the defines locally in this driver. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>