[PATCH] make more file_operation structs static
[deliverable/linux.git] / drivers / char / pc8736x_gpio.c
index 1c706ccfdbb36265aa3f66ac029007c73e684bc8..4005ee0aa11ed5a9a2bc02ccc1f069c2c2d05ff6 100644 (file)
@@ -236,7 +236,7 @@ static int pc8736x_gpio_open(struct inode *inode, struct file *file)
        return nonseekable_open(inode, file);
 }
 
-static struct file_operations pc8736x_gpio_fops = {
+static const struct file_operations pc8736x_gpio_fops = {
        .owner  = THIS_MODULE,
        .open   = pc8736x_gpio_open,
        .write  = nsc_gpio_write,
@@ -319,9 +319,10 @@ static int __init pc8736x_gpio_init(void)
        return 0;
 
 undo_platform_dev_add:
-       platform_device_put(pdev);
+       platform_device_del(pdev);
 undo_platform_dev_alloc:
-       kfree(pdev);
+       platform_device_put(pdev);
+
        return rc;
 }
 
This page took 0.025846 seconds and 5 git commands to generate.