LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header
@ 2015-01-30  9:57 Ian Abbott
  2015-01-30  9:57 ` [PATCH 01/10] staging: comedi: add comedi_pcmcia.h Ian Abbott
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

"comedidev.h" includes PCMCIA-specific stuff that gets included by all
comedi drivers including non-PCMCIA ones.  Separate it out into its own
header "comedi_pcmcia.h".  Make the new header include
<pcmcia/cistpl.h>, <pcmcia/ds.h> and "comedidev.h" so that comedi PCMCIA
drivers do not need to include them explicitly.

01) staging: comedi: add comedi_pcmcia.h
02) staging: comedi: comedi_pcmcia.c: include new "comedi_pcmcia.h"
    header
03) staging: comedi: cb_das16_cs: include new "comedi_pcmcia.h" header
04) staging: comedi: das08_cs: include new "comedi_pcmcia.h" header
05) staging: comedi: ni_daq_700: include new "comedi_pcmcia.h" header
06) staging: comedi: ni_daq_dio24: include new "comedi_pcmcia.h" header
07) staging: comedi: ni_labpc_cs: include new "comedi_pcmcia.h" header
08) staging: comedi: ni_mio_cs: include new "comedi_pcmcia.h" header
09) staging: comedi: quatech_daqp_cs: include new "comedi_pcmcia.h"
    header
10) staging: comedi: comedi_pcmcia.h: move PCMCIA stuff out of
    comedidev.h

 drivers/staging/comedi/comedi_pcmcia.c           |  5 +--
 drivers/staging/comedi/comedi_pcmcia.h           | 55 ++++++++++++++++++++++++
 drivers/staging/comedi/comedidev.h               | 33 --------------
 drivers/staging/comedi/drivers/cb_das16_cs.c     |  5 +--
 drivers/staging/comedi/drivers/das08_cs.c        |  5 +--
 drivers/staging/comedi/drivers/ni_daq_700.c      |  5 +--
 drivers/staging/comedi/drivers/ni_daq_dio24.c    |  6 +--
 drivers/staging/comedi/drivers/ni_labpc_cs.c     |  6 +--
 drivers/staging/comedi/drivers/ni_mio_cs.c       |  6 +--
 drivers/staging/comedi/drivers/quatech_daqp_cs.c |  7 +--
 10 files changed, 63 insertions(+), 70 deletions(-)

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 01/10] staging: comedi: add comedi_pcmcia.h
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 02/10] staging: comedi: comedi_pcmcia.c: include new "comedi_pcmcia.h" header Ian Abbott
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Add a new header that Comedi PCMCIA drivers can include instead of
"comedidev.h".  Currently, it just pulls in <pcmcia/cistpl.h>,
<pcmcia/ds.h> and "comedidev.h", but the plan is to migrate the
PCMCIA-specific stuff from "comedidev.h" here.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/comedi_pcmcia.h | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)
 create mode 100644 drivers/staging/comedi/comedi_pcmcia.h

diff --git a/drivers/staging/comedi/comedi_pcmcia.h b/drivers/staging/comedi/comedi_pcmcia.h
new file mode 100644
index 0000000..ba073af
--- /dev/null
+++ b/drivers/staging/comedi/comedi_pcmcia.h
@@ -0,0 +1,31 @@
+/*
+ * comedi_pcmcia.h
+ * header file for Comedi PCMCIA drivers
+ *
+ * COMEDI - Linux Control and Measurement Device Interface
+ * Copyright (C) 1997-2000 David A. Schleef <ds@schleef.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef _COMEDI_PCMCIA_H
+#define _COMEDI_PCMCIA_H
+
+#include <pcmcia/cistpl.h>
+#include <pcmcia/ds.h>
+
+#include "comedidev.h"
+
+/*
+ * TODO: Move PCMCIA-specific stuff into here from "comedidev.h".
+ */
+
+#endif /* _COMEDI_PCMCIA_H */
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 02/10] staging: comedi: comedi_pcmcia.c: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
  2015-01-30  9:57 ` [PATCH 01/10] staging: comedi: add comedi_pcmcia.h Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 03/10] staging: comedi: cb_das16_cs: " Ian Abbott
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "comedi_pcmcia.h" header instead of <pcmcia/cistpl.h>,
<pcmcia/ds.h> and "comedidev.h", which will now get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/comedi_pcmcia.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/staging/comedi/comedi_pcmcia.c b/drivers/staging/comedi/comedi_pcmcia.c
index 0529bae..7e78439 100644
--- a/drivers/staging/comedi/comedi_pcmcia.c
+++ b/drivers/staging/comedi/comedi_pcmcia.c
@@ -19,10 +19,7 @@
 #include <linux/module.h>
 #include <linux/kernel.h>
 
