summaryrefslogtreecommitdiffstats
path: root/target/linux/generic/files
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/generic/files')
-rw-r--r--target/linux/generic/files/drivers/char/gpio_dev.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/target/linux/generic/files/drivers/char/gpio_dev.c b/target/linux/generic/files/drivers/char/gpio_dev.c
index 0f428bd38..c74157302 100644
--- a/target/linux/generic/files/drivers/char/gpio_dev.c
+++ b/target/linux/generic/files/drivers/char/gpio_dev.c
@@ -141,6 +141,8 @@ out:
static int
gpio_remove(struct platform_device *dev)
{
+ device_destroy(gpiodev_class, MKDEV(dev_major, 0));
+ class_destroy(gpiodev_class);
unregister_chrdev(dev_major, DEVNAME);
return 0;
}