From patchwork Wed Nov 16 09:17:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 13044577 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 008A0C4332F for ; Wed, 16 Nov 2022 09:17:39 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 5477410E449; Wed, 16 Nov 2022 09:17:38 +0000 (UTC) Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by gabe.freedesktop.org (Postfix) with ESMTPS id D79B110E44C for ; Wed, 16 Nov 2022 09:17:23 +0000 (UTC) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 018D05C0135; Wed, 16 Nov 2022 04:17:23 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Wed, 16 Nov 2022 04:17:23 -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 :in-reply-to:message-id:mime-version:references:reply-to:sender :subject:subject:to:to; s=fm2; t=1668590242; x=1668676642; bh=Rw Uykb/iqubbswUUCNf44Y0WfA2Nq+FieB2GLHcmZE8=; b=hV1oWcE8PhoZbG2Ojx dDaWg4TWokIevb1x6PD121oKeXobpaClxv/KhYdyASLEa/Mc6EdJ0ECQjbYyIh9d A+/lyz1h70/jCseOGHyATJQ6nd+8Md2HhdD6hTNYDSk857pN1GqnasxstUgGKeZF SCPPGdP0OBYI/jEO4+eLKPILwWFX7OVe24X5u2EYPi5FS25wjAcJDqHqmJfsQHvS 8YDoryeQiyhacpSd2QfsvAxDWxZ63daQNJDFpzP1TsK6rpV7fQwwUCGS1I/7OgvN czOtchPJK88dh4N7qpSk0e6JSJu2PabpnenVtJlppOLXM1LXcFdhnnm4SsMzddcZ MDbg== 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:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; t=1668590242; x=1668676642; bh=RwUykb/iqubbs wUUCNf44Y0WfA2Nq+FieB2GLHcmZE8=; b=LDAhTobKekHP7uP4Vd2rpJ/4UjDl6 jqh3VlR7FZSK8mFgb83GfkTf3qHLyUcdEerdnKu/6CDp/hYeSLwtrsp1UVzkdTm5 s/7dwC6+4NCAL7Cf7fiQGf4BWT+IwZBC1lYmmzHf0k/P6jHF2aJqwEGLg+kPrukr JcCKKkh5GY4GV0SyDHEXBFa3TLD6S5xWSe4KW/sZr9z8KzNR8t+/94wOCMSxl3av 5Tma3+JQ5dtIqIhZAwfM3d3/YZcTwfLyWgxZWSHuT3QNksd2wblzUom5tCvQb5F/ p6qc2yeodt4zkwt6BVxv8mItOrnkE5x2BzFytfhvflFxUFzPEbjBCwv3A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvgedrgeehgdduvdekucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkofgjfhgggfestdekredtredttdenucfhrhhomhepofgrgihi mhgvucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucggtffrrg htthgvrhhnpeelkeefteduhfekjeeihfetudfguedvveekkeetteekhfekhfdtlefgfedu vdejhfenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe hmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Feedback-ID: i8771445c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 16 Nov 2022 04:17:21 -0500 (EST) From: Maxime Ripard To: Daniel Vetter , David Airlie , Maarten Lankhorst , Thomas Zimmermann , Maxime Ripard , Florian Fainelli Subject: [PATCH 3/3] firmware: raspberrypi: Fix type assignment Date: Wed, 16 Nov 2022 10:17:12 +0100 Message-Id: <20221116091712.1309651-3-maxime@cerno.tech> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221116091712.1309651-1-maxime@cerno.tech> References: <20221116091712.1309651-1-maxime@cerno.tech> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, kernel test robot Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" 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 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)