Subject: [PATCH] ARM: MINI2440: Fix mini2440 crash on boot due to improper __initdata qualifier

From: [email-masked] (Ben Dooks)
Date: Fri, 15 Jan 2010 08:17:41 +0000

On Fri, Jan 15, 2010 at 07:31:55AM +0200, Uri Yosef wrote:
> On Fri, Jan 15, 2010 at 3:16 AM, Ben Dooks <[email-masked]> wrote:
> > On Thu, Jan 14, 2010 at 12:06:32PM +0200, Uri Yosef wrote:
> >> From: Uri Yosef <[email-masked]>
> >>
> >> This patch fix mini2440 crash on boot due to improper __initdata
> >> qualifier on mini2440_led1_pdata.
> >
> > I've tried to apply this, but git-am is refusing to belive it is a valid
> > patch file. The only thing I can see wrong is that something has changed
> > the TABs in the mail into spaces. However having reduced it to a single
> > line change it is still refusing to apply.
> >
> > Applying: ARM: MINI2440: Fix mini2440 crash on boot due to improper __initdata qualifier
> > error: patch failed: arch/arm/mach-s3c2440/mach-mini2440.c:402
> > error: arch/arm/mach-s3c2440/mach-mini2440.c: patch does not apply
> > Patch failed at 0001.
> >
> > $ git apply -v yuri
> > Checking patch arch/arm/mach-s3c2440/mach-mini2440.c...
> > error: while searching for:
> > static struct s3c24xx_led_platdata mini2440_led1_pdata __initdata = {
> >
> > error: patch failed: arch/arm/mach-s3c2440/mach-mini2440.c:402
> > error: arch/arm/mach-s3c2440/mach-mini2440.c: patch does not apply
> >
> > seems to suggest something else got borked with the formatting.
> >
> > Please sort this out and re-send.
> >
> 
> Re-send, patch file also included.

I've managed to apply this now to for-linus/samsung and sent a pull request
thanks.
 
> diff -ruN a/arch/arm/mach-s3c2440/mach-mini2440.c
> b/arch/arm/mach-s3c2440/mach-mini2440.c
> --- a/arch/arm/mach-s3c2440/mach-mini2440.c     2010-01-13
> 07:15:00.000000000 +0200
> +++ b/arch/arm/mach-s3c2440/mach-mini2440.c     2010-01-15
> 07:27:08.789255622 +0200
> @@ -399,35 +399,35 @@
> 
>  /* LEDS */
> 
> -static struct s3c24xx_led_platdata mini2440_led1_pdata __initdata = {
> +static struct s3c24xx_led_platdata mini2440_led1_pdata = {
>         .name           = "led1",
>         .gpio           = S3C2410_GPB(5),
>         .flags          = S3C24XX_LEDF_ACTLOW | S3C24XX_LEDF_TRISTATE,
>         .def_trigger    = "heartbeat",
>  };
> 
> -static struct s3c24xx_led_platdata mini2440_led2_pdata __initdata = {
> +static struct s3c24xx_led_platdata mini2440_led2_pdata = {
>         .name           = "led2",
>         .gpio           = S3C2410_GPB(6),
>         .flags          = S3C24XX_LEDF_ACTLOW | S3C24XX_LEDF_TRISTATE,
>         .def_trigger    = "nand-disk",
>  };
> 
> -static struct s3c24xx_led_platdata mini2440_led3_pdata __initdata = {
> +static struct s3c24xx_led_platdata mini2440_led3_pdata = {
>         .name           = "led3",
>         .gpio           = S3C2410_GPB(7),
>         .flags          = S3C24XX_LEDF_ACTLOW | S3C24XX_LEDF_TRISTATE,
>         .def_trigger    = "mmc0",
>  };
> 
> -static struct s3c24xx_led_platdata mini2440_led4_pdata __initdata = {
> +static struct s3c24xx_led_platdata mini2440_led4_pdata = {
>         .name           = "led4",
>         .gpio           = S3C2410_GPB(8),
>         .flags          = S3C24XX_LEDF_ACTLOW | S3C24XX_LEDF_TRISTATE,
>         .def_trigger    = "",
>  };
> 
> -static struct s3c24xx_led_platdata mini2440_led_backlight_pdata __initdata = {
> +static struct s3c24xx_led_platdata mini2440_led_backlight_pdata = {
>         .name           = "backlight",
>         .gpio           = S3C2410_GPG(4),
>         .def_trigger    = "backlight",

-- 
-- 
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.