-#include <pcmcia/cistpl.h>
-#include <pcmcia/ds.h>
-
-#include "comedidev.h"
+#include "comedi_pcmcia.h"
 
 /**
  * comedi_to_pcmcia_dev() - comedi_device pointer to pcmcia_device pointer.
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 03/10] staging: comedi: cb_das16_cs: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
  2015-01-30  9:57 ` [PATCH 01/10] staging: comedi: add comedi_pcmcia.h Ian Abbott
  2015-01-30  9:57 ` [PATCH 02/10] staging: comedi: comedi_pcmcia.c: include new "comedi_pcmcia.h" header Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 04/10] staging: comedi: das08_cs: " Ian Abbott
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/ds.h> and "../comedidev.h", which will now
get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/cb_das16_cs.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/staging/comedi/drivers/cb_das16_cs.c b/drivers/staging/comedi/drivers/cb_das16_cs.c
index 0a48d2a..1079b6c 100644
--- a/drivers/staging/comedi/drivers/cb_das16_cs.c
+++ b/drivers/staging/comedi/drivers/cb_das16_cs.c
@@ -38,10 +38,7 @@ Status: experimental
 #include <linux/interrupt.h>
 #include <linux/delay.h>
 
-#include "../comedidev.h"
-
-#include <pcmcia/cistpl.h>
-#include <pcmcia/ds.h>
+#include "../comedi_pcmcia.h"
 
 #include "comedi_fc.h"
 #include "8253.h"
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 04/10] staging: comedi: das08_cs: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (2 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 03/10] staging: comedi: cb_das16_cs: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 05/10] staging: comedi: ni_daq_700: " Ian Abbott
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/ds.h> and "../comedidev.h", which will now
get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/das08_cs.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/staging/comedi/drivers/das08_cs.c b/drivers/staging/comedi/drivers/das08_cs.c
index f3ccc2c..93fab68 100644
--- a/drivers/staging/comedi/drivers/das08_cs.c
+++ b/drivers/staging/comedi/drivers/das08_cs.c
@@ -41,10 +41,7 @@ Command support does not exist, but could be added for this board.
 
 #include <linux/module.h>
 
-#include "../comedidev.h"
-
-#include <pcmcia/cistpl.h>
-#include <pcmcia/ds.h>
+#include "../comedi_pcmcia.h"
 
 #include "das08.h"
 
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 05/10] staging: comedi: ni_daq_700: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (3 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 04/10] staging: comedi: das08_cs: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 06/10] staging: comedi: ni_daq_dio24: " Ian Abbott
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/ds.h> and "../comedidev.h", which will now
get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/ni_daq_700.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/staging/comedi/drivers/ni_daq_700.c b/drivers/staging/comedi/drivers/ni_daq_700.c
index 5e472cb..8f6396e 100644
--- a/drivers/staging/comedi/drivers/ni_daq_700.c
+++ b/drivers/staging/comedi/drivers/ni_daq_700.c
@@ -51,10 +51,7 @@
 #include <linux/delay.h>
 #include <linux/interrupt.h>
 
-#include "../comedidev.h"
-
-#include <pcmcia/cistpl.h>
-#include <pcmcia/ds.h>
+#include "../comedi_pcmcia.h"
 
 /* daqcard700 registers */
 #define DIO_W		0x04	/* WO 8bit */
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 06/10] staging: comedi: ni_daq_dio24: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (4 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 05/10] staging: comedi: ni_daq_700: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 07/10] staging: comedi: ni_labpc_cs: " Ian Abbott
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/cisreg.h>, <pcmcia/ds.h> and
"../comedidev.h".  <pcmcia/cisreg.h> isn't needed and the others will
now get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/ni_daq_dio24.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/staging/comedi/drivers/ni_daq_dio24.c b/drivers/staging/comedi/drivers/ni_daq_dio24.c
index 8cfabdb..a208cb3 100644
--- a/drivers/staging/comedi/drivers/ni_daq_dio24.c
+++ b/drivers/staging/comedi/drivers/ni_daq_dio24.c
@@ -32,11 +32,7 @@ the PCMCIA interface.
 */
 
 #include <linux/module.h>
