mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
leds: pwm: silently error out on EPROBE_DEFER
When probing, if we fail to get the pwm due to probe deferal, we shouldn't print an error message. Just be silent in this case. Signed-off-by: Jerome Brunet <[email protected]> Signed-off-by: Jacek Anaszewski <[email protected]>
This commit is contained in:
parent
f813eec972
commit
9aec30371f
1 changed files with 3 additions and 2 deletions
|
|
@ -100,8 +100,9 @@ static int led_pwm_add(struct device *dev, struct led_pwm_priv *priv,
|
|||
led_data->pwm = devm_pwm_get(dev, led->name);
|
||||
if (IS_ERR(led_data->pwm)) {
|
||||
ret = PTR_ERR(led_data->pwm);
|
||||
dev_err(dev, "unable to request PWM for %s: %d\n",
|
||||
led->name, ret);
|
||||
if (ret != -EPROBE_DEFER)
|
||||
dev_err(dev, "unable to request PWM for %s: %d\n",
|
||||
led->name, ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue