From: Bernd Porr Date: Wed, 11 Dec 2013 16:06:15 +0000 (+0000) Subject: staging: comedi: fix result of memdup_user for user chanlist X-Git-Tag: v3.14-rc1~150^2~250 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e56b1401056288a725d50942ef300dcbed5e519a;p=pandora-kernel.git staging: comedi: fix result of memdup_user for user chanlist If the channel list is not set in userspace we get an error at PTR_ERR(async->cmd.chanlist). However, do_become_nonbusy(dev, s) cleans up this pointer which causes a kernel ooops. Setting the channel list in async to NULL and checking this in do_become_nonbusy prevents the oops. [Ian Abbott] Also do the same for the chanlist allocated in do_cmdtest_ioctl(). Signed-off-by: Bernd Porr Signed-off-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed