Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp2070911pxt; Sun, 8 Aug 2021 10:28:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJysJiua24e0BLDc8TfMB5P7mwllrGPRaICi2x3StnYcD2ktwLmUAmx+1glgPKgnbEhNMx+L X-Received: by 2002:a02:1cc5:: with SMTP id c188mr18675998jac.46.1628443727949; Sun, 08 Aug 2021 10:28:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628443727; cv=none; d=google.com; s=arc-20160816; b=gVDstYyb8978o6ptaJgGOTJaUKEFQClTiDPEDvo6oMGLtLzvjmsuciZQIRuTx58nGW RmL9UiaQwSgTgpO1RU4zK7mbSapn13IcjEpSmEDIJ+VRUmIbOU0h8t4E8Kn81yBf8KsW bi7jzIjbRXlCY526IfqUrm6uj1Yt9n3pgJKnh5iXuOSUlvY8k3oArHaaQgHq/oDn4BMt 3kp1eCF5paUwJiTelUxAxBVI5NDQeoZZxOG57J1kEb5dL7KNzUXcaRJ/wMbkiGDDLHvD pu1KGnx+rMPZa4EFWR9MOXyxKQiN2jE+7Z2nLRb60czoGrwvxRCQibe99AuByG4r3Pxl A4QQ== 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 :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=YWt/hmq40ZnOLH0WM4DY83a2EFqyrMuxvhfM6pIA7UI=; b=YLORFh9COAHSYkX1S6l48ng+OcZWqp/RzgPtsLy22xrFXsahVsCZq6bhqNe3NsY6Dh whtfXCAYmTT5IcpapDJtwHtvnoRd2zeiiXS7Ft//a1LSaHHkIBjoXe2A3p2kryafsmuz 3t6TLmmtSw+9NOKIec5fg7UqfplED5Sb62FrM+kkBQW3608Ke19XzBX1nvMQWHutDFBM trR7Angj6I1J7fqDsbZSJxJ1oenN0hYsvpq5SWbawqe3TBqtHYpxJGfCldm4gYuP+AGx KxSvZ3hLqXBXXFpru7OTvMPnnVbHTnEhzl8isUeI1aJeoAUInU4Nh39skL8HpNHPaFmR fgeQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i12si16138001jan.18.2021.08.08.10.28.36; Sun, 08 Aug 2021 10:28:47 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231674AbhHHQwN (ORCPT + 99 others); Sun, 8 Aug 2021 12:52:13 -0400 Received: from smtprelay0022.hostedemail.com ([216.40.44.22]:38654 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S230201AbhHHQwM (ORCPT ); Sun, 8 Aug 2021 12:52:12 -0400 Received: from omf10.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay07.hostedemail.com (Postfix) with ESMTP id D6620181D302B; Sun, 8 Aug 2021 16:51:52 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: joe@perches.com) by omf10.hostedemail.com (Postfix) with ESMTPA id 684482351F4; Sun, 8 Aug 2021 16:51:51 +0000 (UTC) Message-ID: Subject: Re: [PATCH v5 1/5] iio: adc: ad7949: define and use bitfield names From: Joe Perches To: Liam Beguin , lars@metafoo.de, Michael.Hennerich@analog.com, jic23@kernel.org, charles-antoine.couret@essensium.com, Nuno.Sa@analog.com Cc: linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, robh+dt@kernel.org Date: Sun, 08 Aug 2021 09:51:50 -0700 In-Reply-To: <20210808015659.2955443-2-liambeguin@gmail.com> References: <20210808015659.2955443-1-liambeguin@gmail.com> <20210808015659.2955443-2-liambeguin@gmail.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.40.0-1 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 684482351F4 X-Spam-Status: No, score=1.32 X-Stat-Signature: ddw8bkdreeyu6mbshx3jbmc5jirr99wu X-Rspamd-Server: rspamout02 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Session-ID: U2FsdGVkX1/tA4iFDvhMsYDj0WcE4jvt7feIyi5W9k8= X-HE-Tag: 1628441511-89359 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 2021-08-07 at 21:56 -0400, Liam Beguin wrote: > Replace raw configuration register values by using FIELD_PREP and > defines to improve readability. [] > diff --git a/drivers/iio/adc/ad7949.c b/drivers/iio/adc/ad7949.c [] +#define AD7949_CFG_BIT_INCC GENMASK(12, 10) I think the naming is a bit confusing as it appears as if these bitfield ranges are single bits. > +/* REF: reference/buffer selection */ > +#define AD7949_CFG_BIT_REF GENMASK(5, 3) [] > +/* SEQ: channel sequencer. Allows for scanning channels */ > +#define AD7949_CFG_BIT_SEQ GENMASK(2, 1) >