Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1762026pxj; Sun, 16 May 2021 03:27:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyy0fFLx1tqeA7MjRktH0AXVZNHzK7/2K2I3wNMCMYbK0L0Bi82oHIXVRLHpNydmbPgWiSy X-Received: by 2002:a05:6402:128f:: with SMTP id w15mr19850091edv.354.1621160878747; Sun, 16 May 2021 03:27:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621160878; cv=none; d=google.com; s=arc-20160816; b=A+yK349mLyeR9Rdq80Ayia95Etx7y/jeDvvCZ7Q8qYRcv3127MbnMIrAdZuOTcJKDL AlgcodstDz0ZxPZ8vy5BMiWj+6dpeCYZNJFN90zPVJOgHTYVzH3/QOInjOHqx10uInt8 p6J8JZ1mj2TRKLUEoEh7D3LMPPnLFK6eN2V9xneqOy2yrwnfafbTkUsqXflgzCbkrxRl DZuugvD2ie9JR8XjXD66t1gqB0tvc67e7CiT+ceDBos77rfI4zfOjeYfuxuYDSjf5M+y 4oUgpFNzous+t+IM3dva2yQZ0glDdA2Q+NDVZT6iRlKAZw9S9fneV1qE6iBG4pcPP+wb v3Qg== 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:subject:cc:to:from:date; bh=Lj+eRyo1L9l9IULgOJXKCMBpV8TkHj9o7nC6X7EB75s=; b=brcay/fiITTJm6OZZXVjfVD/JvxjUeek/zpwSSVJKKZE4he848HFPqa8rYbvDzjF/X 00Cu9o4QKuyudRFLbw1tBNRl8EDyfcPGXz9BbxKl/Tcft0D5QCsCTU5fXp4otqjkQx5e fvF9J09/k82UGqFgi5iyXR8TjHHF3VNwpdn10EdOQyPYF9Fr/m4zTLXWCjoV8Ly9QyoZ aVdgSrPGXVLU0fL5BFakpUZA0Ka26dJkmjVKnAvTxl/H2TZRM5OhT9+yHAdWvBhk/C2c NaKDjuea7C5GeaLuYI1uuUHq7GO+nW4CsZ+alFi75fRV5kwSXFjFayaQZ6xLj3yLjafd DAvg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t15si13599511ejx.9.2021.05.16.03.27.31; Sun, 16 May 2021 03:27:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234439AbhEPJRt (ORCPT + 99 others); Sun, 16 May 2021 05:17:49 -0400 Received: from mail.kernel.org ([198.145.29.99]:52246 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234423AbhEPJRr (ORCPT ); Sun, 16 May 2021 05:17:47 -0400 Received: from jic23-huawei (cpc108967-cmbg20-2-0-cust86.5-4.cable.virginm.net [81.101.6.87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 16A0C610C9; Sun, 16 May 2021 09:16:30 +0000 (UTC) Date: Sun, 16 May 2021 10:17:42 +0100 From: Jonathan Cameron To: YueHaibing Cc: , , , , Subject: Re: [PATCH v2 -next] iio: adc: ad7793: Add missing error code in ad7793_setup() Message-ID: <20210516101742.7ff1d3ed@jic23-huawei> In-Reply-To: <20210514080254.9620-1-yuehaibing@huawei.com> References: <20210514080254.9620-1-yuehaibing@huawei.com> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 14 May 2021 16:02:54 +0800 YueHaibing wrote: > Set error code while device ID query failed. > > Fixes: 88bc30548aae ("IIO: ADC: New driver for AD7792/AD7793 3 Channel SPI ADC") > Signed-off-by: YueHaibing This one is going to be 'interesting' as that bit of code has changed a lot since the fixes tag so chances are we may need to do a manual backport (or several!) Applied to the fixes-togreg branch of iio.git. Thanks, Jonathan > --- > v2: use ENODEV instead of EINVAL > > drivers/iio/adc/ad7793.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/iio/adc/ad7793.c b/drivers/iio/adc/ad7793.c > index 5e980a06258e..b4f9ac3838e1 100644 > --- a/drivers/iio/adc/ad7793.c > +++ b/drivers/iio/adc/ad7793.c > @@ -279,6 +279,7 @@ static int ad7793_setup(struct iio_dev *indio_dev, > id &= AD7793_ID_MASK; > > if (id != st->chip_info->id) { > + ret = -ENODEV; > dev_err(&st->sd.spi->dev, "device ID query failed\n"); > goto out; > }