usb: misc: ljca: Fix enumeration error on Dell Latitude 9420
PATCH v3 1/1 usb: misc: ljca: Fix enumeration error on Dell Latitude 9420
Not all LJCA chips implement SPI and on chips without SPI reading the SPI descriptors will timeout.
On laptop models like the Dell Latitude 9420, this is expected behavior and not an error.
Modify the driver to continue without instantiating a SPI auxbus child, instead of failing to probe() the whole LJCA chip.
---
Changes in v3:
- Fix commit-id in fixes tag
Changes in v2:
- Small commit msg + comment fixes
- Add Fixes tag + Cc: stable
--- drivers/usb/misc/usb-ljca.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/usb/misc/usb-ljca.c +2 -1
@@ -656,10 +656,11 @@ static int ljca_enumerate_spi(struct ljca_adapter *adap)unsigned int i;int ret; +/* Not all LJCA chips implement SPI, a timeout reading the descriptors is normal */ ret =ljca_send (adap,LJCA_CLIENT_MNG ,LJCA_MNG_ENUM_SPI ,NULL ,0 , buf,sizeof (buf), true,LJCA_ENUM_CLIENT_TIMEOUT_MS );if (ret <0 ) -return ret; +return (ret == -ETIMEDOUT ) ?0 : ret;/* check firmware response */ desc = (struct ljca_spi_descriptor *)buf;
Signature · 1 line
2.41.0
Greg Kroah-Hartman
maintainerQuoted 11 lines · Hans de Goede
Not all LJCA chips implement SPI and on chips without SPI reading the SPI descriptors will timeout.
On laptop models like the Dell Latitude 9420, this is expected behavior and not an error.
Modify the driver to continue without instantiating a SPI auxbus child, instead of failing to
probe()the whole LJCA chip.Fixes acd6199f195d ("usb: Add support for Intel LJCA device")
Nit, stable is not needed as the above commit only ended up in 6.7-rc1, nothing older. I'll drop it when I queue this up, thanks!
greg k-h
Hi Hans,
Quoted 11 lines · Hans de Goede
Not all LJCA chips implement SPI and on chips without SPI reading the SPI descriptors will timeout.
On laptop models like the Dell Latitude 9420, this is expected behavior and not an error.
Modify the driver to continue without instantiating a SPI auxbus child, instead of failing to
probe()the whole LJCA chip.Fixes acd6199f195d ("usb: Add support for Intel LJCA device")
did this already make it to stable? I think it is not needed.
Quoted 3 lines
Signed-off-by Hans de Goede <[email protected]>Reviewed-by Wentong Wu <[email protected]>
Thanks,
Andi
Quoted 30 lines
---
Changes in v3:
- Fix commit-id in fixes tagChanges in v2:
- Small commit msg + comment fixes
- Add Fixes tag + Cc: stable--- drivers/usb/misc/usb-ljca.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/usb/misc/usb-ljca.c +2
-1@@ -656,10 +656,11 @@ static int ljca_enumerate_spi(struct ljca_adapter *adap)unsigned int i;int ret; +/* Not all LJCA chips implement SPI, a timeout reading the descriptors is normal */ ret =ljca_send (adap,LJCA_CLIENT_MNG ,LJCA_MNG_ENUM_SPI ,NULL ,0 , buf,sizeof (buf), true,LJCA_ENUM_CLIENT_TIMEOUT_MS );if (ret <0 ) -return ret; +return (ret == -ETIMEDOUT ) ?0 : ret;/* check firmware response */ desc = (struct ljca_spi_descriptor *)buf;Signature · 1 line
2.41.0