OSDN Git Service

platform/x86: intel_pmc_core: Respect error code of kstrtou32_from_user()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Wed, 18 Dec 2019 18:42:29 +0000 (20:42 +0200)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Fri, 10 Jan 2020 09:50:32 +0000 (11:50 +0200)
commit9592438886756ce7d1327e9ec998b8bc0c1541bc
tree772e5dce06e1510c98844ab324a59b506a1dd92a
parente883cafd8de012edc979935610b04204c4c2a742
platform/x86: intel_pmc_core: Respect error code of kstrtou32_from_user()

kstrtou32_from_user() may return different error codes on certain
circumstances. Respect all possible values.

While here, move it out of the lock: there is no data access that lock guards.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/platform/x86/intel_pmc_core.c