Tree sweep to fix up initconst
Subsystems (50)
This is a global tree sweep to fix up initconst section problems.
Any variable const in initdata must be marked __initconst, not initdata. const __read_mostly is not allowed.
Otherwise the global sections can get a read only marking and in some circumstances the compiler/and or the linker will detect conflicts.
This patchkit aims to fix it up everywhere.
Also available in git://github.com/andikleen/linux-misc.git const-sections
Note I plan to ask Linus to pull this directly.
-Andi
PATCH 1/27 Initconst section fixes for ARM
From: Andi Kleen <[email protected]>
--- arch/arm/mach-at91/clock.c | 2 +- arch/arm/mach-davinci/board-tnetv107x-evm.c | 6 ++-- arch/arm/mach-davinci/da830.c | 48 +++++++++++++------------- arch/arm/mach-davinci/da850.c | 6 ++-- arch/arm/mach-msm/board-qsd8x50.c | 4 +- arch/arm/mach-omap2/display.c | 6 ++-- arch/arm/mach-omap2/pm24xx.c | 2 +- arch/arm/plat-omap/dmtimer.c | 6 ++-- 8 files changed, 40 insertions(+), 40 deletions(-)
arch/arm/mach-at91/clock.c +1 -1
@@ -570,7 +570,7 @@ fail:return 0 ; } -static struct clk *const standard_pmc_clocks[]__initdata = { +static struct clk *const standard_pmc_clocks[]__initconst = {/* four primary clocks */ &clk32k, &main_clk,
arch/arm/mach-davinci/board-tnetv107x-evm.c +3 -3
@@ -88,7 +88,7 @@ static struct davinci_mmc_config mmc_config = { .version = MMC_CTLR_VERSION_1, }; -static const short sdio1_pins[]__initdata = { +static const short sdio1_pins[]__initconst = {TNETV107X_SDIO1_CLK_1 ,TNETV107X_SDIO1_CMD_1 ,TNETV107X_SDIO1_DATA0_1 ,TNETV107X_SDIO1_DATA1_1 ,TNETV107X_SDIO1_DATA2_1 ,TNETV107X_SDIO1_DATA3_1 ,
@@ -96,12 +96,12 @@ static const short sdio1_pins[] __initdata = {-1 }; -static const short uart1_pins[]__initdata = { +static const short uart1_pins[]__initconst = {TNETV107X_UART1_RD ,TNETV107X_UART1_TD ,-1 }; -static const short ssp_pins[]__initdata = { +static const short ssp_pins[]__initconst = {TNETV107X_SSP0_0 ,TNETV107X_SSP0_1 ,TNETV107X_SSP0_2 ,TNETV107X_SSP1_0 ,TNETV107X_SSP1_1 ,TNETV107X_SSP1_2 ,TNETV107X_SSP1_3 ,-1
arch/arm/mach-davinci/da830.c +24 -24
168 lines not on this page · raw message
arch/arm/mach-davinci/da850.c +3 -3
@@ -598,17 +598,17 @@ static const struct mux_config da850_pins[] = {#endif }; -const short da850_i2c0_pins[]__initdata = { +const short da850_i2c0_pins[]__initconst = {DA850_I2C0_SDA ,DA850_I2C0_SCL ,-1 }; -const short da850_i2c1_pins[]__initdata = { +const short da850_i2c1_pins[]__initconst = {DA850_I2C1_SCL ,DA850_I2C1_SDA ,-1 }; -const short da850_lcdcntl_pins[]__initdata = { +const short da850_lcdcntl_pins[]__initconst = {DA850_LCD_D_0 ,DA850_LCD_D_1 ,DA850_LCD_D_2 ,DA850_LCD_D_3 ,DA850_LCD_D_4 ,DA850_LCD_D_5 ,DA850_LCD_D_6 ,DA850_LCD_D_7 ,DA850_LCD_D_8 ,DA850_LCD_D_9 ,DA850_LCD_D_10 ,DA850_LCD_D_11 ,
arch/arm/mach-msm/board-qsd8x50.c +2 -2
@@ -40,8 +40,8 @@extern struct sys_timer msm_timer; -static const resource_size_t qsd8x50_surf_smc91x_base__initdata =0x70000300 ; -static const unsigned qsd8x50_surf_smc91x_gpio__initdata =156 ; +static const resource_size_t qsd8x50_surf_smc91x_base__initconst =0x70000300 ; +static const unsigned qsd8x50_surf_smc91x_gpio__initconst =156 ;/* Leave smc91x resources empty here, as we'll fill them in * at run-time: they vary from board to board, and the true
arch/arm/mach-omap2/display.c +3 -3
@@ -49,14 +49,14 @@ struct omap_dss_hwmod_data {const int id; }; -static const struct omap_dss_hwmod_data omap2_dss_hwmod_data[]__initdata = { +static const struct omap_dss_hwmod_data omap2_dss_hwmod_data[]__initconst = { {"dss_core" ,"omapdss_dss" ,-1 }, {"dss_dispc" ,"omapdss_dispc" ,-1 }, {"dss_rfbi" ,"omapdss_rfbi" ,-1 }, {"dss_venc" ,"omapdss_venc" ,-1 }, }; -static const struct omap_dss_hwmod_data omap3_dss_hwmod_data[]__initdata = { +static const struct omap_dss_hwmod_data omap3_dss_hwmod_data[]__initconst = { {"dss_core" ,"omapdss_dss" ,-1 }, {"dss_dispc" ,"omapdss_dispc" ,-1 }, {"dss_rfbi" ,"omapdss_rfbi" ,-1 },
@@ -64,7 +64,7 @@ static const struct omap_dss_hwmod_data omap3_dss_hwmod_data[] __initdata = { { "dss_dsi1", "omapdss_dsi1", -1 }, }; -static const struct omap_dss_hwmod_data omap4_dss_hwmod_data[]__initdata = { +static const struct omap_dss_hwmod_data omap4_dss_hwmod_data[]__initconst = { {"dss_core" ,"omapdss_dss" ,-1 }, {"dss_dispc" ,"omapdss_dispc" ,-1 }, { "dss_rfbi", "omapdss_rfbi", -1 },
arch/arm/mach-omap2/pm24xx.c +1 -1
@@ -355,7 +355,7 @@ static const struct platform_suspend_ops omap_pm_ops = { .valid = suspend_valid_only_mem, };#else -static const struct platform_suspend_ops __initdata omap_pm_ops; +static const struct platform_suspend_ops __initconst omap_pm_ops;#endif /* CONFIG_SUSPEND */ /* XXX This function should be shareable between OMAP2xxx and OMAP3 */
arch/arm/plat-omap/dmtimer.c +3 -3
@@ -78,7 +78,7 @@ static struct omap_dm_timer omap2_dm_timers[] = { { .phys_base = 0x4808a000, .irq = INT_24XX_GPTIMER12 }, }; -static const char *omap2_dm_source_names[]__initdata = { +static const char *const omap2_dm_source_names[]__initconst = {"sys_ck" ,"func_32k_ck" , "alt_ck",
@@ -111,7 +111,7 @@ static struct omap_dm_timer omap3_dm_timers[] = { { .phys_base = 0x48304000, .irq = INT_34XX_GPT12_IRQ }, }; -static const char *omap3_dm_source_names[]__initdata = { +static const char *const omap3_dm_source_names[]__initconst = {"sys_ck" ,"omap_32k_fck" , NULL
@@ -142,7 +142,7 @@ static struct omap_dm_timer omap4_dm_timers[] = { { .phys_base = 0x48088000, .irq = OMAP44XX_IRQ_GPT11 }, { .phys_base = 0x4a320000, .irq = OMAP44XX_IRQ_GPT12 }, }; -static const char *omap4_dm_source_names[]__initdata = { +static const char *const omap4_dm_source_names[]__initconst = {"sys_clkin_ck" ,"sys_32k_ck" , NULL
Signature · 1 line
1.7.4.4
PATCH 2/27 Initconst section fixes for FRV
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/frv/kernel/setup.c | 2 +- arch/frv/mb93090-mb00/pci-irq.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
arch/frv/kernel/setup.c +1 -1
@@ -184,7 +184,7 @@ static struct clock_cmode __pminitdata clock_cmodes_fr555[16] = { [6] = { _x1, _x1_5, _x1_5, _x4_5, _x0_375 }, }; -static const struct clock_cmode __pminitdata *clock_cmodes; +static const struct clock_cmode __pminitconst *clock_cmodes; static int __pminitdata clock_doubled; static struct uart_port __pminitdata __frv_uart0 = {
arch/frv/mb93090-mb00/pci-irq.c +1 -1
@@ -28,7 +28,7 @@* */ -static const uint8_t __initdata pci_bus0_irq_routing[32 ][4 ] = { +static const uint8_t __initconst pci_bus0_irq_routing[32 ][4 ] = { [0 ] = {IRQ_FPGA_MB86943_PCI_INTA }, [16 ] = {IRQ_FPGA_RTL8029_INTA }, [17 ] = {IRQ_FPGA_PCI_INTC ,IRQ_FPGA_PCI_INTD ,IRQ_FPGA_PCI_INTA ,IRQ_FPGA_PCI_INTB },
Signature · 1 line
1.7.4.4
Re: [PATCH 02/27] Initconst section fixes for FRV
Quoted 4 lines · Andi Kleen
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>
PATCH 3/27 Initconst section fixes for H8300
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/h8300/kernel/timer/itu.c | 2 +- arch/h8300/kernel/timer/timer16.c | 2 +- arch/h8300/kernel/timer/timer8.c | 2 +- arch/h8300/kernel/timer/tpu.c | 2 +- arch/h8300/platform/h8300h/irq.c | 4 ++-- arch/h8300/platform/h8s/irq.c | 4 ++-- 6 files changed, 8 insertions(+), 8 deletions(-)
arch/h8300/kernel/timer/itu.c +1 -1
@@ -62,7 +62,7 @@ static struct irqaction itu_irq = { .flags = IRQF_DISABLED | IRQF_TIMER, }; -static const int __initdata divide_rate[] = {1 ,2 ,4 ,8 }; +static const int __initconst divide_rate[] = {1 ,2 ,4 ,8 };void __init h8300_timer_setup (void ) {
arch/h8300/kernel/timer/timer16.c +1 -1
@@ -57,7 +57,7 @@ static struct irqaction timer16_irq = { .flags = IRQF_DISABLED | IRQF_TIMER, }; -static const int __initdata divide_rate[] = {1 ,2 ,4 ,8 }; +static const int __initconst divide_rate[] = {1 ,2 ,4 ,8 };void __init h8300_timer_setup (void ) {
arch/h8300/kernel/timer/timer8.c +1 -1
@@ -77,7 +77,7 @@ static struct irqaction timer8_irq = { .flags = IRQF_DISABLED | IRQF_TIMER, }; -static const int __initdata divide_rate[] = {8 ,64 ,8192 }; +static const int __initconst divide_rate[] = {8 ,64 ,8192 };void __init h8300_timer_setup (void ) {
arch/h8300/kernel/timer/tpu.c +1 -1
@@ -66,7 +66,7 @@ static struct irqaction tpu_irq = { .flags = IRQF_DISABLED | IRQF_TIMER, }; -static const int __initdata divide_rate[] = { +static const int __initconst divide_rate[] = { #if CONFIG_H8300_TPU_CH == 0 1,4,16,64,0,0,0,0, #elif (CONFIG_H8300_TPU_CH == 1) || (CONFIG_H8300_TPU_CH == 5)
arch/h8300/platform/h8300h/irq.c +2 -2
@@ -14,14 +14,14 @@#include <asm/gpio.h> #include <asm/regs306x.h> -const int __initdata h8300_saved_vectors[] = { +const int __initconst h8300_saved_vectors[] = { #if defined(CONFIG_GDB_DEBUG) TRAP3_VEC, /* TRAPA #3 is GDB breakpoint */ #endif -1, }; -const h8300_vector __initdata h8300_trap_table[] = { +const h8300_vector __initconst h8300_trap_table[] = { 0, 0, 0, 0, 0, 0, 0, 0, system_call, 0,
arch/h8300/platform/h8s/irq.c +2 -2
@@ -18,7 +18,7 @@#include <asm/regs267x.h> /* saved vector list */ -const int __initdata h8300_saved_vectors[]={ +const int __initconst h8300_saved_vectors[]={#if defined(CONFIG_GDB_DEBUG )TRACE_VEC , TRAP3_VEC,
@@ -27,7 +27,7 @@ const int __initdata h8300_saved_vectors[]={ };/* trap entry table */ -const H8300_VECTOR __initdata h8300_trap_table[] = { +const H8300_VECTOR __initconst h8300_trap_table[] = {0 ,0 ,0 ,0 ,0 , trace_break,/* TRACE */ 0 ,0 ,
Signature · 1 line
1.7.4.4
PATCH 4/27 Initconst section fixes for IA64
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/ia64/xen/irq_xen.c | 2 +- arch/ia64/xen/irq_xen.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
arch/ia64/xen/irq_xen.c +1 -1
@@ -433,7 +433,7 @@ xen_resend_irq(unsigned int vector) (void )resend_irq_on_evtchn (vector); } -const struct pv_irq_ops xen_irq_ops__initdata = { +const struct pv_irq_ops xen_irq_ops__initconst = { .register_ipi = xen_register_ipi, .assign_irq_vector = xen_assign_irq_vector,
arch/ia64/xen/irq_xen.h +1 -1
@@ -27,7 +27,7 @@ extern void (*late_time_init)(void);extern char xen_event_callback;void __init xen_init_IRQ (void ); -extern const struct pv_irq_ops xen_irq_ops__initdata ; +extern const struct pv_irq_ops xen_irq_ops__initconst ;extern void xen_smp_intr_init (void );extern void xen_send_ipi (int cpu,int vec);
Signature · 1 line
1.7.4.4
PATCH 5/27 Initconst section fixes for M68K
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/m68k/emu/nfeth.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
arch/m68k/emu/nfeth.c +1 -1
@@ -39,7 +39,7 @@ enum {#define MAX_UNIT 8/* These identify the driver base version and may not be removed. */ -static const char version[]__devinitdata = +static const char version[]__devinitconst = KERN_INFO KBUILD_MODNAME ".c:v" DRV_VERSION " " DRV_RELDATE" S.Opichal, M.Jurik, P.Stehlik\n" KERN_INFO " http://aranym.org/\n" ;
Signature · 1 line
1.7.4.4
Re: [PATCH 05/27] Initconst section fixes for M68K
Quoted 4 lines · Andi Kleen
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>
Quoted 14 lines
---
arch/m68k/emu/nfeth.c | 2 +-1 files changed, 1 insertions(+), 1 deletions(-)arch/m68k/emu/nfeth.c +1
-1@@ -39,7 +39,7 @@ enum { #define MAX_UNIT 8 /* These identify the driver base version and may not be removed. */ -static const char version[] __devinitdata = +static const char version[] __devinitconst =
Quoted 3 lines
KERN_INFO
KBUILD_MODNAME".c:v"DRV_VERSION" "DRV_RELDATE" S.Opichal, M.Jurik, P.Stehlik\n"
KERN_INFO " http://aranym.org/\n";
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds
PATCH 6/27 Initconst section fixes for MIPS
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/mips/bcm63xx/boards/board_bcm963xx.c | 2 +- arch/mips/bcm63xx/dev-pcmcia.c | 2 +- arch/mips/mti-malta/malta-setup.c | 2 +- arch/mips/pci/fixup-mpc30x.c | 4 ++-- arch/mips/pci/pci-octeon.c | 2 +- arch/mips/powertv/asic/asic-calliope.c | 2 +- arch/mips/powertv/asic/asic-cronus.c | 2 +- arch/mips/powertv/asic/asic-gaia.c | 2 +- arch/mips/powertv/asic/asic-zeus.c | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-)
arch/mips/bcm63xx/boards/board_bcm963xx.c +1 -1
@@ -591,7 +591,7 @@ static struct board_info __initdata board_DWVS0 = {/* * all boards */ -static const struct board_info __initdata *bcm963xx_boards[] = { +static const struct board_info __initconst *bcm963xx_boards[] = { #ifdef CONFIG_BCM63XX_CPU_6338 &board_96338gw, &board_96338w,
arch/mips/bcm63xx/dev-pcmcia.c +1 -1
@@ -79,7 +79,7 @@ static int __init config_pcmcia_cs(unsigned int cs,return ret; } -static const __initdata struct { +static const __initconst struct { unsigned int cs; unsigned int base; unsigned int size;
arch/mips/mti-malta/malta-setup.c +1 -1
@@ -111,7 +111,7 @@ static void __init pci_clock_check(void)unsigned int __iomem *jmpr_p = (unsigned int *)ioremap (MALTA_JMPRS_REG ,sizeof (unsigned int ));int jmpr = (__raw_readl (jmpr_p) >>2 ) &0x07 ; -static const int pciclocks[]__initdata = { +static const int pciclocks[]__initconst = {33 ,20 ,25 ,30 ,12 ,16 ,37 ,10 };int pciclock = pciclocks[jmpr];
arch/mips/pci/fixup-mpc30x.c +2 -2
@@ -22,13 +22,13 @@#include <asm/vr41xx/mpc30x.h> -static const int internal_func_irqs[]__initdata = { +static const int internal_func_irqs[]__initconst = {VRC4173_CASCADE_IRQ ,VRC4173_AC97_IRQ ,VRC4173_USB_IRQ , }; -static const int irq_tab_mpc30x[]__initdata = { +static const int irq_tab_mpc30x[]__initconst = { [12 ] =VRC4173_PCMCIA1_IRQ , [13 ] =VRC4173_PCMCIA2_IRQ , [29 ] =MQ200_IRQ ,
arch/mips/pci/pci-octeon.c +1 -1
@@ -58,7 +58,7 @@ union octeon_pci_address { } s; }; -int __initdata (*octeon_pcibios_map_irq)(const struct pci_dev *dev, +int __initconst (*octeon_pcibios_map_irq)(const struct pci_dev *dev,u8 slot,u8 pin);enum octeon_dma_bar_type octeon_dma_bar_type =OCTEON_DMA_BAR_TYPE_INVALID ;
arch/mips/powertv/asic/asic-calliope.c +1 -1
@@ -28,7 +28,7 @@#define CALLIOPE_ADDR (x) (CALLIOPE_IO_BASE + (x)) -const struct register_map calliope_register_map__initdata = { +const struct register_map calliope_register_map__initconst = { .eic_slow0_strt_add = {.phys =CALLIOPE_ADDR (0x800000 )}, .eic_cfg_bits = {.phys =CALLIOPE_ADDR (0x800038 )}, .eic_ready_status = {.phys =CALLIOPE_ADDR (0x80004c )},
arch/mips/powertv/asic/asic-cronus.c +1 -1
@@ -28,7 +28,7 @@#define CRONUS_ADDR (x) (CRONUS_IO_BASE + (x)) -const struct register_map cronus_register_map__initdata = { +const struct register_map cronus_register_map__initconst = { .eic_slow0_strt_add = {.phys =CRONUS_ADDR (0x000000 )}, .eic_cfg_bits = {.phys =CRONUS_ADDR (0x000038 )}, .eic_ready_status = {.phys =CRONUS_ADDR (0x00004C )},
arch/mips/powertv/asic/asic-gaia.c +1 -1
@@ -23,7 +23,7 @@#include <linux/init.h> #include <asm/mach-powertv/asic.h> -const struct register_map gaia_register_map__initdata = { +const struct register_map gaia_register_map__initconst = { .eic_slow0_strt_add = {.phys =GAIA_IO_BASE +0x000000 }, .eic_cfg_bits = {.phys =GAIA_IO_BASE +0x000038 }, .eic_ready_status = {.phys =GAIA_IO_BASE +0x00004C },
arch/mips/powertv/asic/asic-zeus.c +1 -1
@@ -28,7 +28,7 @@#define ZEUS_ADDR (x) (ZEUS_IO_BASE + (x)) -const struct register_map zeus_register_map__initdata = { +const struct register_map zeus_register_map__initconst = { .eic_slow0_strt_add = {.phys =ZEUS_ADDR (0x000000 )}, .eic_cfg_bits = {.phys =ZEUS_ADDR (0x000038 )}, .eic_ready_status = {.phys =ZEUS_ADDR (0x00004c )},
Signature · 1 line
1.7.4.4
Re: [PATCH 06/27] Initconst section fixes for MIPS
On Thu, Sep 15, 2011 at 01:09:33PM -0700, Andi Kleen wrote:
Ralf
PATCH 7/27 Initconst section fixes for POWERPC
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/powerpc/platforms/40x/ppc40x_simple.c | 2 +- arch/powerpc/platforms/512x/mpc5121_generic.c | 2 +- arch/powerpc/platforms/52xx/lite5200.c | 2 +- arch/powerpc/platforms/52xx/media5200.c | 2 +- arch/powerpc/platforms/52xx/mpc5200_simple.c | 2 +- arch/powerpc/platforms/52xx/mpc52xx_pci.c | 2 +- arch/powerpc/platforms/83xx/mpc830x_rdb.c | 2 +- arch/powerpc/platforms/83xx/mpc831x_rdb.c | 2 +- arch/powerpc/platforms/83xx/mpc837x_rdb.c | 2 +- arch/powerpc/platforms/85xx/tqm85xx.c | 2 +- arch/powerpc/platforms/cell/qpace_setup.c | 2 +- arch/powerpc/platforms/cell/setup.c | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-)
arch/powerpc/platforms/40x/ppc40x_simple.c +1 -1
@@ -50,7 +50,7 @@ machine_device_initcall(ppc40x_simple, ppc40x_device_probe);* Again, if your board needs to do things differently then create a * board.c file for it rather than adding it to this list. */ -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"amcc,acadia" ,"amcc,haleakala" ,"amcc,kilauea" ,
arch/powerpc/platforms/512x/mpc5121_generic.c +1 -1
@@ -26,7 +26,7 @@/* * list of supported boards */ -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"prt,prtlvt" ,NULL };
arch/powerpc/platforms/52xx/lite5200.c +1 -1
@@ -172,7 +172,7 @@ static void __init lite5200_setup_arch(void)mpc52xx_setup_pci (); } -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"fsl,lite5200" ,"fsl,lite5200b" ,NULL ,
arch/powerpc/platforms/52xx/media5200.c +1 -1
@@ -235,7 +235,7 @@ static void __init media5200_setup_arch(void) }/* list of the supported boards */ -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"fsl,media5200" ,NULL };
arch/powerpc/platforms/52xx/mpc5200_simple.c +1 -1
@@ -49,7 +49,7 @@ static void __init mpc5200_simple_setup_arch(void) }/* list of the supported boards */ -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"intercontrol,digsy-mtc" ,"manroland,mucmc52" ,"manroland,uc101" ,
arch/powerpc/platforms/52xx/mpc52xx_pci.c +1 -1
@@ -93,7 +93,7 @@ struct mpc52xx_pci { };/* MPC5200 device tree match tables */ -const struct of_device_id mpc52xx_pci_ids[]__initdata = { +const struct of_device_id mpc52xx_pci_ids[]__initconst = { { .type ="pci" , .compatible ="fsl,mpc5200-pci" , }, { .type ="pci" , .compatible ="mpc5200-pci" , }, {}
arch/powerpc/platforms/83xx/mpc830x_rdb.c +1 -1
@@ -57,7 +57,7 @@ static void __init mpc830x_rdb_init_IRQ(void)ipic_set_default_priority (); } -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"MPC8308RDB" ,"fsl,mpc8308rdb" ,"denx,mpc8308_p1m" ,
arch/powerpc/platforms/83xx/mpc831x_rdb.c +1 -1
@@ -60,7 +60,7 @@ static void __init mpc831x_rdb_init_IRQ(void)ipic_set_default_priority (); } -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"MPC8313ERDB" ,"fsl,mpc8315erdb" ,NULL
arch/powerpc/platforms/83xx/mpc837x_rdb.c +1 -1
@@ -101,7 +101,7 @@ static void __init mpc837x_rdb_init_IRQ(void)ipic_set_default_priority (); } -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"fsl,mpc8377rdb" ,"fsl,mpc8378rdb" ,"fsl,mpc8379rdb" ,
arch/powerpc/platforms/85xx/tqm85xx.c +1 -1
@@ -187,7 +187,7 @@ static int __init declare_of_platform_devices(void) }machine_device_initcall (tqm85xx, declare_of_platform_devices); -static const char *board[]__initdata = { +static const char *const board[]__initconst = {"tqc,tqm8540" ,"tqc,tqm8541" ,"tqc,tqm8548" ,
arch/powerpc/platforms/cell/qpace_setup.c +1 -1
@@ -60,7 +60,7 @@ static void qpace_progress(char *s, unsigned short hex)printk ("*** %04x : %s\n" , hex, s ? s :"" ); } -static const struct of_device_id qpace_bus_ids[]__initdata = { +static const struct of_device_id qpace_bus_ids[]__initconst = { { .type ="soc" , }, { .compatible ="soc" , }, { .type ="spider" , },
arch/powerpc/platforms/cell/setup.c +1 -1
@@ -139,7 +139,7 @@ static int __devinit cell_setup_phb(struct pci_controller *phb)return 0 ; } -static const struct of_device_id cell_bus_ids[]__initdata = { +static const struct of_device_id cell_bus_ids[]__initconst = { { .type ="soc" , }, { .compatible ="soc" , }, { .type ="spider" , },
Signature · 1 line
1.7.4.4
Re: [PATCH 07/27] Initconst section fixes for POWERPC
Quoted 2 lines · Andi Kleen
From: Andi Kleen <[email protected]>
What's the problem again?
Quoted 4 lines
Signed-off-by Andi Kleen <[email protected]>---
arch/powerpc/platforms/40x/ppc40x_simple.c | 2 +-
<snip>
arch/powerpc/platforms/40x/ppc40x_simple.c machine_device_initcall(ppc40x_simple, ppc40x_device_probe); · line 56
Quoted 13 lines
arch/powerpc/platforms/40x/ppc40x_simple.c +1
-1@@ -50,7 +50,7 @@ machine_device_initcall(ppc40x_simple, ppc40x_device_probe);* Again, if your board needs to do things differently then create a * board.c file for it rather than adding it to this list. */ -static const char *board[]__initdata = { +static const char *const board[]__initconst = { "amcc,acadia", "amcc,haleakala", "amcc,kilauea",
There's an almost identical section in arch/powerpc/platforms/44x/ppc44x_simple.c. Does that need whatever this is fixing as well?
josh
Re: [PATCH 07/27] Initconst section fixes for POWERPC
Quoted 4 lines · Josh Boyer
Quoted 2 lines · Andi Kleen
From: Andi Kleen<[email protected]>
What's the problem again?
It's wrong. For more details see 0/*
Quoted 4 lines
"amcc,kilauea",There's an almost identical section in
arch/powerpc/platforms/44x/ppc44x_simple.c. Does that need whatever this is fixing as well?
That one is not const.
-Andi
Re: [PATCH 07/27] Initconst section fixes for POWERPC
Quoted 9 lines · Andi Kleen
Quoted 6 lines · Josh Boyer
Quoted 3 lines · Andi Kleen
From: Andi Kleen<[email protected]>
What's the problem again?
It's wrong. For more details see 0/*
Do you have an example of the compiler/linker erroring out?
Quoted 7 lines
Quoted 5 lines
"amcc,kilauea",
There's an almost identical section inarch/powerpc/platforms/44x/ppc44x_simple.c. Does that need whatever this is fixing as well?That one is not const.
It should be. Which is not your problem but I guess if I figure out how to have the problem I'll fix it myself.
josh
Re: [PATCH 07/27] Initconst section fixes for POWERPC
Quoted 5 lines · Josh Boyer
Quoted 4 lines · Andi Kleen
Quoted 3 lines · Josh Boyer
Quoted 1 line · Andi Kleen
Quoted 7 lines
Quoted 5 lines
Quoted 3 lines
Quoted 2 lines
From: Andi Kleen<[email protected]>
What's the problem again?
It's wrong. For more details see 0/*
Do you have an example of the compiler/linker erroring out?
You currently need a special toolkit set up for this, it doesn't happen in normal builds. It's still wrong however.
-Andi
Re: [PATCH 07/27] Initconst section fixes for POWERPC
Quoted 8 lines · Andi Kleen
Quoted 7 lines · Josh Boyer
Quoted 6 lines · Andi Kleen
Quoted 5 lines · Josh Boyer
Quoted 3 lines · Andi Kleen
From: Andi Kleen<[email protected]>
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
Quoted 1 line
What's the problem again?
It's wrong. For more details see 0/*
Do you have an example of the compiler/linker erroring out?
You currently need a special toolkit set up for this, it doesn't happen in normal builds. It's still wrong however.
I'm not arguing against the patch. I just want to poke around with what you're reporting. Where can one get the toolkit?
josh
Re: [PATCH 07/27] Initconst section fixes for POWERPC
Quoted 2 lines
I'm not arguing against the patch. I just want to poke around with what you're reporting. Where can one get the toolkit?
You currently need a gcc 4.7, HJ Lu's binutils, a rather largish patchkit of mine to enable a kernel LTO build and then it doesn't quite build yet due to some gcc bugs, but gets far enough to complain about invalid section attribute mismatches.
I think the people who originally introduced initconst* triggered it in the linker, but I'm not fully sure how they did it. What happens is that the linker silently has to change the 'r' attribute of that section, this can be flagged.
-Andi
Signature · 1 line
[email protected] -- Speaking for myself only.
Re: [PATCH 07/27] Initconst section fixes for POWERPC
In reply to Andi KleenQuoted 8 lines · Andi Kleen
Quoted 7 lines · Josh Boyer
Quoted 6 lines · Andi Kleen
Quoted 5 lines · Josh Boyer
Quoted 3 lines · Andi Kleen
From: Andi Kleen<[email protected]>
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
Quoted 1 line
What's the problem again?
It's wrong. For more details see 0/*
Do you have an example of the compiler/linker erroring out?
You currently need a special toolkit set up for this, it doesn't happen in normal builds. ...
Can you please provide the answer to the question which was asked ?
It does not matter at all whether you need a special toolkit or not. Josh explicitely asked for an error output example.
Quoted 1 line
.... It's still wrong however.
So we have to trust special toolkit setups and your infamous impeccability?
Definitely not!
Start providing proper information instead of snotty and useless lumps.
No thanks,
tglx
Re: [PATCH 07/27] Initconst section fixes for POWERPC
In reply to Andi KleenQuoted 8 lines · Andi Kleen
Quoted 5 lines · Josh Boyer
Quoted 1 line · Andi Kleen
From: Andi Kleen<[email protected]>
What's the problem again?
It's wrong. For more details see 0/*
Doesn't that mean that people using "git log", perhaps trying to debug fallout from one of the patches (even if it's as small as making context not match on some later patch), would have no idea what's going on? The cover letter says:
Quoted 9 lines
This is a global tree sweep to fix up initconst section problems.
Any variable const in initdata must be marked
__initconst, not initdata. const__read_mostlyis not allowed.Otherwise the global sections can get a read only marking and in some circumstances the compiler/and or the linker will detect conflicts.
This patchkit aims to fix it up everywhere.
Which seems more sensible. Since this is going through Linus's tree, it might (or might not) make sense to combine the patches and describe the effect once.
PATCH 8/27 Initconst section fixes for SH
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/sh/kernel/ioport.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
arch/sh/kernel/ioport.c +1 -1
@@ -11,7 +11,7 @@#include <linux/module.h> #include <linux/io.h> -const unsigned long sh_io_port_base__read_mostly =-1 ; +unsigned long sh_io_port_base__read_mostly =-1 ;EXPORT_SYMBOL (sh_io_port_base);void __iomem *__ioport_map (unsigned long addr,unsigned int size)
Signature · 1 line
1.7.4.4
PATCH 9/27 Initconst section fixes for X86
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- arch/x86/kernel/rtc.c | 2 +- drivers/platform/x86/dell-laptop.c | 2 +- drivers/platform/x86/thinkpad_acpi.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
arch/x86/kernel/rtc.c +1 -1
@@ -222,7 +222,7 @@ static struct platform_device rtc_device = {static __init int add_rtc_cmos (void ) {#ifdef CONFIG_PNP -static const char *ids[]__initconst = +static const char *const const ids[]__initconst = {"PNP0b00" ,"PNP0b01" ,"PNP0b02" , };struct pnp_dev *dev;struct pnp_id *id;
drivers/platform/x86/dell-laptop.c +1 -1
@@ -78,7 +78,7 @@ static struct rfkill *wifi_rfkill;static struct rfkill *bluetooth_rfkill;static struct rfkill *wwan_rfkill; -static const struct dmi_system_id __initdata dell_device_table[] = { +static const struct dmi_system_id __initconst dell_device_table[] = { { .ident ="Dell laptop" , .matches = {
drivers/platform/x86/thinkpad_acpi.c +1 -1
@@ -522,7 +522,7 @@ static acpi_handle ec_handle; #define TPACPI_HANDLE(object, parent, paths...) \ static acpi_handle object##_handle; \ - static const acpi_handle *object##_parent __initdata = \ + static const acpi_handle * const object##_parent __initconst = \ &parent##_handle; \ static char *object##_paths[] __initdata = { paths }
Signature · 1 line
1.7.4.4
PATCH 10/27 Initconst section fixes for CPUFREQ
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/cpufreq/longhaul.h | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-)
drivers/cpufreq/longhaul.h +13 -13
@@ -56,7 +56,7 @@ union msr_longhaul {/* * VIA C3 Samuel 1 & Samuel 2 (stepping 0) */ -static const int __cpuinitdata samuel1_mults[16 ] = { +static const int __cpuinitconst samuel1_mults[16 ] = {-1 ,/* 0000 -> RESERVED */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -75,7 +75,7 @@ static const int __cpuinitdata samuel1_mults[16] = { -1, /* 1111 -> RESERVED */ }; -static const int __cpuinitdata samuel1_eblcr[16 ] = { +static const int __cpuinitconst samuel1_eblcr[16 ] = {50 ,/* 0000 -> RESERVED */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -97,7 +97,7 @@ static const int __cpuinitdata samuel1_eblcr[16] = {/* * VIA C3 Samuel2 Stepping 1->15 */ -static const int __cpuinitdata samuel2_eblcr[16 ] = { +static const int __cpuinitconst samuel2_eblcr[16 ] = {50 ,/* 0000 -> 5.0x */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -119,7 +119,7 @@ static const int __cpuinitdata samuel2_eblcr[16] = {/* * VIA C3 Ezra */ -static const int __cpuinitdata ezra_mults[16 ] = { +static const int __cpuinitconst ezra_mults[16 ] = {100 ,/* 0000 -> 10.0x */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -138,7 +138,7 @@ static const int __cpuinitdata ezra_mults[16] = { 120, /* 1111 -> 12.0x */ }; -static const int __cpuinitdata ezra_eblcr[16 ] = { +static const int __cpuinitconst ezra_eblcr[16 ] = {50 ,/* 0000 -> 5.0x */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -160,7 +160,7 @@ static const int __cpuinitdata ezra_eblcr[16] = {/* * VIA C3 (Ezra-T) [C5M]. */ -static const int __cpuinitdata ezrat_mults[32 ] = { +static const int __cpuinitconst ezrat_mults[32 ] = {100 ,/* 0000 -> 10.0x */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -196,7 +196,7 @@ static const int __cpuinitdata ezrat_mults[32] = { -1, /* 1111 -> RESERVED (12.0x) */ }; -static const int __cpuinitdata ezrat_eblcr[32 ] = { +static const int __cpuinitconst ezrat_eblcr[32 ] = {50 ,/* 0000 -> 5.0x */ 30 ,/* 0001 -> 3.0x */ 40 ,/* 0010 -> 4.0x */
@@ -235,7 +235,7 @@ static const int __cpuinitdata ezrat_eblcr[32] = {/* * VIA C3 Nehemiah */ -static const int __cpuinitdata nehemiah_mults[32 ] = { +static const int __cpuinitconst nehemiah_mults[32 ] = {100 ,/* 0000 -> 10.0x */ -1 ,/* 0001 -> 16.0x */ 40 ,/* 0010 -> 4.0x */
@@ -270,7 +270,7 @@ static const int __cpuinitdata nehemiah_mults[32] = { -1, /* 1111 -> 12.0x */ }; -static const int __cpuinitdata nehemiah_eblcr[32 ] = { +static const int __cpuinitconst nehemiah_eblcr[32 ] = {50 ,/* 0000 -> 5.0x */ 160 ,/* 0001 -> 16.0x */ 40 ,/* 0010 -> 4.0x */
@@ -315,7 +315,7 @@ struct mV_pos {unsigned short pos; }; -static const struct mV_pos __cpuinitdata vrm85_mV[32 ] = { +static const struct mV_pos __cpuinitconst vrm85_mV[32 ] = { {1250 ,8 }, {1200 ,6 }, {1150 ,4 }, {1100 ,2 }, {1050 ,0 }, {1800 ,30 }, {1750 ,28 }, {1700 ,26 }, {1650 ,24 }, {1600 ,22 }, {1550 ,20 }, {1500 ,18 },
@@ -326,14 +326,14 @@ static const struct mV_pos __cpuinitdata vrm85_mV[32] = { {1475, 17}, {1425, 15}, {1375, 13}, {1325, 11} }; -static const unsigned char __cpuinitdata mV_vrm85[32 ] = { +static const unsigned char __cpuinitconst mV_vrm85[32 ] = {0x04 ,0x14 ,0x03 ,0x13 ,0x02 ,0x12 ,0x01 ,0x11 ,0x00 ,0x10 ,0x0f ,0x1f ,0x0e ,0x1e ,0x0d ,0x1d ,0x0c ,0x1c ,0x0b ,0x1b ,0x0a ,0x1a ,0x09 ,0x19 ,0x08 ,0x18 ,0x07 ,0x17 ,0x06 ,0x16 ,0x05 ,0x15 }; -static const struct mV_pos __cpuinitdata mobilevrm_mV[32 ] = { +static const struct mV_pos __cpuinitconst mobilevrm_mV[32 ] = { {1750 ,31 }, {1700 ,30 }, {1650 ,29 }, {1600 ,28 }, {1550 ,27 }, {1500 ,26 }, {1450 ,25 }, {1400 ,24 }, {1350 ,23 }, {1300 ,22 }, {1250 ,21 }, {1200 ,20 },
@@ -344,7 +344,7 @@ static const struct mV_pos __cpuinitdata mobilevrm_mV[32] = { {675, 3}, {650, 2}, {625, 1}, {600, 0} }; -static const unsigned char __cpuinitdata mV_mobilevrm[32 ] = { +static const unsigned char __cpuinitconst mV_mobilevrm[32 ] = {0x1f ,0x1e ,0x1d ,0x1c ,0x1b ,0x1a ,0x19 ,0x18 ,0x17 ,0x16 ,0x15 ,0x14 ,0x13 ,0x12 ,0x11 ,0x10 ,0x0f ,0x0e ,0x0d ,0x0c ,0x0b ,0x0a ,0x09 ,0x08 ,
Signature · 1 line
1.7.4.4
Re: [PATCH 10/27] Initconst section fixes for CPUFREQ
Quoted 7 lines · Andi Kleen
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>--- drivers/cpufreq/longhaul.h | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-)
PATCH 11/27 Initconst section fixes for EDAC
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/edac/amd64_edac.c | 2 +- drivers/edac/amd76x_edac.c | 2 +- drivers/edac/e752x_edac.c | 2 +- drivers/edac/e7xxx_edac.c | 2 +- drivers/edac/i3000_edac.c | 2 +- drivers/edac/i3200_edac.c | 2 +- drivers/edac/i5000_edac.c | 2 +- drivers/edac/i5100_edac.c | 2 +- drivers/edac/i5400_edac.c | 2 +- drivers/edac/i7300_edac.c | 2 +- drivers/edac/i7core_edac.c | 2 +- drivers/edac/i82443bxgx_edac.c | 2 +- drivers/edac/i82860_edac.c | 2 +- drivers/edac/i82875p_edac.c | 2 +- drivers/edac/i82975x_edac.c | 2 +- drivers/edac/r82600_edac.c | 2 +- drivers/edac/x38_edac.c | 2 +- 17 files changed, 17 insertions(+), 17 deletions(-)
drivers/edac/amd64_edac.c +1 -1
@@ -2670,7 +2670,7 @@ static void __devexit amd64_remove_one_instance(struct pci_dev *pdev)* PCI core identifies what devices are on a system during boot, and then * inquiry this table to see if this driver is for a given device found. */ -static const struct pci_device_id amd64_pci_table[]__devinitdata = { +static const struct pci_device_id amd64_pci_table[]__devinitconst = { { .vendor =PCI_VENDOR_ID_AMD , .device =PCI_DEVICE_ID_AMD_K8_NB_MEMCTL ,
drivers/edac/amd76x_edac.c +1 -1
@@ -321,7 +321,7 @@ static void __devexit amd76x_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id amd76x_pci_tbl[]__devinitdata = { +static const struct pci_device_id amd76x_pci_tbl[]__devinitconst = { {PCI_VEND_DEV (AMD ,FE_GATE_700C ),PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,AMD762 },
drivers/edac/e752x_edac.c +1 -1
@@ -1380,7 +1380,7 @@ static void __devexit e752x_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id e752x_pci_tbl[]__devinitdata = { +static const struct pci_device_id e752x_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 7520_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,E7520 },
drivers/edac/e7xxx_edac.c +1 -1
@@ -525,7 +525,7 @@ static void __devexit e7xxx_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id e7xxx_pci_tbl[]__devinitdata = { +static const struct pci_device_id e7xxx_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 7205_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,E7205 },
drivers/edac/i3000_edac.c +1 -1
@@ -470,7 +470,7 @@ static void __devexit i3000_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id i3000_pci_tbl[]__devinitdata = { +static const struct pci_device_id i3000_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 3000_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0,I3000 },
drivers/edac/i3200_edac.c +1 -1
@@ -456,7 +456,7 @@ static void __devexit i3200_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id i3200_pci_tbl[]__devinitdata = { +static const struct pci_device_id i3200_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 3200_HB), PCI_ANY_ID, PCI_ANY_ID, 0, 0,I3200 },
drivers/edac/i5000_edac.c +1 -1
@@ -1516,7 +1516,7 @@ static void __devexit i5000_remove_one(struct pci_dev *pdev)* * The "E500P" device is the first device supported. */ -static const struct pci_device_id i5000_pci_tbl[]__devinitdata = { +static const struct pci_device_id i5000_pci_tbl[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_I5000_DEV16 ), .driver_data =I5000P },
drivers/edac/i5100_edac.c +1 -1
@@ -1051,7 +1051,7 @@ static void __devexit i5100_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id i5100_pci_tbl[]__devinitdata = { +static const struct pci_device_id i5100_pci_tbl[]__devinitconst = {/* Device 16, Function 0, Channel 0 Memory Map, Error Flag/Mask, ... */ {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_5100_16 ) }, {0 , }
drivers/edac/i5400_edac.c +1 -1
@@ -1383,7 +1383,7 @@ static void __devexit i5400_remove_one(struct pci_dev *pdev)* * The "E500P" device is the first device supported. */ -static const struct pci_device_id i5400_pci_tbl[]__devinitdata = { +static const struct pci_device_id i5400_pci_tbl[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_5400_ERR )}, {0 ,}/* 0 terminated list. */ };
drivers/edac/i7300_edac.c +1 -1
@@ -1191,7 +1191,7 @@ static void __devexit i7300_remove_one(struct pci_dev *pdev)* * Has only 8086:360c PCI ID */ -static const struct pci_device_id i7300_pci_tbl[]__devinitdata = { +static const struct pci_device_id i7300_pci_tbl[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_I7300_MCH_ERR )}, {0 ,}/* 0 terminated list. */ };
drivers/edac/i7core_edac.c +1 -1
@@ -359,7 +359,7 @@ static const struct pci_id_table pci_dev_table[] = {/* * pci_device_id table for which devices we are looking for */ -static const struct pci_device_id i7core_pci_tbl[]__devinitdata = { +static const struct pci_device_id i7core_pci_tbl[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_X58_HUB_MGMT )}, {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_LYNNFIELD_QPI_LINK0 )}, {0 ,}/* 0 terminated list. */
drivers/edac/i82443bxgx_edac.c +1 -1
@@ -380,7 +380,7 @@ static void __devexit i82443bxgx_edacmc_remove_one(struct pci_dev *pdev)EXPORT_SYMBOL_GPL (i82443bxgx_edacmc_remove_one); -static const struct pci_device_id i82443bxgx_pci_tbl[]__devinitdata = { +static const struct pci_device_id i82443bxgx_pci_tbl[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_82443BX_0 )}, {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_82443BX_2 )}, {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,PCI_DEVICE_ID_INTEL_82443GX_0 )},
drivers/edac/i82860_edac.c +1 -1
@@ -270,7 +270,7 @@ static void __devexit i82860_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id i82860_pci_tbl[]__devinitdata = { +static const struct pci_device_id i82860_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 82860_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,I82860 },
drivers/edac/i82875p_edac.c +1 -1
@@ -511,7 +511,7 @@ static void __devexit i82875p_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id i82875p_pci_tbl[]__devinitdata = { +static const struct pci_device_id i82875p_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 82875_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,I82875P },
drivers/edac/i82975x_edac.c +1 -1
@@ -604,7 +604,7 @@ static void __devexit i82975x_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id i82975x_pci_tbl[]__devinitdata = { +static const struct pci_device_id i82975x_pci_tbl[]__devinitconst = { { PCI_VEND_DEV(INTEL, 82975_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,I82975X
drivers/edac/r82600_edac.c +1 -1
@@ -373,7 +373,7 @@ static void __devexit r82600_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id r82600_pci_tbl[]__devinitdata = { +static const struct pci_device_id r82600_pci_tbl[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_RADISYS ,R82600_BRIDGE_ID ) },
drivers/edac/x38_edac.c +1 -1
@@ -440,7 +440,7 @@ static void __devexit x38_remove_one(struct pci_dev *pdev)edac_mc_free (mci); } -static const struct pci_device_id x38_pci_tbl[]__devinitdata = { +static const struct pci_device_id x38_pci_tbl[]__devinitconst = { {PCI_VEND_DEV (INTEL ,X38_HB ),PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,X38 },
Signature · 1 line
1.7.4.4
PATCH 12/27 Initconst section fixes for hwmon
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/hwmon/w83627ehf.c | 16 ++++++++-------- drivers/hwmon/w83627hf.c | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-)
drivers/hwmon/w83627ehf.c +8 -8
@@ -2309,14 +2309,14 @@ static struct platform_driver w83627ehf_driver = {static int __init w83627ehf_find (int sioaddr,unsigned short *addr,struct w83627ehf_sio_data *sio_data) { -static const char __initdata sio_name_W83627EHF[] ="W83627EHF" ; -static const char __initdata sio_name_W83627EHG[] ="W83627EHG" ; -static const char __initdata sio_name_W83627DHG[] ="W83627DHG" ; -static const char __initdata sio_name_W83627DHG_P[] ="W83627DHG-P" ; -static const char __initdata sio_name_W83667HG[] ="W83667HG" ; -static const char __initdata sio_name_W83667HG_B[] ="W83667HG-B" ; -static const char __initdata sio_name_NCT6775[] ="NCT6775F" ; -static const char __initdata sio_name_NCT6776[] ="NCT6776F" ; +static const char __initconst sio_name_W83627EHF[] ="W83627EHF" ; +static const char __initconst sio_name_W83627EHG[] ="W83627EHG" ; +static const char __initconst sio_name_W83627DHG[] ="W83627DHG" ; +static const char __initconst sio_name_W83627DHG_P[] ="W83627DHG-P" ; +static const char __initconst sio_name_W83667HG[] ="W83667HG" ; +static const char __initconst sio_name_W83667HG_B[] ="W83667HG-B" ; +static const char __initconst sio_name_NCT6775[] ="NCT6775F" ; +static const char __initconst sio_name_NCT6776[] ="NCT6776F" ;u16 val;const char *sio_name;
drivers/hwmon/w83627hf.c +1 -1
@@ -1129,7 +1129,7 @@ static int __init w83627hf_find(int sioaddr, unsigned short *addr,int err = -ENODEV ;u16 val; -static const __initdata char *names[] = { +static __initconst char *const names[] = {"W83627HF" ,"W83627THF" ,"W83697HF" ,
Signature · 1 line
1.7.4.4
PATCH 13/27 Initconst section fixes for IDE
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/ide/aec62xx.c | 2 +- drivers/ide/ali14xx.c | 4 ++-- drivers/ide/alim15x3.c | 2 +- drivers/ide/amd74xx.c | 2 +- drivers/ide/at91_ide.c | 2 +- drivers/ide/atiixp.c | 2 +- drivers/ide/cmd640.c | 2 +- drivers/ide/cmd64x.c | 2 +- drivers/ide/cs5520.c | 2 +- drivers/ide/cs5530.c | 2 +- drivers/ide/cs5535.c | 2 +- drivers/ide/cy82c693.c | 2 +- drivers/ide/dtc2278.c | 2 +- drivers/ide/hpt366.c | 24 ++++++++++++------------ drivers/ide/ht6560b.c | 2 +- drivers/ide/icside.c | 2 +- drivers/ide/ide-pci-generic.c | 2 +- drivers/ide/it8172.c | 2 +- drivers/ide/it8213.c | 2 +- drivers/ide/it821x.c | 2 +- drivers/ide/jmicron.c | 2 +- drivers/ide/ns87415.c | 2 +- drivers/ide/opti621.c | 2 +- drivers/ide/pdc202xx_new.c | 2 +- drivers/ide/pdc202xx_old.c | 2 +- drivers/ide/piix.c | 2 +- drivers/ide/qd65xx.c | 2 +- drivers/ide/rz1000.c | 2 +- drivers/ide/sc1200.c | 2 +- drivers/ide/scc_pata.c | 2 +- drivers/ide/serverworks.c | 2 +- drivers/ide/siimage.c | 2 +- drivers/ide/sis5513.c | 2 +- drivers/ide/sl82c105.c | 2 +- drivers/ide/slc90e66.c | 2 +- drivers/ide/tc86c001.c | 2 +- drivers/ide/triflex.c | 2 +- drivers/ide/trm290.c | 2 +- drivers/ide/tx4938ide.c | 2 +- drivers/ide/tx4939ide.c | 2 +- drivers/ide/umc8672.c | 2 +- drivers/ide/via82cxxx.c | 2 +- 42 files changed, 54 insertions(+), 54 deletions(-)
drivers/ide/aec62xx.c +1 -1
@@ -181,7 +181,7 @@ static const struct ide_port_ops atp86x_port_ops = { .cable_detect = atp86x_cable_detect, }; -static const struct ide_port_info aec62xx_chipsets[]__devinitdata = { +static const struct ide_port_info aec62xx_chipsets[]__devinitconst = { {/* 0: AEC6210 */ .name =DRV_NAME , .init_chipset = init_chipset_aec62xx,
drivers/ide/ali14xx.c +2 -2
@@ -52,13 +52,13 @@/* port addresses for auto-detection */ #define ALI_NUM_PORTS 4 -static const int ports[ALI_NUM_PORTS ]__initdata = +static const int ports[ALI_NUM_PORTS ]__initconst = {0x074 ,0x0f4 ,0x034 ,0x0e4 };/* register initialization data */ typedef struct {u8 reg, data; }RegInitializer ; -static const RegInitializer initData[]__initdata = { +static const RegInitializer initData[]__initconst = { {0x01 ,0x0f }, {0x02 ,0x00 }, {0x03 ,0x00 }, {0x04 ,0x00 }, {0x05 ,0x00 }, {0x06 ,0x00 }, {0x07 ,0x2b }, {0x0a ,0x0f }, {0x25 ,0x00 }, {0x26 ,0x00 }, {0x27 ,0x00 }, {0x28 ,0x00 },
drivers/ide/alim15x3.c +1 -1
@@ -512,7 +512,7 @@ static const struct ide_dma_ops ali_dma_ops = { .dma_sff_read_status = ide_dma_sff_read_status, }; -static const struct ide_port_info ali15x3_chipset__devinitdata = { +static const struct ide_port_info ali15x3_chipset__devinitconst = { .name =DRV_NAME , .init_chipset = init_chipset_ali15x3, .init_hwif = init_hwif_ali15x3,
drivers/ide/amd74xx.c +1 -1
@@ -223,7 +223,7 @@ static const struct ide_port_ops amd_port_ops = { .udma_mask = udma, \ } -static const struct ide_port_info amd74xx_chipsets[]__devinitdata = { +static const struct ide_port_info amd74xx_chipsets[]__devinitconst = {/* 0: AMD7401 */ DECLARE_AMD_DEV (0x00 ,ATA_UDMA2 ),/* 1: AMD7409 */ DECLARE_AMD_DEV (ATA_SWDMA2 ,ATA_UDMA4 ),/* 2: AMD7411/7441 */ DECLARE_AMD_DEV (ATA_SWDMA2 ,ATA_UDMA5 ),
drivers/ide/at91_ide.c +1 -1
@@ -208,7 +208,7 @@ static const struct ide_port_ops at91_ide_port_ops = { .set_pio_mode = at91_ide_set_pio_mode, }; -static const struct ide_port_info at91_ide_port_info__initdata = { +static const struct ide_port_info at91_ide_port_info__initconst = { .port_ops = &at91_ide_port_ops, .tp_ops = &at91_ide_tp_ops, .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA | IDE_HFLAG_SINGLE |
drivers/ide/atiixp.c +1 -1
@@ -139,7 +139,7 @@ static const struct ide_port_ops atiixp_port_ops = { .cable_detect = atiixp_cable_detect, }; -static const struct ide_port_info atiixp_pci_info[]__devinitdata = { +static const struct ide_port_info atiixp_pci_info[]__devinitconst = { {/* 0: IXP200/300/400/700 */ .name =DRV_NAME , .enablebits = {{0x48 ,0x01 ,0x00 }, {0x48 ,0x08 ,0x00 }},
drivers/ide/cmd640.c +1 -1
@@ -684,7 +684,7 @@ static int pci_conf2(void)return 0 ; } -static const struct ide_port_info cmd640_port_info__initdata = { +static const struct ide_port_info cmd640_port_info__initconst = { .chipset = ide_cmd640, .host_flags =IDE_HFLAG_SERIALIZE | IDE_HFLAG_NO_DMA |
drivers/ide/cmd64x.c +1 -1
@@ -327,7 +327,7 @@ static const struct ide_dma_ops cmd646_rev1_dma_ops = { .dma_sff_read_status = ide_dma_sff_read_status, }; -static const struct ide_port_info cmd64x_chipsets[]__devinitdata = { +static const struct ide_port_info cmd64x_chipsets[]__devinitconst = { {/* 0: CMD643 */ .name =DRV_NAME , .init_chipset = init_chipset_cmd64x,
drivers/ide/cs5520.c +1 -1
@@ -94,7 +94,7 @@ static const struct ide_port_ops cs5520_port_ops = { .set_dma_mode = cs5520_set_dma_mode, }; -static const struct ide_port_info cyrix_chipset__devinitdata = { +static const struct ide_port_info cyrix_chipset__devinitconst = { .name =DRV_NAME , .enablebits = { {0x60 ,0x01 ,0x01 }, {0x60 ,0x02 ,0x02 } }, .port_ops = &cs5520_port_ops,
drivers/ide/cs5530.c +1 -1
@@ -245,7 +245,7 @@ static const struct ide_port_ops cs5530_port_ops = { .udma_filter = cs5530_udma_filter, }; -static const struct ide_port_info cs5530_chipset__devinitdata = { +static const struct ide_port_info cs5530_chipset__devinitconst = { .name =DRV_NAME , .init_chipset = init_chipset_cs5530, .init_hwif = init_hwif_cs5530,
drivers/ide/cs5535.c +1 -1
@@ -170,7 +170,7 @@ static const struct ide_port_ops cs5535_port_ops = { .cable_detect = cs5535_cable_detect, }; -static const struct ide_port_info cs5535_chipset__devinitdata = { +static const struct ide_port_info cs5535_chipset__devinitconst = { .name =DRV_NAME , .port_ops = &cs5535_port_ops, .host_flags =IDE_HFLAG_SINGLE |IDE_HFLAG_POST_SET_MODE ,
drivers/ide/cy82c693.c +1 -1
@@ -163,7 +163,7 @@ static const struct ide_port_ops cy82c693_port_ops = { .set_dma_mode = cy82c693_set_dma_mode, }; -static const struct ide_port_info cy82c693_chipset__devinitdata = { +static const struct ide_port_info cy82c693_chipset__devinitconst = { .name =DRV_NAME , .init_iops = init_iops_cy82c693, .port_ops = &cy82c693_port_ops,
drivers/ide/dtc2278.c +1 -1
@@ -91,7 +91,7 @@ static const struct ide_port_ops dtc2278_port_ops = { .set_pio_mode = dtc2278_set_pio_mode, }; -static const struct ide_port_info dtc2278_port_info__initdata = { +static const struct ide_port_info dtc2278_port_info__initconst = { .name =DRV_NAME , .chipset = ide_dtc2278, .port_ops = &dtc2278_port_ops,
drivers/ide/hpt366.c +12 -12
@@ -443,7 +443,7 @@ static struct hpt_timings hpt37x_timings = { } }; -static const struct hpt_info hpt36x__devinitdata = { +static const struct hpt_info hpt36x__devinitconst = { .chip_name ="HPT36x" , .chip_type = HPT36x, .udma_mask =HPT366_ALLOW_ATA66_3 ? (HPT366_ALLOW_ATA66_4 ?ATA_UDMA4 :ATA_UDMA3 ) :ATA_UDMA2 ,
@@ -451,7 +451,7 @@ static const struct hpt_info hpt36x __devinitdata = { .timings = &hpt36x_timings }; -static const struct hpt_info hpt370__devinitdata = { +static const struct hpt_info hpt370__devinitconst = { .chip_name ="HPT370" , .chip_type =HPT370 , .udma_mask =HPT370_ALLOW_ATA100_5 ?ATA_UDMA5 :ATA_UDMA4 ,
@@ -459,7 +459,7 @@ static const struct hpt_info hpt370 __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt370a__devinitdata = { +static const struct hpt_info hpt370a__devinitconst = { .chip_name ="HPT370A" , .chip_type =HPT370A , .udma_mask =HPT370_ALLOW_ATA100_5 ?ATA_UDMA5 :ATA_UDMA4 ,
@@ -467,7 +467,7 @@ static const struct hpt_info hpt370a __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt374__devinitdata = { +static const struct hpt_info hpt374__devinitconst = { .chip_name ="HPT374" , .chip_type =HPT374 , .udma_mask =ATA_UDMA5 ,
@@ -475,7 +475,7 @@ static const struct hpt_info hpt374 __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt372__devinitdata = { +static const struct hpt_info hpt372__devinitconst = { .chip_name ="HPT372" , .chip_type =HPT372 , .udma_mask =HPT372_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -483,7 +483,7 @@ static const struct hpt_info hpt372 __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt372a__devinitdata = { +static const struct hpt_info hpt372a__devinitconst = { .chip_name ="HPT372A" , .chip_type =HPT372A , .udma_mask =HPT372_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -491,7 +491,7 @@ static const struct hpt_info hpt372a __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt302__devinitdata = { +static const struct hpt_info hpt302__devinitconst = { .chip_name ="HPT302" , .chip_type =HPT302 , .udma_mask =HPT302_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -499,7 +499,7 @@ static const struct hpt_info hpt302 __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt371__devinitdata = { +static const struct hpt_info hpt371__devinitconst = { .chip_name ="HPT371" , .chip_type =HPT371 , .udma_mask =HPT371_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -507,7 +507,7 @@ static const struct hpt_info hpt371 __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt372n__devinitdata = { +static const struct hpt_info hpt372n__devinitconst = { .chip_name ="HPT372N" , .chip_type =HPT372N , .udma_mask =HPT372_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -515,7 +515,7 @@ static const struct hpt_info hpt372n __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt302n__devinitdata = { +static const struct hpt_info hpt302n__devinitconst = { .chip_name ="HPT302N" , .chip_type =HPT302N , .udma_mask =HPT302_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -523,7 +523,7 @@ static const struct hpt_info hpt302n __devinitdata = { .timings = &hpt37x_timings }; -static const struct hpt_info hpt371n__devinitdata = { +static const struct hpt_info hpt371n__devinitconst = { .chip_name ="HPT371N" , .chip_type =HPT371N , .udma_mask =HPT371_ALLOW_ATA133_6 ?ATA_UDMA6 :ATA_UDMA5 ,
@@ -1361,7 +1361,7 @@ static const struct ide_dma_ops hpt36x_dma_ops = { .dma_sff_read_status = ide_dma_sff_read_status, }; -static const struct ide_port_info hpt366_chipsets[]__devinitdata = { +static const struct ide_port_info hpt366_chipsets[]__devinitconst = { {/* 0: HPT36x */ .name =DRV_NAME , .init_chipset = init_chipset_hpt366,
drivers/ide/ht6560b.c +1 -1
@@ -341,7 +341,7 @@ static const struct ide_port_ops ht6560b_port_ops = { .set_pio_mode = ht6560b_set_pio_mode, }; -static const struct ide_port_info ht6560b_port_info__initdata = { +static const struct ide_port_info ht6560b_port_info__initconst = { .name =DRV_NAME , .chipset = ide_ht6560b, .tp_ops = &ht6560b_tp_ops,
drivers/ide/icside.c +1 -1
@@ -453,7 +453,7 @@ err_free:return ret; } -static const struct ide_port_info icside_v6_port_info__initdata = { +static const struct ide_port_info icside_v6_port_info__initconst = { .init_dma = icside_dma_off_init, .port_ops = &icside_v6_no_dma_port_ops, .dma_ops = &icside_v6_dma_ops,
drivers/ide/ide-pci-generic.c +1 -1
@@ -53,7 +53,7 @@ static const struct ide_port_ops netcell_port_ops = { .udma_mask = ATA_UDMA6, \ } -static const struct ide_port_info generic_chipsets[]__devinitdata = { +static const struct ide_port_info generic_chipsets[]__devinitconst = {/* 0: Unknown */ DECLARE_GENERIC_PCI_DEV (0 ),
drivers/ide/it8172.c +1 -1
@@ -115,7 +115,7 @@ static const struct ide_port_ops it8172_port_ops = { .set_dma_mode = it8172_set_dma_mode, }; -static const struct ide_port_info it8172_port_info__devinitdata = { +static const struct ide_port_info it8172_port_info__devinitconst = { .name =DRV_NAME , .port_ops = &it8172_port_ops, .enablebits = { {0x41 ,0x80 ,0x80 }, {0x00 ,0x00 ,0x00 } },
drivers/ide/it8213.c +1 -1
@@ -156,7 +156,7 @@ static const struct ide_port_ops it8213_port_ops = { .cable_detect = it8213_cable_detect, }; -static const struct ide_port_info it8213_chipset__devinitdata = { +static const struct ide_port_info it8213_chipset__devinitconst = { .name =DRV_NAME , .enablebits = { {0x41 ,0x80 ,0x80 } }, .port_ops = &it8213_port_ops,
drivers/ide/it821x.c +1 -1
@@ -630,7 +630,7 @@ static const struct ide_port_ops it821x_port_ops = { .cable_detect = it821x_cable_detect, }; -static const struct ide_port_info it821x_chipset__devinitdata = { +static const struct ide_port_info it821x_chipset__devinitconst = { .name =DRV_NAME , .init_chipset = init_chipset_it821x, .init_hwif = init_hwif_it821x,
drivers/ide/jmicron.c +1 -1
@@ -102,7 +102,7 @@ static const struct ide_port_ops jmicron_port_ops = { .cable_detect = jmicron_cable_detect, }; -static const struct ide_port_info jmicron_chipset__devinitdata = { +static const struct ide_port_info jmicron_chipset__devinitconst = { .name =DRV_NAME , .enablebits = { {0x40 ,0x01 ,0x01 }, {0x40 ,0x10 ,0x10 } }, .port_ops = &jmicron_port_ops,
drivers/ide/ns87415.c +1 -1
@@ -293,7 +293,7 @@ static const struct ide_dma_ops ns87415_dma_ops = { .dma_sff_read_status = superio_dma_sff_read_status, }; -static const struct ide_port_info ns87415_chipset__devinitdata = { +static const struct ide_port_info ns87415_chipset__devinitconst = { .name =DRV_NAME , .init_hwif = init_hwif_ns87415, .tp_ops = &ns87415_tp_ops,
drivers/ide/opti621.c +1 -1
@@ -131,7 +131,7 @@ static const struct ide_port_ops opti621_port_ops = { .set_pio_mode = opti621_set_pio_mode, }; -static const struct ide_port_info opti621_chipset__devinitdata = { +static const struct ide_port_info opti621_chipset__devinitconst = { .name =DRV_NAME , .enablebits = { {0x45 ,0x80 ,0x00 }, {0x40 ,0x08 ,0x00 } }, .port_ops = &opti621_port_ops,
drivers/ide/pdc202xx_new.c +1 -1
@@ -465,7 +465,7 @@ static const struct ide_port_ops pdcnew_port_ops = { .udma_mask = udma, \ } -static const struct ide_port_info pdcnew_chipsets[]__devinitdata = { +static const struct ide_port_info pdcnew_chipsets[]__devinitconst = {/* 0: PDC202{68,70} */ DECLARE_PDCNEW_DEV (ATA_UDMA5 ),/* 1: PDC202{69,71,75,76,77} */ DECLARE_PDCNEW_DEV (ATA_UDMA6 ), };
drivers/ide/pdc202xx_old.c +1 -1
@@ -270,7 +270,7 @@ static const struct ide_dma_ops pdc2026x_dma_ops = { .max_sectors = sectors, \ } -static const struct ide_port_info pdc202xx_chipsets[]__devinitdata = { +static const struct ide_port_info pdc202xx_chipsets[]__devinitconst = { {/* 0: PDC20246 */ .name =DRV_NAME , .init_chipset = init_chipset_pdc202xx,
drivers/ide/piix.c +1 -1
@@ -344,7 +344,7 @@ static const struct ide_port_ops ich_port_ops = { .udma_mask = udma, \ } -static const struct ide_port_info piix_pci_info[]__devinitdata = { +static const struct ide_port_info piix_pci_info[]__devinitconst = {/* 0: MPIIX */ {/* * MPIIX actually has only a single IDE channel mapped to
drivers/ide/qd65xx.c +1 -1
@@ -336,7 +336,7 @@ static const struct ide_port_ops qd6580_port_ops = { .set_pio_mode = qd6580_set_pio_mode, }; -static const struct ide_port_info qd65xx_port_info__initdata = { +static const struct ide_port_info qd65xx_port_info__initconst = { .name =DRV_NAME , .tp_ops = &qd65xx_tp_ops, .chipset = ide_qd65xx,
drivers/ide/rz1000.c +1 -1
@@ -38,7 +38,7 @@ static int __devinit rz1000_disable_readahead(struct pci_dev *dev) } } -static const struct ide_port_info rz1000_chipset__devinitdata = { +static const struct ide_port_info rz1000_chipset__devinitconst = { .name =DRV_NAME , .host_flags =IDE_HFLAG_NO_DMA , };
drivers/ide/sc1200.c +1 -1
@@ -291,7 +291,7 @@ static const struct ide_dma_ops sc1200_dma_ops = { .dma_sff_read_status = ide_dma_sff_read_status, }; -static const struct ide_port_info sc1200_chipset__devinitdata = { +static const struct ide_port_info sc1200_chipset__devinitconst = { .name =DRV_NAME , .port_ops = &sc1200_port_ops, .dma_ops = &sc1200_dma_ops,
drivers/ide/scc_pata.c +1 -1
@@ -811,7 +811,7 @@ static const struct ide_dma_ops scc_dma_ops = { .dma_sff_read_status = scc_dma_sff_read_status, }; -static const struct ide_port_info scc_chipset__devinitdata = { +static const struct ide_port_info scc_chipset__devinitconst = { .name ="sccIDE" , .init_iops = init_iops_scc, .init_dma = scc_init_dma,
drivers/ide/serverworks.c +1 -1
@@ -337,7 +337,7 @@ static const struct ide_port_ops svwks_port_ops = { .cable_detect = svwks_cable_detect, }; -static const struct ide_port_info serverworks_chipsets[]__devinitdata = { +static const struct ide_port_info serverworks_chipsets[]__devinitconst = { {/* 0: OSB4 */ .name =DRV_NAME , .init_chipset = init_chipset_svwks,
drivers/ide/siimage.c +1 -1
@@ -719,7 +719,7 @@ static const struct ide_dma_ops sil_dma_ops = { .udma_mask = ATA_UDMA6, \ } -static const struct ide_port_info siimage_chipsets[]__devinitdata = { +static const struct ide_port_info siimage_chipsets[]__devinitconst = {/* 0: SiI680 */ DECLARE_SII_DEV (&sil_pata_port_ops),/* 1: SiI3112 */ DECLARE_SII_DEV (&sil_sata_port_ops) };
drivers/ide/sis5513.c +1 -1
@@ -563,7 +563,7 @@ static const struct ide_port_ops sis_ata133_port_ops = { .cable_detect = sis_cable_detect, }; -static const struct ide_port_info sis5513_chipset__devinitdata = { +static const struct ide_port_info sis5513_chipset__devinitconst = { .name =DRV_NAME , .init_chipset = init_chipset_sis5513, .enablebits = { {0x4a ,0x02 ,0x02 }, {0x4a ,0x04 ,0x04 } },
drivers/ide/sl82c105.c +1 -1
@@ -299,7 +299,7 @@ static const struct ide_dma_ops sl82c105_dma_ops = { .dma_sff_read_status = ide_dma_sff_read_status, }; -static const struct ide_port_info sl82c105_chipset__devinitdata = { +static const struct ide_port_info sl82c105_chipset__devinitconst = { .name =DRV_NAME , .init_chipset = init_chipset_sl82c105, .enablebits = {{0x40 ,0x01 ,0x01 }, {0x40 ,0x10 ,0x10 }},
drivers/ide/slc90e66.c +1 -1
@@ -132,7 +132,7 @@ static const struct ide_port_ops slc90e66_port_ops = { .cable_detect = slc90e66_cable_detect, }; -static const struct ide_port_info slc90e66_chipset__devinitdata = { +static const struct ide_port_info slc90e66_chipset__devinitconst = { .name =DRV_NAME , .enablebits = { {0x41 ,0x80 ,0x80 }, {0x43 ,0x80 ,0x80 } }, .port_ops = &slc90e66_port_ops,
drivers/ide/tc86c001.c +1 -1
@@ -191,7 +191,7 @@ static const struct ide_dma_ops tc86c001_dma_ops = { .dma_sff_read_status = ide_dma_sff_read_status, }; -static const struct ide_port_info tc86c001_chipset__devinitdata = { +static const struct ide_port_info tc86c001_chipset__devinitconst = { .name =DRV_NAME , .init_hwif = init_hwif_tc86c001, .port_ops = &tc86c001_port_ops,
drivers/ide/triflex.c +1 -1
@@ -92,7 +92,7 @@ static const struct ide_port_ops triflex_port_ops = { .set_dma_mode = triflex_set_mode, }; -static const struct ide_port_info triflex_device__devinitdata = { +static const struct ide_port_info triflex_device__devinitconst = { .name =DRV_NAME , .enablebits = {{0x80 ,0x01 ,0x01 }, {0x80 ,0x02 ,0x02 }}, .port_ops = &triflex_port_ops,
drivers/ide/trm290.c +1 -1
@@ -324,7 +324,7 @@ static struct ide_dma_ops trm290_dma_ops = { .dma_check = trm290_dma_check, }; -static const struct ide_port_info trm290_chipset__devinitdata = { +static const struct ide_port_info trm290_chipset__devinitconst = { .name =DRV_NAME , .init_hwif = init_hwif_trm290, .tp_ops = &trm290_tp_ops,
drivers/ide/tx4938ide.c +1 -1
@@ -117,7 +117,7 @@ static const struct ide_port_ops tx4938ide_port_ops = { .set_pio_mode = tx4938ide_set_pio_mode, }; -static const struct ide_port_info tx4938ide_port_info__initdata = { +static const struct ide_port_info tx4938ide_port_info__initconst = { .port_ops = &tx4938ide_port_ops, #ifdef __BIG_ENDIAN .tp_ops = &tx4938ide_tp_ops,
drivers/ide/tx4939ide.c +1 -1
@@ -522,7 +522,7 @@ static const struct ide_dma_ops tx4939ide_dma_ops = { .dma_sff_read_status = tx4939ide_dma_sff_read_status, }; -static const struct ide_port_info tx4939ide_port_info__initdata = { +static const struct ide_port_info tx4939ide_port_info__initconst = { .init_hwif = tx4939ide_init_hwif, .init_dma = tx4939ide_init_dma, .port_ops = &tx4939ide_port_ops,
drivers/ide/umc8672.c +1 -1
@@ -128,7 +128,7 @@ static const struct ide_port_ops umc8672_port_ops = { .set_pio_mode = umc_set_pio_mode, }; -static const struct ide_port_info umc8672_port_info__initdata = { +static const struct ide_port_info umc8672_port_info__initconst = { .name =DRV_NAME , .chipset = ide_umc8672, .port_ops = &umc8672_port_ops,
drivers/ide/via82cxxx.c +1 -1
@@ -403,7 +403,7 @@ static const struct ide_port_ops via_port_ops = { .cable_detect = via82cxxx_cable_detect, }; -static const struct ide_port_info via82cxxx_chipset__devinitdata = { +static const struct ide_port_info via82cxxx_chipset__devinitconst = { .name =DRV_NAME , .init_chipset = init_chipset_via82cxxx, .enablebits = { {0x40 ,0x02 ,0x02 }, {0x40 ,0x01 ,0x01 } },
Signature · 1 line
1.7.4.4
Re: [PATCH 13/27] Initconst section fixes for IDE
From: Andi Kleen <[email protected]>
Date: Thu, 15 Sep 2011 13:09:40 -0700
Quoted 4 lines
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>
PATCH 14/27 Initconst section fixes for macintosh
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/macintosh/macio_asic.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/macintosh/macio_asic.c +1 -1
@@ -748,7 +748,7 @@ static void __devexit macio_pci_remove(struct pci_dev* pdev)* MacIO is matched against any Apple ID, it's probe() function * will then decide wether it applies or not */ -static const struct pci_device_id __devinitdata pci_ids [] = { { +static const struct pci_device_id __devinitconst pci_ids [] = { { .vendor =PCI_VENDOR_ID_APPLE , .device =PCI_ANY_ID , .subvendor =PCI_ANY_ID ,
Signature · 1 line
1.7.4.4
PATCH 15/27 Initconst section fixes for media
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/media/dvb/ngene/ngene-cards.c | 2 +- drivers/media/video/cx88/cx88-alsa.c | 2 +- drivers/media/video/timblogiw.c | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-)
drivers/media/dvb/ngene/ngene-cards.c +1 -1
@@ -477,7 +477,7 @@ static struct ngene_info ngene_info_m780 = {/****************************************************************************/ -static const struct pci_device_id ngene_id_tbl[]__devinitdata = { +static const struct pci_device_id ngene_id_tbl[]__devinitconst = {NGENE_ID (0x18c3 ,0xabc3 , ngene_info_cineS2),NGENE_ID (0x18c3 ,0xabc4 , ngene_info_cineS2),NGENE_ID (0x18c3 ,0xdb01 , ngene_info_satixS2),
drivers/media/video/cx88/cx88-alsa.c +1 -1
@@ -766,7 +766,7 @@ static struct snd_kcontrol_new snd_cx88_alc_switch = {* Only boards with eeprom and byte 1 at eeprom=1 have it */ -static const struct pci_device_id const cx88_audio_pci_tbl[]__devinitdata = { +static const struct pci_device_id const cx88_audio_pci_tbl[]__devinitconst = { {0x14f1 ,0x8801 ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, {0x14f1 ,0x8811 ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, {0 , }
drivers/media/video/timblogiw.c +3 -3
@@ -744,7 +744,7 @@ static int timblogiw_mmap(struct file *file, struct vm_area_struct *vma)/* Platform device functions */ -static __devinitconst struct v4l2_ioctl_ops timblogiw_ioctl_ops = { +static const __devinitconst struct v4l2_ioctl_ops timblogiw_ioctl_ops = { .vidioc_querycap = timblogiw_querycap, .vidioc_enum_fmt_vid_cap = timblogiw_enum_fmt, .vidioc_g_fmt_vid_cap = timblogiw_g_fmt,
@@ -766,7 +766,7 @@ static __devinitconst struct v4l2_ioctl_ops timblogiw_ioctl_ops = { .vidioc_enum_framesizes = timblogiw_enum_framesizes, }; -static __devinitconst struct v4l2_file_operations timblogiw_fops = { +static const __devinitconst struct v4l2_file_operations timblogiw_fops = { .owner =THIS_MODULE , .open = timblogiw_open, .release = timblogiw_close,
@@ -776,7 +776,7 @@ static __devinitconst struct v4l2_file_operations timblogiw_fops = { .poll = timblogiw_poll, }; -static __devinitconst struct video_device timblogiw_template = { +static const __devinitconst struct video_device timblogiw_template = { .name =TIMBLOGIWIN_NAME , .fops = &timblogiw_fops, .ioctl_ops = &timblogiw_ioctl_ops,
Signature · 1 line
1.7.4.4
PATCH 16/27 Initconst section fixes for mfd
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/mfd/ab3100-core.c | 2 +- drivers/mfd/ab3550-core.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/mfd/ab3100-core.c +1 -1
@@ -809,7 +809,7 @@ struct ab_family_id {char *name; }; -static const struct ab_family_id ids[]__devinitdata = { +static const struct ab_family_id ids[]__devinitconst = {/* AB3100 */ { .id =0xc0 ,
drivers/mfd/ab3550-core.c +1 -1
@@ -1193,7 +1193,7 @@ struct ab_family_id {char *name; }; -static const struct ab_family_id ids[]__initdata = { +static const struct ab_family_id ids[]__initconst = {/* AB3550 */ { .id =AB3550_P1A ,
Signature · 1 line
1.7.4.4
Re: [PATCH 16/27] Initconst section fixes for mfd
Hi Andi,
Quoted 1 line · Andi Kleen
From: Andi Kleen <[email protected]>
Patch applied manually, thanks. The ab3550 part was already fixed on my for-next branch.
Cheers,
Samuel.
Signature · 2 lines
Intel Open Source Technology Centre http://oss.intel.com/
PATCH 17/27 Initconst section fixes for mmc
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/mmc/host/sdhci-pci.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/mmc/host/sdhci-pci.c +1 -1
@@ -542,7 +542,7 @@ static const struct sdhci_pci_fixes sdhci_via = { .probe = via_probe, }; -static const struct pci_device_id pci_ids[]__devinitdata = { +static const struct pci_device_id pci_ids[]__devinitconst = { { .vendor =PCI_VENDOR_ID_RICOH , .device =PCI_DEVICE_ID_RICOH_R5C822 ,
Signature · 1 line
1.7.4.4
PATCH 18/27 Initconst section fixes for mtd
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/mtd/maps/wr_sbc82xx_flash.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/mtd/maps/wr_sbc82xx_flash.c +1 -1
@@ -60,7 +60,7 @@ static struct mtd_partition bigflash_parts[] = { } }; -static const char *part_probes[]__initdata = {"cmdlinepart" ,"RedBoot" ,NULL }; +static const char *const part_probes[]__initconst = {"cmdlinepart" ,"RedBoot" ,NULL };#define init_sbc82xx_one_flash (map, br, or) \ do { \
Signature · 1 line
1.7.4.4
PATCH 19/27 Initconst section fixes for drivers/net
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/net/8139too.c | 2 +- drivers/net/atlx/atl2.c | 2 +- drivers/net/can/slcan.c | 2 +- drivers/net/can/vcan.c | 2 +- drivers/net/fealnx.c | 2 +- drivers/net/hamradio/6pack.c | 6 +++--- drivers/net/hamradio/bpqether.c | 2 +- drivers/net/hamradio/mkiss.c | 6 +++--- drivers/net/hamradio/scc.c | 2 +- drivers/net/hamradio/yam.c | 2 +- drivers/net/ne3210.c | 2 +- drivers/net/qlcnic/qlcnic_hw.c | 2 +- drivers/net/sis190.c | 2 +- drivers/net/starfire.c | 2 +- drivers/net/sundance.c | 2 +- drivers/net/tokenring/smctr.c | 2 +- drivers/net/tulip/eeprom.c | 2 +- drivers/net/tulip/winbond-840.c | 2 +- drivers/net/wan/z85230.c | 2 +- 19 files changed, 23 insertions(+), 23 deletions(-)
drivers/net/8139too.c +1 -1
@@ -228,7 +228,7 @@ typedef enum {static const struct {const char *name;u32 hw_flags; -} board_info[]__devinitdata = { +} board_info[]__devinitconst = { {"RealTek RTL8139" ,RTL8139_CAPS }, {"RealTek RTL8129" ,RTL8129_CAPS }, };
drivers/net/atlx/atl2.c +1 -1
@@ -2857,7 +2857,7 @@ static void atl2_force_ps(struct atl2_hw *hw)*/ #define ATL2_PARAM (X , desc) \ - static const int __devinitdata X[ATL2_MAX_NIC + 1] = ATL2_PARAM_INIT; \ + static const int __devinitconst X[ATL2_MAX_NIC + 1] = ATL2_PARAM_INIT; \ MODULE_PARM(X, "1-" __MODULE_STRING(ATL2_MAX_NIC) "i"); \ MODULE_PARM_DESC(X, desc);#else
drivers/net/can/slcan.c +1 -1
@@ -59,7 +59,7 @@#include <linux/kernel.h> #include <linux/can.h> -static __initdata const char banner[] = +static __initconst const char banner[] =KERN_INFO "slcan: serial line CAN interface driver\n" ;MODULE_ALIAS_LDISC (N_SLCAN );
drivers/net/can/vcan.c +1 -1
@@ -51,7 +51,7 @@#include <linux/slab.h> #include <net/rtnetlink.h> -static __initdata const char banner[] = +static __initconst const char banner[] =KERN_INFO "vcan: Virtual CAN interface driver\n" ;MODULE_DESCRIPTION ("virtual CAN interface" );
drivers/net/fealnx.c +1 -1
@@ -150,7 +150,7 @@ struct chip_info {int flags; }; -static const struct chip_info skel_netdrv_tbl[]__devinitdata = { +static const struct chip_info skel_netdrv_tbl[]__devinitconst = { {"100/10M Ethernet PCI Adapter" ,HAS_MII_XCVR }, {"100/10M Ethernet PCI Adapter" ,HAS_CHIP_XCVR }, {"1000/100/10M Ethernet PCI Adapter" ,HAS_MII_XCVR },
drivers/net/hamradio/6pack.c +3 -3
@@ -812,9 +812,9 @@ static struct tty_ldisc_ops sp_ldisc = {/* Initialize 6pack control device -- register 6pack line discipline */ -static const char msg_banner[] __initdata = KERN_INFO \ +static const char msg_banner[] __initconst = KERN_INFO \"AX.25: 6pack driver, " SIXPACK_VERSION "\n" ; -static const char msg_regfail[] __initdata = KERN_ERR \ +static const char msg_regfail[] __initconst = KERN_ERR \"6pack: can't register line discipline (err = %d)\n" ;static int __init sixpack_init_driver (void )
@@ -830,7 +830,7 @@ static int __init sixpack_init_driver(void)return status; } -static const char msg_unregfail[] __exitdata = KERN_ERR \ +static char msg_unregfail[] __exitdata = KERN_ERR \"6pack: can't unregister line discipline (err = %d)\n" ; static void __exit sixpack_exit_driver(void)
drivers/net/hamradio/bpqether.c +1 -1
@@ -88,7 +88,7 @@#include <linux/bpqether.h> -static const char banner[] __initdata = KERN_INFO \ +static const char banner[] __initconst = KERN_INFO \"AX.25: bpqether driver version 004\n" ;static char bcast_addr[6 ]={0xFF ,0xFF ,0xFF ,0xFF ,0xFF ,0xFF };
drivers/net/hamradio/mkiss.c +3 -3
@@ -998,9 +998,9 @@ static struct tty_ldisc_ops ax_ldisc = { .write_wakeup = mkiss_write_wakeup }; -static const char banner[] __initdata = KERN_INFO \ +static const char banner[] __initconst = KERN_INFO \"mkiss: AX.25 Multikiss, Hans Albas PE1AYX\n" ; -static const char msg_regfail[] __initdata = KERN_ERR \ +static const char msg_regfail[] __initconst = KERN_ERR \"mkiss: can't register line discipline (err = %d)\n" ;static int __init mkiss_init_driver (void )
@@ -1016,7 +1016,7 @@ static int __init mkiss_init_driver(void)return status; } -static const char msg_unregfail[] __exitdata = KERN_ERR \ +static char msg_unregfail[] __exitdata = KERN_ERR \"mkiss: can't unregister line discipline (err = %d)\n" ; static void __exit mkiss_exit_driver(void)
drivers/net/hamradio/scc.c +1 -1
@@ -183,7 +183,7 @@#include "z8530.h" -static const char banner[] __initdata = KERN_INFO \ +static const char banner[] __initconst = KERN_INFO \"AX.25: Z8530 SCC driver version " VERSION ".dl1bke\n" ;static void t_dwait (unsigned long );
drivers/net/hamradio/yam.c +1 -1
@@ -77,7 +77,7 @@/* --------------------------------------------------------------------- */ static const char yam_drvname[] ="yam" ; -static const char yam_drvinfo[] __initdata = KERN_INFO \ +static const char yam_drvinfo[] __initconst = KERN_INFO \"YAM driver version 0.8 by F1OAT/F6FBB\n" ;/* --------------------------------------------------------------------- */
drivers/net/ne3210.c +1 -1
@@ -82,7 +82,7 @@ static void ne3210_block_output(struct net_device *dev, int count, const unsignestatic unsigned char irq_map[]__initdata = {15 ,12 ,11 ,10 ,9 ,7 ,5 ,3 };static unsigned int shmem_map[]__initdata = {0xff0 ,0xfe0 ,0xfff0 ,0xd8 ,0xffe0 ,0xffc0 ,0xd0 ,0x0 }; -static const char *ifmap[]__initdata = {"UTP" ,"?" ,"BNC" ,"AUI" }; +static const char *const ifmap[]__initconst = {"UTP" ,"?" ,"BNC" ,"AUI" };static int ifmap_val[]__initdata = {IF_PORT_10BASET ,IF_PORT_UNKNOWN ,
drivers/net/qlcnic/qlcnic_hw.c +1 -1
@@ -38,7 +38,7 @@ static inline void writeq(u64 val, void __iomem *addr) }#endif -static const struct crb_128M_2M_block_map +static struct crb_128M_2M_block_map crb_128M_2M_map[64] __cacheline_aligned_in_smp = { {{{0 ,0 ,0 ,0 } } },/* 0: PCI */ {{{1 ,0x0100000 ,0x0102000 ,0x120000 },/* 1: PCIE */
drivers/net/sis190.c +1 -1
@@ -1624,7 +1624,7 @@ static int __devinit sis190_get_mac_addr_from_eeprom(struct pci_dev *pdev,static int __devinit sis190_get_mac_addr_from_apc (struct pci_dev *pdev,struct net_device *dev) { -static const u16 __devinitdata ids[] = {0x0965 ,0x0966 ,0x0968 }; +static const u16 __devinitconst ids[] = {0x0965 ,0x0966 ,0x0968 };struct sis190_private *tp =netdev_priv (dev);struct pci_dev *isa_bridge;u8 reg, tmp8;
drivers/net/starfire.c +1 -1
@@ -308,7 +308,7 @@ MODULE_DEVICE_TABLE(pci, starfire_pci_tbl);static const struct chip_info {const char *name;int drv_flags; -} netdrv_tbl[]__devinitdata = { +} netdrv_tbl[]__devinitconst = { {"Adaptec Starfire 6915" , CanHaveMII }, };
drivers/net/sundance.c +1 -1
@@ -218,7 +218,7 @@ enum {struct pci_id_info {const char *name; }; -static const struct pci_id_info pci_id_tbl[]__devinitdata = { +static const struct pci_id_info pci_id_tbl[]__devinitconst = { {"D-Link DFE-550TX FAST Ethernet Adapter" }, {"D-Link DFE-550FX 100Mbps Fiber-optics Adapter" }, {"D-Link DFE-580TX 4 port Server Adapter" },
drivers/net/tokenring/smctr.c +1 -1
@@ -60,7 +60,7 @@#include "smctr.h" /* Our Stuff */ -static const char version[]__initdata = +static const char version[]__initconst =KERN_INFO "smctr.c: v1.4 7/12/00 by [email protected]\n" ;static const char cardname[] ="smctr" ;
drivers/net/tulip/eeprom.c +1 -1
@@ -81,7 +81,7 @@ static struct eeprom_fixup eeprom_fixups[] __devinitdata = { {NULL}}; -static const char *block_name[]__devinitdata = { +static const char *const block_name[]__devinitconst = {"21140 non-MII" ,"21140 MII PHY" ,"21142 Serial PHY" ,
drivers/net/tulip/winbond-840.c +1 -1
@@ -236,7 +236,7 @@ struct pci_id_info {int drv_flags;/* Driver use, intended as capability flags. */ }; -static const struct pci_id_info pci_id_tbl[]__devinitdata = { +static const struct pci_id_info pci_id_tbl[]__devinitconst = { {/* Sometime a Level-One switch card. */ "Winbond W89c840" , CanHaveMII | HasBrokenTx | FDXOnNoMII}, {"Winbond W89c840" , CanHaveMII | HasBrokenTx},
drivers/net/wan/z85230.c +1 -1
@@ -1775,7 +1775,7 @@ EXPORT_SYMBOL(z8530_queue_xmit);/* * Module support */ -static const char banner[]__initdata = +static const char banner[]__initconst =KERN_INFO "Generic Z85C30/Z85230 interface driver v0.02\n" ;static int __init z85230_init_driver (void )
Signature · 1 line
1.7.4.4
Re: [PATCH 19/27] Initconst section fixes for drivers/net
From: Andi Kleen <[email protected]>
Date: Thu, 15 Sep 2011 13:09:46 -0700
Quoted 5 lines
From: Andi Kleen <[email protected]>
PATCH 20/27 Initconst section fixes for SCSI
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/scsi/aacraid/linit.c | 2 +- drivers/scsi/aic94xx/aic94xx_init.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/scsi/aacraid/linit.c +1 -1
@@ -92,7 +92,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_tbl) = { #elif defined(__devinitconst) static const struct pci_device_id aac_pci_tbl[] __devinitconst = { #else -static const struct pci_device_id aac_pci_tbl[] __devinitdata = { +static const struct pci_device_id aac_pci_tbl[] __devinitconst = { #endif { 0x1028, 0x0001, 0x1028, 0x0001, 0, 0, 0 }, /* PERC 2/Si (Iguana/PERC2Si) */ { 0x1028, 0x0002, 0x1028, 0x0002, 0, 0, 1 }, /* PERC 3/Di (Opal/PERC3Di) */
drivers/scsi/aic94xx/aic94xx_init.c +1 -1
@@ -1012,7 +1012,7 @@ static struct sas_domain_function_template aic94xx_transport_functions = { .lldd_control_phy = asd_control_phy, }; -static const struct pci_device_id aic94xx_pci_table[]__devinitdata = { +static const struct pci_device_id aic94xx_pci_table[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_ADAPTEC2 ,0x410 ),0 ,0 ,1 }, {PCI_DEVICE (PCI_VENDOR_ID_ADAPTEC2 ,0x412 ),0 ,0 ,1 }, {PCI_DEVICE (PCI_VENDOR_ID_ADAPTEC2 ,0x416 ),0 ,0 ,1 },
Signature · 1 line
1.7.4.4
Re: [PATCH 20/27] Initconst section fixes for SCSI
Quoted 1 line · Andi Kleen
From: Andi Kleen <[email protected]>
I don't know why you're doing this without a description (and please cc at least linux-scsi on SCSI patches).
Quoted 12 lines
Signed-off-by Andi Kleen <[email protected]>--- drivers/scsi/aacraid/linit.c | 2 +- drivers/scsi/aic94xx/aic94xx_init.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)drivers/scsi/aacraid/linit.c +0
-0
drivers/scsi/aacraid/linit.c static DECLARE_PCI_DEVICE_TABLE(aac_pci_tbl) = { · line 95
Quoted 5 lines
drivers/scsi/aacraid/linit.c +1
-1@@ -92,7 +92,7 @@ static DECLARE_PCI_DEVICE_TABLE(aac_pci_tbl) = {#elif defined(__devinitconst) static const struct pci_device_id aac_pci_tbl[] __devinitconst = {#else -static const struct pci_device_id aac_pci_tbl[] __devinitdata = { +static const struct pci_device_id aac_pci_tbl[] __devinitconst = {
How can this possibly be correct? You just checked in the preceding #elif defined() that __devinitconst wasn't defined for this leg, so if it's taken there'll be an instant compile failure.
If you want to argue the whole of the #ifdef construct should be removed then I'd be interested.
James
Re: [PATCH 20/27] Initconst section fixes for SCSI
Quoted 3 lines
How can this possibly be correct? You just checked in the preceding #elif
defined()that__devinitconstwasn't defined for this leg, so if it's taken there'll be an instant compile failure.
It just came out of my grep. But you're right since this is dead code it does not need to be fixed.
I'll drop the patch.
Thanks,
-Andi
Signature · 1 line
[email protected] -- Speaking for myself only.
PATCH 21/27 Initconst section fixes for SPI
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/spi/spi-dw-pci.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/spi/spi-dw-pci.c +1 -1
@@ -148,7 +148,7 @@ static int spi_resume(struct pci_dev *pdev)#define spi_resume NULL#endif -static const struct pci_device_id pci_ids[]__devinitdata = { +static const struct pci_device_id pci_ids[]__devinitconst = {/* Intel MID platform SPI controller 0 */ {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,0x0800 ) }, {},
Signature · 1 line
1.7.4.4
Re: [PATCH 21/27] Initconst section fixes for SPI
Quoted 4 lines · Andi Kleen
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>
Is this one going to be merged with the rest of the series? Or do I need to pick it up?
g.
Quoted 20 lines
--- drivers/spi/spi-dw-pci.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/spi/spi-dw-pci.c +1
-1@@ -148,7 +148,7 @@ static int spi_resume(struct pci_dev *pdev)#define spi_resume NULL#endif -static const struct pci_device_id pci_ids[]__devinitdata = { +static const struct pci_device_id pci_ids[]__devinitconst = {/* Intel MID platform SPI controller 0 */ {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,0x0800 ) }, {},Signature · 1 line
1.7.4.4
Re: [PATCH 21/27] Initconst section fixes for SPI
Quoted 9 lines · Grant Likely
Quoted 4 lines · Andi Kleen
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>Acked-by Grant Likely <[email protected]>Is this one going to be merged with the rest of the series? Or do I need to pick it up?
Will be with the rest of the series.
-Andi
PATCH 22/27 Initconst section fixes for TTY
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/tty/serial/mfd.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/tty/serial/mfd.c +1 -1
@@ -1423,7 +1423,7 @@ static void serial_hsu_remove(struct pci_dev *pdev) }/* First 3 are UART ports, and the 4th is the DMA */ -static const struct pci_device_id pci_ids[]__devinitdata = { +static const struct pci_device_id pci_ids[]__devinitconst = { {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,0x081B ) }, {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,0x081C ) }, {PCI_DEVICE (PCI_VENDOR_ID_INTEL ,0x081D ) },
Signature · 1 line
1.7.4.4
PATCH 23/27 Initconst section fixes for VIDEO
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/video/aty/aty128fb.c | 2 +- drivers/video/geode/gx1fb_core.c | 2 +- drivers/video/gxt4500.c | 4 ++-- drivers/video/i810/i810_main.c | 2 +- drivers/video/jz4740_fb.c | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-)
drivers/video/aty/aty128fb.c +1 -1
@@ -148,7 +148,7 @@ enum { };/* Must match above enum */ -static const char *r128_family[]__devinitdata = { +static char *const r128_family[]__devinitconst = {"AGP" ,"PCI" ,"PRO AGP" ,
drivers/video/geode/gx1fb_core.c +1 -1
@@ -29,7 +29,7 @@ static int crt_option = 1;static char panel_option[32 ] ="" ;/* Modes relevant to the GX1 (taken from modedb.c) */ -static const struct fb_videomode __devinitdata gx1_modedb[] = { +static const struct fb_videomode __devinitconst gx1_modedb[] = {/* 640x480-60 VESA */ {NULL ,60 ,640 ,480 ,39682 ,48 ,16 ,33 ,10 ,96 ,2 ,0 ,FB_VMODE_NONINTERLACED ,FB_MODE_IS_VESA },
drivers/video/gxt4500.c +2 -2
@@ -156,7 +156,7 @@ struct gxt4500_par {static char *mode_option;/* default mode: 1280x1024 @ 60 Hz, 8 bpp */ -static const struct fb_videomode defaultmode__devinitdata = { +static const struct fb_videomode defaultmode__devinitconst = { .refresh =60 , .xres =1280 , .yres =1024 ,
@@ -581,7 +581,7 @@ static int gxt4500_blank(int blank, struct fb_info *info)return 0 ; } -static const struct fb_fix_screeninfo gxt4500_fix__devinitdata = { +static const struct fb_fix_screeninfo gxt4500_fix__devinitconst = { .id ="IBM GXT4500P" , .type =FB_TYPE_PACKED_PIXELS , .visual =FB_VISUAL_PSEUDOCOLOR ,
drivers/video/i810/i810_main.c +1 -1
@@ -97,7 +97,7 @@ static int i810fb_blank (int blank_mode, struct fb_info *info);static void i810fb_release_resource (struct fb_info *info,struct i810fb_par *par);/* PCI */ -static const char *i810_pci_list[]__devinitdata = { +static const char *const i810_pci_list[]__devinitconst = {"Intel(R) 810 Framebuffer Device" ,"Intel(R) 810-DC100 Framebuffer Device" ,"Intel(R) 810E Framebuffer Device" ,
drivers/video/jz4740_fb.c +1 -1
@@ -136,7 +136,7 @@ struct jzfb {uint32_t pseudo_palette[16 ]; }; -static const struct fb_fix_screeninfo jzfb_fix__devinitdata = { +static const struct fb_fix_screeninfo jzfb_fix__devinitconst = { .id ="JZ4740 FB" , .type =FB_TYPE_PACKED_PIXELS , .visual =FB_VISUAL_TRUECOLOR ,
Signature · 1 line
1.7.4.4
PATCH 24/27 Initconst section fixes for watchdog
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- drivers/watchdog/sbc_epx_c3.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/watchdog/sbc_epx_c3.c +1 -1
@@ -173,7 +173,7 @@ static struct notifier_block epx_c3_notifier = { .notifier_call = epx_c3_notify_sys, }; -static const char banner[] __initdata = KERN_INFO PFX +static const char banner[] __initconst = KERN_INFO PFX"Hardware Watchdog Timer for Winsystems EPX-C3 SBC: 0.1\n" ;static int __init watchdog_init (void )
Signature · 1 line
1.7.4.4
PATCH 25/27 Initconst section fixes for percpu
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- include/linux/percpu.h | 2 +- mm/percpu.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
include/linux/percpu.h +1 -1
@@ -107,7 +107,7 @@ enum pcpu_fc { PCPU_FC_NR, }; -extern const char *pcpu_fc_names[PCPU_FC_NR ]; +extern const char *const pcpu_fc_names[PCPU_FC_NR ];extern enum pcpu_fc pcpu_chosen_fc;
mm/percpu.c +1 -1
@@ -1344,7 +1344,7 @@ int __init pcpu_setup_first_chunk(const struct pcpu_alloc_info *ai,#ifdef CONFIG_SMP -const char *pcpu_fc_names[PCPU_FC_NR ]__initdata = { +const char *const pcpu_fc_names[PCPU_FC_NR ]__initconst = { [PCPU_FC_AUTO ] ="auto" , [PCPU_FC_EMBED ] ="embed" , [PCPU_FC_PAGE] = "page",
Signature · 1 line
1.7.4.4
Re: [PATCH 25/27] Initconst section fixes for percpu
Hello,
Quoted 4 lines · Andi Kleen
From: Andi Kleen <[email protected]>
Signed-off-by Andi Kleen <[email protected]>
Andrew, can you please take this one too?
Thank you very much.
Quoted 33 lines
--- include/linux/percpu.h | 2 +- mm/percpu.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)include/linux/percpu.h +1
-1@@ -107,7 +107,7 @@ enum pcpu_fc { PCPU_FC_NR, }; -extern const char *pcpu_fc_names[PCPU_FC_NR ]; +extern const char *const pcpu_fc_names[PCPU_FC_NR ];extern enum pcpu_fc pcpu_chosen_fc;mm/percpu.c +1
-1@@ -1344,7 +1344,7 @@ int __init pcpu_setup_first_chunk(const struct pcpu_alloc_info *ai,#ifdef CONFIG_SMP -const char *pcpu_fc_names[PCPU_FC_NR ]__initdata = { +const char *const pcpu_fc_names[PCPU_FC_NR ]__initconst = { [PCPU_FC_AUTO ] ="auto" , [PCPU_FC_EMBED ] ="embed" , [PCPU_FC_PAGE] = "page",Signature · 1 line
1.7.4.4
Signature · 1 line
tejun
PATCH 26/27 Initconst section fixes for net
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- include/net/net_namespace.h | 2 ++ net/can/af_can.c | 2 +- net/can/bcm.c | 2 +- net/can/raw.c | 2 +- net/decnet/dn_rules.c | 2 +- net/ipv4/fib_rules.c | 2 +- net/ipv4/ipmr.c | 2 +- net/ipv6/addrlabel.c | 2 +- net/ipv6/fib6_rules.c | 2 +- net/ipv6/ip6mr.c | 2 +- 10 files changed, 11 insertions(+), 9 deletions(-)
include/net/net_namespace.h +2 -0
@@ -240,10 +240,12 @@ static inline struct net *read_pnet(struct net * const *pnet)#define __net_init#define __net_exit#define __net_initdata +#define __net_initconst#else #define __net_init __init#define __net_exit __exit_refok#define __net_initdata __initdata +#define __net_initconst __initconst#endif struct pernet_operations {
net/can/af_can.c +1 -1
@@ -64,7 +64,7 @@#include "af_can.h" -static __initdata const char banner[] =KERN_INFO +static __initconst const char banner[] =KERN_INFO "can: controller area network core (" CAN_VERSION_STRING ")\n" ;MODULE_DESCRIPTION ("Controller Area Network PF_CAN core" );
net/can/bcm.c +1 -1
@@ -79,7 +79,7 @@ (CAN_SFF_MASK | CAN_EFF_FLAG | CAN_RTR_FLAG))#define CAN_BCM_VERSION CAN_VERSION -static __initdata const char banner[] =KERN_INFO +static __initconst const char banner[] =KERN_INFO "can: broadcast manager protocol (rev " CAN_BCM_VERSION " t)\n" ;MODULE_DESCRIPTION ("PF_CAN broadcast manager protocol" );
net/can/raw.c +1 -1
@@ -57,7 +57,7 @@#include <net/net_namespace.h> #define CAN_RAW_VERSION CAN_VERSION -static __initdata const char banner[] = +static __initconst const char banner[] =KERN_INFO "can: raw protocol (rev " CAN_RAW_VERSION ")\n" ;MODULE_DESCRIPTION ("PF_CAN raw protocol" );
net/decnet/dn_rules.c +1 -1
@@ -219,7 +219,7 @@ static void dn_fib_rule_flush_cache(struct fib_rules_ops *ops)dn_rt_cache_flush (-1 ); } -static const struct fib_rules_ops __net_initdata dn_fib_rules_ops_template = { +static const struct fib_rules_ops __net_initconst dn_fib_rules_ops_template = { .family = AF_DECnet, .rule_size =sizeof (struct dn_fib_rule ), .addr_size =sizeof (u16),
net/ipv4/fib_rules.c +1 -1
@@ -247,7 +247,7 @@ static void fib4_rule_flush_cache(struct fib_rules_ops *ops)rt_cache_flush (ops->fro_net,-1 ); } -static const struct fib_rules_ops __net_initdata fib4_rules_ops_template = { +static const struct fib_rules_ops __net_initconst fib4_rules_ops_template = { .family =AF_INET , .rule_size =sizeof (struct fib4_rule ), .addr_size =sizeof (u32),
net/ipv4/ipmr.c +1 -1
@@ -218,7 +218,7 @@ static int ipmr_rule_fill(struct fib_rule *rule, struct sk_buff *skb,return 0 ; } -static const struct fib_rules_ops __net_initdata ipmr_rules_ops_template = { +static const struct fib_rules_ops __net_initconst ipmr_rules_ops_template = { .family =RTNL_FAMILY_IPMR , .rule_size =sizeof (struct ipmr_rule ), .addr_size =sizeof (u32),
net/ipv6/addrlabel.c +1 -1
@@ -75,7 +75,7 @@ struct net *ip6addrlbl_net(const struct ip6addrlbl_entry *lbl)#define IPV6_ADDR_LABEL_DEFAULT 0xffffffffUL -static const __net_initdata struct ip6addrlbl_init_table +static const __net_initconst struct ip6addrlbl_init_table { const struct in6_addr *prefix; int prefixlen;
net/ipv6/fib6_rules.c +1 -1
@@ -239,7 +239,7 @@ static size_t fib6_rule_nlmsg_payload(struct fib_rule *rule) +nla_total_size (16 );/* src */ } -static const struct fib_rules_ops __net_initdata fib6_rules_ops_template = { +static const struct fib_rules_ops __net_initconst fib6_rules_ops_template = { .family =AF_INET6 , .rule_size =sizeof (struct fib6_rule ), .addr_size =sizeof (struct in6_addr ),
net/ipv6/ip6mr.c +1 -1
@@ -205,7 +205,7 @@ static int ip6mr_rule_fill(struct fib_rule *rule, struct sk_buff *skb,return 0 ; } -static const struct fib_rules_ops __net_initdata ip6mr_rules_ops_template = { +static const struct fib_rules_ops __net_initconst ip6mr_rules_ops_template = { .family =RTNL_FAMILY_IP6MR , .rule_size =sizeof (struct ip6mr_rule ), .addr_size =sizeof (struct in6_addr ),
Signature · 1 line
1.7.4.4
Re: [PATCH 26/27] Initconst section fixes for net
From: Andi Kleen <[email protected]>
Date: Thu, 15 Sep 2011 13:09:53 -0700
Quoted 5 lines
From: Andi Kleen <[email protected]>
PATCH 27/27 Initconst section fixes for lib
In reply to Andi KleenFrom: Andi Kleen <[email protected]>
--- lib/test-kstrtox.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
lib/test-kstrtox.c +2 -2
@@ -11,7 +11,7 @@ struct test_fail { };#define DEFINE_TEST_FAIL (test) \ - const struct test_fail test[] __initdata + const struct test_fail test[] __initconst#define DECLARE_TEST_OK (type, test_type) \ test_type { \
@@ -21,7 +21,7 @@ struct test_fail { }#define DEFINE_TEST_OK (type, test) \ - const type test[] __initdata + const type test[] __initconst#define TEST_FAIL (fn, type, fmt, test) \ { \
Signature · 1 line
1.7.4.4
Quoted 7 lines · Andi Kleen
This is a global tree sweep to fix up initconst section problems.
Any variable const in initdata must be marked
__initconst, not initdata. const__read_mostlyis not allowed.Otherwise the global sections can get a read only marking and in some circumstances the compiler/and or the linker will detect conflicts.
In some circumstances? Care to explain that in detail?
Quoted 1 line
This patchkit aims to fix it up everywhere.
Aims? How did you generate these patches? [grep|compile+look] and hack or did you actually use something sensible like coccinelle?
Quoted 3 lines
Also available in
git://github.com/andikleen/linux-misc.gitconst-sectionsNote I plan to ask Linus to pull this directly.
You can plan what you want, but unless you provide substantial information please target your plan towards /dev/null
Thanks,
tglx