Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp2209940pxb; Thu, 3 Feb 2022 01:35:01 -0800 (PST) X-Google-Smtp-Source: ABdhPJzFzyz/2XCu6FgQ9vRBlsQjY5UtkUYFpkTAYvXYXomwiN37ftyqE6iviAU47SnA4Km9CQme X-Received: by 2002:a17:907:a422:: with SMTP id sg34mr29278354ejc.221.1643880901439; Thu, 03 Feb 2022 01:35:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643880901; cv=none; d=google.com; s=arc-20160816; b=sgYLCfdz6cxpEePxsjJo2HLgOFA+/+MzQLg56q1pudrjxcE0V4exXNsMM9Y8YII3wn Tal15wwz2YVabVq8uZktKK7pfvBJIm2PvOGBcNSlBsdnBEGqIrGOmrbkrdgDD6SvXAZt zWOSv8nxa35Gr2oLh0u0LQhwm2/WFKPUfnW+R94/rr1tOgoooTwSshjwrXaHQEzkXFaR QgEOmFUWBoEyXt6uwp/7PDORnJQ1FrzoC31fdYWLSze0SAc1Itjuw4Y/0BYR7c2Iv/Oz FFOcoq3cUOxtEbK/j5wD3ZPsjmXapgeBYFqPAyb9g8OWOsRRdZMBtiPz5QmeUtR3BT5a Oe4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=aKbhLaruFzJihRr6tuHWqUwiyv5AacGBfXx3Ff7B0io=; b=eeUJk17f9f/HECn9EMfM1cO3rzHRaC8NLFXzfjMAogQzh0xTLN7yttVGKnSZZc120I cYGZxhcp0shyihvydELOjJbdWgTrTlgKUDhJO+RnO8JlMrv7nItyZ7265OKzzwmWsr8G ML1jW5HPFs9WglNji+8Aa5GGuxnSVbmcILQvrBbuubuq22uvc5il9AoBGZxRrkVKPIqx vrJMvwdV6hwgyQPIcwx/Nud/+hpvmEQmYRy59IIp1/XjLnU1xMocaPyPIBM03lCosVgs Z88FSYLww1BbQptifpVc3kmZVld7WCB/vRhJUm1XFBk13jY6daJTQv9/D4kOcfyKNXgM o+0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=SYedvhKz; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ji5si11538709ejc.206.2022.02.03.01.34.36; Thu, 03 Feb 2022 01:35:01 -0800 (PST) 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; dkim=pass header.i=@gmail.com header.s=20210112 header.b=SYedvhKz; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347465AbiBBVN6 (ORCPT + 99 others); Wed, 2 Feb 2022 16:13:58 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50686 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239968AbiBBVNz (ORCPT ); Wed, 2 Feb 2022 16:13:55 -0500 Received: from mail-qt1-x835.google.com (mail-qt1-x835.google.com [IPv6:2607:f8b0:4864:20::835]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3C304C061714; Wed, 2 Feb 2022 13:13:55 -0800 (PST) Received: by mail-qt1-x835.google.com with SMTP id y8so424948qtn.8; Wed, 02 Feb 2022 13:13:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=aKbhLaruFzJihRr6tuHWqUwiyv5AacGBfXx3Ff7B0io=; b=SYedvhKztxYN6/73vqzNbvu0Qr5H5hpvoKUwVsBTwGsvFLq1GKGs5oF77oWeMy1gtR 17RhhPxDJRo/NdyISTDSIRI84kFh9x1D7x5M2AFL5lE4MbIwN3H7z+rCsPHiyXGLgutB Tv9wbPZUtLpfcFYANRdDAlsIWXzVX0fG6Y9i+o+HIHoGPAH19h5yjZuuf/vpf/29MY7x zEjRwyoQgzUhTwtVQhyLkWZfXCY6FaS+wcfgnU2DXEB8UtrVj4x2FbPE4Cq2RHXf38Np FgBiMBqrAM74b+jQIv1f0AhXr3LqMAiDrUex57Ze6sVUDvkISJAHqSu6eYdWwUrlFL1X s8nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=aKbhLaruFzJihRr6tuHWqUwiyv5AacGBfXx3Ff7B0io=; b=0PDyigdySpBSHsn7i3U8JBMyUg1cRmmkC5bqOp5BnpC90s3Z7NuCjTbI+g8ri8LtkE LcRJYh/GJmOSQhqCGg87Un1uG7xI1nP5WhFnKbp+ePXE/ZGGpu2t0vuzBUNT18xma8LL oJikVmp1utAatxkJI4Rxp3lsMg8J1Rv4DXERUTJv+32dhcV+Vb3wQG1rzCuAKusMlvOk VvwT/UtG9wvMjz7uuZ/tHGmwA0sW0zLuAUyrRtVlkheTpeANYLKN7CBi36qR2AuemiCD pik9uWzIfzRkcP/MCNCXn9emrZ6vuZlN/C0aRwS85XZMnfFqL3vKNFAyy8JceqXifOu8 HOwA== X-Gm-Message-State: AOAM531lF61k0/Up7lG0BMX/SEqvDgxtrzcUdrlA5X8egw7OqvbTXCVP FEA0ku8ZkE5UUXwZOcnORXJqEXgpxqA= X-Received: by 2002:ac8:7d55:: with SMTP id h21mr24439359qtb.331.1643836434380; Wed, 02 Feb 2022 13:13:54 -0800 (PST) Received: from shaak (modemcable055.92-163-184.mc.videotron.ca. [184.163.92.55]) by smtp.gmail.com with ESMTPSA id w4sm13542192qko.123.2022.02.02.13.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Feb 2022 13:13:53 -0800 (PST) Date: Wed, 2 Feb 2022 16:13:51 -0500 From: Liam Beguin To: Peter Rosin Cc: jic23@kernel.org, andy.shevchenko@gmail.com, lars@metafoo.de, linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, robh+dt@kernel.org Subject: Re: [PATCH v13 02/11] iio: afe: rescale: add INT_PLUS_{MICRO,NANO} support Message-ID: References: <20220130161101.1067691-1-liambeguin@gmail.com> <20220130161101.1067691-3-liambeguin@gmail.com> <8347a069-c36c-cb30-a0be-5b38f3c59b32@axentia.se> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8347a069-c36c-cb30-a0be-5b38f3c59b32@axentia.se> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Peter, On Wed, Feb 02, 2022 at 06:04:25PM +0100, Peter Rosin wrote: > Hi! > > On 2022-01-30 17:10, Liam Beguin wrote: > > Some ADCs use IIO_VAL_INT_PLUS_{NANO,MICRO} scale types. > > Add support for these to allow using the iio-rescaler with them. > > > > Signed-off-by: Liam Beguin > > Reviewed-by: Peter Rosin > > --- > > drivers/iio/afe/iio-rescale.c | 35 +++++++++++++++++++++++++++++++++++ > > 1 file changed, 35 insertions(+) > > > > diff --git a/drivers/iio/afe/iio-rescale.c b/drivers/iio/afe/iio-rescale.c > > index 65832dd09249..f833eb38f8bb 100644 > > --- a/drivers/iio/afe/iio-rescale.c > > +++ b/drivers/iio/afe/iio-rescale.c > > @@ -14,6 +14,7 @@ > > #include > > #include > > #include > > +#include > > This include should be moved to the first patch that uses stuff from > it. Some defines are used a bit further down in mult (copied back from the original message): > > case IIO_VAL_INT_PLUS_NANO: > > case IIO_VAL_INT_PLUS_MICRO: > > mult = scale_type == IIO_VAL_INT_PLUS_NANO ? GIGA : MEGA; > Cheers, > Peter > > *snip* Cheers, Liam