-#include "../comedidev.h"
-
-#include <pcmcia/cistpl.h>
-#include <pcmcia/cisreg.h>
-#include <pcmcia/ds.h>
+#include "../comedi_pcmcia.h"
 
 #include "8255.h"
 
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 07/10] staging: comedi: ni_labpc_cs: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (5 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 06/10] staging: comedi: ni_daq_dio24: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 08/10] staging: comedi: ni_mio_cs: " Ian Abbott
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/cisreg.h>, <pcmcia/ds.h> and
"../comedidev.h".  <pcmcia/cisreg.h> isn't needed and the others will
now get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/ni_labpc_cs.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/staging/comedi/drivers/ni_labpc_cs.c b/drivers/staging/comedi/drivers/ni_labpc_cs.c
index ece0010..746c4cd9 100644
--- a/drivers/staging/comedi/drivers/ni_labpc_cs.c
+++ b/drivers/staging/comedi/drivers/ni_labpc_cs.c
@@ -55,11 +55,7 @@ NI manuals:
 
 #include <linux/module.h>
 
-#include "../comedidev.h"
-
-#include <pcmcia/cistpl.h>
-#include <pcmcia/cisreg.h>
-#include <pcmcia/ds.h>
+#include "../comedi_pcmcia.h"
 
 #include "ni_labpc.h"
 
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 08/10] staging: comedi: ni_mio_cs: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (6 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 07/10] staging: comedi: ni_labpc_cs: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 09/10] staging: comedi: quatech_daqp_cs: " Ian Abbott
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/ds.h> and "../comedidev.h", which will now
get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/ni_mio_cs.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/staging/comedi/drivers/ni_mio_cs.c b/drivers/staging/comedi/drivers/ni_mio_cs.c
index 9b201e4..1a59351 100644
--- a/drivers/staging/comedi/drivers/ni_mio_cs.c
+++ b/drivers/staging/comedi/drivers/ni_mio_cs.c
@@ -37,16 +37,12 @@ See the notes in the ni_atmio.o driver.
 */
 
 #include <linux/module.h>
-#include "../comedidev.h"
-
 #include <linux/delay.h>
 
+#include "../comedi_pcmcia.h"
 #include "ni_stc.h"
 #include "8255.h"
 
