From: Sasha Levin Date: Sun, 9 Sep 2012 14:16:58 +0000 (+0200) Subject: dlm: check the maximum size of a request from user X-Git-Tag: omap-for-v3.7-rc1/fixes-cpufreq-signed~71^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2b75bc9121e54e22537207b47b71373bcb0be41c;p=pandora-kernel.git dlm: check the maximum size of a request from user device_write only checks whether the request size is big enough, but it doesn't check if the size is too big. At that point, it also tries to allocate as much memory as the user has requested even if it's too much. This can lead to OOM killer kicking in, or memory corruption if (count + 1) overflows. Signed-off-by: Sasha Levin Signed-off-by: David Teigland --- Reading git-diff-tree failed