All of lore.kernel.org
 help / color / mirror / Atom feed
* patch "iio: magnetometer: yas530: Fix return value on error path" added to staging-next
@ 2021-04-07  8:10 gregkh
  0 siblings, 0 replies; only message in thread
From: gregkh @ 2021-04-07  8:10 UTC (permalink / raw)
  To: linus.walleij, Jonathan.Cameron, Stable, andy.shevchenko,
	dan.carpenter, lkp


This is a note to let you know that I've just added the patch titled

    iio: magnetometer: yas530: Fix return value on error path

to my staging git tree which can be found at
    git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
in the staging-next branch.

The patch will show up in the next release of the linux-next tree
(usually sometime within the next 24 hours during the week.)

The patch will also be merged in the next major kernel release
during the merge window.

If you have any questions about this process, please let me know.


From e64837bf9e2c063d6b5bab51c0554a60270f636d Mon Sep 17 00:00:00 2001
From: Linus Walleij <linus.walleij@linaro.org>
Date: Mon, 15 Feb 2021 16:30:23 +0100
Subject: iio: magnetometer: yas530: Fix return value on error path

There was a missed return variable assignment in the
default errorpath of the switch statement in yas5xx_probe().
Fix it.

Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20210215153023.47899-1-linus.walleij@linaro.org
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
---
 drivers/iio/magnetometer/yamaha-yas530.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/iio/magnetometer/yamaha-yas530.c b/drivers/iio/magnetometer/yamaha-yas530.c
index d46f23d82b3d..cee6207d8847 100644
--- a/drivers/iio/magnetometer/yamaha-yas530.c
+++ b/drivers/iio/magnetometer/yamaha-yas530.c
@@ -887,6 +887,7 @@ static int yas5xx_probe(struct i2c_client *i2c,
 		strncpy(yas5xx->name, "yas532", sizeof(yas5xx->name));
 		break;
 	default:
+		ret = -ENODEV;
 		dev_err(dev, "unhandled device ID %02x\n", yas5xx->devid);
 		goto assert_reset;
 	}
-- 
2.31.1



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-04-07  8:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-07  8:10 patch "iio: magnetometer: yas530: Fix return value on error path" added to staging-next gregkh

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.