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 C88D5C25B4E for ; Tue, 24 Jan 2023 13:32:58 +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-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:CC:To:From:Date: Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=hE95Gskx9JMtg7ujNOHecN+PFWbXBjkqB068uwsdji0=; b=nXFE6YM8pN7Dz641vqAwCrRUx5 qhjQ8MNdWTtnJj1t3X5h54jK/RS5C4jlCCsN9v7jzJKSVwCHNooCxHBgf1H3G0o12D/6nyRl+zCGv 91tg/OqHTDayIaeS+90s2G4ZXFLmr5+NW5S2BrSAsEsOA/xi48hSBiz7Mlun8XABC9WMXwLBJtO1a XTt3nFrVdsQa/vSOJ9GZYW4gq9tsyeiBoSEXDI6bT/J4hlY27cLQ6macT+sXIQw7Ql98IpAuRgCwe loQeGxjNKSGyIlLLBbt9Yg967SxrdxDoLPiz+N5kSSrvVOed//9DsHOOOsYQ8PBxVA/QUKDUnxVEV F794n9YQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pKJP4-003zNo-2m; Tue, 24 Jan 2023 13:31:58 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pKJP0-003zNJ-L7 for linux-arm-kernel@lists.infradead.org; Tue, 24 Jan 2023 13:31:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1674567115; x=1706103115; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=K2lHqDxHA1j9+i0Zq00dJ1rYZq4W/0cdhAmEOjB/Gzk=; b=bG92WK94r46vQ2pI3lzJyhyYWYKTxyGliI0Hx9xuVnQpd8kpLvgj8/Gi iico4uFgFQL2ISjy9n95fHWTNlo08qpkkiBOaKaXUUYr7TWgKs44dxAb5 BFZKxvL6mbvMK+8DOM9lnTi/oKyZ2WFwzZ7fU4jcHGvtskW84IrQlZWBD KdY90uBdk8WT+2jP1M0Vfec0bZnp5wAaADOx3oKzjchWfgxyTVs+CSGBH mcaK/eZl7GoiOA+Bz0zlfCzbPY4VDQLL8m2T3Z2zTPXr6DRzZczs07p3w D3obM0jJWzsYfmzCFZ1ucH+7BqGBHQYLI2PbiLoKdN2LBWGCgfcbP8dIH Q==; X-IronPort-AV: E=Sophos;i="5.97,242,1669100400"; d="asc'?scan'208";a="193624415" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa4.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 24 Jan 2023 06:31:36 -0700 Received: from chn-vm-ex01.mchp-main.com (10.10.85.143) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Tue, 24 Jan 2023 06:31:31 -0700 Received: from wendy (10.10.115.15) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16 via Frontend Transport; Tue, 24 Jan 2023 06:31:29 -0700 Date: Tue, 24 Jan 2023 13:31:06 +0000 From: Conor Dooley To: Pierre Gondois CC: , Dan Carpenter , kernel test robot , Catalin Marinas , Will Deacon , Greg Kroah-Hartman , "Rafael J. Wysocki" , Sudeep Holla , Palmer Dabbelt , Gavin Shan , Subject: Re: [PATCH -next] cacheinfo: Correctly handle new acpi_get_cache_info() prototype Message-ID: References: <20230124123450.321852-1-pierre.gondois@arm.com> MIME-Version: 1.0 In-Reply-To: <20230124123450.321852-1-pierre.gondois@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230124_053154_773401_F88BFF1A X-CRM114-Status: GOOD ( 19.54 ) 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: , Content-Type: multipart/mixed; boundary="===============7200221309642930065==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============7200221309642930065== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="nk57ke8/f2usmaAy" Content-Disposition: inline --nk57ke8/f2usmaAy Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hey! On Tue, Jan 24, 2023 at 01:34:46PM +0100, Pierre Gondois wrote: > commit bd500361a937 ("ACPI: PPTT: Update acpi_find_last_cache_level() > to acpi_get_cache_info()") > updates the function acpi_get_cache_info(). >=20 > If CONFIG_ACPI_PPTT is not defined, acpi_get_cache_info() doesn't > update its *levels and *split_levels parameters and returns 0. > This can lead to a faulty behaviour. >=20 > Make acpi_get_cache_info() return an error code if CONFIG_ACPI_PPTT > is not defined. Initialize levels and split_levels before passing > their address to acpi_get_cache_info(). >=20 > Also, in init_cache_level(): Hmm... > - commit e75d18cecbb3 ("arm64: cacheinfo: Fix incorrect > assignment of signed error value to unsigned fw_level") > checks the fw_level value in init_cache_level() in case > the value is negative. Remove this check as the error code > is not returned through fw_level anymore. > - if no PPTT is present or CONFIG_ACPI_PPTT is not defined, > it is still possible to use the cache information from clidr_el1. > Instead of aborting if acpi_get_cache_info() returns an error > code, just continue. To be honest, these feel like entirely separate things that should be in different patches. You've got: - Dan's smatch fixes - a redundant check being removed - a behaviour change for if acpi_get_cache_info() returns an error > Reported-by: Dan Carpenter > Reported-by: kernel test robot How about Link: to the LKP/Dan's report? Link: https://lore.kernel.org/all/Y86iruJPuwNN7rZw@kili/ I did a quick check but didn't don't see the LKP report... Also a Fixes: tag too, no? Thanks, Conor. --nk57ke8/f2usmaAy Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCY8/djQAKCRB4tDGHoIJi 0ullAQCykmFyIh/vjpHYTKvq97fTTrk+p6uQxzD/5NrxVPUh6gEAvlyvCAfISQHE QRsAEdOLOyv31XHz9mXhbr+UM7vmcgo= =fhiN -----END PGP SIGNATURE----- --nk57ke8/f2usmaAy-- --===============7200221309642930065== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============7200221309642930065==--