[PATCH] staging: lirc: remove redundant NULL check in unregister_from_lirc()

2014-04-02 Thread Daeseok Youn

ir is already checked before calling unregister_from_lirc().

Signed-off-by: Daeseok Youn daeseok.y...@gmail.com
---
 drivers/staging/media/lirc/lirc_igorplugusb.c |6 --
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/media/lirc/lirc_igorplugusb.c 
b/drivers/staging/media/lirc/lirc_igorplugusb.c
index f508a13..e93e1c2 100644
--- a/drivers/staging/media/lirc/lirc_igorplugusb.c
+++ b/drivers/staging/media/lirc/lirc_igorplugusb.c
@@ -222,12 +222,6 @@ static int unregister_from_lirc(struct igorplug *ir)
struct lirc_driver *d;
int devnum;
 
-   if (!ir) {
-   dev_err(ir-usbdev-dev,
-   %s: called with NULL device struct!\n, __func__);
-   return -EINVAL;
-   }
-
devnum = ir-devnum;
d = ir-d;
 
-- 
1.7.4.4


--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] staging: lirc: remove redundant NULL check in unregister_from_lirc()

2014-04-02 Thread Dan Carpenter
On Wed, Apr 02, 2014 at 02:49:03AM -0700, Daeseok Youn wrote:
 
 ir is already checked before calling unregister_from_lirc().


Reviewed-by: Dan Carpenter dan.carpen...@oracle.com

regards,
dan carpenter

--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html