From: H Hartley Sweeten Date: Mon, 29 Oct 2012 23:51:33 +0000 (-0700) Subject: staging: comedi: addi-data: move the main #include's to the drivers X-Git-Tag: firefly_0821_release~3680^2~1519^2~841 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=3d41c44370a9a1e78e53c9997289347ec97d46ee;p=firefly-linux-kernel-4.4.55.git staging: comedi: addi-data: move the main #include's to the drivers The addi-data drivers are all built by the main driver files including addi-data/addi_common.c. That file then includes other files depending on what driver is being compiled. This is makes the code quite messy and hard to follow. Start cleaning it up by removing the unneeded #include's in addi_common.c and moving the some of the comedi #include's into the individual driver files. This is the first step in getting rid of the #ifdef'ery in addi_common.c. Signed-off-by: H Hartley Sweeten Cc: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/comedi/drivers/addi-data/addi_common.c b/drivers/staging/comedi/drivers/addi-data/addi_common.c index 6d7f6ea45c6d..9b0f5b2f6a11 100644 --- a/drivers/staging/comedi/drivers/addi-data/addi_common.c +++ b/drivers/staging/comedi/drivers/addi-data/addi_common.c @@ -46,28 +46,6 @@ You should also find the complete GPL in the COPYING file accompanying this sour +----------+-----------+------------------------------------------------+ */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "../../comedidev.h" -#if defined(CONFIG_APCI_1710) || defined(CONFIG_APCI_3200) || defined(CONFIG_APCI_3300) -#include -#endif -#include "../comedi_fc.h" - -#include "addi_common.h" -#include "addi_amcc_s5933.h" - #ifndef ADDIDATA_DRIVER_NAME #define ADDIDATA_DRIVER_NAME "addi_common" #endif diff --git a/drivers/staging/comedi/drivers/addi_apci_035.c b/drivers/staging/comedi/drivers/addi_apci_035.c index 4c00df4bc153..694b58080a50 100644 --- a/drivers/staging/comedi/drivers/addi_apci_035.c +++ b/drivers/staging/comedi/drivers/addi_apci_035.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_035 1 #define ADDIDATA_WATCHDOG 2 /* Or shold it be something else */ diff --git a/drivers/staging/comedi/drivers/addi_apci_1032.c b/drivers/staging/comedi/drivers/addi_apci_1032.c index 7831ce33b02e..bf983fcefab9 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1032.c +++ b/drivers/staging/comedi/drivers/addi_apci_1032.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_1032 1 #define ADDIDATA_DRIVER_NAME "addi_apci_1032" diff --git a/drivers/staging/comedi/drivers/addi_apci_1500.c b/drivers/staging/comedi/drivers/addi_apci_1500.c index bfd84f66d9c0..20e14acd110a 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1500.c +++ b/drivers/staging/comedi/drivers/addi_apci_1500.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_1500 1 #define ADDIDATA_DRIVER_NAME "addi_apci_1500" diff --git a/drivers/staging/comedi/drivers/addi_apci_1516.c b/drivers/staging/comedi/drivers/addi_apci_1516.c index a12e2f421370..09b1c31a40ac 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1516.c +++ b/drivers/staging/comedi/drivers/addi_apci_1516.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_1516 1 #define ADDIDATA_DRIVER_NAME "addi_apci_1516" diff --git a/drivers/staging/comedi/drivers/addi_apci_1564.c b/drivers/staging/comedi/drivers/addi_apci_1564.c index 1b9d598fb6ca..72c626352834 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1564.c +++ b/drivers/staging/comedi/drivers/addi_apci_1564.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_1564 1 #define ADDIDATA_DRIVER_NAME "addi_apci_1564" diff --git a/drivers/staging/comedi/drivers/addi_apci_16xx.c b/drivers/staging/comedi/drivers/addi_apci_16xx.c index d54218d59c58..23093a51d272 100644 --- a/drivers/staging/comedi/drivers/addi_apci_16xx.c +++ b/drivers/staging/comedi/drivers/addi_apci_16xx.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_16XX 1 #define ADDIDATA_DRIVER_NAME "addi_apci_16xx" diff --git a/drivers/staging/comedi/drivers/addi_apci_1710.c b/drivers/staging/comedi/drivers/addi_apci_1710.c index df6ba8ccf56f..4853b31f9e32 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1710.c +++ b/drivers/staging/comedi/drivers/addi_apci_1710.c @@ -1,3 +1,11 @@ +#include + +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_1710 1 #define ADDIDATA_DRIVER_NAME "addi_apci_1710" diff --git a/drivers/staging/comedi/drivers/addi_apci_2016.c b/drivers/staging/comedi/drivers/addi_apci_2016.c index fa50c7bb7ade..a1be859e56e8 100644 --- a/drivers/staging/comedi/drivers/addi_apci_2016.c +++ b/drivers/staging/comedi/drivers/addi_apci_2016.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_2016 1 #define ADDIDATA_DRIVER_NAME "addi_apci_2016" diff --git a/drivers/staging/comedi/drivers/addi_apci_2032.c b/drivers/staging/comedi/drivers/addi_apci_2032.c index 073a8a56dbe4..07446d5d82c0 100644 --- a/drivers/staging/comedi/drivers/addi_apci_2032.c +++ b/drivers/staging/comedi/drivers/addi_apci_2032.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_2032 1 #define ADDIDATA_DRIVER_NAME "addi_apci_2032" diff --git a/drivers/staging/comedi/drivers/addi_apci_2200.c b/drivers/staging/comedi/drivers/addi_apci_2200.c index adfbb5d410ef..0316462bea65 100644 --- a/drivers/staging/comedi/drivers/addi_apci_2200.c +++ b/drivers/staging/comedi/drivers/addi_apci_2200.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_2200 1 #define ADDIDATA_DRIVER_NAME "addi_apci_2200" diff --git a/drivers/staging/comedi/drivers/addi_apci_3001.c b/drivers/staging/comedi/drivers/addi_apci_3001.c index 00ac762965c1..71da7b168f6f 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3001.c +++ b/drivers/staging/comedi/drivers/addi_apci_3001.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_3001 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3001" diff --git a/drivers/staging/comedi/drivers/addi_apci_3120.c b/drivers/staging/comedi/drivers/addi_apci_3120.c index c35515845cf3..db73b736cdda 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3120.c +++ b/drivers/staging/comedi/drivers/addi_apci_3120.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_3120 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3120" diff --git a/drivers/staging/comedi/drivers/addi_apci_3200.c b/drivers/staging/comedi/drivers/addi_apci_3200.c index 159313997dcf..eb4056bf38fc 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3200.c +++ b/drivers/staging/comedi/drivers/addi_apci_3200.c @@ -1,3 +1,11 @@ +#include + +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_3200 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3200" diff --git a/drivers/staging/comedi/drivers/addi_apci_3300.c b/drivers/staging/comedi/drivers/addi_apci_3300.c index 733c69abc43a..94be6449a8c3 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3300.c +++ b/drivers/staging/comedi/drivers/addi_apci_3300.c @@ -1,3 +1,11 @@ +#include + +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_3300 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3300" diff --git a/drivers/staging/comedi/drivers/addi_apci_3501.c b/drivers/staging/comedi/drivers/addi_apci_3501.c index dd2c1d3bc18b..e795f8d4e32d 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3501.c +++ b/drivers/staging/comedi/drivers/addi_apci_3501.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_3501 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3501" diff --git a/drivers/staging/comedi/drivers/addi_apci_3xxx.c b/drivers/staging/comedi/drivers/addi_apci_3xxx.c index 03161c88eac2..fc3d50fcecfe 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3xxx.c +++ b/drivers/staging/comedi/drivers/addi_apci_3xxx.c @@ -1,3 +1,9 @@ +#include "../comedidev.h" +#include "comedi_fc.h" + +#include "addi-data/addi_common.h" +#include "addi-data/addi_amcc_s5933.h" + #define CONFIG_APCI_3XXX 1 #define ADDIDATA_DRIVER_NAME "addi_apci_3xxx"