Removing dead code
cover Removing dead code
Hi all!
As part of the VAMOS[0] research project at the University of
Erlangen we are looking at multiple integrity errors in linux' configuration system.
I've been running a check on the blackfin sourcetree for
config Items not defined in Kconfig and found many such cases. Sourcecode blocks depending on these Items are not reachable from a vanilla kernel -- dead code. I've seen such dead blocks made on purpose e.g. while integrating new features into the kernel but generally they're just useless.
Each of the patches in this patchset removes on such dead
config Item, I'd be glad if you consider applying them. I've been doing deeper analysis of such issues before and can do so again but I'm not so sure they were fastly usefull.
There were many more dead flags in the vanilla kernel cause the config options were only introduced into the blackfin.uclinux.org kernel. I hope i just got patches for real problem flags[1]. Perhaps some syncing here would do something good for the blackfin arch.
I wasn't able to build the kernel for blackfin, so be aware that this patches might break the compiling process, but i don't think so cause they (hopefully) are just removing dead code.
Please keep me informed of this patch getting confirmed /
merged so we can keep track of it.
Regards
Christian Dietrich
[0] http://vamos1.informatik.uni-erlangen.de/
[1] Dead Flags in vanilla kernel but not in blackfin.uclinux.org
## Blackfin -- blackfin.uclinux.org
BFIN_SPI_ADC
NET_DSA_KSZ8893M
BFIN_TWI_LCD
FB_BF537_LQ035
FB_HITACHI_TX09
INPUT_ADXL34X_SPI
USB_NET2272
SPI_BFIN_SPORT
AD2S120X
AD2S90
INPUT_ADXL34X
INPUT_ADXL34X_I2C
INPUT_ADXL34X_SPI
USB_SL811_BFIN_USE_VBUS
JOYSTICK_AD7142
AD7152
SND_SOC_ADAU1361
FB_BFIN_7393
BACKLIGHT_ADP8870
SND_SOC_ADAU1371
AD7414
SND_SOC_ADAU1761
REGULATOR_AD5398
AD7150
AD7416Christian Dietrich (6):
arch/blackfin: Remove config HIGHMEM arch/blackfin: Remove dead CONFIG_BF535 arch/blackfin: Remove CONFIG_MEM_GENERIC_BOARD arch/blackfin: Remove dead CONFIG_REGULATOR_ADP_SWITCH arch/blackfin: Remove dead CONFIG_ADF702X arch/blackfin: Removing dead SND_BLACKFIN_AD183X
arch/blackfin/Kconfig | 5 - arch/blackfin/include/asm/mem_init.h | 18 --- arch/blackfin/include/asm/traps.h | 2 +- arch/blackfin/kernel/traps.c | 11 +-- arch/blackfin/mach-bf527/boards/cm_bf527.c | 18 --- arch/blackfin/mach-bf527/boards/ezkit.c | 18 --- arch/blackfin/mach-bf533/boards/H8606.c | 17 --- arch/blackfin/mach-bf533/boards/cm_bf533.c | 17 --- arch/blackfin/mach-bf533/boards/ezkit.c | 16 --- arch/blackfin/mach-bf533/boards/stamp.c | 17 --- arch/blackfin/mach-bf537/boards/cm_bf537e.c | 17 --- arch/blackfin/mach-bf537/boards/cm_bf537u.c | 17 --- arch/blackfin/mach-bf537/boards/pnav10.c | 18 --- arch/blackfin/mach-bf537/boards/stamp.c | 162 --------------------------- arch/blackfin/mach-bf537/boards/tcm_bf537.c | 17 --- arch/blackfin/mach-bf548/boards/ezkit.c | 18 --- arch/blackfin/mach-bf561/boards/cm_bf561.c | 16 --- arch/blackfin/mach-bf561/boards/ezkit.c | 18 --- arch/blackfin/mm/init.c | 3 - 19 files changed, 2 insertions(+), 423 deletions(-)
PATCH 1/6 arch/blackfin: Remove config HIGHMEM
CONFIG_HIGHMEM can't be selected in blackfin, therefore all references to it can be removed from the arch/blackfin.
--- arch/blackfin/mm/init.c | 3 --- 1 files changed, 0 insertions(+), 3 deletions(-)
arch/blackfin/mm/init.c +0 -3
@@ -49,9 +49,6 @@ void __init paging_init(void) [0] = 0, [ZONE_DMA] = (end_mem - PAGE_OFFSET) >> PAGE_SHIFT, [ZONE_NORMAL] = 0, -#ifdef CONFIG_HIGHMEM - [ZONE_HIGHMEM] = 0, -#endif };/* Set up SFC/DFC registers (user data space) */
Signature · 1 line
1.7.0.4
Re: [PATCH 1/6] arch/blackfin: Remove config HIGHMEM
Quoted 2 lines · Christian Dietrich
CONFIG_HIGHMEMcan't be selected in blackfin, therefore all references to it can be removed from thearch/blackfin.
while currently we dont support highmem (as our current parts max out at 512MiB), this should be feasible in the not-so-far future, in which case we will have highmem support added. so i'm inclined to leave it be as in a highmem world, this is the code we'd want. thanks though. -mike
PATCH 2/6 arch/blackfin: Remove dead CONFIG_BF535
In reply to Christian DietrichCONFIG_BF535 doesn't exist in Kconfig, therefore removing all references to it from the source. In the past[0] there was also removed code for this kind of CPU, reasoning, that it's not supported at all.
[0] 986d6c1e05642edac81cb8cc99f36a26d16ef220
--- arch/blackfin/include/asm/traps.h | 2 +- arch/blackfin/kernel/traps.c | 11 +---------- 2 files changed, 2 insertions(+), 11 deletions(-)
arch/blackfin/include/asm/traps.h +1 -1
@@ -36,7 +36,7 @@#define VEC_CPLB_M (38)#define VEC_CPLB_MHIT (39)#define VEC_WATCH (40) -#define VEC_ISTRU_VL (41)/*ADSP-BF535 only (MH) */ +/* VEC_ISTRU_VL was defined here as (41), but BF535 is not supported */ #define VEC_MISALI_I (42)#define VEC_CPLB_I_VL (43)#define VEC_CPLB_I_M (44)
arch/blackfin/kernel/traps.c +1 -10
@@ -280,17 +280,8 @@ asmlinkage notrace void trap_c(struct pt_regs *fp) goto traps_done; else break; -#ifdef CONFIG_BF535 -/* 0x29 - Instruction fetch access error (535 only) */ -case VEC_ISTRU_VL :/* ADSP-BF535 only (MH) */ - info.si_code =BUS_OPFETCH ; - sig =SIGBUS ; - strerror =KERN_NOTICE "BF535: VEC_ISTRU_VL\n" ; -CHK_DEBUGGER_TRAP_MAYBE (); -break ; -#else +/* 0x29 - Reserved, Caught by default */ -#endif /* 0x2A - Instruction fetch misaligned, handled here */ case VEC_MISALI_I : info.si_code =BUS_ADRALN ;
Signature · 1 line
1.7.0.4
Re: [PATCH 2/6] arch/blackfin: Remove dead CONFIG_BF535
Quoted 3 lines · Christian Dietrich
CONFIG_BF535doesn't exist inKconfig, therefore removing all references to it from the source. In the past[0] there was also removed code for this kind of CPU, reasoning, that it's not supported at all.
while true, i like to keep this vector in the code as a reminder that we dont have to handle it on newer parts. so ill pass on this patch. -mike
PATCH 3/6 arch/blackfin: Remove CONFIG_MEM_GENERIC_BOARD
In reply to Christian DietrichMEM_GENERIC_BOARD depends on GENERIC_BOARD, but this flag was removed in 4f25eb85d64640bc656e72917113a84701521b99, therefore all references to it from the source can be removed
--- arch/blackfin/Kconfig | 5 ----- arch/blackfin/include/asm/mem_init.h | 18 ------------------ 2 files changed, 0 insertions(+), 23 deletions(-)
arch/blackfin/Kconfig +0 -5
@@ -328,11 +328,6 @@ config BF53x depends on (BF531 || BF532 || BF533 || BF534 || BF536 || BF537) default y -config MEM_GENERIC_BOARD - bool - depends on GENERIC_BOARD - default y - config MEM_MT48LC64M4A2FB_7E bool depends on (BFIN533_STAMP)
arch/blackfin/include/asm/mem_init.h +0 -18
@@ -10,7 +10,6 @@ #if defined(CONFIG_MEM_MT48LC16M16A2TG_75) || \ defined(CONFIG_MEM_MT48LC64M4A2FB_7E) || \ defined(CONFIG_MEM_MT48LC16M8A2TG_75) || \ - defined(CONFIG_MEM_GENERIC_BOARD) || \ defined(CONFIG_MEM_MT48LC32M8A2_75) || \ defined(CONFIG_MEM_MT48LC8M32B2B5_7) || \ defined(CONFIG_MEM_MT48LC32M16A2TG_75) || \
@@ -178,7 +177,6 @@#if defined(CONFIG_MEM_MT48LC32M8A2_75 ) || \ defined(CONFIG_MEM_MT48LC64M4A2FB_7E ) || \ - defined(CONFIG_MEM_GENERIC_BOARD ) || \ defined(CONFIG_MEM_MT48LC32M16A2TG_75 ) || \ defined(CONFIG_MEM_MT48LC16M16A2TG_75 ) || \ defined(CONFIG_MEM_MT48LC32M8A2_75 )
@@ -248,22 +246,6 @@#define DDR_tWR DDR_TWR(MIN_DDR_SCLK(15))#endif -#if defined(CONFIG_MEM_GENERIC_BOARD ) -#define DDR_SIZE DEVSZ_512 -#define DDR_WIDTH DEVWD_16 -#define DDR_MAX_tCK 13 - -#define DDR_tRCD DDR_TRCD(3) -#define DDR_tWTR DDR_TWTR(2) -#define DDR_tWR DDR_TWR(2) -#define DDR_tMRD DDR_TMRD(2) -#define DDR_tRP DDR_TRP(3) -#define DDR_tRAS DDR_TRAS(7) -#define DDR_tRC DDR_TRC(10) -#define DDR_tRFC DDR_TRFC(12) -#define DDR_tREFI DDR_TREFI(1288) -#endif -#if (CONFIG_SCLK_HZ <DDR_CLK_HZ (DDR_MAX_tCK))# error "CONFIG_SCLK_HZ is too small (<DDR_CLK_HZ(DDR_MAX_tCK) Hz)."#elif (CONFIG_SCLK_HZ <=133333333 )
Signature · 1 line
1.7.0.4
Re: [PATCH 3/6] arch/blackfin: Remove CONFIG_MEM_GENERIC_BOARD
Quoted 3 lines · Christian Dietrich
MEM_GENERIC_BOARDdepends onGENERIC_BOARD, but this flag was removed in4f25eb85d64640bc656e72917113a84701521b99, therefore all references to it from the source can be removed
thanks, this one is OK and i'll merge it in a bit
-mike
PATCH 4/6 arch/blackfin: Remove dead CONFIG_REGULATOR_ADP_SWITCH
In reply to Christian DietrichREGULATOR_ADP_SWITCH doesn't exist in Kconfig, therefore removing all references for it from the source.
--- arch/blackfin/mach-bf537/boards/stamp.c | 103 ------------------------------- 1 files changed, 0 insertions(+), 103 deletions(-)
arch/blackfin/mach-bf537/boards/stamp.c +0 -103
@@ -35,9 +35,6 @@#include <asm/reboot.h> #include <asm/portmux.h> #include <asm/dpmc.h> -#ifdef CONFIG_REGULATOR_ADP_SWITCH -#include <linux/regulator/adp_switch.h> -#endif #ifdef CONFIG_REGULATOR_AD5398 #include <linux/regulator/ad5398.h> #endif
@@ -2146,97 +2143,6 @@ static struct platform_device bfin_ac97 = { };#endif -#if defined(CONFIG_REGULATOR_ADP_SWITCH ) || defined(CONFIG_REGULATOR_ADP_SWITCH_MODULE ) -#define REGULATOR_ADP122 "adp122" -#define REGULATOR_ADP150 "adp150" - -static struct regulator_consumer_supply adp122_consumers = { - .supply =REGULATOR_ADP122 , -}; - -static struct regulator_consumer_supply adp150_consumers = { - .supply =REGULATOR_ADP150 , -}; - -static struct regulator_init_data adp_switch_regulator_data[] = { - { - .constraints = { - .name =REGULATOR_ADP122 , - .valid_ops_mask =REGULATOR_CHANGE_STATUS , - .min_uA =0 , - .max_uA =300000 , - }, - .num_consumer_supplies =1 ,/* only 1 */ - .consumer_supplies = &adp122_consumers, - .driver_data = (void *)GPIO_PF2 ,/* gpio port only */ - }, - { - .constraints = { - .name =REGULATOR_ADP150 , - .valid_ops_mask =REGULATOR_CHANGE_STATUS , - .min_uA =0 , - .max_uA =150000 , - }, - .num_consumer_supplies =1 ,/* only 1 */ - .consumer_supplies = &adp150_consumers, - .driver_data = (void *)GPIO_PF3 ,/* gpio port only */ - }, -}; - -static struct adp_switch_platform_data adp_switch_pdata = { - .regulator_num =ARRAY_SIZE (adp_switch_regulator_data), - .regulator_data = adp_switch_regulator_data, -}; - -static struct platform_device adp_switch_device = { - .name ="adp_switch" , - .id =0 , - .dev = { - .platform_data = &adp_switch_pdata, - }, -}; - -#if defined(CONFIG_REGULATOR_USERSPACE_CONSUMER ) || \ - defined(CONFIG_REGULATOR_USERSPACE_CONSUMER_MODULE ) -static struct regulator_bulk_data adp122_bulk_data = { - .supply =REGULATOR_ADP122 , -}; - -static struct regulator_userspace_consumer_data adp122_userspace_comsumer_data = { - .name =REGULATOR_ADP122 , - .num_supplies =1 , - .supplies = &adp122_bulk_data, -}; - -static struct platform_device adp122_userspace_consumer_device = { - .name ="reg-userspace-consumer" , - .id =0 , - .dev = { - .platform_data = &adp122_userspace_comsumer_data, - }, -}; - -static struct regulator_bulk_data adp150_bulk_data = { - .supply =REGULATOR_ADP150 , -}; - -static struct regulator_userspace_consumer_data adp150_userspace_comsumer_data = { - .name =REGULATOR_ADP150 , - .num_supplies =1 , - .supplies = &adp150_bulk_data, -}; - -static struct platform_device adp150_userspace_consumer_device = { - .name ="reg-userspace-consumer" , - .id =1 , - .dev = { - .platform_data = &adp150_userspace_comsumer_data, - }, -}; -#endif -#endif - -static struct platform_device *stamp_devices[]__initdata = { &bfin_dpmc,
@@ -2367,15 +2273,6 @@ static struct platform_device *stamp_devices[] __initdata = { &ad5398_userspace_consumer_device,#endif #endif - -#if defined(CONFIG_REGULATOR_ADP_SWITCH ) || defined(CONFIG_REGULATOR_ADP_SWITCH_MODULE ) - &adp_switch_device, -#if defined(CONFIG_REGULATOR_USERSPACE_CONSUMER ) || \ - defined(CONFIG_REGULATOR_USERSPACE_CONSUMER_MODULE ) - &adp122_userspace_consumer_device, - &adp150_userspace_consumer_device, -#endif -#endif };static int __init stamp_init (void )
Signature · 1 line
1.7.0.4
Re: [PATCH 4/6] arch/blackfin: Remove dead CONFIG_REGULATOR_ADP_SWITCH
Quoted 2 lines · Christian Dietrich
REGULATOR_ADP_SWITCHdoesn't exist inKconfig, therefore removing all references for it from the source.
we have patches pending locally to take care of this in a different way, so i'll stick with those
-mike
PATCH 5/6 arch/blackfin: Remove dead CONFIG_ADF702X
In reply to Christian DietrichADF702X doesn't exist in Kconfig, therefore removing all references to it from the source.
--- arch/blackfin/mach-bf537/boards/stamp.c | 59 ------------------------------- 1 files changed, 0 insertions(+), 59 deletions(-)
arch/blackfin/mach-bf537/boards/stamp.c +0 -59
@@ -824,53 +824,6 @@ static struct bfin5xx_spi_chip enc28j60_spi_chip_info = { };#endif -#if defined(CONFIG_ADF702X ) || defined(CONFIG_ADF702X_MODULE ) -static struct bfin5xx_spi_chip adf7021_spi_chip_info = { - .bits_per_word =16 , - .cs_gpio =GPIO_PF10 , -}; - -#include <linux/spi/adf702x.h> -#define TXREG 0x0160A470 -static const u32 adf7021_regs[] = { -0x09608FA0 , -0x00575011 , -0x00A7F092 , -0x2B141563 , -0x81F29E94 , -0x00003155 , -0x050A4F66 , -0x00000007 , -0x00000008 , -0x000231E9 , -0x3296354A , -0x891A2B3B , -0x00000D9C , -0x0000000D , -0x0000000E , -0x0000000F , -}; - -static struct adf702x_platform_data adf7021_platform_data = { - .regs_base = (void *)SPORT1_TCR1 , - .dma_ch_rx =CH_SPORT1_RX , - .dma_ch_tx =CH_SPORT1_TX , - .irq_sport_err =IRQ_SPORT1_ERROR , - .gpio_int_rfs =GPIO_PF8 , - .pin_req = {P_SPORT1_DTPRI ,P_SPORT1_RFS ,P_SPORT1_DRPRI , -P_SPORT1_RSCLK ,P_SPORT1_TSCLK ,0 }, - .adf702x_model =MODEL_ADF7021 , - .adf702x_regs = adf7021_regs, - .tx_reg =TXREG , -}; -static inline void adf702x_mac_init (void ) -{ -random_ether_addr (adf7021_platform_data.mac_addr); -} -#else -static inline void adf702x_mac_init (void ) {} -#endif -#if defined(CONFIG_TOUCHSCREEN_ADS7846 ) || defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE )#include <linux/spi/ads7846.h> static struct bfin5xx_spi_chip ad7873_spi_chip_info = {
@@ -1116,17 +1069,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { .mode = SPI_MODE_3, },#endif -#if defined(CONFIG_ADF702X) || defined(CONFIG_ADF702X_MODULE) - { - .modalias = "adf702x", - .max_speed_hz = 16000000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = 0, /* GPIO controlled SSEL */ - .controller_data = &adf7021_spi_chip_info, - .platform_data = &adf7021_platform_data, - .mode = SPI_MODE_0, - }, -#endif#if defined(CONFIG_TOUCHSCREEN_ADS7846 ) || defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE ) { .modalias = "ads7846",
@@ -2279,7 +2221,6 @@ static int __init stamp_init(void) {printk (KERN_INFO "%s(): registering device resources\n" , __func__);bfin_plat_nand_init (); -adf702x_mac_init ();platform_add_devices (stamp_devices,ARRAY_SIZE (stamp_devices));i2c_register_board_info (0 , bfin_i2c_board_info,ARRAY_SIZE (bfin_i2c_board_info));
Signature · 1 line
1.7.0.4
Mike Frysinger
NAKRe: [PATCH 5/6] arch/blackfin: Remove dead CONFIG_ADF702X
Quoted 2 lines · Christian Dietrich
ADF702X doesn't exist in
Kconfig, therefore removing all references to it from the source.
NAK: this driver is pending for the netdev tree
btw, any ADI/Blackfin maintainer is on the uclinux-dist mailing list, so dont need to include them directly
-mike
PATCH 6/6 arch/blackfin: Removing dead SND_BLACKFIN_AD183X
In reply to Christian DietrichCONFIG_SND_BLACKFIN_AD183X doesn't exist in Kconfig, therefore removing all references to it from the source.
--- arch/blackfin/mach-bf527/boards/cm_bf527.c | 18 ------------------ arch/blackfin/mach-bf527/boards/ezkit.c | 18 ------------------ arch/blackfin/mach-bf533/boards/H8606.c | 17 ----------------- arch/blackfin/mach-bf533/boards/cm_bf533.c | 17 ----------------- arch/blackfin/mach-bf533/boards/ezkit.c | 16 ---------------- arch/blackfin/mach-bf533/boards/stamp.c | 17 ----------------- arch/blackfin/mach-bf537/boards/cm_bf537e.c | 17 ----------------- arch/blackfin/mach-bf537/boards/cm_bf537u.c | 17 ----------------- arch/blackfin/mach-bf537/boards/pnav10.c | 18 ------------------ arch/blackfin/mach-bf537/boards/tcm_bf537.c | 17 ----------------- arch/blackfin/mach-bf548/boards/ezkit.c | 18 ------------------ arch/blackfin/mach-bf561/boards/cm_bf561.c | 16 ---------------- arch/blackfin/mach-bf561/boards/ezkit.c | 18 ------------------ 13 files changed, 0 insertions(+), 224 deletions(-)
arch/blackfin/mach-bf527/boards/cm_bf527.c +0 -18
@@ -343,14 +343,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -421,16 +413,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf527/boards/ezkit.c +0 -18
@@ -432,14 +432,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -548,16 +540,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf533/boards/H8606.c +0 -17
@@ -171,13 +171,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -/* Notice: for blackfin, the speed_hz is the value of register * SPI_BAUD, not the real baudrate */ static struct spi_board_info bfin_spi_board_info[]__initdata = {
@@ -206,16 +199,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) - { - .modalias = "ad1836", - .max_speed_hz = 16, - .bus_num = 1, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif - };/* SPI (0) */
arch/blackfin/mach-bf533/boards/cm_bf533.c +0 -17
@@ -71,13 +71,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -110,16 +103,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf533/boards/ezkit.c +0 -16
@@ -222,13 +222,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_SPI_SPIDEV ) || defined(CONFIG_SPI_SPIDEV_MODULE )static struct bfin5xx_spi_chip spidev_chip_info = { .enable_dma = 0,
@@ -261,15 +254,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif#if defined(CONFIG_SPI_SPIDEV ) || defined(CONFIG_SPI_SPIDEV_MODULE ) { .modalias = "spidev",
arch/blackfin/mach-bf533/boards/stamp.c +0 -17
@@ -184,13 +184,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_SPI_SPIDEV ) || defined(CONFIG_SPI_SPIDEV_MODULE )static struct bfin5xx_spi_chip spidev_chip_info = { .enable_dma = 0,
@@ -251,16 +244,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif -#if defined(CONFIG_SPI_SPIDEV ) || defined(CONFIG_SPI_SPIDEV_MODULE ) { .modalias = "spidev",
arch/blackfin/mach-bf537/boards/cm_bf537e.c +0 -17
@@ -73,13 +73,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -112,16 +105,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf537/boards/cm_bf537u.c +0 -17
@@ -74,13 +74,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -113,16 +106,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf537/boards/pnav10.c +0 -18
@@ -175,14 +175,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -238,16 +230,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf537/boards/tcm_bf537.c +0 -17
@@ -74,13 +74,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -113,16 +106,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf548/boards/ezkit.c +0 -18
@@ -967,14 +967,6 @@ static struct bfin5xx_spi_chip spi_flash_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_TOUCHSCREEN_AD7877 ) || defined(CONFIG_TOUCHSCREEN_AD7877_MODULE )static struct bfin5xx_spi_chip spi_ad7877_chip_info = { .enable_dma = 0,
@@ -1024,16 +1016,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { .mode = SPI_MODE_3, },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 1, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif#if defined(CONFIG_TOUCHSCREEN_AD7877 ) || defined(CONFIG_TOUCHSCREEN_AD7877_MODULE ) { .modalias = "ad7877",
arch/blackfin/mach-bf561/boards/cm_bf561.c +0 -16
@@ -72,13 +72,6 @@ static struct bfin5xx_spi_chip spi_adc_chip_info = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE )static struct bfin5xx_spi_chip mmc_spi_chip_info = { .enable_dma = 0,
@@ -111,15 +104,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { },#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X) || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif#if defined(CONFIG_MMC_SPI ) || defined(CONFIG_MMC_SPI_MODULE ) { .modalias = "mmc_spi",
arch/blackfin/mach-bf561/boards/ezkit.c +0 -18
@@ -274,14 +274,6 @@ static struct platform_device ezkit_flash_device = { };#endif -#if defined(CONFIG_SND_BLACKFIN_AD183X ) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) -static struct bfin5xx_spi_chip ad1836_spi_chip_info = { - .enable_dma =0 , - .bits_per_word =16 , -}; -#endif -#if defined(CONFIG_SPI_SPIDEV ) || defined(CONFIG_SPI_SPIDEV_MODULE )static struct bfin5xx_spi_chip spidev_chip_info = { .enable_dma = 0,
@@ -328,16 +320,6 @@ static struct platform_device bfin_spi0_device = {#endif static struct spi_board_info bfin_spi_board_info[] __initdata = { -#if defined(CONFIG_SND_BLACKFIN_AD183X ) \ - || defined(CONFIG_SND_BLACKFIN_AD183X_MODULE ) - { - .modalias = "ad1836", - .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ - .bus_num = 0, - .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, - .controller_data = &ad1836_spi_chip_info, - }, -#endif #if defined(CONFIG_SPI_SPIDEV) || defined(CONFIG_SPI_SPIDEV_MODULE) { .modalias = "spidev",
Signature · 1 line
1.7.0.4
Mike Frysinger
NAKRe: [PATCH 6/6] arch/blackfin: Removing dead SND_BLACKFIN_AD183X
Quoted 2 lines · Christian Dietrich
CONFIG_SND_BLACKFIN_AD183Xdoesn't exist inKconfig, therefore removing all references to it from the source.
NAK: this driver is pending for the ASoC tree
-mike
Quoted 4 lines · Christian Dietrich
There were many more dead flags in the vanilla kernel cause the config options were only introduced into the blackfin.uclinux.org kernel. I hope i just got patches for real problem flags[1]. Perhaps some syncing here would do something good for the blackfin arch.
yeah, our board resources often lead the rest of the tree in the vanilla release. this is because it's easy for us to merge board resources without adversely impacting anything else, and sometimes we dont know when the actual driver will get around to being merged. -ike