aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/drivers/firmware/stratix10-rsu.c
diff options
context:
space:
mode:
authorRichard Gong <richard.gong@intel.com>2020-06-03 09:06:52 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-07-02 14:48:48 +0200
commit52f944ee5d39b6b93797480f9181d3d40ed0d07b (patch)
tree771cf9c363599905d1be7117a36b68aab650728a /drivers/firmware/stratix10-rsu.c
parentfirmware: rsu: add device attributes to sysfs interface (diff)
downloadwireguard-linux-52f944ee5d39b6b93797480f9181d3d40ed0d07b.tar.xz
wireguard-linux-52f944ee5d39b6b93797480f9181d3d40ed0d07b.zip
firmware: stratix10-rsu: fix warnings
Patch fixes sparse warnings: using plain integer as NULL pointer. Replaces equal to with logical not operator. Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Richard Gong <richard.gong@intel.com> Link: https://lore.kernel.org/r/1591193212-15082-1-git-send-email-richard.gong@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/firmware/stratix10-rsu.c')
-rw-r--r--drivers/firmware/stratix10-rsu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/firmware/stratix10-rsu.c b/drivers/firmware/stratix10-rsu.c
index 0686338baafc..9378075d04e9 100644
--- a/drivers/firmware/stratix10-rsu.c
+++ b/drivers/firmware/stratix10-rsu.c
@@ -416,7 +416,7 @@ static ssize_t reboot_image_store(struct device *dev,
unsigned long address;
int ret;
- if (priv == 0)
+ if (!priv)
return -ENODEV;
ret = kstrtoul(buf, 0, &address);
@@ -441,7 +441,7 @@ static ssize_t notify_store(struct device *dev,
unsigned long status;
int ret;
- if (priv == 0)
+ if (!priv)
return -ENODEV;
ret = kstrtoul(buf, 0, &status);