Re: [PATCH 2/2] backlight: Add SY7758 6-channel High Efficiency LED Driver support
From: Neil Armstrong
Date: Wed Apr 29 2026 - 05:03:57 EST
On 4/29/26 01:35, Gyeyoung Baek wrote:
Hi,
+
+static int sy7758_probe(struct i2c_client *client)
+{
+
+ /* try read and check device id */
+ ret = regmap_read(sydev->regmap, REG_DEV_ID, &dev_id);
+ if (ret < 0)
+ return dev_err_probe(dev, -EPROBE_DEFER,
+ "failed to read device id\n");
regmap_read() seems it can return errors other than -EPROBE_DEFER
(like -EINVAL,), and hardcoding -EPROBE_DEFER here might drop the
actual error.
And maybe would keep retrying probe forever
I forgot to change it, initially the powering was clunky and we had a read error
in the first probe, but now it's solved so I'll remove it.
Neil
How about this?
+ return dev_err_probe(dev, ret, "failed to read device id\n");