All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ramona Bolboaca <ramona.bolboaca@analog.com>
To: <jic23@kernel.org>, <robh+dt@kernel.org>,
	<krzysztof.kozlowski+dt@linaro.org>, <linux-iio@vger.kernel.org>,
	<devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Cc: Ramona Bolboaca <ramona.bolboaca@analog.com>
Subject: [PATCH v2 1/3] drivers: iio: accel: Use warning if invalid device id is detected
Date: Mon, 31 Oct 2022 12:51:27 +0200	[thread overview]
Message-ID: <20221031105129.47740-2-ramona.bolboaca@analog.com> (raw)
In-Reply-To: <20221031105129.47740-1-ramona.bolboaca@analog.com>

Use warning instead of failing driver probe if invalid device id is
detected for ADXL355 device.

Signed-off-by: Ramona Bolboaca <ramona.bolboaca@analog.com>
---
changes in v2:
 - new patch
 drivers/iio/accel/adxl355_core.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/iio/accel/adxl355_core.c b/drivers/iio/accel/adxl355_core.c
index 4bc648eac8b2..dd08253d66d0 100644
--- a/drivers/iio/accel/adxl355_core.c
+++ b/drivers/iio/accel/adxl355_core.c
@@ -262,10 +262,8 @@ static int adxl355_setup(struct adxl355_data *data)
 	if (ret)
 		return ret;
 
-	if (regval != ADXL355_PARTID_VAL) {
-		dev_err(data->dev, "Invalid DEV ID 0x%02x\n", regval);
-		return -ENODEV;
-	}
+	if (regval != ADXL355_PARTID_VAL)
+		dev_warn(data->dev, "Invalid DEV ID 0x%02x\n", regval);
 
 	/*
 	 * Perform a software reset to make sure the device is in a consistent
-- 
2.25.1


  reply	other threads:[~2022-10-31 10:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-31 10:51 [PATCH v2 0/3] Add ADXL359 support Ramona Bolboaca
2022-10-31 10:51 ` Ramona Bolboaca [this message]
2022-10-31 10:51 ` [PATCH v2 2/3] dt-bindings: iio: accel: Add docs for ADXL359 Ramona Bolboaca
2022-11-02 15:58   ` Rob Herring
2022-10-31 10:51 ` [PATCH v2 3/3] drivers: iio: accel: Add support for ADXL359 device Ramona Bolboaca
2022-11-06 12:56   ` Jonathan Cameron

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20221031105129.47740-2-ramona.bolboaca@analog.com \
    --to=ramona.bolboaca@analog.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jic23@kernel.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.