* [PATCH 0/4] media: i2c/pci: Various error logging improvements
@ 2025-06-23 11:00 Hans de Goede
2025-06-23 11:00 ` [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
` (3 more replies)
0 siblings, 4 replies; 10+ messages in thread
From: Hans de Goede @ 2025-06-23 11:00 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media
Hi all,
Here is a resend of a bunch or error logging improvements which I send
out last year, but which seem to have fallen through the cracks.
Regards,
Hans
Hans de Goede (4):
media: ov5693: Improve error logging when fwnode is not found
media: ov7251: Improve error logging when fwnode is not found
media: ov8865: Improve error logging when fwnode is not found
media: ipu-bridge: Improve error logging when waiting for IVSC to
become ready
drivers/media/i2c/ov5693.c | 7 ++++++-
drivers/media/i2c/ov7251.c | 7 ++++++-
drivers/media/i2c/ov8865.c | 3 ++-
drivers/media/pci/intel/ipu-bridge.c | 3 ++-
4 files changed, 16 insertions(+), 4 deletions(-)
--
2.49.0
^ permalink raw reply [flat|nested] 10+ messages in thread* [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found
2025-06-23 11:00 [PATCH 0/4] media: i2c/pci: Various error logging improvements Hans de Goede
@ 2025-06-23 11:00 ` Hans de Goede
2025-06-24 12:43 ` Daniel Scally
2025-06-23 11:00 ` [PATCH 2/4] media: ov7251: " Hans de Goede
` (2 subsequent siblings)
3 siblings, 1 reply; 10+ messages in thread
From: Hans de Goede @ 2025-06-23 11:00 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media, Hans de Goede
From: Hans de Goede <hdegoede@redhat.com>
The ov5693 driver waits for the endpoint fwnode to show up in case this
fwnode is created by a bridge-driver.
It does this by returning -EPROBE_DEFER, but it does not use
dev_err_probe() so no reason for deferring gets registered.
After 30 seconds the kernel logs a warning that the probe is still
deferred, which looks like this:
[ 33.951709] i2c i2c-INT33BE:00: deferred probe pending: (reason unknown)
Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
deferral reason changing the error to:
deferred probe pending: waiting for fwnode graph endpoint
Also update the comment to not refer to the no longer existing cio2-bridge
code.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/i2c/ov5693.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/media/i2c/ov5693.c b/drivers/media/i2c/ov5693.c
index 46b9ce111676..485efd15257e 100644
--- a/drivers/media/i2c/ov5693.c
+++ b/drivers/media/i2c/ov5693.c
@@ -1222,9 +1222,14 @@ static int ov5693_check_hwcfg(struct ov5693_device *ov5693)
unsigned int i;
int ret;
+ /*
+ * Sometimes the fwnode graph is initialized by the bridge driver
+ * Bridge drivers doing this may also add GPIO mappings, wait for this.
+ */
endpoint = fwnode_graph_get_next_endpoint(fwnode, NULL);
if (!endpoint)
- return -EPROBE_DEFER; /* Could be provided by cio2-bridge */
+ return dev_err_probe(ov5693->dev, -EPROBE_DEFER,
+ "waiting for fwnode graph endpoint\n");
ret = v4l2_fwnode_endpoint_alloc_parse(endpoint, &bus_cfg);
fwnode_handle_put(endpoint);
--
2.49.0
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found
2025-06-23 11:00 ` [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
@ 2025-06-24 12:43 ` Daniel Scally
0 siblings, 0 replies; 10+ messages in thread
From: Daniel Scally @ 2025-06-24 12:43 UTC (permalink / raw)
To: Hans de Goede
Cc: Sakari Ailus, Mauro Carvalho Chehab, linux-media, Hans de Goede
Hi Hans; trying again now that I remembered how to Reply All...
On Mon, Jun 23, 2025 at 12:00 PM Hans de Goede <hansg@kernel.org> wrote:
>
> From: Hans de Goede <hdegoede@redhat.com>
>
> The ov5693 driver waits for the endpoint fwnode to show up in case this
> fwnode is created by a bridge-driver.
>
> It does this by returning -EPROBE_DEFER, but it does not use
> dev_err_probe() so no reason for deferring gets registered.
>
> After 30 seconds the kernel logs a warning that the probe is still
> deferred, which looks like this:
>
> [ 33.951709] i2c i2c-INT33BE:00: deferred probe pending: (reason unknown)
>
> Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
> deferral reason changing the error to:
>
> deferred probe pending: waiting for fwnode graph endpoint
>
> Also update the comment to not refer to the no longer existing cio2-bridge
> code.
>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Daniel Scally <djrscally@gmail.com>
> ---
> drivers/media/i2c/ov5693.c | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/i2c/ov5693.c b/drivers/media/i2c/ov5693.c
> index 46b9ce111676..485efd15257e 100644
> --- a/drivers/media/i2c/ov5693.c
> +++ b/drivers/media/i2c/ov5693.c
> @@ -1222,9 +1222,14 @@ static int ov5693_check_hwcfg(struct ov5693_device *ov5693)
> unsigned int i;
> int ret;
>
> + /*
> + * Sometimes the fwnode graph is initialized by the bridge driver
> + * Bridge drivers doing this may also add GPIO mappings, wait for this.
> + */
> endpoint = fwnode_graph_get_next_endpoint(fwnode, NULL);
> if (!endpoint)
> - return -EPROBE_DEFER; /* Could be provided by cio2-bridge */
> + return dev_err_probe(ov5693->dev, -EPROBE_DEFER,
> + "waiting for fwnode graph endpoint\n");
>
> ret = v4l2_fwnode_endpoint_alloc_parse(endpoint, &bus_cfg);
> fwnode_handle_put(endpoint);
> --
> 2.49.0
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 2/4] media: ov7251: Improve error logging when fwnode is not found
2025-06-23 11:00 [PATCH 0/4] media: i2c/pci: Various error logging improvements Hans de Goede
2025-06-23 11:00 ` [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
@ 2025-06-23 11:00 ` Hans de Goede
2025-06-24 12:44 ` Daniel Scally
2025-06-23 11:00 ` [PATCH 3/4] media: ov8865: " Hans de Goede
2025-06-23 11:00 ` [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready Hans de Goede
3 siblings, 1 reply; 10+ messages in thread
From: Hans de Goede @ 2025-06-23 11:00 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media, Hans de Goede
From: Hans de Goede <hdegoede@redhat.com>
The ov7251 driver waits for the endpoint fwnode to show up in case this
fwnode is created by a bridge-driver.
It does this by returning -EPROBE_DEFER, but it does not use
dev_err_probe() so no reason for deferring gets registered.
After 30 seconds the kernel logs a warning that the probe is still
deferred, which looks like this:
[ 33.952052] i2c i2c-INT347E:00: deferred probe pending: (reason unknown)
Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
deferral reason changing the error to:
deferred probe pending: waiting for fwnode graph endpoint
Also update the comment to not refer to the no longer existing cio2-bridge
code.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/i2c/ov7251.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/media/i2c/ov7251.c b/drivers/media/i2c/ov7251.c
index 3226888d77e9..31a42d81e970 100644
--- a/drivers/media/i2c/ov7251.c
+++ b/drivers/media/i2c/ov7251.c
@@ -1486,9 +1486,14 @@ static int ov7251_check_hwcfg(struct ov7251 *ov7251)
unsigned int i, j;
int ret;
+ /*
+ * Sometimes the fwnode graph is initialized by the bridge driver
+ * Bridge drivers doing this may also add GPIO mappings, wait for this.
+ */
endpoint = fwnode_graph_get_next_endpoint(fwnode, NULL);
if (!endpoint)
- return -EPROBE_DEFER; /* could be provided by cio2-bridge */
+ return dev_err_probe(ov7251->dev, -EPROBE_DEFER,
+ "waiting for fwnode graph endpoint\n");
ret = v4l2_fwnode_endpoint_alloc_parse(endpoint, &bus_cfg);
fwnode_handle_put(endpoint);
--
2.49.0
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH 2/4] media: ov7251: Improve error logging when fwnode is not found
2025-06-23 11:00 ` [PATCH 2/4] media: ov7251: " Hans de Goede
@ 2025-06-24 12:44 ` Daniel Scally
0 siblings, 0 replies; 10+ messages in thread
From: Daniel Scally @ 2025-06-24 12:44 UTC (permalink / raw)
To: Hans de Goede
Cc: Sakari Ailus, Mauro Carvalho Chehab, linux-media, Hans de Goede
On Mon, Jun 23, 2025 at 12:00 PM Hans de Goede <hansg@kernel.org> wrote:
>
> From: Hans de Goede <hdegoede@redhat.com>
>
> The ov7251 driver waits for the endpoint fwnode to show up in case this
> fwnode is created by a bridge-driver.
>
> It does this by returning -EPROBE_DEFER, but it does not use
> dev_err_probe() so no reason for deferring gets registered.
>
> After 30 seconds the kernel logs a warning that the probe is still
> deferred, which looks like this:
>
> [ 33.952052] i2c i2c-INT347E:00: deferred probe pending: (reason unknown)
>
> Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
> deferral reason changing the error to:
>
> deferred probe pending: waiting for fwnode graph endpoint
>
> Also update the comment to not refer to the no longer existing cio2-bridge
> code.
>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Daniel Scally <djrscally@gmail.com>
> ---
> drivers/media/i2c/ov7251.c | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/i2c/ov7251.c b/drivers/media/i2c/ov7251.c
> index 3226888d77e9..31a42d81e970 100644
> --- a/drivers/media/i2c/ov7251.c
> +++ b/drivers/media/i2c/ov7251.c
> @@ -1486,9 +1486,14 @@ static int ov7251_check_hwcfg(struct ov7251 *ov7251)
> unsigned int i, j;
> int ret;
>
> + /*
> + * Sometimes the fwnode graph is initialized by the bridge driver
> + * Bridge drivers doing this may also add GPIO mappings, wait for this.
> + */
> endpoint = fwnode_graph_get_next_endpoint(fwnode, NULL);
> if (!endpoint)
> - return -EPROBE_DEFER; /* could be provided by cio2-bridge */
> + return dev_err_probe(ov7251->dev, -EPROBE_DEFER,
> + "waiting for fwnode graph endpoint\n");
>
> ret = v4l2_fwnode_endpoint_alloc_parse(endpoint, &bus_cfg);
> fwnode_handle_put(endpoint);
> --
> 2.49.0
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 3/4] media: ov8865: Improve error logging when fwnode is not found
2025-06-23 11:00 [PATCH 0/4] media: i2c/pci: Various error logging improvements Hans de Goede
2025-06-23 11:00 ` [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
2025-06-23 11:00 ` [PATCH 2/4] media: ov7251: " Hans de Goede
@ 2025-06-23 11:00 ` Hans de Goede
2025-06-24 12:44 ` Daniel Scally
2025-06-23 11:00 ` [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready Hans de Goede
3 siblings, 1 reply; 10+ messages in thread
From: Hans de Goede @ 2025-06-23 11:00 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media, Hans de Goede
From: Hans de Goede <hdegoede@redhat.com>
The ov8865 driver waits for the endpoint fwnode to show up in case this
fwnode is created by a bridge-driver.
It does this by returning -EPROBE_DEFER, but it does not use
dev_err_probe() so no reason for deferring gets registered.
After 30 seconds the kernel logs a warning that the probe is still
deferred, which looks like this:
[ 33.952061] i2c i2c-INT347A:00: deferred probe pending: (reason unknown)
Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
deferral reason changing the error to:
deferred probe pending: waiting for fwnode graph endpoint
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/i2c/ov8865.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/media/i2c/ov8865.c b/drivers/media/i2c/ov8865.c
index 95ffe7536aa6..a2138f7988aa 100644
--- a/drivers/media/i2c/ov8865.c
+++ b/drivers/media/i2c/ov8865.c
@@ -2991,7 +2991,8 @@ static int ov8865_probe(struct i2c_client *client)
handle = fwnode_graph_get_next_endpoint(dev_fwnode(dev), NULL);
if (!handle)
- return -EPROBE_DEFER;
+ return dev_err_probe(dev, -EPROBE_DEFER,
+ "waiting for fwnode graph endpoint\n");
sensor->endpoint.bus_type = V4L2_MBUS_CSI2_DPHY;
--
2.49.0
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH 3/4] media: ov8865: Improve error logging when fwnode is not found
2025-06-23 11:00 ` [PATCH 3/4] media: ov8865: " Hans de Goede
@ 2025-06-24 12:44 ` Daniel Scally
0 siblings, 0 replies; 10+ messages in thread
From: Daniel Scally @ 2025-06-24 12:44 UTC (permalink / raw)
To: Hans de Goede
Cc: Sakari Ailus, Mauro Carvalho Chehab, linux-media, Hans de Goede
On Mon, Jun 23, 2025 at 12:00 PM Hans de Goede <hansg@kernel.org> wrote:
>
> From: Hans de Goede <hdegoede@redhat.com>
>
> The ov8865 driver waits for the endpoint fwnode to show up in case this
> fwnode is created by a bridge-driver.
>
> It does this by returning -EPROBE_DEFER, but it does not use
> dev_err_probe() so no reason for deferring gets registered.
>
> After 30 seconds the kernel logs a warning that the probe is still
> deferred, which looks like this:
>
> [ 33.952061] i2c i2c-INT347A:00: deferred probe pending: (reason unknown)
>
> Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
> deferral reason changing the error to:
>
> deferred probe pending: waiting for fwnode graph endpoint
>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Daniel Scally <djrscally@gmail.com>
> ---
> drivers/media/i2c/ov8865.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/i2c/ov8865.c b/drivers/media/i2c/ov8865.c
> index 95ffe7536aa6..a2138f7988aa 100644
> --- a/drivers/media/i2c/ov8865.c
> +++ b/drivers/media/i2c/ov8865.c
> @@ -2991,7 +2991,8 @@ static int ov8865_probe(struct i2c_client *client)
>
> handle = fwnode_graph_get_next_endpoint(dev_fwnode(dev), NULL);
> if (!handle)
> - return -EPROBE_DEFER;
> + return dev_err_probe(dev, -EPROBE_DEFER,
> + "waiting for fwnode graph endpoint\n");
>
> sensor->endpoint.bus_type = V4L2_MBUS_CSI2_DPHY;
>
> --
> 2.49.0
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready
2025-06-23 11:00 [PATCH 0/4] media: i2c/pci: Various error logging improvements Hans de Goede
` (2 preceding siblings ...)
2025-06-23 11:00 ` [PATCH 3/4] media: ov8865: " Hans de Goede
@ 2025-06-23 11:00 ` Hans de Goede
2025-06-24 12:44 ` Daniel Scally
3 siblings, 1 reply; 10+ messages in thread
From: Hans de Goede @ 2025-06-23 11:00 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media, Hans de Goede
From: Hans de Goede <hdegoede@redhat.com>
The ipu-bridge code waits for the IVSC to become ready (on platforms with
an IVSC chip).
It does this by returning -EPROBE_DEFER, but it does not use
dev_err_probe() so no reason for deferring gets registered.
After 30 seconds the kernel logs a warning that the probe is still
deferred, which looks like this:
[ 33.951709] pci 0000:00:14.3: deferred probe pending: (reason unknown)
Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
deferral reason changing the error to:
deferred probe pending: waiting for IVSC to become ready
to help with debugging why drivers are not binding if the iVSC does
not become ready for some reason.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/pci/intel/ipu-bridge.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/media/pci/intel/ipu-bridge.c b/drivers/media/pci/intel/ipu-bridge.c
index c80af394ce18..dbb847a104e0 100644
--- a/drivers/media/pci/intel/ipu-bridge.c
+++ b/drivers/media/pci/intel/ipu-bridge.c
@@ -811,7 +811,8 @@ int ipu_bridge_init(struct device *dev,
return 0;
if (!ipu_bridge_ivsc_is_ready())
- return -EPROBE_DEFER;
+ return dev_err_probe(dev, -EPROBE_DEFER,
+ "waiting for IVSC to become ready\n");
bridge = kzalloc(sizeof(*bridge), GFP_KERNEL);
if (!bridge)
--
2.49.0
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready
2025-06-23 11:00 ` [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready Hans de Goede
@ 2025-06-24 12:44 ` Daniel Scally
0 siblings, 0 replies; 10+ messages in thread
From: Daniel Scally @ 2025-06-24 12:44 UTC (permalink / raw)
To: Hans de Goede
Cc: Sakari Ailus, Mauro Carvalho Chehab, linux-media, Hans de Goede
On Mon, Jun 23, 2025 at 12:00 PM Hans de Goede <hansg@kernel.org> wrote:
>
> From: Hans de Goede <hdegoede@redhat.com>
>
> The ipu-bridge code waits for the IVSC to become ready (on platforms with
> an IVSC chip).
>
> It does this by returning -EPROBE_DEFER, but it does not use
> dev_err_probe() so no reason for deferring gets registered.
>
> After 30 seconds the kernel logs a warning that the probe is still
> deferred, which looks like this:
>
> [ 33.951709] pci 0000:00:14.3: deferred probe pending: (reason unknown)
>
> Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
> deferral reason changing the error to:
>
> deferred probe pending: waiting for IVSC to become ready
>
> to help with debugging why drivers are not binding if the iVSC does
> not become ready for some reason.
>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Daniel Scally <djrscally@gmail.com>
> ---
> drivers/media/pci/intel/ipu-bridge.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/pci/intel/ipu-bridge.c b/drivers/media/pci/intel/ipu-bridge.c
> index c80af394ce18..dbb847a104e0 100644
> --- a/drivers/media/pci/intel/ipu-bridge.c
> +++ b/drivers/media/pci/intel/ipu-bridge.c
> @@ -811,7 +811,8 @@ int ipu_bridge_init(struct device *dev,
> return 0;
>
> if (!ipu_bridge_ivsc_is_ready())
> - return -EPROBE_DEFER;
> + return dev_err_probe(dev, -EPROBE_DEFER,
> + "waiting for IVSC to become ready\n");
>
> bridge = kzalloc(sizeof(*bridge), GFP_KERNEL);
> if (!bridge)
> --
> 2.49.0
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found
@ 2024-10-05 12:15 Hans de Goede
2024-10-05 12:15 ` [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready Hans de Goede
0 siblings, 1 reply; 10+ messages in thread
From: Hans de Goede @ 2024-10-05 12:15 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media
The ov5693 driver waits for the endpoint fwnode to show up in case this
fwnode is created by a bridge-driver.
It does this by returning -EPROBE_DEFER, but it does not use
dev_err_probe() so no reason for deferring gets registered.
After 30 seconds the kernel logs a warning that the probe is still
deferred, which looks like this:
[ 33.951709] i2c i2c-INT33BE:00: deferred probe pending: (reason unknown)
Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
deferral reason changing the error to:
deferred probe pending: waiting for fwnode graph endpoint
Also update the comment to not refer to the no longer existing cio2-bridge
code.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/i2c/ov5693.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/media/i2c/ov5693.c b/drivers/media/i2c/ov5693.c
index 46b9ce111676..485efd15257e 100644
--- a/drivers/media/i2c/ov5693.c
+++ b/drivers/media/i2c/ov5693.c
@@ -1222,9 +1222,14 @@ static int ov5693_check_hwcfg(struct ov5693_device *ov5693)
unsigned int i;
int ret;
+ /*
+ * Sometimes the fwnode graph is initialized by the bridge driver
+ * Bridge drivers doing this may also add GPIO mappings, wait for this.
+ */
endpoint = fwnode_graph_get_next_endpoint(fwnode, NULL);
if (!endpoint)
- return -EPROBE_DEFER; /* Could be provided by cio2-bridge */
+ return dev_err_probe(ov5693->dev, -EPROBE_DEFER,
+ "waiting for fwnode graph endpoint\n");
ret = v4l2_fwnode_endpoint_alloc_parse(endpoint, &bus_cfg);
fwnode_handle_put(endpoint);
--
2.46.2
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready
2024-10-05 12:15 [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
@ 2024-10-05 12:15 ` Hans de Goede
0 siblings, 0 replies; 10+ messages in thread
From: Hans de Goede @ 2024-10-05 12:15 UTC (permalink / raw)
To: Daniel Scally, Sakari Ailus
Cc: Hans de Goede, Mauro Carvalho Chehab, linux-media
The ipu-bridge code waits for the IVSC to become ready (on platforms with
an IVSC chip).
It does this by returning -EPROBE_DEFER, but it does not use
dev_err_probe() so no reason for deferring gets registered.
After 30 seconds the kernel logs a warning that the probe is still
deferred, which looks like this:
[ 33.951709] pci 0000:00:14.3: deferred probe pending: (reason unknown)
Use dev_err_probe() when returning -EPROBE_DEFER to register the probe
deferral reason changing the error to:
deferred probe pending: waiting for IVSC to become ready
to help with debugging why drivers are not binding if the iVSC does
not become ready for some reason.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/media/pci/intel/ipu-bridge.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/media/pci/intel/ipu-bridge.c b/drivers/media/pci/intel/ipu-bridge.c
index e407c69bfcdc..35088601ed20 100644
--- a/drivers/media/pci/intel/ipu-bridge.c
+++ b/drivers/media/pci/intel/ipu-bridge.c
@@ -830,7 +830,8 @@ int ipu_bridge_init(struct device *dev,
return 0;
if (!ipu_bridge_ivsc_is_ready())
- return -EPROBE_DEFER;
+ return dev_err_probe(dev, -EPROBE_DEFER,
+ "waiting for IVSC to become ready\n");
bridge = kzalloc(sizeof(*bridge), GFP_KERNEL);
if (!bridge)
--
2.46.2
^ permalink raw reply related [flat|nested] 10+ messages in thread
end of thread, other threads:[~2025-06-24 12:45 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-23 11:00 [PATCH 0/4] media: i2c/pci: Various error logging improvements Hans de Goede
2025-06-23 11:00 ` [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
2025-06-24 12:43 ` Daniel Scally
2025-06-23 11:00 ` [PATCH 2/4] media: ov7251: " Hans de Goede
2025-06-24 12:44 ` Daniel Scally
2025-06-23 11:00 ` [PATCH 3/4] media: ov8865: " Hans de Goede
2025-06-24 12:44 ` Daniel Scally
2025-06-23 11:00 ` [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready Hans de Goede
2025-06-24 12:44 ` Daniel Scally
-- strict thread matches above, loose matches on Subject: below --
2024-10-05 12:15 [PATCH 1/4] media: ov5693: Improve error logging when fwnode is not found Hans de Goede
2024-10-05 12:15 ` [PATCH 4/4] media: ipu-bridge: Improve error logging when waiting for IVSC to become ready Hans de Goede
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox