From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 791EC137760; Wed, 3 Jul 2024 12:19:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720009195; cv=none; b=V6Fj9JQ/+kLJxq8Nec7W/UziWQnsu3MTsi+ns/Z1jCkPNxUQb0Rt+9FlxJAoKyCdYaVbmuoc2dasYAwrZAMn5BWbO2o/E9lR14e9DohIIh4lyMqZmcSaG8Z+0UxlpUqVZGiHDZ/ORFclMrbU4WXpR3JaE3k3hvwOlMGWDj7QRxk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720009195; c=relaxed/simple; bh=PV2N/+E0TeveYq/L7WEz74LT6mDkLMAp/0Rtz5xspzk=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=ajf0HalFv18fqqjwz7uvCWnXYv55c1C8sL9wIbwk667GbU7oka9D5PIlsIuaeWq4Ch+whTQnht+DW0xu7KxcDMBrUX91IpqYjrTCj576N3Udn0/zNCvz8qf7AVvbAcUEeNH2j0W28ubebFXbBhqqBAI0++q02Wz9O+UrwlmiCZU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id B9443367; Wed, 3 Jul 2024 05:20:16 -0700 (PDT) Received: from donnerap.manchester.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id EE8AA3F766; Wed, 3 Jul 2024 05:19:44 -0700 (PDT) Date: Wed, 3 Jul 2024 13:19:42 +0100 From: Andre Przywara To: Luca Ceresoli Cc: Miguel Ojeda , Rob Herring , Saravana Kannan , Nathan Chancellor , Michael Turquette , Stephen Boyd , Tony Lindgren , Bjorn Andersson , Emilio =?UTF-8?B?TMOzcGV6?= , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Krzysztof Kozlowski , Daniel Lezcano , Thomas Gleixner , Florian Fainelli , Broadcom internal kernel review list , Linus Walleij , Bartosz Golaszewski , Jonathan Cameron , Lee Jones , Shawn Guo , Pengutronix Kernel Team , Uwe =?UTF-8?B?S2xlaW5lLUvDtm5pZw==?= , Greg Kroah-Hartman , Jiri Slaby , Richard Leitner , Liam Girdwood , Mark Brown , Nicolas Ferre , Michael Ellerman , Nicholas Piggin , Christophe Leroy , "Naveen N. Rao" , Damien Le Moal , "Peng Fan (OSS)" , Thomas Petazzoni , linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, llvm@lists.linux.dev, linux-clk@vger.kernel.org, linux-omap@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-samsung-soc@vger.kernel.org, linux-gpio@vger.kernel.org, linux-iio@vger.kernel.org, linux-pwm@vger.kernel.org, linux-serial@vger.kernel.org, linux-usb@vger.kernel.org, patches@opensource.cirrus.com, linux-sound@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org Subject: Re: [PATCH 05/20] clk: sunxi: clk-sun8i-bus-gates: convert to of_property_for_each_u32_new() Message-ID: <20240703131942.1fc653fa@donnerap.manchester.arm.com> In-Reply-To: <20240703-of_property_for_each_u32-v1-5-42c1fc0b82aa@bootlin.com> References: <20240703-of_property_for_each_u32-v1-0-42c1fc0b82aa@bootlin.com> <20240703-of_property_for_each_u32-v1-5-42c1fc0b82aa@bootlin.com> Organization: ARM X-Mailer: Claws Mail 3.18.0 (GTK+ 2.24.32; aarch64-unknown-linux-gnu) Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Wed, 03 Jul 2024 12:36:49 +0200 Luca Ceresoli wrote: > Simplify code using of_property_for_each_u32_new() as the two additional > parameters in of_property_for_each_u32() are not used here. > > Signed-off-by: Luca Ceresoli Reviewed-by: Andre Przywara Cheers, Andre > --- > drivers/clk/sunxi/clk-sun8i-bus-gates.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/drivers/clk/sunxi/clk-sun8i-bus-gates.c b/drivers/clk/sunxi/clk-sun8i-bus-gates.c > index b87f331f63c9..21f036457a86 100644 > --- a/drivers/clk/sunxi/clk-sun8i-bus-gates.c > +++ b/drivers/clk/sunxi/clk-sun8i-bus-gates.c > @@ -24,11 +24,9 @@ static void __init sun8i_h3_bus_gates_init(struct device_node *node) > const char *parents[PARENT_MAX]; > struct clk_onecell_data *clk_data; > const char *clk_name; > - struct property *prop; > struct resource res; > void __iomem *clk_reg; > void __iomem *reg; > - const __be32 *p; > int number, i; > u8 clk_bit; > int index; > @@ -58,7 +56,7 @@ static void __init sun8i_h3_bus_gates_init(struct device_node *node) > goto err_free_data; > > i = 0; > - of_property_for_each_u32(node, "clock-indices", prop, p, index) { > + of_property_for_each_u32_new(node, "clock-indices", index) { > of_property_read_string_index(node, "clock-output-names", > i, &clk_name); > >