From patchwork Mon Oct 31 10:51:27 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ramona Bolboaca X-Patchwork-Id: 13197 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp2237747wru; Mon, 31 Oct 2022 03:53:22 -0700 (PDT) X-Google-Smtp-Source: AMsMyM42t469MOLA+aeS5ApxKKOL+aa8iOgL2D014UPgydHqQ5gM1pEvuFkWlDn34HBB6q81I28q X-Received: by 2002:a17:90a:1150:b0:213:a42b:a734 with SMTP id d16-20020a17090a115000b00213a42ba734mr14394116pje.163.1667213601862; Mon, 31 Oct 2022 03:53:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667213601; cv=none; d=google.com; s=arc-20160816; b=NCznuL9JhkLtNHgQsmLysHjzVVtMpkts/5KrczvPNbpqNR/W1bL8zb7k8FlQFN5sbm XXAyaS4MIzPmLLtH0HXgv7EQIsuwIoOZTAQV8qdBHbLr5XpgYWaBvCcANNheSOarXi7D /2o8KkqgGoDavxy1Ritwc+ftmqyJflLL0PCs8dmmyQeyvKG4LI4PkREpkB8bc7QSW2hO c16uV6vGbabmfMWGIWKeNQZiMecq8ybY14UHC48Ypc6pVtcW3YJXDsi6pSzBdV8sSGBM NdTaobnqylK4d3iCwNQKnuq2QlXU8GP6gpbfQQQEm/P+efDRrMFUy+YDeogiLWztpm1t 12Tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=5lj8N2Gt+2t2nutj0186/kHRoI3UYSBw+hJv1HIjijk=; b=F4PE15MK6kV73dIixL36u5wk7osNhe/y6gngq6GcsPHqU/Pi/LRK+nf8vwhAhzPO3X Dnka7nsNZhaxhoVn2h24b4lzbcFJhhnt5gUWX/2mM87Glixim/o2JLXmVGMn3goRwv8z 2os4cfmkrnDoxoId7sCAt8/dC+gMyoPvHsy4wiqWMGZwDhrOJxwRGIiYhR4eWsk3l0/J BV+wMU28ES/j16j8ik176R/OkvAVfyhUB6FF5sMR//Dtfi0zN6RbkboKPNLs198rf0fk tViwvXzW5z1u1ZT01CZ4+vtOKNlo4KzXseCfsyssv00XNvMTwWxkN+Q5/DUjlCa2d/T7 1Upw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=analog.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ck4-20020a056a00328400b0053e1d872a91si509867pfb.83.2022.10.31.03.53.09; Mon, 31 Oct 2022 03:53:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=analog.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230045AbiJaKwf (ORCPT + 99 others); Mon, 31 Oct 2022 06:52:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229553AbiJaKwc (ORCPT ); Mon, 31 Oct 2022 06:52:32 -0400 Received: from mx0a-00128a01.pphosted.com (mx0a-00128a01.pphosted.com [148.163.135.77]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DC5B4273F; Mon, 31 Oct 2022 03:52:31 -0700 (PDT) Received: from pps.filterd (m0167089.ppops.net [127.0.0.1]) by mx0a-00128a01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 29V7wATX013358; Mon, 31 Oct 2022 06:52:23 -0400 Received: from nwd2mta4.analog.com ([137.71.173.58]) by mx0a-00128a01.pphosted.com (PPS) with ESMTPS id 3kj6ghhta9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 31 Oct 2022 06:52:23 -0400 Received: from ASHBMBX9.ad.analog.com (ASHBMBX9.ad.analog.com [10.64.17.10]) by nwd2mta4.analog.com (8.14.7/8.14.7) with ESMTP id 29VAqL5O050430 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 31 Oct 2022 06:52:21 -0400 Received: from ASHBCASHYB4.ad.analog.com (10.64.17.132) by ASHBMBX9.ad.analog.com (10.64.17.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.14; Mon, 31 Oct 2022 06:52:21 -0400 Received: from ASHBMBX8.ad.analog.com (10.64.17.5) by ASHBCASHYB4.ad.analog.com (10.64.17.132) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.14; Mon, 31 Oct 2022 06:52:20 -0400 Received: from zeus.spd.analog.com (10.66.68.11) by ashbmbx8.ad.analog.com (10.64.17.5) with Microsoft SMTP Server id 15.2.986.14 via Frontend Transport; Mon, 31 Oct 2022 06:52:20 -0400 Received: from rbolboac.ad.analog.com ([10.48.65.139]) by zeus.spd.analog.com (8.15.1/8.15.1) with ESMTP id 29VAq8wV021417; Mon, 31 Oct 2022 06:52:14 -0400 From: Ramona Bolboaca To: , , , , , CC: Ramona Bolboaca 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 Message-ID: <20221031105129.47740-2-ramona.bolboaca@analog.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221031105129.47740-1-ramona.bolboaca@analog.com> References: <20221031105129.47740-1-ramona.bolboaca@analog.com> MIME-Version: 1.0 X-ADIRuleOP-NewSCL: Rule Triggered X-Proofpoint-GUID: VXo7QakVfF5KFPNX3fr4XPESstYQptMj X-Proofpoint-ORIG-GUID: VXo7QakVfF5KFPNX3fr4XPESstYQptMj X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-10-31_06,2022-10-31_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 lowpriorityscore=0 malwarescore=0 mlxscore=0 impostorscore=0 phishscore=0 mlxlogscore=978 suspectscore=0 priorityscore=1501 spamscore=0 clxscore=1015 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2210310068 X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1748200169871296557?= X-GMAIL-MSGID: =?utf-8?q?1748200169871296557?= Use warning instead of failing driver probe if invalid device id is detected for ADXL355 device. Signed-off-by: Ramona Bolboaca --- 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