From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.9 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A3D25C3B187 for ; Tue, 11 Feb 2020 07:51:49 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7751120848 for ; Tue, 11 Feb 2020 07:51:49 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="ddLBv4uY" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727436AbgBKHvt (ORCPT ); Tue, 11 Feb 2020 02:51:49 -0500 Received: from mail-lj1-f194.google.com ([209.85.208.194]:47070 "EHLO mail-lj1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727079AbgBKHvs (ORCPT ); Tue, 11 Feb 2020 02:51:48 -0500 Received: by mail-lj1-f194.google.com with SMTP id x14so10390760ljd.13 for ; Mon, 10 Feb 2020 23:51:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=fgdXEI6JDSFS3pt+rYa0nTov0L2yZsdOlWEnF1jO+qI=; b=ddLBv4uY/qPo4/WTa/6s7tVhISjcyuYVDvgQOt5lPYCUhn46Lxqx2yGRttA4M21jJ2 XkwMHB2igDABKHrdvt4nVls/8e0kQFJsmxyreR1Q61+ucKy/eeV8Q9bDiWEjjSidoZ7k Gx39B1vhT0TaWXqsqA3kkNyLJr3KFZfyC1jg76rEv9vZlhAJ67OnTzGy+7/GjFqvdN7P wtxXdKK1FaKDVoOL+su8cwMhwUqVp9mUQp/6jcCE0sVkt5uRAiV5F7Z6lstP9G2avxdU +x9OfGyUApmKDtWgbFDbec+yjxe7/X9lDveUTBZFbGATUAlJEqoUkYnKnYyHuyY8PTVF vnkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=fgdXEI6JDSFS3pt+rYa0nTov0L2yZsdOlWEnF1jO+qI=; b=Ul/WZtQlrBtPqyTQjuhr2RL3e55eP7ZnzgOuafjbGbY9fedmDxNLpMDOxXlxnz+J1n RC1sBXRKFOEbSaNdpk29qefwro5W1mIl2mkkNJWovvXHS5oQEd4BvCuuifC+SNHl/CYA eGSB7wXGYxYcbYo9FJ8g8FEQR3lFJlbo/ROeeaXgodpr2DjOoYA6kaOpghQpcrIPJmNb TLLIL75cKrk2bwbjx+QgnBDFzXT/mV5hhddIUOA+RQ7hQ6wtpdWscb7JQ/JmRkTQzpU3 M1Li+ku5w4jBrYBc8zwF+7y7za4LTApZz4u6b/7hE7ft4h5I3JMROYUTRkaXQXfqv2ih /QfA== X-Gm-Message-State: APjAAAUR9goBK1fySMfH48Hua6u8Qz6CoOuyT5Z5AYj5epWx1egd4mEe k85ZJD/ghDWJ/dfovfUAJ8dOlD24/YFk2Qg99YStcozn X-Google-Smtp-Source: APXvYqxJnQiE7JS2C880wGFnRgKbIHzgQWhPhVIMYC44J9kQAOsRaBs5fWMhUIFhqiIqmsjxjXlsnNnqXnI9FCpfo+s= X-Received: by 2002:a05:651c:2c7:: with SMTP id f7mr3314342ljo.125.1581407504815; Mon, 10 Feb 2020 23:51:44 -0800 (PST) MIME-Version: 1.0 References: <20200208123359.396-1-linus.walleij@linaro.org> <74ab4b7b-eae2-0c6f-bb4a-eabbd3b4d042@gmail.com> <395b3e38-cea4-9376-1544-f1ef85abf171@gmail.com> <9797aa15-eed1-932c-3cd6-64d7ccbf9d5e@gmail.com> In-Reply-To: <9797aa15-eed1-932c-3cd6-64d7ccbf9d5e@gmail.com> From: Linus Walleij Date: Tue, 11 Feb 2020 08:51:33 +0100 Message-ID: Subject: Re: [PATCH] RFT: iio: gp2ap002: Replace LUT with math To: Gregor Riepl Cc: Jonathan Bakker , Jonathan Cameron , linux-iio , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald-Stadler , Linux Input Content-Type: text/plain; charset="UTF-8" Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org On Tue, Feb 11, 2020 at 8:15 AM Gregor Riepl wrote: > How about this, then? > With a full-range lookup table (47 values), it's even possible to avoid > additional constants and simply clamp to the size of the table. This looks VERY good! Can you provide a patch against upstream (Jonathan's tree) or do you want me to pick the method and send a patch (I can add in your Signed-off-by in that case, if you approve). Yours, Linus Walleij