-#include <pcmcia/cistpl.h>
-#include <pcmcia/ds.h>
-
 /*
  *  AT specific setup
  */
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 09/10] staging: comedi: quatech_daqp_cs: include new "comedi_pcmcia.h" header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (7 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 08/10] staging: comedi: ni_mio_cs: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30  9:57 ` [PATCH 10/10] staging: comedi: comedi_pcmcia.h: move PCMCIA stuff out of comedidev.h Ian Abbott
  2015-01-30 17:03 ` [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Hartley Sweeten
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Include the new "../comedi_pcmcia.h" header instead of
<pcmcia/cistpl.h>, <pcmcia/cisreg.h>, <pcmcia/ds.h> and
"../comedidev.h".  <pcmcia/cisreg.h> isn't needed and the others will
now get included indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/drivers/quatech_daqp_cs.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/staging/comedi/drivers/quatech_daqp_cs.c b/drivers/staging/comedi/drivers/quatech_daqp_cs.c
index dd06734..8387fd0 100644
--- a/drivers/staging/comedi/drivers/quatech_daqp_cs.c
+++ b/drivers/staging/comedi/drivers/quatech_daqp_cs.c
@@ -48,15 +48,10 @@ Devices: [Quatech] DAQP-208 (daqp), DAQP-308
 */
 
 #include <linux/module.h>
-#include "../comedidev.h"
 #include <linux/semaphore.h>
-
-#include <pcmcia/cistpl.h>
-#include <pcmcia/cisreg.h>
-#include <pcmcia/ds.h>
-
 #include <linux/completion.h>
 
+#include "../comedi_pcmcia.h"
 #include "comedi_fc.h"
 
 struct daqp_private {
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 10/10] staging: comedi: comedi_pcmcia.h: move PCMCIA stuff out of comedidev.h
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (8 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 09/10] staging: comedi: quatech_daqp_cs: " Ian Abbott
@ 2015-01-30  9:57 ` Ian Abbott
  2015-01-30 17:03 ` [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Hartley Sweeten
  10 siblings, 0 replies; 12+ messages in thread
From: Ian Abbott @ 2015-01-30  9:57 UTC (permalink / raw)
  To: driverdev-devel
  Cc: Greg Kroah-Hartman, Ian Abbott, H Hartley Sweeten, linux-kernel

Move the PCMCIA-specific stuff out of "comedidev.h" into
"comedi_pcmcia.h".  Comedi PCMCIA drivers now include "comedi_pcmcia.h"
instead of "comedidev.h", which now gets pulled in indirectly.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
 drivers/staging/comedi/comedi_pcmcia.h | 28 ++++++++++++++++++++++++++--
 drivers/staging/comedi/comedidev.h     | 33 ---------------------------------
 2 files changed, 26 insertions(+), 35 deletions(-)

diff --git a/drivers/staging/comedi/comedi_pcmcia.h b/drivers/staging/comedi/comedi_pcmcia.h
index ba073af..5d3db2b 100644
--- a/drivers/staging/comedi/comedi_pcmcia.h
+++ b/drivers/staging/comedi/comedi_pcmcia.h
@@ -24,8 +24,32 @@
 
 #include "comedidev.h"
 
-/*
- * TODO: Move PCMCIA-specific stuff into here from "comedidev.h".
+struct pcmcia_device *comedi_to_pcmcia_dev(struct comedi_device *);
+
+int comedi_pcmcia_enable(struct comedi_device *,
+			 int (*conf_check)(struct pcmcia_device *, void *));
+void comedi_pcmcia_disable(struct comedi_device *);
+
+int comedi_pcmcia_auto_config(struct pcmcia_device *, struct comedi_driver *);
+void comedi_pcmcia_auto_unconfig(struct pcmcia_device *);
+
+int comedi_pcmcia_driver_register(struct comedi_driver *,
+				  struct pcmcia_driver *);
+void comedi_pcmcia_driver_unregister(struct comedi_driver *,
+				     struct pcmcia_driver *);
+
+/**
+ * module_comedi_pcmcia_driver() - Helper macro for registering a comedi PCMCIA driver
+ * @__comedi_driver: comedi_driver struct
+ * @__pcmcia_driver: pcmcia_driver struct
+ *
+ * Helper macro for comedi PCMCIA drivers which do not do anything special
+ * in module init/exit. This eliminates a lot of boilerplate. Each
+ * module may only use this macro once, and calling it replaces
+ * module_init() and module_exit()
  */
+#define module_comedi_pcmcia_driver(__comedi_driver, __pcmcia_driver) \
+	module_driver(__comedi_driver, comedi_pcmcia_driver_register, \
+			comedi_pcmcia_driver_unregister, &(__pcmcia_driver))
 
 #endif /* _COMEDI_PCMCIA_H */
diff --git a/drivers/staging/comedi/comedidev.h b/drivers/staging/comedi/comedidev.h
index bc1dfc1..e138eb0 100644
--- a/drivers/staging/comedi/comedidev.h
+++ b/drivers/staging/comedi/comedidev.h
@@ -596,37 +596,4 @@ void comedi_pci_driver_unregister(struct comedi_driver *, struct pci_driver *);
 	module_driver(__comedi_driver, comedi_pci_driver_register, \
 			comedi_pci_driver_unregister, &(__pci_driver))
 
-/* comedi_pcmcia.c - comedi PCMCIA driver specific functions */
-
-struct pcmcia_driver;
-struct pcmcia_device;
-
-struct pcmcia_device *comedi_to_pcmcia_dev(struct comedi_device *);
-
-int comedi_pcmcia_enable(struct comedi_device *,
-			 int (*conf_check)(struct pcmcia_device *, void *));
-void comedi_pcmcia_disable(struct comedi_device *);
-
-int comedi_pcmcia_auto_config(struct pcmcia_device *, struct comedi_driver *);
-void comedi_pcmcia_auto_unconfig(struct pcmcia_device *);
-
-int comedi_pcmcia_driver_register(struct comedi_driver *,
-				  struct pcmcia_driver *);
-void comedi_pcmcia_driver_unregister(struct comedi_driver *,
-				     struct pcmcia_driver *);
-
-/**
- * module_comedi_pcmcia_driver() - Helper macro for registering a comedi PCMCIA driver
- * @__comedi_driver: comedi_driver struct
- * @__pcmcia_driver: pcmcia_driver struct
- *
- * Helper macro for comedi PCMCIA drivers which do not do anything special
- * in module init/exit. This eliminates a lot of boilerplate. Each
- * module may only use this macro once, and calling it replaces
- * module_init() and module_exit()
- */
-#define module_comedi_pcmcia_driver(__comedi_driver, __pcmcia_driver) \
-	module_driver(__comedi_driver, comedi_pcmcia_driver_register, \
-			comedi_pcmcia_driver_unregister, &(__pcmcia_driver))
-
 #endif /* _COMEDIDEV_H */
-- 
2.1.4


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header
  2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
                   ` (9 preceding siblings ...)
  2015-01-30  9:57 ` [PATCH 10/10] staging: comedi: comedi_pcmcia.h: move PCMCIA stuff out of comedidev.h Ian Abbott
@ 2015-01-30 17:03 ` Hartley Sweeten
  10 siblings, 0 replies; 12+ messages in thread
From: Hartley Sweeten @ 2015-01-30 17:03 UTC (permalink / raw)
  To: Ian Abbott, driverdev-devel; +Cc: Greg Kroah-Hartman, linux-kernel

On Friday, January 30, 2015 2:57 AM, Ian Abbott wrote:
> "comedidev.h" includes PCMCIA-specific stuff that gets included by all
> comedi drivers including non-PCMCIA ones.  Separate it out into its own
> header "comedi_pcmcia.h".  Make the new header include
> <pcmcia/cistpl.h>, <pcmcia/ds.h> and "comedidev.h" so that comedi PCMCIA
> drivers do not need to include them explicitly.
>
> 01) staging: comedi: add comedi_pcmcia.h
> 02) staging: comedi: comedi_pcmcia.c: include new "comedi_pcmcia.h"
>     header
> 03) staging: comedi: cb_das16_cs: include new "comedi_pcmcia.h" header
> 04) staging: comedi: das08_cs: include new "comedi_pcmcia.h" header
> 05) staging: comedi: ni_daq_700: include new "comedi_pcmcia.h" header
> 06) staging: comedi: ni_daq_dio24: include new "comedi_pcmcia.h" header
> 07) staging: comedi: ni_labpc_cs: include new "comedi_pcmcia.h" header
> 08) staging: comedi: ni_mio_cs: include new "comedi_pcmcia.h" header
> 09) staging: comedi: quatech_daqp_cs: include new "comedi_pcmcia.h"
>     header
> 10) staging: comedi: comedi_pcmcia.h: move PCMCIA stuff out of
>     comedidev.h
>
>  drivers/staging/comedi/comedi_pcmcia.c           |  5 +--
>  drivers/staging/comedi/comedi_pcmcia.h           | 55 ++++++++++++++++++++++++
>  drivers/staging/comedi/comedidev.h               | 33 --------------
>  drivers/staging/comedi/drivers/cb_das16_cs.c     |  5 +--
>  drivers/staging/comedi/drivers/das08_cs.c        |  5 +--
>  drivers/staging/comedi/drivers/ni_daq_700.c      |  5 +--
>  drivers/staging/comedi/drivers/ni_daq_dio24.c    |  6 +--
>  drivers/staging/comedi/drivers/ni_labpc_cs.c     |  6 +--
>  drivers/staging/comedi/drivers/ni_mio_cs.c       |  6 +--
>  drivers/staging/comedi/drivers/quatech_daqp_cs.c |  7 +--
>  10 files changed, 63 insertions(+), 70 deletions(-)

Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com>


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2015-01-30 17:03 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-30  9:57 [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Ian Abbott
2015-01-30  9:57 ` [PATCH 01/10] staging: comedi: add comedi_pcmcia.h Ian Abbott
2015-01-30  9:57 ` [PATCH 02/10] staging: comedi: comedi_pcmcia.c: include new "comedi_pcmcia.h" header Ian Abbott
2015-01-30  9:57 ` [PATCH 03/10] staging: comedi: cb_das16_cs: " Ian Abbott
2015-01-30  9:57 ` [PATCH 04/10] staging: comedi: das08_cs: " Ian Abbott
2015-01-30  9:57 ` [PATCH 05/10] staging: comedi: ni_daq_700: " Ian Abbott
2015-01-30  9:57 ` [PATCH 06/10] staging: comedi: ni_daq_dio24: " Ian Abbott
2015-01-30  9:57 ` [PATCH 07/10] staging: comedi: ni_labpc_cs: " Ian Abbott
2015-01-30  9:57 ` [PATCH 08/10] staging: comedi: ni_mio_cs: " Ian Abbott
2015-01-30  9:57 ` [PATCH 09/10] staging: comedi: quatech_daqp_cs: " Ian Abbott
2015-01-30  9:57 ` [PATCH 10/10] staging: comedi: comedi_pcmcia.h: move PCMCIA stuff out of comedidev.h Ian Abbott
2015-01-30 17:03 ` [PATCH 00/10] staging: comedi: introduce comedi_pcmcia.h header Hartley Sweeten

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).