lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1651138365-17362-2-git-send-email-u0084500@gmail.com>
Date:   Thu, 28 Apr 2022 17:32:42 +0800
From:   cy_huang <u0084500@...il.com>
To:     pavel@....cz, matthias.bgg@...il.com
Cc:     cy_huang@...htek.com, jacek.anaszewski@...il.com,
        gene_chen@...htek.com, linux-leds@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org,
        linux-mediatek@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: [PATCH 1/4] leds: flash: mt6360: Fix the wrong enable_reg in multicolor brightness set

From: ChiYuan Huang <cy_huang@...htek.com>

Fix the wrong enable_reg in multicolor brightness set.

Signed-off-by: ChiYuan Huang <cy_huang@...htek.com>
---
 drivers/leds/flash/leds-mt6360.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/leds/flash/leds-mt6360.c b/drivers/leds/flash/leds-mt6360.c
index e1066a5..712cd46 100644
--- a/drivers/leds/flash/leds-mt6360.c
+++ b/drivers/leds/flash/leds-mt6360.c
@@ -115,7 +115,8 @@ static int mt6360_mc_brightness_set(struct led_classdev *lcdev,
 		struct mc_subled *subled = mccdev->subled_info + i;
 
 		real_bright = min(lcdev->max_brightness, subled->brightness);
-		ret = regmap_update_bits(priv->regmap, MT6360_REG_ISNK(i),
+		ret = regmap_update_bits(priv->regmap,
+					 MT6360_REG_ISNK(subled->channel),
 					 MT6360_ISNK_MASK, real_bright);
 		if (ret)
 			goto out;
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