Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp5566517ybp; Tue, 8 Oct 2019 05:06:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqw2jicBZyO2JMKC08FGAWAQYp8j/bX4GNYm3UMSOAFNUvbkkGE5lxeEeugxYYHSUxJMDz/J X-Received: by 2002:a17:906:2ccc:: with SMTP id r12mr28241940ejr.219.1570536367946; Tue, 08 Oct 2019 05:06:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570536367; cv=none; d=google.com; s=arc-20160816; b=trl/VdxlW47YDc6JiCWQwrRooBtAJakItLaioeruMxeV6E8Lqkof5zppzNVQdeb4FU RZCAgKSU1xE1Y95c4cnMOcQgSP5maQwtc+VEx45e8NIICANQ3d5d6I6sI00OCsJsHb5b OpUf54b+Zca0GFbR++5uFOOzntq3BRNa74rtG11GbeekljShOxFijTq3igQkf1exzIpF cUVs5QZlJYt8FbJlDFlEeqxITRlyRJ+a3NUVyLVoXUNhn3/Ha5DVQUG398P4ft5lZgdU BRM1mLLDx0hGOiPiWEQXIP9QZeOx1WdeHHyxUSUGo0tAi9LnFP0rxtbL0/jro1guW7S3 G2fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=yIqqIP3EIw1WUky7Dl5KboQRqFaypkEePxm8k0rEc9o=; b=qIPqOWWsK5RNBc+SG7ucCtfQVHQKNCCvhJGERShtIvuiIbf9ZF+SpPIpjCohaXT4xQ URAcXtN00KvqNBBZJEzbS989sh5s3NOsoW0hzFfr5q0La41rYv6fcxPb7iTJiKhwStAo 9NSb3SIc33O+voGMQE2JB8eGYFNiAKqC42aT2fP2e1xElHaxLGBKqyx4E245Fvisqw7w tJc/+1dg9H7+/0LMbPwcbwasFLBiCakIWhCEdr4AfKMe3vFu0PEB6KUCkInrSl++17XD +/6JfYHW62yNkWY3ubof5d50Aj0BuVjRIBEY1dmSoiYnf3y8qgTGSKbZuoa9l517HbS/ ghTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rasmusvillemoes.dk header.s=google header.b=AponybTx; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b35si10854044edb.204.2019.10.08.05.05.43; Tue, 08 Oct 2019 05:06:07 -0700 (PDT) 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=@rasmusvillemoes.dk header.s=google header.b=AponybTx; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730883AbfJHMFS (ORCPT + 99 others); Tue, 8 Oct 2019 08:05:18 -0400 Received: from mail-lf1-f66.google.com ([209.85.167.66]:46272 "EHLO mail-lf1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730710AbfJHMFS (ORCPT ); Tue, 8 Oct 2019 08:05:18 -0400 Received: by mail-lf1-f66.google.com with SMTP id t8so11691963lfc.13 for ; Tue, 08 Oct 2019 05:05:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=yIqqIP3EIw1WUky7Dl5KboQRqFaypkEePxm8k0rEc9o=; b=AponybTxAeH4Qwys7uf32YeqpoJ78jgDddTlKOmqmCAlexPcNn8x24ajVQ+O7+xRkR RuBT096o6RaBaaTnFRhKPGbBnK69SeSdi0jX5VxETzV8yWF+FlbeSjLE8LtoSz+LXe/9 1SJ01i6mDKGlRWpaglFSkyprM69Ur66rByxaU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=yIqqIP3EIw1WUky7Dl5KboQRqFaypkEePxm8k0rEc9o=; b=UQMice3leCmg8FexiZ5RarV5egJ0qbP3Znaw90roUSuUsXPi4/oEFadUy/avtt5Yf1 TfAEClJgGnOyKtSCBoEssQlgiWizF+uwc6DiaqsBXoNDTHeU1LTtUXmoz6MAMvfuU8GK RzAqYL2MzivMXrlj648ErNTfdDQqKJAB7Eoe2ai0hUZSq+MbNYslJGEIHp8yHBA8ZzDA B41Nj/vtHAsYG1Td6JPq+Dxi0UlrLfe6Tb66PEGN3g0IgEg7dnW2NME2f2zT61M6fuLn tVOS0Wa5s3nCPHSXvjipztmiip/em34xXuDOssJ91hDNdC3n6Cn3mG6p79McfwoI6wg5 V7vw== X-Gm-Message-State: APjAAAUG6U+kK84EtNJ+awKPjqKrUujcw2WZADUCH93DLvUWiJcxyZFA mmRteSicpb/gzdLZRU+PQKD5DQ== X-Received: by 2002:a19:ec16:: with SMTP id b22mr20438594lfa.189.1570536316077; Tue, 08 Oct 2019 05:05:16 -0700 (PDT) Received: from prevas-ravi.prevas.se ([81.216.59.226]) by smtp.gmail.com with ESMTPSA id z18sm3918033ljh.17.2019.10.08.05.05.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Oct 2019 05:05:15 -0700 (PDT) From: Rasmus Villemoes To: Thierry Reding , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , Lee Jones , Daniel Thompson , Jingoo Han , Bartlomiej Zolnierkiewicz , linux-pwm@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Rasmus Villemoes Subject: [PATCH v2 0/4] backlight: pwm_bl: optimizations and small fix for cie1913 Date: Tue, 8 Oct 2019 14:03:23 +0200 Message-Id: <20191008120327.24208-1-linux@rasmusvillemoes.dk> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org These patches optimize the cie1913() implementation by using fewer 64 bit divisions and multiplications. It also contains a minor fix for the linear constant used. v2: - Drop patch 5. - Fix thinko in patch 4, otherwise no code change. - Better changelog in patch 3. - Add Daniel's Reviewed-By to the four patches. Daniel, I took the liberty of adding your R-B to patch 4 despite changing it a little to fix a thinko - I should add 1<<31 and not 1<<15. Please tell me if that was inappropriate. Rasmus Villemoes (4): backlight: pwm_bl: fix cie1913 comments and constant backlight: pwm_bl: eliminate a 64/32 division backlight: pwm_bl: drop use of int_pow() backlight: pwm_bl: switch to power-of-2 base for fixed-point math drivers/video/backlight/pwm_bl.c | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) -- 2.20.1