Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp4461261ybc; Fri, 15 Nov 2019 05:08:50 -0800 (PST) X-Google-Smtp-Source: APXvYqwM2xcwqGvjwKewDXyY5z8aB18VUyOiydvPaxKJNfyNPMSHH2csoaoZC7fQY/+wGMlshvaE X-Received: by 2002:a17:906:7691:: with SMTP id o17mr747551ejm.323.1573823330050; Fri, 15 Nov 2019 05:08:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573823330; cv=none; d=google.com; s=arc-20160816; b=KhDxVI4Yo7oP03pCZJcrQdIOz9VLFjdnYGGYGLE/uCtIkmOHHqnb77hXYQc2/8OAy9 hP1QRGy6S68mcCiSI72mCIL/zVA7YybqHKnd+2G4FPNgmb3UivFbIuDEVCDdYOejUdKG NcDmTEAekvVOcUSd4mLssOfFQnu1Ypoqol3EOwEO+6mLEsu4xg/o63niXOMtr44L1itE LNAnHHZMPLLjGnzrJi5zRoyGWpTAgrlVjy0Ni9Kwf8ZUOmfqiHNyqPhTUjruinqJeNlA oSpxMU/Q2VbxNFX4u9Ode0dq24SH3lWIydxURUtds5sGyb0RVpZoIPPFaG2QH/q/9tMn cihQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=NFSSVbjhEqElsrA73XhmCVdsI7Nss0hsHyVS7FwP2+Q=; b=v7bBYvkF91btfGmuAkglzUTXyD/ekCOusgpQhe97tHsBrMHJamuyYkh7uM2HLmiFGK MCboNh83tB84T2Myy6jjzEo7ixuDQMxOxbunWkq441fNy9bICKlmg4+/SfTxrCwKDiyf /XCWqCO456xo0rjgcEHEkAyKf1mMxjYXsCHYfoIUsnkikCNbMOIqQRz0Oh3iOf1jCSGp 7F6fWwD6iwa+x10fiAw8Zht/luMrbbr9QuxijhRXG0/MxTw29jA7dvrhIr9sc/d6UwOo PKF0oE+MLwXRIySmL9Kf/YjNwcvdneYN72jB1UZwXKSV9jUJt2R2Z+iQyq165T9FXLm3 bWLA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2019-08-05 header.b=YQVJAjOD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d20si5846582edq.317.2019.11.15.05.08.25; Fri, 15 Nov 2019 05:08:50 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2019-08-05 header.b=YQVJAjOD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727428AbfKONEt (ORCPT + 99 others); Fri, 15 Nov 2019 08:04:49 -0500 Received: from aserp2120.oracle.com ([141.146.126.78]:36866 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727329AbfKONEt (ORCPT ); Fri, 15 Nov 2019 08:04:49 -0500 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id xAFCx9Ue167692; Fri, 15 Nov 2019 13:04:16 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2019-08-05; bh=NFSSVbjhEqElsrA73XhmCVdsI7Nss0hsHyVS7FwP2+Q=; b=YQVJAjOD8u/DCdzbTWgjB6kB+86XbwfNvVG7HB4og2jcOuYIoorw9Q0nkqXYcYRYisSN aepKCWa+8+eYyaAJ3vCuvuCAxqGNJYt/T/V07mfYHzTeQo0Gy/ggjPSc0Vc98o2b30ul wtXquJGr3i3w8r/zQiIYaXbhGct+RBGyxizIoCLdpAGfNU8GwaV4T7UQQmWSLq6/hBwU oP2OyO7QXXejzW08cEid5+zGbKT/76G/p51uxVcWg5xjdIWdMshHO9vtZzBKNhgff9a4 Vam6PKjXqF83Nz2Y/U7zL6RKBmqe40HuI9EQLO5rpaip/GGr3Qnm3sGc1oSR8u82aGyS mw== Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by aserp2120.oracle.com with ESMTP id 2w9gxpk4b3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 15 Nov 2019 13:04:16 +0000 Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.27/8.16.0.27) with SMTP id xAFCx7p0167338; Fri, 15 Nov 2019 13:04:15 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userp3030.oracle.com with ESMTP id 2w9h14fam4-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 15 Nov 2019 13:04:15 +0000 Received: from abhmp0009.oracle.com (abhmp0009.oracle.com [141.146.116.15]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id xAFD48Hx001873; Fri, 15 Nov 2019 13:04:08 GMT Received: from kadam.lan (/129.205.23.165) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 15 Nov 2019 05:04:08 -0800 Date: Fri, 15 Nov 2019 16:03:59 +0300 From: Dan Carpenter To: Beniamin Bia Cc: jic23@kernel.org, devel@driverdev.osuosl.org, mark.rutland@arm.com, lars@metafoo.de, biabeniamin@outlook.com, Michael.Hennerich@analog.com, devicetree@vger.kernel.org, linux-iio@vger.kernel.org, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, robh+dt@kernel.org, pmeerw@pmeerw.net, knaack.h@gmx.de, Paul Cercueil Subject: Re: [PATCH v4 2/4] iio: adc: ad7091r5: Add scale and external VREF support Message-ID: <20191115130359.GE19101@kadam.lan> References: <20191115122316.20893-1-beniamin.bia@analog.com> <20191115122316.20893-2-beniamin.bia@analog.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191115122316.20893-2-beniamin.bia@analog.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9441 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1911140001 definitions=main-1911150120 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9441 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1911140001 definitions=main-1911150120 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 15, 2019 at 02:23:14PM +0200, Beniamin Bia wrote: > @@ -216,6 +240,21 @@ int ad7091r_probe(struct device *dev, const char *name, > return ret; > } > > + st->vref = devm_regulator_get_optional(dev, "vref"); > + if (IS_ERR(st->vref)) { > + if (PTR_ERR(st->vref) == EPROBE_DEFER) ^^^^^^^^^^^^^^^ Missing - on EPROBE_DEFER. > + return -EPROBE_DEFER; > + > + st->vref = NULL; > + } else { > + ret = regulator_enable(st->vref); > + if (ret) > + return ret; > + ret = devm_add_action_or_reset(dev, ad7091r_remove, st); > + if (ret) > + return ret; > + } Curly brace is indented an extra tab. regards, dan carpenter