Commit ce157f80 authored by H Hartley Sweeten's avatar H Hartley Sweeten Committed by Greg Kroah-Hartman

staging: comedi: don't rely on comedidev.h to include headers

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: default avatarH Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0bdab509
......@@ -19,21 +19,7 @@
#ifndef _COMEDIDEV_H
#define _COMEDIDEV_H
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/kdev_t.h>
#include <linux/delay.h>
#include <linux/errno.h>
#include <linux/spinlock.h>
#include <linux/mutex.h>
#include <linux/wait.h>
#include <linux/mm.h>
#include <linux/init.h>
#include <linux/vmalloc.h>
#include <linux/dma-mapping.h>
#include <linux/uaccess.h>
#include <linux/io.h>
#include <linux/timer.h>
#include "comedi.h"
......
......@@ -73,6 +73,7 @@ I/O port base address can be found in the output of 'lspci -v'.
will copy the latched value to a Comedi buffer.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -50,6 +50,7 @@ Interrupt support for these boards is also not currently supported.
Configuration Options: not applicable, uses PCI auto config
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -22,6 +22,8 @@
* for more details.
*/
#include <linux/delay.h>
#define NVRAM_USER_DATA_START 0x100
#define NVCMD_BEGIN_READ (0x7 << 5) /* nvRam begin read command */
......
......@@ -40,6 +40,8 @@ This program is distributed in the hope that it will be useful, but WITHOUT ANY
+----------+-----------+------------------------------------------------+
*/
#include <linux/delay.h>
/*
* ADDON RELATED ADDITIONS
*/
......
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
#include <linux/module.h>
#include <linux/pci.h>
#include <asm/i387.h>
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
#include <linux/module.h>
#include <linux/pci.h>
#include <asm/i387.h>
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
#include <linux/sched.h>
......
......@@ -22,6 +22,7 @@
* more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -18,6 +18,7 @@
* GNU General Public License for more details.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include "addi_watchdog.h"
......
......@@ -38,6 +38,7 @@ Configuration Options: not applicable, uses PCI auto config
- adl_pci9118.c
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -44,6 +44,7 @@ driver.
Configuration Options: not applicable, uses comedi PCI auto config
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -27,6 +27,7 @@
*/
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -64,6 +64,7 @@ a multiple of chanlist_len*convert_arg.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -77,6 +77,7 @@ Configuration options:
* manual attachment.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/gfp.h>
......
......@@ -73,6 +73,9 @@ If you do not specify any options, they will default to
*/
#include <linux/module.h>
#include <linux/delay.h>
#include "../comedidev.h"
/* address scheme (page 2.17 of the manual) */
......
......@@ -41,6 +41,7 @@ Configuration options:
device will be used.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -43,6 +43,7 @@ configures all channels in the same group.
3. Implement calibration.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -52,6 +52,8 @@ supported PCI devices are configured as comedi devices automatically.
*/
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -29,6 +29,7 @@ Configuration options:
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
......
......@@ -35,6 +35,7 @@ Configuration Options:
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
#include "8255.h"
......
......@@ -30,6 +30,7 @@ Configuration Options:
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -192,6 +192,7 @@
* order they appear in the channel list.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include "amplc_dio200.h"
......
......@@ -19,6 +19,7 @@
GNU General Public License for more details.
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -220,6 +220,7 @@
* order they appear in the channel list.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -47,6 +47,7 @@ the IRQ jumper. If no interrupt is connected, then subdevice 1 is
unused.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -33,6 +33,7 @@ connected to a reed-relay. Relay contacts are closed when output is 1.
The state of the outputs can be read.
*/
#include <linux/module.h>
#include "../comedidev.h"
#define PC263_DRIVER_NAME "amplc_pc263"
......
......@@ -98,6 +98,7 @@ Passing a zero for an option is the same as leaving it unspecified.
correctly.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -184,6 +184,7 @@ Support for PCI230+/260+, more triggered scan functionality, and workarounds
for (or detection of) various hardware problems added by Ian Abbott.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -32,6 +32,7 @@ connected to a reed-relay. Relay contacts are closed when output is 1.
The state of the outputs can be read.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -34,6 +34,7 @@ Status: experimental
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/delay.h>
......
......@@ -61,6 +61,7 @@ AI Triggering:
analog triggering on 1602 series
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -82,6 +82,7 @@
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -37,6 +37,7 @@
* Only simple analog output writing is supported.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -35,6 +35,7 @@ No interrupts, multi channel or FIFO AI, although the card looks like it could s
See http://www.mccdaq.com/PDFs/Manuals/pcim-das1602-16.pdf for more details.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -74,6 +74,7 @@ Configuration Options: not applicable, uses PCI auto config
-Calin Culianu <calin@ajvar.org>
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -45,6 +45,7 @@ Configuration Options:
within each minor will be concatenated together in the order given here.
*/
#include <linux/module.h>
#include <linux/string.h>
#include <linux/slab.h>
#include "../comedi.h"
......
......@@ -19,6 +19,7 @@
GNU General Public License for more details.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include "comedi_fc.h"
......
......@@ -76,6 +76,7 @@ pin, which can be used to wake up tasks.
or http://www.linux-magazin.de/ausgabe/1999/10/IO/io.html
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/interrupt.h>
#include <linux/ioport.h>
......
......@@ -45,6 +45,7 @@ zero volts).
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <asm/div64.h>
......
......@@ -25,6 +25,7 @@ Status: works
Configuration Options: not applicable, uses comedi PCI auto config
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -102,6 +102,7 @@ Configuration options: not applicable, uses PCI auto config
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -33,6 +33,7 @@
* cheap das08 hardware doesn't really support them.
*/
#include <linux/module.h>
#include <linux/delay.h>
#include "../comedidev.h"
......
......@@ -39,6 +39,7 @@ Options (for pcm-das08):
Command support does not exist, but could be added for this board.
*/
#include <linux/module.h>
#include <linux/delay.h>
#include "../comedidev.h"
......
......@@ -43,6 +43,7 @@
* [0] - base io address
*/
#include <linux/module.h>
#include "../comedidev.h"
#include "das08.h"
......
......@@ -31,6 +31,7 @@
* Configuration Options: not applicable, uses PCI auto config
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -73,6 +73,8 @@ www.measurementcomputing.com
*/
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -52,6 +52,7 @@ list has 2 or more channels in it, then two conditions must be satisfied:
irq can be omitted, although the cmd interface will not work without it.
*/
#include <linux/module.h>
#include <linux/ioport.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -94,6 +94,7 @@ Unipolar and bipolar ranges cannot be mixed in the channel/gain list.
read insn for analog out
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/slab.h>
#include <linux/io.h>
......
......@@ -33,6 +33,7 @@ Devices: [Keithley Metrabyte] DAS6402 (das6402)
This driver has suffered bitrot.
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -56,6 +56,7 @@ cmd triggers supported:
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -32,6 +32,8 @@ Configuration Options:
comedi_config /dev/comedi0 dmm32at baseaddr,irq
*/
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -29,6 +29,7 @@ Configuration options:
[5] - D/A 1 range (same choices)
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/delay.h>
#include <linux/ioport.h>
......
......@@ -41,6 +41,7 @@ Configuration options:
[4] - D/A 1 range (same choices)
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -34,6 +34,7 @@ a power of 10, from 1 to 10^7, of which only 3 or 4 are useful. In
addition, the clock does not seem to be very accurate.
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -51,6 +51,7 @@ Configuration options:
[12] - Analog output 7 range configuration (same options)
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -33,6 +33,7 @@ Configuration options:
[0] - I/O port base base address
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -51,13 +51,17 @@ Configuration options:
be fixed to check for this situation and return an error.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/delay.h>
#include <linux/gfp.h>
#include <linux/ioport.h>
#include <linux/interrupt.h>
#include <linux/io.h>
#include <asm/dma.h>
#include "comedi_fc.h"
#define DEBUG
......
......@@ -50,6 +50,7 @@ AO commands are not supported.
#define DEBUG 1
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -39,6 +39,7 @@ for my needs.
*/
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/errno.h>
#include <linux/init.h>
#include <linux/module.h>
......
......@@ -33,6 +33,8 @@
their cards in their manuals.
*/
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include <linux/mutex.h>
......
......@@ -18,6 +18,7 @@ Configuration options:
#define DEBUG 0
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/delay.h>
......
......@@ -42,6 +42,7 @@
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -42,6 +42,7 @@ There are 4 x 12-bit Analogue Outputs. Ranges : 5V, 10V, +/-5V, +/-10V
Configuration options: not applicable, uses PCI auto config
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -77,6 +77,7 @@ options for PCI-20341M:
3 200
*/
#include <linux/module.h>
#include "../comedidev.h"
#define PCI20000_ID 0x1d
......
......@@ -38,6 +38,7 @@
*/
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/ctype.h>
......
......@@ -29,6 +29,7 @@ This driver is a simple driver to read the counter values from
Kolter Electronic PCI Counter Card.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -40,6 +40,7 @@ broken.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
......
......@@ -30,6 +30,7 @@
* Analog Input, Analog Output, Digital I/O
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
#include <linux/sched.h>
......
......@@ -46,6 +46,7 @@
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
#include <linux/module.h>
#include <linux/pci.h>
#include "../comedidev.h"
......
......@@ -51,6 +51,7 @@ Configuration Options:
1 -10.1V .. +10.1V
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -24,6 +24,7 @@ Devices: [Quanser Consulting] MultiQ-3 (multiq3)
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -36,6 +36,7 @@ Updated: Sat, 25 Jan 2003 13:24:40 -0800
#define DEBUG 1
#define DEBUG_FLAGS
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -46,6 +46,7 @@ except maybe the 6514.
#define DEBUG 1
#define DEBUG_FLAGS
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -34,6 +34,7 @@
* DAQ 6601/6602 User Manual (NI 322137B-01)
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -36,6 +36,7 @@ Commands are not supported.
*/
#include <linux/module.h>
#include <linux/pci.h>
#include <linux/interrupt.h>
......
......@@ -58,12 +58,15 @@ TRIG_WAKE_EOS
*/
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/slab.h>
#include "../comedidev.h"
#include <linux/ioport.h>
#include <linux/io.h>
#include <asm/dma.h>
#include "8253.h"
......
......@@ -36,6 +36,7 @@ Configuration options:
* document 320379.pdf.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/ioport.h>
......
......@@ -89,6 +89,7 @@ are not supported.
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -30,6 +30,7 @@ Devices: [National Instruments] AT-MIO-16 (atmio16), AT-MIO-16D (atmio16d)
*
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
......@@ -45,6 +45,8 @@ Manuals: Register level: http://www.ni.com/pdf/manuals/340698.pdf
User Manual: http://www.ni.com/pdf/manuals/320676d.pdf
*/
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/ioport.h>
#include <linux/interrupt.h>
......
......@@ -31,6 +31,7 @@ This is just a wrapper around the 8255.o driver to properly handle
the PCMCIA interface.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <pcmcia/cistpl.h>
......
......@@ -57,6 +57,7 @@
* 320502b (lab-pc+)
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/slab.h>
#include <linux/io.h>
......
......@@ -53,6 +53,7 @@ NI manuals:
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/delay.h>
......
......@@ -29,6 +29,7 @@
* 340914a (pci-1200)
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/pci.h>
......
......@@ -36,6 +36,7 @@ See the notes in the ni_atmio.o driver.
*/
#include <linux/module.h>
#include "../comedidev.h"
#include <linux/delay.h>
......
......@@ -50,6 +50,7 @@ comedi_nonfree_firmware tarball available from http://www.comedi.org
/* #define DEBUG 1 */
/* #define DEBUG_FLAGS */
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/sched.h>
......
......@@ -106,6 +106,7 @@ SCXI is probably broken for m-series boards.
*/
#include <linux/module.h>
#include <linux/delay.h>
#include "../comedidev.h"
......
......@@ -44,6 +44,7 @@ DAQ 6601/6602 User Manual (NI 322137B-01)
Support use of both banks X and Y
*/
#include <linux/module.h>
#include <linux/slab.h>
#include "ni_tio_internal.h"
......
......@@ -44,6 +44,7 @@ DAQ 6601/6602 User Manual (NI 322137B-01)
Support use of both banks X and Y
*/
#include <linux/module.h>
#include "comedi_fc.h"
#include "ni_tio_internal.h"
#include "mite.h"
......
......@@ -53,6 +53,7 @@ supported.
*/
#include <linux/module.h>
#include <linux/interrupt.h>
#include "../comedidev.h"
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment