Whamcloud - gitweb
LU-8774 lprocfs: not use MAX_STRING_SIZE in copy_from_user 62/23462/4
authorJian Yu <jian.yu@intel.com>
Mon, 31 Oct 2016 06:26:45 +0000 (14:26 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Sat, 19 Nov 2016 22:44:20 +0000 (22:44 +0000)
commita9ae88bbaca0770f28f3c88a4afed6b99403aec6
treee0ac085ffda30a29db9fad429fd2f9988d2bd231
parent4bc9bae59fea315bdd36e8170e8388d5fce2a397
LU-8774 lprocfs: not use MAX_STRING_SIZE in copy_from_user

This patch removes the usage of MAX_STRING_SIZE from
copy_from_user() and just copies enough bytes to cover
count passed in.

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I1ac2c779b5cd984f88bb85d4ae8d571f7931091f
Reviewed-on: http://review.whamcloud.com/23462
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/ldlm/ldlm_resource.c
lustre/obdclass/lprocfs_status.c