Skip to content

Commit

Permalink
hwmon: (corsair-psu) fix plain integer used as NULL pointer
Browse files Browse the repository at this point in the history
[ Upstream commit 8383226 ]

sparse warnings: (new ones prefixed by >>)
>> drivers/hwmon/corsair-psu.c:536:82: sparse: sparse: Using plain
   integer as NULL pointer

Fixes: d115b51 ("hwmon: add Corsair PSU HID controller driver")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Wilken Gottwalt <wilken.gottwalt@posteo.net>
Link: https://lore.kernel.org/r/YY9hAL8MZEQYLYPf@monster.localdomain
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
wgottwalt authored and gregkh committed Dec 17, 2021
1 parent d89e421 commit c0d44c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/hwmon/corsair-psu.c
Expand Up @@ -729,7 +729,7 @@ static int corsairpsu_probe(struct hid_device *hdev, const struct hid_device_id
corsairpsu_check_cmd_support(priv);

priv->hwmon_dev = hwmon_device_register_with_info(&hdev->dev, "corsairpsu", priv,
&corsairpsu_chip_info, 0);
&corsairpsu_chip_info, NULL);

if (IS_ERR(priv->hwmon_dev)) {
ret = PTR_ERR(priv->hwmon_dev);
Expand Down

0 comments on commit c0d44c5

Please sign in to comment.