From patchwork Fri Feb 23 13:43:47 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Ian King X-Patchwork-Id: 13569232 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 C1E52C5478C for ; Fri, 23 Feb 2024 14:51:01 +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=NjoRzfPtzKd0m7AuvYVWqNOGgmw/87xH3bPfv80k6v4=; b=Vg2RZ9D7Flvife xk32x7+JKithrs5RxXzgOiDmYkLvTNNUlNqoVLg3r5E5mIr1dIeySKDJVgMqikEh1rZXCKFfbk73P 38M2TQ8NWIbnnXq4fsKyC9HuMFtZRDdAj1xrtpLAN94Bd5RiuMrZz6GQHMErsSmm11q9gUqPP0hip pBPbLOwNHj7J6cfDEt7XHcU2d85+4rg2i8ChzaeqLDPRHOsWAX9PzK5QH9/nbVdK21+anqexito9E SSm2XF0drzyBTBc/xZia7slAzikc9Pks8i01hLiFAyvw+j6a0+Du3+B49iTwdB+NnBb9O5ccn3K82 zMNNi9wkpJgXnIBThTgw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdWsw-00000009rDW-2uVF; Fri, 23 Feb 2024 14:50:46 +0000 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdVqD-00000009cgl-48Bw for linux-arm-kernel@lists.infradead.org; Fri, 23 Feb 2024 13:43:58 +0000 Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-4128f3ee934so5970225e9.3 for ; Fri, 23 Feb 2024 05:43:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708695828; x=1709300628; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=MU2sVD1dKQkXFBV/2lOKUBvmSJdVDqTPygsANSVveDA=; b=dDbp4m8jzq35bDzp1PLmO1hEkckB6jjBLAs65U9rOoz67ZggLU3ti3o/+kmpqDuzwD rV9a7gcCdGM0wo1dpuiYXFAmL2U5GwAtpBqGBgKuADxW2coUDyPq5th3K1+kwJS+ws0h HJ64yCh3PYObXk7xA1KaESUQMxVAf6/lGISRNF3iXUZUdDtbL2GgIw71Lqzs8cuIzG6o 2uF52ztVay/cWCBQeX+uKzH8aBQhcbsT96YEbn/eTVBYha1iM/cWap99ZVsqG6m++vbT r8c3ysPRU2SzFm9xi4poJGfiUt25zcyJPe/YEpbK/CugRgaccTtWUCW4/ffPo2MJpOXF HWjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708695828; x=1709300628; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=MU2sVD1dKQkXFBV/2lOKUBvmSJdVDqTPygsANSVveDA=; b=goXqXcUFIosst9ZVdfeXIBRZJXYfyUpxpv7C6AI7tPVdADVCpt2v99uLoRBllOGVM4 +8f3lX3lxGM9R+DDZh3kHABKl+3SeQ0t+tyLY60zWhi05H7FZ0VOl+73z1Jujar8qgNH LvyYk4dwN+H0W645FypI4PAhRXDI7i5a8mbVri7ahJfNJegIbq40EQ2J/QTi1LnHHpMz vzeHrdRCwZFHr7mPBXbkNpjA9Rird+AldCD+9DfRlYYZGe9UY8uFQEthwMmbttg6ylhl Ie6cdl1PjNxl4foy7X7sw+t7//iN1h9khtwFfPfUfkO9l6nlbS4k0xPYksL+4szj66O+ bI0A== X-Forwarded-Encrypted: i=1; AJvYcCXQciLlB7FwBAWbkcdOXME3g8hGyLNqoL5z/94DGgQdLsUZNNQZzOxOiXwH+xh7E+i18VUDS5AYj0Re/6Enqp+WAgT8fHyDkQRnL5PHJcTffqNz4Zc= X-Gm-Message-State: AOJu0Yw0qajU1nglh30+c18BJRWZ+AjiX9PE727+UdBqPfKu8uuY6R3R +BI00gHEAgeMAJoYdoeCpbtEMYlbUluBgYZL7DdhTCCAYcXV/mh9 X-Google-Smtp-Source: AGHT+IEoOr/wovuVU84wwaIU1tZ3DkQrFObSLZXV9WEeLb+FRbEKQKNr7Px6ERkE1O9z4rS6In43/w== X-Received: by 2002:a05:600c:3b89:b0:412:94b7:bc2 with SMTP id n9-20020a05600c3b8900b0041294b70bc2mr1322633wms.2.1708695828307; Fri, 23 Feb 2024 05:43:48 -0800 (PST) Received: from localhost (cpc154979-craw9-2-0-cust193.16-3.cable.virginm.net. [80.193.200.194]) by smtp.gmail.com with ESMTPSA id hi17-20020a05600c535100b0041290251dc2sm2316210wmb.14.2024.02.23.05.43.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Feb 2024 05:43:47 -0800 (PST) From: Colin Ian King To: Michael Turquette , Stephen Boyd , Michal Simek , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] clk: clocking-wizard: Remove redundant initialization of pointer div_addr Date: Fri, 23 Feb 2024 13:43:47 +0000 Message-Id: <20240223134347.3908301-1-colin.i.king@gmail.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240223_054354_112848_0C3727B6 X-CRM114-Status: GOOD ( 14.01 ) 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 The pointer div_addr is being assigned a value that is never used, it is being re-assigned a different value near the end of the function where it is being read in the next statement. The initialization is redundant and can be removed. Cleans up clang scan build warning: drivers/clk/xilinx/clk-xlnx-clock-wizard.c:501:16: warning: Value stored to 'div_addr' during its initialization is never read [deadcode.DeadStores] Signed-off-by: Colin Ian King Reviewed-by: Michal Simek --- drivers/clk/xilinx/clk-xlnx-clock-wizard.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/xilinx/clk-xlnx-clock-wizard.c b/drivers/clk/xilinx/clk-xlnx-clock-wizard.c index 6a6e5d9292e8..19eb3fb7ae31 100644 --- a/drivers/clk/xilinx/clk-xlnx-clock-wizard.c +++ b/drivers/clk/xilinx/clk-xlnx-clock-wizard.c @@ -498,7 +498,7 @@ static int clk_wzrd_dynamic_all_nolock(struct clk_hw *hw, unsigned long rate, { struct clk_wzrd_divider *divider = to_clk_wzrd_divider(hw); unsigned long vco_freq, rate_div, clockout0_div; - void __iomem *div_addr = divider->base; + void __iomem *div_addr; u32 reg, pre, f; int err;