Move the addi-data specific #include's from addi_common.h to the individual driver files. The apci-1710, apci-3200, and apci-3300 drivers still have floating point code in them and are currently disabled in the Kconfig and Makefile. For now, move the fpu_{begin,end} functions from addi_common.c to the main driver file so we can get rid of the #ifdef'ery. Signed-off-by: H Hartley Sweeten <hsweeten@xxxxxxxxxxxxxxxxxxx> Cc: Ian Abbott <abbotti@xxxxxxxxx> Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- .../staging/comedi/drivers/addi-data/addi_common.c | 60 ---------------------- drivers/staging/comedi/drivers/addi_apci_035.c | 2 + drivers/staging/comedi/drivers/addi_apci_1032.c | 2 + drivers/staging/comedi/drivers/addi_apci_1500.c | 2 + drivers/staging/comedi/drivers/addi_apci_1516.c | 2 + drivers/staging/comedi/drivers/addi_apci_1564.c | 2 + drivers/staging/comedi/drivers/addi_apci_16xx.c | 2 + drivers/staging/comedi/drivers/addi_apci_1710.c | 12 +++++ drivers/staging/comedi/drivers/addi_apci_2016.c | 2 + drivers/staging/comedi/drivers/addi_apci_2032.c | 2 + drivers/staging/comedi/drivers/addi_apci_2200.c | 2 + drivers/staging/comedi/drivers/addi_apci_3001.c | 2 + drivers/staging/comedi/drivers/addi_apci_3120.c | 2 + drivers/staging/comedi/drivers/addi_apci_3200.c | 12 +++++ drivers/staging/comedi/drivers/addi_apci_3300.c | 12 +++++ drivers/staging/comedi/drivers/addi_apci_3501.c | 2 + drivers/staging/comedi/drivers/addi_apci_3xxx.c | 2 + 17 files changed, 62 insertions(+), 60 deletions(-) diff --git a/drivers/staging/comedi/drivers/addi-data/addi_common.c b/drivers/staging/comedi/drivers/addi-data/addi_common.c index 985ec88..f4311a4 100644 --- a/drivers/staging/comedi/drivers/addi-data/addi_common.c +++ b/drivers/staging/comedi/drivers/addi-data/addi_common.c @@ -54,66 +54,6 @@ You should also find the complete GPL in the COPYING file accompanying this sour /* Update-0.7.57->0.7.68MODULE_DESCRIPTION("Comedi ADDI-DATA module"); */ /* Update-0.7.57->0.7.68MODULE_LICENSE("GPL"); */ -#if defined(CONFIG_APCI_1710) || defined(CONFIG_APCI_3200) || defined(CONFIG_APCI_3300) -/* BYTE b_SaveFPUReg [94]; */ - -void fpu_begin(void) -{ - /* asm ("fstenv b_SaveFPUReg"); */ - kernel_fpu_begin(); -} - -void fpu_end(void) -{ - /* asm ("frstor b_SaveFPUReg"); */ - kernel_fpu_end(); -} -#endif - -#include "addi_eeprom.c" -#if (defined (CONFIG_APCI_3120) || defined (CONFIG_APCI_3001)) -#include "hwdrv_apci3120.c" -#endif -#ifdef CONFIG_APCI_1032 -#include "hwdrv_apci1032.c" -#endif -#ifdef CONFIG_APCI_1516 -#include "hwdrv_apci1516.c" -#endif -#ifdef CONFIG_APCI_2016 -#include "hwdrv_apci2016.c" -#endif -#ifdef CONFIG_APCI_2032 -#include "hwdrv_apci2032.c" -#endif -#ifdef CONFIG_APCI_2200 -#include "hwdrv_apci2200.c" -#endif -#ifdef CONFIG_APCI_1564 -#include "hwdrv_apci1564.c" -#endif -#ifdef CONFIG_APCI_1500 -#include "hwdrv_apci1500.c" -#endif -#ifdef CONFIG_APCI_3501 -#include "hwdrv_apci3501.c" -#endif -#ifdef CONFIG_APCI_035 -#include "hwdrv_apci035.c" -#endif -#if (defined (CONFIG_APCI_3200) || defined (CONFIG_APCI_3300)) -#include "hwdrv_apci3200.c" -#endif -#ifdef CONFIG_APCI_1710 -#include "hwdrv_APCI1710.c" -#endif -#ifdef CONFIG_APCI_16XX -#include "hwdrv_apci16xx.c" -#endif -#ifdef CONFIG_APCI_3XXX -#include "hwdrv_apci3xxx.c" -#endif - #ifndef COMEDI_SUBD_TTLIO #define COMEDI_SUBD_TTLIO 11 /* Digital Input Output But TTL */ #endif diff --git a/drivers/staging/comedi/drivers/addi_apci_035.c b/drivers/staging/comedi/drivers/addi_apci_035.c index 694b580..85c7ee4 100644 --- a/drivers/staging/comedi/drivers/addi_apci_035.c +++ b/drivers/staging/comedi/drivers/addi_apci_035.c @@ -10,6 +10,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_035" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci035.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_1032.c b/drivers/staging/comedi/drivers/addi_apci_1032.c index bf983fc..e7a8f92f 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1032.c +++ b/drivers/staging/comedi/drivers/addi_apci_1032.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_1032" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci1032.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_1500.c b/drivers/staging/comedi/drivers/addi_apci_1500.c index 20e14ac..c2a89c4 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1500.c +++ b/drivers/staging/comedi/drivers/addi_apci_1500.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_1500" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci1500.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_1516.c b/drivers/staging/comedi/drivers/addi_apci_1516.c index 09b1c31..2504b64 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1516.c +++ b/drivers/staging/comedi/drivers/addi_apci_1516.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_1516" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci1516.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_1564.c b/drivers/staging/comedi/drivers/addi_apci_1564.c index 72c6263..a37b3c4 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1564.c +++ b/drivers/staging/comedi/drivers/addi_apci_1564.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_1564" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci1564.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_16xx.c b/drivers/staging/comedi/drivers/addi_apci_16xx.c index 23093a5..f8ef19f 100644 --- a/drivers/staging/comedi/drivers/addi_apci_16xx.c +++ b/drivers/staging/comedi/drivers/addi_apci_16xx.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_16xx" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci16xx.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_1710.c b/drivers/staging/comedi/drivers/addi_apci_1710.c index 4853b31..fb805d0 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1710.c +++ b/drivers/staging/comedi/drivers/addi_apci_1710.c @@ -6,8 +6,20 @@ #include "addi-data/addi_common.h" #include "addi-data/addi_amcc_s5933.h" +static void fpu_begin(void) +{ + kernel_fpu_begin(); +} + +static void fpu_end(void) +{ + kernel_fpu_end(); +} + #define CONFIG_APCI_1710 1 #define ADDIDATA_DRIVER_NAME "addi_apci_1710" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_APCI1710.c" #include "addi-data/addi_common.c" diff --git a/drivers/staging/comedi/drivers/addi_apci_2016.c b/drivers/staging/comedi/drivers/addi_apci_2016.c index a1be859..bb2ee96 100644 --- a/drivers/staging/comedi/drivers/addi_apci_2016.c +++ b/drivers/staging/comedi/drivers/addi_apci_2016.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_2016" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci2016.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_2032.c b/drivers/staging/comedi/drivers/addi_apci_2032.c index 07446d5..7733758 100644 --- a/drivers/staging/comedi/drivers/addi_apci_2032.c +++ b/drivers/staging/comedi/drivers/addi_apci_2032.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_2032" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci2032.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_2200.c b/drivers/staging/comedi/drivers/addi_apci_2200.c index 0316462..ac13fc3 100644 --- a/drivers/staging/comedi/drivers/addi_apci_2200.c +++ b/drivers/staging/comedi/drivers/addi_apci_2200.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_2200" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci2200.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_3001.c b/drivers/staging/comedi/drivers/addi_apci_3001.c index 71da7b1..084dfcf 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3001.c +++ b/drivers/staging/comedi/drivers/addi_apci_3001.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_3001" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci3120.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_3120.c b/drivers/staging/comedi/drivers/addi_apci_3120.c index db73b73..6324f745 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3120.c +++ b/drivers/staging/comedi/drivers/addi_apci_3120.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_3120" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci3120.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_3200.c b/drivers/staging/comedi/drivers/addi_apci_3200.c index eb4056b..34ac22a 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3200.c +++ b/drivers/staging/comedi/drivers/addi_apci_3200.c @@ -6,8 +6,20 @@ #include "addi-data/addi_common.h" #include "addi-data/addi_amcc_s5933.h" +static void fpu_begin(void) +{ + kernel_fpu_begin(); +} + +static void fpu_end(void) +{ + kernel_fpu_end(); +} + #define CONFIG_APCI_3200 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3200" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci3200.c" #include "addi-data/addi_common.c" diff --git a/drivers/staging/comedi/drivers/addi_apci_3300.c b/drivers/staging/comedi/drivers/addi_apci_3300.c index 94be644..5d3d567 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3300.c +++ b/drivers/staging/comedi/drivers/addi_apci_3300.c @@ -6,8 +6,20 @@ #include "addi-data/addi_common.h" #include "addi-data/addi_amcc_s5933.h" +static void fpu_begin(void) +{ + kernel_fpu_begin(); +} + +static void fpu_end(void) +{ + kernel_fpu_end(); +} + #define CONFIG_APCI_3300 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3300" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci3200.c" #include "addi-data/addi_common.c" diff --git a/drivers/staging/comedi/drivers/addi_apci_3501.c b/drivers/staging/comedi/drivers/addi_apci_3501.c index e795f8d..8fb5b50 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3501.c +++ b/drivers/staging/comedi/drivers/addi_apci_3501.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_3501" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci3501.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); diff --git a/drivers/staging/comedi/drivers/addi_apci_3xxx.c b/drivers/staging/comedi/drivers/addi_apci_3xxx.c index fc3d50f..c5205d3 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3xxx.c +++ b/drivers/staging/comedi/drivers/addi_apci_3xxx.c @@ -8,6 +8,8 @@ #define ADDIDATA_DRIVER_NAME "addi_apci_3xxx" +#include "addi-data/addi_eeprom.c" +#include "addi-data/hwdrv_apci3xxx.c" #include "addi-data/addi_common.c" MODULE_AUTHOR("Comedi http://www.comedi.org"); -- 1.7.11 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/devel