- Added a check for the return value of spi_setup() in the l4f00242t03 driver to catch errors.

-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEdrbJNaO+IJqU8IdIUa+KL4f8d2EFAmbxjT8ACgkQUa+KL4f8
 d2G9/g/+PkSH2AAcArhenm9KaCK0spyGrZ7Pdai7cF0nhUcTibh6T5MaOqBecPLd
 nPNZ27CLcLoKnBAPWmbE0FLNAX8OFudCAr114KpBkZe3eP7FhJ0uO/qEi+4Nbfhv
 t5Uef15sf7wnkLJq+rJFNqg1tMj9EqsAIQj85Z9G3e5m9BveCDlq675rFWmbByED
 pVwFtqF2kgI/F4Zdv8RSaExcRTz+q3k7jRTamFKS2V0SmhsWuy64Wz0O+fk3SWE5
 jgopT/lGrN7K/cqnJfr++5kK012CwgOOqbgmbDEUfidbZkqsHOxKyjp5NdLykV2V
 vdHTAnmIVCanVd3yy7HSNafgCJkmonn2n9RMDEpIzhB6IfDN+kylqKFuhQ1/MwbS
 yfPQI4f+iHkSeVd85pEbCEeZuWMriwOBdiydqELs0FPhyZ9ezv4De+B9BKndlpuC
 JTzSgYvO4HqxsYGyTRIPmrd9zWSwfrxUFKLN4zYP3oCVQdLUVWh3JHWOQlWmds4e
 GyWnTfjpCK3FpjEVJZ8siS4Qbv5UzIQj+BsaoS5kkxkDL3GNOG4x+V6dm2FH6jbq
 po6K9cK3Zlxc5mfgGxvEsJ2DlIXpzQmrb2dsW5vR0UHjQAUapExIXlwlSYtgEybg
 sh8PHsTnbNa/5Uj6G/Cr9GTv3YZifS3EFrF06bMYjBcygnQJ1Uk=
 =9M/C
 -----END PGP SIGNATURE-----

Merge tag 'backlight-next-6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight

Pull backlight update from Lee Jones:

 - Added a check for the return value of spi_setup() in the l4f00242t03
   driver to catch errors

* tag 'backlight-next-6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight:
  backlight: l4f00242t03: Add check for spi_setup
This commit is contained in:
Linus Torvalds 2024-09-23 14:29:11 -07:00
commit 20d9ba738b

View File

@ -166,6 +166,7 @@ static const struct lcd_ops l4f_ops = {
static int l4f00242t03_probe(struct spi_device *spi)
{
struct l4f00242t03_priv *priv;
int ret;
priv = devm_kzalloc(&spi->dev, sizeof(struct l4f00242t03_priv),
GFP_KERNEL);
@ -174,7 +175,9 @@ static int l4f00242t03_probe(struct spi_device *spi)
spi_set_drvdata(spi, priv);
spi->bits_per_word = 9;
spi_setup(spi);
ret = spi_setup(spi);
if (ret < 0)
return dev_err_probe(&spi->dev, ret, "Unable to setup spi.\n");
priv->spi = spi;