Changeset 10623


Ignore:
Timestamp:
2008-03-19T11:35:56+01:00 (9 years ago)
Author:
mb
Message:

bcm47xx: Register a GPIODEV platform device to allow GPIO access via /dev/gpio

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/brcm47xx/files/arch/mips/bcm947xx/setup.c

    r10509 r10623  
    227227} 
    228228 
     229static int __init bcm47xx_register_gpiodev(void) 
     230{ 
     231        static struct resource res = { 
     232                .start = 0xFFFFFFFF, 
     233        }; 
     234        struct platform_device *pdev; 
     235 
     236        pdev = platform_device_register_simple("GPIODEV", 0, &res, 1); 
     237        if (!pdev) { 
     238                printk(KERN_ERR "bcm47xx: GPIODEV init failed\n"); 
     239                return -ENODEV; 
     240        } 
     241 
     242        return 0; 
     243} 
     244device_initcall(bcm47xx_register_gpiodev); 
     245 
    229246EXPORT_SYMBOL(ssb); 
Note: See TracChangeset for help on using the changeset viewer.