From patchwork Tue Apr 30 19:02:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe JAILLET X-Patchwork-Id: 13649881 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5B56BC4345F for ; Tue, 30 Apr 2024 19:03:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=qp5g0RpbTz8aeCZWv9cYV7me51cnxyOyrWUWzwkb1xA=; b=eKQDYMww+vI63E DuyDKyOb7jV5mFKKcbH2PQHcacT6ZoEMT71HgVmDLrRFD1VPtBtqEBmA81bTYxqg8YWYXmRbRnbOE Jpk5n3iSTbCq6hY6y4hxl5We0PYQBC1uGBUJWWpoxSq16Sa3C3gljHRtZobZHS048eT23bydQ7WGX mgAefmE7G+YZJkFflrufXzAIMUQSOYunJlX2igUvDQY3ki+lhh3s/5vXhLK1pmY0HF+7Z+8QQcpoO yxSjtKwqn58aUt+T2GmsTU9mX4YcLrggJf3pFFEApO28SCHrVYWaUaPk2tYBxlWlTs0atPH3KPLaO sb4Y0ZAaXD7URx0UFAQQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1s1slC-00000007fh0-1KNr; Tue, 30 Apr 2024 19:03:26 +0000 Received: from smtp-19.smtpout.orange.fr ([80.12.242.19] helo=smtp.smtpout.orange.fr) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1s1sl7-00000007fgL-3j5M; Tue, 30 Apr 2024 19:03:24 +0000 Received: from localhost.localdomain ([86.243.17.157]) by smtp.orange.fr with ESMTPA id 1skxsYnM1PWAk1skxsYEec; Tue, 30 Apr 2024 21:03:14 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wanadoo.fr; s=t20230301; t=1714503794; bh=VEKXdsrN4FCUT2d2eWfWEpHgGeD3ZeJqsDSnHgARRQc=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=FqFvg2W7mwZwu3pd8aMBdiabZL+lLxGETx8aDFjgfSAYIVqZeJHGXaWc5IHQVTnP2 9BNFKKRrxu+4nCH4x7IFk3lBu+89i3N4xdVVP0hWqGqGMclO5VUTOOZM5BNeyKeTI/ ZI8Hkh57B0qnHXFLbgBctIaeTYxnQuQOHV7Cpwg2OP4IU+Ya1Nri8gY4Luai/nnydL Uhj0o4DfaBcEmH5Oy+FaQ08CALqKpbQF8uXCtbpc1xIvmua8aU7Irb5X3D5y96GV3J JEtgV6xojiG/ya/AJHoq1EQyU/ZYS/Qy94vaMh5z2sPJ/yOlmoylaqq46AHZat3XRW 8UZ6OXjSVQ6dA== X-ME-Helo: localhost.localdomain X-ME-Auth: Y2hyaXN0b3BoZS5qYWlsbGV0QHdhbmFkb28uZnI= X-ME-Date: Tue, 30 Apr 2024 21:03:14 +0200 X-ME-IP: 86.243.17.157 From: Christophe JAILLET To: Pavel Machek , Lee Jones , Matthias Brugger , AngeloGioacchino Del Regno , ChiaEn Wu , ChiYuan Huang , Jacek Anaszewski , Alice Chen Cc: linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Christophe JAILLET , linux-leds@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: [PATCH v2] leds: mt6370: Remove an unused field in struct mt6370_priv Date: Tue, 30 Apr 2024 21:02:22 +0200 Message-ID: <22704991f7acca6c2e687ff4bec7822087e1305a.1714503647.git.christophe.jaillet@wanadoo.fr> X-Mailer: git-send-email 2.44.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240430_120322_389987_204F30DB X-CRM114-Status: GOOD ( 11.13 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org In "struct mt6370_priv", the 'reg_cfgs' field is unused. Moreover the "struct reg_cfg" is defined nowhere. Neither in this file, nor in a global .h file, so it is completely pointless. So, remove it. Found with cppcheck, unusedStructMember. Fixes: 5c38376ef5b4 ("leds: rgb: mt6370: Add MediaTek MT6370 current sink type LED Indicator support") Signed-off-by: Christophe JAILLET Reviewed-by: AngeloGioacchino Del Regno --- Compile tested only. Changes in v2: - Tweak the commit message [AngeloGioacchino Del Regno] - Add a Fixes: tag [AngeloGioacchino Del Regno] - Add a R-b: tag v1: https://lore.kernel.org/all/e389be5e1012dc05fc2641123883ca3b0747525a.1714328839.git.christophe.jaillet@wanadoo.fr/ --- drivers/leds/rgb/leds-mt6370-rgb.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/leds/rgb/leds-mt6370-rgb.c b/drivers/leds/rgb/leds-mt6370-rgb.c index 448d0da11848..359ef00498b4 100644 --- a/drivers/leds/rgb/leds-mt6370-rgb.c +++ b/drivers/leds/rgb/leds-mt6370-rgb.c @@ -149,7 +149,6 @@ struct mt6370_priv { struct regmap_field *fields[F_MAX_FIELDS]; const struct reg_field *reg_fields; const struct linear_range *ranges; - struct reg_cfg *reg_cfgs; const struct mt6370_pdata *pdata; unsigned int leds_count; unsigned int leds_active;