Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp745462ybx; Tue, 5 Nov 2019 05:01:40 -0800 (PST) X-Google-Smtp-Source: APXvYqyDnAqXIFLeTiy0YK4hMvhs3pqFzlcMtQhl/BCSLBCzpUdplk6r5p/p6ZgT191UAQUoj87W X-Received: by 2002:a17:906:6b94:: with SMTP id l20mr26885660ejr.238.1572958900207; Tue, 05 Nov 2019 05:01:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1572958900; cv=none; d=google.com; s=arc-20160816; b=v0drsWiFyy7uGUynonPHPSP+u5h8nxFWQqCBE9nm+IWmNK3lcWTog6fLhhyOhM7NmT UJDISlVPGIHRs4jnBgrOWV1EPWo807NB89yawGvlYOFPRjJHIvyFStmWE6xDYh6bpuFF gPOsUNvgisYHnAOgKupv8EG6tUQ2uH2VUSv19ne/vlmphYJnjpIznIi7/I3vgYwzQGrx X87tPuogkJXIqf+wufNEKrL/X+eMeX+Hw8ir8crycY4JV3202dNPQYnv9P8kZvYBTOY3 d0TyXHO+nKS+kd5lo9h5ORboo0HLIRIzanRls6y69yVUG8Ay8tKWaY9R1xxgXmPAPDsv 0rGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=egm1HHHFNZuvWB8q/WZPtFjfU8YWUDhwX8uAusn8p4o=; b=wGWKdBqCkCDIE07VVK5mASJNewXV7ya0KT9WknIlzg5kX52acjABayAPizAqNLr6kK 5X96gs6z2jTeZ6aJjnGw4ZceVwdsbxNRlyCxfaJ5yAE1wTQQNzH+pjGBo2uBFYY3wmbp dvQA++vcr5pkZAMIm/mVGdE7eh2mubUPBdDt4BfzJTZN40AT3ceKCFBNMvc4lRtSvxFe mwHtaKtDLcbL5yh46JcHUoeNqwJnhWdGRfkJYVcBs49kFKuAYIlggdp7YX+hQx71z3RY exvhVb2Pnn6jnejjnOB3NLeHZoPAislm6m3poK4S0LX7Qx2uXIqq63FNIvAybJt+4HFS Ss7g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id si4si912491ejb.156.2019.11.05.05.01.16; Tue, 05 Nov 2019 05:01:40 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388848AbfKEM7V (ORCPT + 99 others); Tue, 5 Nov 2019 07:59:21 -0500 Received: from metis.ext.pengutronix.de ([85.220.165.71]:56829 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388678AbfKEM7U (ORCPT ); Tue, 5 Nov 2019 07:59:20 -0500 Received: from gallifrey.ext.pengutronix.de ([2001:67c:670:201:5054:ff:fe8d:eefb] helo=[IPv6:::1]) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1iRyQW-0002wH-Ga; Tue, 05 Nov 2019 13:59:16 +0100 Subject: Re: [PATCH] clk: imx: pll14xx: initialize flags to 0 To: Peng Fan , "sboyd@kernel.org" , "shawnguo@kernel.org" , "s.hauer@pengutronix.de" , "festevam@gmail.com" , Abel Vesa Cc: Aisheng Dong , "linux-kernel@vger.kernel.org" , dl-linux-imx , "kernel@pengutronix.de" , Leonard Crestez , "linux-clk@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" References: <1572938372-7006-1-git-send-email-peng.fan@nxp.com> From: Ahmad Fatoum Message-ID: <7966140a-7fec-0a8f-6ced-e4fbccef51da@pengutronix.de> Date: Tue, 5 Nov 2019 13:59:16 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: <1572938372-7006-1-git-send-email-peng.fan@nxp.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 2001:67c:670:201:5054:ff:fe8d:eefb X-SA-Exim-Mail-From: a.fatoum@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Peng, On 11/5/19 8:21 AM, Peng Fan wrote: > From: Peng Fan > > init.flags is initialized with value from pll_clk->flags, however > imx_1443x_pll and imx_1416x_pll are not static structure, They don't have a static in front of them, but they still have static storage duration. > so flags > might be random value. So let's initialize flags as 0 now. I fail to see how. Members not listed in the { initializer-list } are implicitly initialized as if they were static objects, so flags should already be zero. (I assumed this patch is based on Shawn's imx-clk-5.5 tag) Cheers Ahmad > > Signed-off-by: Peng Fan > --- > drivers/clk/imx/clk-pll14xx.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/clk/imx/clk-pll14xx.c b/drivers/clk/imx/clk-pll14xx.c > index fa76e04251c4..a7f1c1abe664 100644 > --- a/drivers/clk/imx/clk-pll14xx.c > +++ b/drivers/clk/imx/clk-pll14xx.c > @@ -65,12 +65,14 @@ struct imx_pll14xx_clk imx_1443x_pll = { > .type = PLL_1443X, > .rate_table = imx_pll1443x_tbl, > .rate_count = ARRAY_SIZE(imx_pll1443x_tbl), > + .flags = 0, > }; > > struct imx_pll14xx_clk imx_1416x_pll = { > .type = PLL_1416X, > .rate_table = imx_pll1416x_tbl, > .rate_count = ARRAY_SIZE(imx_pll1416x_tbl), > + .flags = 0, > }; > > static const struct imx_pll14xx_rate_table *imx_get_pll_settings( > -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |