From patchwork Tue Jun 2 17:24:35 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin King X-Patchwork-Id: 11584151 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C03451391 for ; Tue, 2 Jun 2020 17:24:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B2BA42074B for ; Tue, 2 Jun 2020 17:24:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726636AbgFBRYj (ORCPT ); Tue, 2 Jun 2020 13:24:39 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:45762 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726630AbgFBRYj (ORCPT ); Tue, 2 Jun 2020 13:24:39 -0400 Received: from 1.general.cking.uk.vpn ([10.172.193.212] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1jgAeS-0006h8-08; Tue, 02 Jun 2020 17:24:36 +0000 From: Colin King To: Michael Turquette , Stephen Boyd , Serge Semin , linux-clk@vger.kernel.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] clk: baikal-t1: remove redundant assignment to variable 'divider' Date: Tue, 2 Jun 2020 18:24:35 +0100 Message-Id: <20200602172435.70282-1-colin.king@canonical.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Sender: linux-clk-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-clk@vger.kernel.org From: Colin Ian King The variable divider is being initialized with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King Reviewed-by: Serge Semin --- drivers/clk/baikal-t1/ccu-div.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/baikal-t1/ccu-div.c b/drivers/clk/baikal-t1/ccu-div.c index bd40f5936f08..4062092d67f9 100644 --- a/drivers/clk/baikal-t1/ccu-div.c +++ b/drivers/clk/baikal-t1/ccu-div.c @@ -248,7 +248,7 @@ static int ccu_div_var_set_rate_fast(struct clk_hw *hw, unsigned long rate, unsigned long parent_rate) { struct ccu_div *div = to_ccu_div(hw); - unsigned long flags, divider = 1; + unsigned long flags, divider; u32 val; divider = ccu_div_var_calc_divider(rate, parent_rate, div->mask);