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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 688AFC433FE for ; Tue, 8 Nov 2022 16:06:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234240AbiKHQGH (ORCPT ); Tue, 8 Nov 2022 11:06:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47154 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232035AbiKHQGF (ORCPT ); Tue, 8 Nov 2022 11:06:05 -0500 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 2A2EA1EC7F; Tue, 8 Nov 2022 08:06:04 -0800 (PST) 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 E197C1FB; Tue, 8 Nov 2022 08:06:09 -0800 (PST) Received: from bogus (e103737-lin.cambridge.arm.com [10.1.197.49]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 10D103F73D; Tue, 8 Nov 2022 08:06:00 -0800 (PST) Date: Tue, 8 Nov 2022 16:05:58 +0000 From: Sudeep Holla To: Pierre Gondois Cc: linux-kernel@vger.kernel.org, Catalin Marinas , Will Deacon , Paul Walmsley , Palmer Dabbelt , Albert Ou , "Rafael J. Wysocki" , Len Brown , Greg Kroah-Hartman , Gavin Shan , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , SeongJae Park , Jakub Kicinski , linux-arm-kernel@lists.infradead.org, linux-riscv@lists.infradead.org, linux-acpi@vger.kernel.org Subject: Re: [PATCH 2/5] cacheinfo: Return error code in init_of_cache_level() Message-ID: <20221108160558.ee7etff5oom57ddd@bogus> References: <20221108110424.166896-1-pierre.gondois@arm.com> <20221108110424.166896-3-pierre.gondois@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221108110424.166896-3-pierre.gondois@arm.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 08, 2022 at 12:04:18PM +0100, Pierre Gondois wrote: > Make init_of_cache_level() return an error code when the cache > information parsing fails to help detecting missing information. > > init_of_cache_level() is only called for riscv. Returning an error > code instead of 0 will prevent detect_cache_attributes() to allocate > memory if an incomplete DT is parsed. > Reviewed-by: Sudeep Holla -- Regards, Sudeep