Ticket #79: gta01-missing-platform_data.patch

File gta01-missing-platform_data.patch, 1.8 KB (added by mwester@…, 11 years ago)

Add missing platform_data that caused the GTA01 to crash on suspend/resume

  • arch/arm/mach-s3c2410/mach-gta01.c

    old new  
    7373#include <asm/plat-s3c24xx/pm.h> 
    7474#include <asm/plat-s3c24xx/udc.h> 
    7575#include <asm/plat-s3c24xx/neo1973.h> 
     76#include <linux/jbt6k74.h> 
    7677 
    7778static struct map_desc gta01_iodesc[] __initdata = { 
    7879        { 
     
    389390        int bit; 
    390391        int mv = 1700; /* 1.7V for MMC_VDD_165_195 */ 
    391392 
    392         printk(KERN_DEBUG "mmc_set_power(power_mode=%u, vdd=%u\n", 
     393        printk(KERN_DEBUG "mmc_set_power(power_mode=%u, vdd=%u)\n", 
    393394               power_mode, vdd); 
    394395 
    395396        switch (system_rev) { 
     
    499500 
    500501/* SPI */ 
    501502 
     503void gta01_jbt6k74_reset(int devidx, int level) 
     504{ 
     505        /* empty place holder; gta01 does not yet use this */ 
     506        printk(KERN_DEBUG "gta01_jbt6k74_reset\n"); 
     507} 
     508 
     509const struct jbt6k74_platform_data gta01_jbt6k74_pdata = { 
     510        .reset          = gta01_jbt6k74_reset, 
     511}; 
     512 
    502513static struct spi_board_info gta01_spi_board_info[] = { 
    503514        { 
    504515                .modalias       = "jbt6k74", 
    505                 /* platform_data */ 
     516                .platform_data  = &gta01_jbt6k74_pdata, 
    506517                /* controller_data */ 
    507518                /* irq */ 
    508519                .max_speed_hz   = 10 * 1000 * 1000, 
     
    641652 
    642653static irqreturn_t gta01_modem_irq(int irq, void *param) 
    643654{ 
    644         printk(KERN_DEBUG "modem wakeup interrupt\n"); 
     655        printk(KERN_DEBUG "GSM wakeup interrupt (IRQ %d)\n", irq); 
    645656        return IRQ_HANDLED; 
    646657} 
    647658 
     
    709720        set_irq_type(GTA01_IRQ_MODEM, IRQT_RISING); 
    710721        rc = request_irq(GTA01_IRQ_MODEM, gta01_modem_irq, IRQF_DISABLED, 
    711722                         "modem", NULL); 
    712         if (!rc) 
    713                 printk(KERN_ERR  "GTA01: can't request GSM modem wakeup IRQ\n"); 
    714723        enable_irq_wake(GTA01_IRQ_MODEM); 
     724        printk(KERN_DEBUG  "Enabled GSM wakeup IRQ %d (rc=%d)\n", 
     725               GTA01_IRQ_MODEM, rc); 
    715726} 
    716727 
    717728MACHINE_START(NEO1973_GTA01, "GTA01")