From mboxrd@z Thu Jan 1 00:00:00 1970 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 08CDDC27C4F for ; Mon, 24 Jun 2024 02:10:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:CC:To: Subject:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=s0Vopej6tuckLDNuLItjyCBo0sr9HIkUOwUqg72lEds=; b=ZL2Ku9Qjhk0huYiWxy0IVWN5pF WxLGWkoO1HjAoHxRtQbhQwom2z0pDuP6C0+1aBg3+IlEI2vYA0xQ4lk27lahMCpWZPvqUNwZdWHn/ WYCOhpgSo8hGmq9iSOcJBEB2V48Ctl+WD6IHfCWsVm8aRt+mWDB11S9PKmf4V4rjxa8iwaUBTsdNV FavM+2vd3jbGGkg8r0E+Xa54ua1PyUdDAeL4gJf3wcV8xNHFyLlgEGddAN1paZzUfhGq7IC/vODgo jGFL7JKHXmeZE7mu9QU2b++x2vnwsQmgbdX+SE4oeuCPNF0/aJ/uGthXFIAmNYyT4eaIYUH9vvejl Uk8gZD2g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sLZ9W-0000000FFni-38Rl; Mon, 24 Jun 2024 02:09:54 +0000 Received: from szxga03-in.huawei.com ([45.249.212.189]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sLZ9R-0000000FFmi-0ub5 for linux-arm-kernel@lists.infradead.org; Mon, 24 Jun 2024 02:09:51 +0000 Received: from mail.maildlp.com (unknown [172.19.163.174]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4W6rsb3sBwzPsdf; Mon, 24 Jun 2024 10:05:55 +0800 (CST) Received: from dggpemf500002.china.huawei.com (unknown [7.185.36.57]) by mail.maildlp.com (Postfix) with ESMTPS id 62E90140E62; Mon, 24 Jun 2024 10:09:33 +0800 (CST) Received: from [10.174.178.247] (10.174.178.247) by dggpemf500002.china.huawei.com (7.185.36.57) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.11; Mon, 24 Jun 2024 10:09:32 +0800 Subject: Re: [PATCH] ACPI / amba: Drop unnecessary check for registered amba_dummy_clk To: Youwan Wang CC: , , , , , , , , References: <20240620133758.319392-1-youwan@nfschina.com> From: Hanjun Guo Message-ID: <974a1539-531a-6aa3-ba07-5d2c9003d08f@huawei.com> Date: Mon, 24 Jun 2024 10:09:32 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0 MIME-Version: 1.0 In-Reply-To: <20240620133758.319392-1-youwan@nfschina.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.178.247] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpemf500002.china.huawei.com (7.185.36.57) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240623_190949_494325_80DFA540 X-CRM114-Status: GOOD ( 19.48 ) 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 Hi Youwan, Please use v4 for your patch subject which was suggested by Sudeep: [PATCH v4] ACPI / amba: Drop unnecessary check for registered amba_dummy_clk On 2024/6/20 21:37, Youwan Wang wrote: > amba_register_dummy_clk() is called only once from acpi_amba_init() > and acpi_amba_init() itself is called once during the initialisation. > amba_dummy_clk can't be initialised before this in any other code > path and hence the check for already registered amba_dummy_clk is > not necessary. Drop the same. > > Signed-off-by: Youwan Wang > Acked-by: Sudeep Holla > --- > v1->v2->v3: Modify the commit log description Please update it as follows: Changes from v3: - Update the commit message suggested by Sudeep; - Add Acked-by from Sudeep; - +Cc ARM64 maintainers Catalin and Will. > --- > drivers/acpi/arm64/amba.c | 6 +----- > 1 file changed, 1 insertion(+), 5 deletions(-) > > diff --git a/drivers/acpi/arm64/amba.c b/drivers/acpi/arm64/amba.c > index 60be8ee1dbdc..ef438417cc80 100644 > --- a/drivers/acpi/arm64/amba.c > +++ b/drivers/acpi/arm64/amba.c > @@ -35,11 +35,7 @@ static const struct acpi_device_id amba_id_list[] = { > > static void amba_register_dummy_clk(void) > { > - static struct clk *amba_dummy_clk; > - > - /* If clock already registered */ > - if (amba_dummy_clk) > - return; > + struct clk *amba_dummy_clk; > > amba_dummy_clk = clk_register_fixed_rate(NULL, "apb_pclk", NULL, 0, 0); > clk_register_clkdev(amba_dummy_clk, "apb_pclk", NULL); With that updated, Acked-by: Hanjun Guo Thanks Hanjun