Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp2689177pxv; Sun, 25 Jul 2021 02:16:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyAlOdTlSQ99y55KOLWBPb8vVIl61qPXqe695AYsLTLFquBQHHxjHWfMpA8mL6CaDx/8wtd X-Received: by 2002:a92:d6c9:: with SMTP id z9mr8909107ilp.134.1627204605094; Sun, 25 Jul 2021 02:16:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627204605; cv=none; d=google.com; s=arc-20160816; b=IC3v4JfQw9WAbTlNrquLPca76OHhNqpjg8ws9WAp1+XWjWYc0GNFzFmhEAV0ECJ4q6 DvBzb5eEncq4LSG78Rr4y3sPf5TbJOJqr4YbXpdc1xcri2x4zWOkFaEXgPf3O+A/gz48 CVnOBpSqFL6TP9HO87CV15QSb9KrZcxj6Y6TwY36LpwqkiAKa2N2032jUz3M41kIIvPw 10AT2Nbpgw5rwe1918XMS7RCJ1ePUc3dB95JOGJ3dPd2Yriekyc2wm/Ji5Bzb9Wj8R39 RWGRIiwSTBwdjJmq0+C2uZLMDBYdBUunQMT3Sea1jftbjZnHzQt0/EtgD+CYqo7FoGAf YbtA== 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:cc:to:subject:from:date; bh=H7ZQUF3BLMyPGtoLxaMful3kYBz/Oge0dDj3XjSL040=; b=iEqIboKuFBc9+uQg/Z+6kUsOB4ETpxjDnTX8HFQ4qxorTsTF/VkfikyFALYy0rQF4E zspCcr8Fs5lIk7scsszeUCmqwDim0XqST6tGZRj6KvGJmVtWCsVqeRpifc2W7nKkQOYE 0iLaJ2LUJC/1vSHVa69l95rR07TyTPWpqatlVOlB0+GCHS6jGjsNyNNz8jgudZJPurtv vDEkgzQq1TWfFH13jx2MwqfD+iYn/co2tgAH5aN77mKPBfmssx3iuLbF6EmslXqcrHLS ON0piUeanq38bxogoiiafrlGpUTudyXwtqCsJrkA6awv1d1THSmZb92NHnKE23QYaA2w K0aw== 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=fail (p=NONE sp=NONE dis=NONE) header.from=crapouillou.net Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g17si37874001jaq.116.2021.07.25.02.16.34; Sun, 25 Jul 2021 02:16:45 -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=fail (p=NONE sp=NONE dis=NONE) header.from=crapouillou.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230310AbhGYIeH convert rfc822-to-8bit (ORCPT + 99 others); Sun, 25 Jul 2021 04:34:07 -0400 Received: from aposti.net ([89.234.176.197]:41052 "EHLO aposti.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229883AbhGYIeH (ORCPT ); Sun, 25 Jul 2021 04:34:07 -0400 Date: Sun, 25 Jul 2021 10:14:26 +0100 From: Paul Cercueil Subject: Re: [PATCH v3 1/5] iio/adc: ingenic: rename has_aux2 to has_aux_md To: Christophe Branchereau Cc: jic23@kernel.org, lars@metafoo.de, linux-mips@vger.kernel.org, linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, robh+dt@kernel.org, devicetree@vger.kernel.org, linux@roeck-us.net, contact@artur-rojek.eu Message-Id: <20NSWQ.3V5OK4JZMMRN@crapouillou.net> In-Reply-To: <20210724190449.221894-2-cbranchereau@gmail.com> References: <20210724190449.221894-1-cbranchereau@gmail.com> <20210724190449.221894-2-cbranchereau@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 8BIT Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Christophe, Le sam., juil. 24 2021 at 21:04:45 +0200, Christophe Branchereau a ?crit : > The jz4760(b) socs have 3 aux channels. > > The purpose of has_aux2 is to set the MD bits used to select > the AUX channel to be sampled, not to describe the hardware. > > Rename it to a more appropriate name. > > Signed-off-by: Christophe Branchereau Reviewed-by: Paul Cercueil Cheers, -Paul > --- > drivers/iio/adc/ingenic-adc.c | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/drivers/iio/adc/ingenic-adc.c > b/drivers/iio/adc/ingenic-adc.c > index 34c03a264f74..40f2d8c2cf72 100644 > --- a/drivers/iio/adc/ingenic-adc.c > +++ b/drivers/iio/adc/ingenic-adc.c > @@ -92,7 +92,7 @@ struct ingenic_adc_soc_data { > const int *battery_scale_avail; > size_t battery_scale_avail_size; > unsigned int battery_vref_mode: 1; > - unsigned int has_aux2: 1; > + unsigned int has_aux_md: 1; > const struct iio_chan_spec *channels; > unsigned int num_channels; > int (*init_clk_div)(struct device *dev, struct ingenic_adc *adc); > @@ -506,7 +506,7 @@ static const struct ingenic_adc_soc_data > jz4725b_adc_soc_data = { > .battery_scale_avail = jz4725b_adc_battery_scale_avail, > .battery_scale_avail_size = > ARRAY_SIZE(jz4725b_adc_battery_scale_avail), > .battery_vref_mode = true, > - .has_aux2 = false, > + .has_aux_md = false, > .channels = jz4740_channels, > .num_channels = ARRAY_SIZE(jz4740_channels), > .init_clk_div = jz4725b_adc_init_clk_div, > @@ -520,7 +520,7 @@ static const struct ingenic_adc_soc_data > jz4740_adc_soc_data = { > .battery_scale_avail = jz4740_adc_battery_scale_avail, > .battery_scale_avail_size = > ARRAY_SIZE(jz4740_adc_battery_scale_avail), > .battery_vref_mode = true, > - .has_aux2 = false, > + .has_aux_md = false, > .channels = jz4740_channels, > .num_channels = ARRAY_SIZE(jz4740_channels), > .init_clk_div = NULL, /* no ADCLK register on JZ4740 */ > @@ -534,7 +534,7 @@ static const struct ingenic_adc_soc_data > jz4770_adc_soc_data = { > .battery_scale_avail = jz4770_adc_battery_scale_avail, > .battery_scale_avail_size = > ARRAY_SIZE(jz4770_adc_battery_scale_avail), > .battery_vref_mode = false, > - .has_aux2 = true, > + .has_aux_md = true, > .channels = jz4770_channels, > .num_channels = ARRAY_SIZE(jz4770_channels), > .init_clk_div = jz4770_adc_init_clk_div, > @@ -581,7 +581,7 @@ static int ingenic_adc_read_chan_info_raw(struct > iio_dev *iio_dev, > > /* We cannot sample AUX/AUX2 in parallel. */ > mutex_lock(&adc->aux_lock); > - if (adc->soc_data->has_aux2 && engine == 0) { > + if (adc->soc_data->has_aux_md && engine == 0) { > bit = BIT(chan->channel == INGENIC_ADC_AUX2); > ingenic_adc_set_config(adc, JZ_ADC_REG_CFG_AUX_MD, bit); > } > -- > 2.30.2 >