From: Oleg Nesterov Date: Wed, 10 Dec 2014 23:45:12 +0000 (-0800) Subject: proc: task_state: deuglify the max_fds calculation X-Git-Tag: omap-for-v3.19/fixes-rc1~142^2~104 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0f4a0d53f20c76a70cb5b69b6aa237de2107e171;p=pandora-kernel.git proc: task_state: deuglify the max_fds calculation 1. The usage of fdt looks very ugly, it can't be NULL if ->files is not NULL. We can use "unsigned int max_fds" instead. 2. This also allows to move seq_printf(max_fds) outside of task_lock() and join it with the previous seq_printf(). See also the next patch. Signed-off-by: Oleg Nesterov Cc: Aaron Tomlin Cc: Alexey Dobriyan Cc: "Eric W. Biederman" , Cc: Sterling Alexander Cc: Peter Zijlstra Cc: Roland McGrath Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed