示例#1
0
static int s3c24xx_led_suspend(struct platform_device *dev, pm_message_t state)
{
	struct s3c24xx_gpio_led *led = pdev_to_gpio(dev);

	led_classdev_suspend(&led->cdev);
	return 0;
}
示例#2
0
static int s3c24xx_led_resume(struct platform_device *dev)
{
	struct s3c24xx_gpio_led *led = pdev_to_gpio(dev);

	led_classdev_resume(&led->cdev);
	return 0;
}
示例#3
0
static int s3c24xx_led_remove(struct platform_device *dev)
{
    struct s3c24xx_gpio_led *led = pdev_to_gpio(dev);
    printk(KERN_ALERT "Goodbye, cruel world\n");
    led_classdev_unregister(&led->cdev);

    return 0;
}
示例#4
0
static int s3c24xx_led_remove(struct platform_device *dev)
{
	struct s3c24xx_gpio_led *led = pdev_to_gpio(dev);

	led_classdev_unregister(&led->cdev);
	kfree(led);

	return 0;
}
示例#5
0
static int __devexit gpio_sw_remove(struct platform_device *dev)
{
    struct gpio_sw *gpio = pdev_to_gpio(dev);
    GPIO_SW_DEBUG("pio_hdle is %x \n",gpio->cdev.pio_hdle);
    gpio_sw_put_resource(gpio);
    GPIO_SW_DEBUG("gpio_sw_put_resource ok !\n");
    gpio_sw_classdev_unregister(&gpio->cdev);
    GPIO_SW_DEBUG("gpio_sw_classdev_unregister ok !\n");
    kfree(gpio);
    GPIO_SW_DEBUG("kfree ok !\n");
    return 0;
}