From 4e2b07e9ab8f8ddc7f6dbb6617ddb2bc704d15e9 Mon Sep 17 00:00:00 2001 From: Bill Pemberton <wfp5p@worldbroken.com> Date: Thu, 15 Jan 2015 21:18:26 -0500 Subject: [PATCH] greybus: gb-vibrator: remove useless if in timeout_store() val is an unsigned long so there is no point in checking if it is less than zero. Signed-off-by: Bill Pemberton <wfp5p@worldbroken.com> Signed-off-by: Greg Kroah-Hartman <greg@kroah.com> --- drivers/staging/greybus/gb-vibrator.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/staging/greybus/gb-vibrator.c b/drivers/staging/greybus/gb-vibrator.c index c85d95085040d..b5332df7039ca 100644 --- a/drivers/staging/greybus/gb-vibrator.c +++ b/drivers/staging/greybus/gb-vibrator.c @@ -100,8 +100,6 @@ static ssize_t timeout_store(struct device *dev, struct device_attribute *attr, return retval; } - if (val < 0) - return -EINVAL; if (val) retval = turn_on(vib, (u16)val); else -- 2.30.2