* [lm-sensors] [PATCH -next] hwmon: (pwm-fan) Fix sparse NULL pointer warning
@ 2014-07-28 13:17 weiyj_lk
2014-07-28 14:26 ` Guenter Roeck
0 siblings, 1 reply; 2+ messages in thread
From: weiyj_lk @ 2014-07-28 13:17 UTC (permalink / raw)
To: lm-sensors
From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Fixes the following sparse warnings:
drivers/hwmon/pwm-fan.c:107:67: warning: Using plain integer as NULL pointer
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
drivers/hwmon/pwm-fan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hwmon/pwm-fan.c b/drivers/hwmon/pwm-fan.c
index ba7fe3e..af30dd6 100644
--- a/drivers/hwmon/pwm-fan.c
+++ b/drivers/hwmon/pwm-fan.c
@@ -104,7 +104,7 @@ static int pwm_fan_probe(struct platform_device *pdev)
mutex_init(&ctx->lock);
- ctx->pwm = devm_of_pwm_get(&pdev->dev, pdev->dev.of_node, 0);
+ ctx->pwm = devm_of_pwm_get(&pdev->dev, pdev->dev.of_node, NULL);
if (IS_ERR(ctx->pwm)) {
dev_err(&pdev->dev, "Could not get PWM\n");
return PTR_ERR(ctx->pwm);
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [lm-sensors] [PATCH -next] hwmon: (pwm-fan) Fix sparse NULL pointer warning
2014-07-28 13:17 [lm-sensors] [PATCH -next] hwmon: (pwm-fan) Fix sparse NULL pointer warning weiyj_lk
@ 2014-07-28 14:26 ` Guenter Roeck
0 siblings, 0 replies; 2+ messages in thread
From: Guenter Roeck @ 2014-07-28 14:26 UTC (permalink / raw)
To: lm-sensors
On 07/28/2014 06:17 AM, weiyj_lk@163.com wrote:
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> Fixes the following sparse warnings:
>
> drivers/hwmon/pwm-fan.c:107:67: warning: Using plain integer as NULL pointer
>
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
I already had the fix for this in my tree.
Thanks,
Guenter
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-07-28 14:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-28 13:17 [lm-sensors] [PATCH -next] hwmon: (pwm-fan) Fix sparse NULL pointer warning weiyj_lk
2014-07-28 14:26 ` Guenter Roeck
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.