From patchwork Mon Jan 2 11:52:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 13086721 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 61F7DC3DA7A for ; Mon, 2 Jan 2023 11:54:57 +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=AbU/u+onDjos0mRV4b6vjYd34HDsRl5E/EFo1YNaij4=; b=1WGRADZsoZxfdD z6l0zFZXhwV+yklLnomZuRY9atzzmYpsSgYkF0OBxgEXBl6Ky97tCkTp2zDK3ccCyePGYn95JyLlE qCUggBSc2flKyVYSYm4/afDMba+FFQ6Ze2Zc90A8gZcFdSS938vr2SJbif2TK7smBjCD4PbKYi0oj 6VFTKY5s7dyQVOJS5T8q+URh6NEi1wQTvvpAyYwGY5uxewt8LY358KzroI/U+3ez2Tags+TlQPTxC D7RvO49DTPT+xWOfDV/ThNxDnl2lqwZ2ryMr/xyaAukPRhiMu1aijL7x6PVot7/UHBZay2b2hO7qu 517c5l4M7SknViRmtFLg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pCJNo-00B0aj-Je; Mon, 02 Jan 2023 11:53:36 +0000 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pCJNJ-00B0AB-2Z; Mon, 02 Jan 2023 11:53:08 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id C89F432007F9; Mon, 2 Jan 2023 06:53:00 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Mon, 02 Jan 2023 06:53:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h=cc :cc:content-transfer-encoding:date:date:from:from:in-reply-to :message-id:mime-version:reply-to:sender:subject:subject:to:to; s=fm3; t=1672660380; x=1672746780; bh=gQUtkmNZ6+Yr1Z5PtkAytHeKz 4tO0KqJblojWaOYoI8=; b=TgMdrcefYLKjw+9KpTa17EGOaLL9BOuLhwOIrV/XR 6Uf8KQqFsnWMN8YD7MITZSLnTEI0bGANW317eT9PCqe/5HagYZcjMMu1Jo/zHh62 4u+u48ejp9q3bOeiQ9FIHnxyoBs+4ahTOEFH+YZ/luUVzS0/1bdABKm1WwMldnA9 k9cNTALR9bA8va1IqOWc/yQbeLH+JTaw7d+R4TZeQTdIb8QsjAw6R7PRqOwR+chw 14539TNSBArMR1TIvpdGMn5a9Bis6B55A+jIsjCiRMGm1UD3EjixyZ4T9rIMjxE2 yZoWEn5HVgZuHje26Q+xxEsf9S159lp7wPBWEN4yq1pJA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding:date:date :feedback-id:feedback-id:from:from:in-reply-to:message-id :mime-version:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t= 1672660380; x=1672746780; bh=gQUtkmNZ6+Yr1Z5PtkAytHeKz4tO0KqJblo jWaOYoI8=; b=hdS+ArDjlN+Gl7TbiOvgPZeAA8HeDT9ZYpSA2zzvXpi+uJFFUqf ghpqry7jL0r6Nvgf/jUyKClW4e1rD4Pm1IIMLuhCFfkeDX6QD9RJlQ7nmTSzvmAM KEipeNqSpdazTQEEj476BOv0mJJ0eNdGuJxO+iHsB3ZtZJil4hUzZouEgdgdqW0v AOh5c4V0odOVoVzIZOfnOoZVJEnXhLsEwlwclszPdt0GkFVqajxW+IvGUOI2IAIz ScGHDb89Ps3zMJMGSs87O3fSGSDYcTzn2kX5IVm2CI39Lng01CwGtG704ozW/LIA 1EbqhVq5L8bjjdWfydKsFK/ToiD5NbYV56g== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrjedvgdefgecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvfevufffkffoggfgsedtkeertdertddtnecuhfhrohhmpeforgigihhmvgcu tfhiphgrrhguuceomhgrgihimhgvsegtvghrnhhordhtvggthheqnecuggftrfgrthhtvg hrnhepkeffkeejhffhvdffuddtjeelteehheeiteejtefgkeeutdevgeeujeevteeileej necuffhomhgrihhnpehkvghrnhgvlhdrohhrghenucevlhhushhtvghrufhiiigvpedtne curfgrrhgrmhepmhgrihhlfhhrohhmpehmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Feedback-ID: i8771445c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 2 Jan 2023 06:52:59 -0500 (EST) From: Maxime Ripard To: Florian Fainelli , Ray Jui , Scott Branden Cc: bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, Maxime Ripard , kernel test robot Subject: [PATCH RESEND] firmware: raspberrypi: Fix type assignment Date: Mon, 2 Jan 2023 12:52:55 +0100 Message-Id: <20230102115255.17802-1-maxime@cerno.tech> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230102_035305_535189_DE4EE7E5 X-CRM114-Status: UNSURE ( 9.79 ) X-CRM114-Notice: Please train this message. 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 We silently cast an unsigned int into a __le32 which makes sparse complain. Moreover, we never actually convert endianness between the CPU's and the expected little-endian value. Fix both at once by calling cpu_to_le32(). Fixes: 40c31955e4e9 ("firmware: raspberrypi: Provide a helper to query a clock max rate") Reported-by: kernel test robot Link: https://lore.kernel.org/r/20221116091712.1309651-3-maxime@cerno.tech Signed-off-by: Maxime Ripard --- include/soc/bcm2835/raspberrypi-firmware.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/soc/bcm2835/raspberrypi-firmware.h b/include/soc/bcm2835/raspberrypi-firmware.h index ab955591cb72..73cac8d0287e 100644 --- a/include/soc/bcm2835/raspberrypi-firmware.h +++ b/include/soc/bcm2835/raspberrypi-firmware.h @@ -170,7 +170,7 @@ struct rpi_firmware_clk_rate_request { #define RPI_FIRMWARE_CLK_RATE_REQUEST(_id) \ { \ - .id = _id, \ + .id = cpu_to_le32(_id), \ } #if IS_ENABLED(CONFIG_RASPBERRYPI_FIRMWARE)