From: Sudip Mukherjee Date: Thu, 3 Sep 2015 14:50:49 +0000 (+0530) Subject: drivers/misc/sgi-gru: remove always false condition X-Git-Tag: v4.14-rc1~4418^2~160 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c2ed545cee2412a47a5931340ba408b8abcee22c;p=platform%2Fkernel%2Flinux-rpi.git drivers/misc/sgi-gru: remove always false condition The member gid in struct gru_dump_chiplet_state_req is unsigned int. So it can never be less than 0. Signed-off-by: Sudip Mukherjee Acked-by: Dimitri Sivanich Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/misc/sgi-gru/grukdump.c b/drivers/misc/sgi-gru/grukdump.c index 7e9aae5..313da31 100644 --- a/drivers/misc/sgi-gru/grukdump.c +++ b/drivers/misc/sgi-gru/grukdump.c @@ -194,7 +194,7 @@ int gru_dump_chiplet_request(unsigned long arg) return -EFAULT; /* Currently, only dump by gid is implemented */ - if (req.gid >= gru_max_gids || req.gid < 0) + if (req.gid >= gru_max_gids) return -EINVAL; gru = GID_TO_GRU(req.gid);