From: H Hartley Sweeten Date: Thu, 17 Apr 2014 17:07:46 +0000 (-0700) Subject: staging: comedi: drivers: core validates chanlist_len max X-Git-Tag: omap-for-v3.16/fixes-against-rc1~39^2~36^2~1340 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=860b7c398a744c1eef42a59b661e870aca12d9be;p=pandora-kernel.git staging: comedi: drivers: core validates chanlist_len max The comedi core checks if the (cmd->chanlist_len > s->len_chanlist) when the comedi_cmd is copied from user to kernel space by __comedi_get_user_cmd(). If so, the core returns -EINVAL and will not call the subdevice (*do_cmdtest) and (*do_cmd). Remove the unnecessary "max" checks in the comedi driver (*do_cmdtest) and helper functions. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed