platform/x86: surface3_power: Fix always true condition in mshw0011_space_handler()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 30 Mar 2020 10:26:50 +0000 (13:26 +0300)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 30 Mar 2020 10:26:50 +0000 (13:26 +0300)
commitd878bdfba8ffda64265c921cf7497934a607f83a
treebefd94c3b5474376ad279dc8f1c37f7c4a4228e5
parentba308bd09099d3997f7d95e928a3664f8b20e619
platform/x86: surface3_power: Fix always true condition in mshw0011_space_handler()

smatch warnings:
.../surface3_power.c:417 mshw0011_space_handler() warn: always true condition '(ret >= 0) => +(0-u32max >= 0)'

Refactor error handling returned by mshw0011_adp_psr() to avoid always
true condition.

Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/platform/x86/surface3_power.c