From: Mauro Carvalho Chehab Date: Wed, 3 Sep 2014 18:18:27 +0000 (-0300) Subject: [media] media-devnode: just return 0 instead of using a var X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8b37c6455fc8f43e0e95db2847284e618db6a4f8;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git [media] media-devnode: just return 0 instead of using a var Instead of allocating a var to store 0 and just return it, change the code to return 0 directly. Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/media-devnode.c b/drivers/media/media-devnode.c index 7acd19c881de..ebf9626e5ae5 100644 --- a/drivers/media/media-devnode.c +++ b/drivers/media/media-devnode.c @@ -192,7 +192,6 @@ static int media_open(struct inode *inode, struct file *filp) static int media_release(struct inode *inode, struct file *filp) { struct media_devnode *mdev = media_devnode_data(filp); - int ret = 0; if (mdev->fops->release) mdev->fops->release(filp); @@ -201,7 +200,7 @@ static int media_release(struct inode *inode, struct file *filp) return value is ignored. */ put_device(&mdev->dev); filp->private_data = NULL; - return ret; + return 0; } static const struct file_operations media_devnode_fops = {