From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from frasgout.his.huawei.com (frasgout.his.huawei.com [185.176.79.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3E5311A01AB for ; Tue, 22 Oct 2024 14:44:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.176.79.56 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729608283; cv=none; b=DJm6bnDsxEeKdkKCf0axIdwFU/CBDD92Lvc4e4tCQcY1LH+ORBYzydZfybsDTwOxGsLlgKB2DhoTVz64fD2+vG3wFESB9L07WijmQ5uCkd9AEGGoIz6NpgH/42A4eysMkJxViMUmur6zTTuhPIxyLSeZBYqvA1/p/WD/QQ61kDo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729608283; c=relaxed/simple; bh=fmcSPGwUxCXR3lWs/7xq45VVwxCtjYhUI+2xpjqzwUo=; h=Date:From:To:CC:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=etOv6BqivvSkzQ7OZ6o5Pj05d6kmvhh12HspuGaR+LI/49ct0ueFHkUKuSUaqZm63x59Xl/koeVjyPpb+aVxuYqCMw6qmDEcR+A6YUMt/MQkI3n8Jk134GDWhWNhrL+Hse0FJUilHjcgFBeS1Zjj0MPt1FVMSosFFoRqgycOpbA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=Huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=185.176.79.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=Huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.18.186.231]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4XXw0b2ftvz6JBBn; Tue, 22 Oct 2024 22:43:43 +0800 (CST) Received: from frapeml500008.china.huawei.com (unknown [7.182.85.71]) by mail.maildlp.com (Postfix) with ESMTPS id BD65B1400DB; Tue, 22 Oct 2024 22:44:38 +0800 (CST) Received: from localhost (10.203.177.66) by frapeml500008.china.huawei.com (7.182.85.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Tue, 22 Oct 2024 16:44:37 +0200 Date: Tue, 22 Oct 2024 15:44:36 +0100 From: Jonathan Cameron To: Zhao Liu CC: "Daniel P . =?ISO-8859-1?Q?Berrang=E9?=" , "Igor Mammedov" , Eduardo Habkost , Marcel Apfelbaum , Philippe =?ISO-8859-1?Q?Ma?= =?ISO-8859-1?Q?thieu-Daud=E9?= , Yanan Wang , "Michael S.Tsirkin " , "Paolo Bonzini" , Richard Henderson , Eric Blake , "Markus Armbruster" , Marcelo Tosatti , Alex =?ISO-8859-1?Q?Benn=E9e?= , Peter Maydell , Sia Jee Heng , Alireza Sanaee , , , , , "Zhenyu Wang" , Dapeng Mi Subject: Re: [PATCH v4 5/9] hw/core: Add a helper to check the cache topology level Message-ID: <20241022154436.000028af@Huawei.com> In-Reply-To: <20241022135151.2052198-6-zhao1.liu@intel.com> References: <20241022135151.2052198-1-zhao1.liu@intel.com> <20241022135151.2052198-6-zhao1.liu@intel.com> Organization: Huawei Technologies Research and Development (UK) Ltd. X-Mailer: Claws Mail 4.1.0 (GTK 3.24.33; x86_64-w64-mingw32) Precedence: bulk X-Mailing-List: kvm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-ClientProxiedBy: lhrpeml100004.china.huawei.com (7.191.162.219) To frapeml500008.china.huawei.com (7.182.85.71) Resend. Claws-mail is still chewing up the to list for unknown reasons and I forgot to fix it by hand. On Tue, 22 Oct 2024 21:51:47 +0800 Zhao Liu wrote: > Currently, we have no way to expose the arch-specific default cache > model because the cache model is sometimes related to the CPU model > (e.g., i386). > > Since the user might configure "default" level, any comparison with > "default" is meaningless before the machine knows the specific level > that "default" refers to. > > We can only check the correctness of the cache topology after the arch > loads the user-configured cache model from MachineState.smp_cache and > consumes the special "default" level by replacing it with the specific > level. > > Signed-off-by: Zhao Liu Looks like useful sanity check code to me. Reviewed-by: Jonathan Cameron 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 lists.gnu.org (lists.gnu.org [209.51.188.17]) (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 AF505D2C560 for ; Tue, 22 Oct 2024 14:45:13 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t3G7s-0005rA-As; Tue, 22 Oct 2024 10:44:48 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t3G7o-0005kf-1H; Tue, 22 Oct 2024 10:44:44 -0400 Received: from frasgout.his.huawei.com ([185.176.79.56]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t3G7m-0000U9-Jb; Tue, 22 Oct 2024 10:44:43 -0400 Received: from mail.maildlp.com (unknown [172.18.186.231]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4XXw0b2ftvz6JBBn; Tue, 22 Oct 2024 22:43:43 +0800 (CST) Received: from frapeml500008.china.huawei.com (unknown [7.182.85.71]) by mail.maildlp.com (Postfix) with ESMTPS id BD65B1400DB; Tue, 22 Oct 2024 22:44:38 +0800 (CST) Received: from localhost (10.203.177.66) by frapeml500008.china.huawei.com (7.182.85.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Tue, 22 Oct 2024 16:44:37 +0200 Date: Tue, 22 Oct 2024 15:44:36 +0100 To: Zhao Liu CC: "Daniel P . =?ISO-8859-1?Q?Berrang=E9?=" , "Igor Mammedov" , Eduardo Habkost , Marcel Apfelbaum , Philippe =?ISO-8859-1?Q?Ma?= =?ISO-8859-1?Q?thieu-Daud=E9?= , Yanan Wang , "Michael S.Tsirkin " , "Paolo Bonzini" , Richard Henderson , Eric Blake , "Markus Armbruster" , Marcelo Tosatti , Alex =?ISO-8859-1?Q?Benn=E9e?= , Peter Maydell , Sia Jee Heng , Alireza Sanaee , , , , , "Zhenyu Wang" , Dapeng Mi Subject: Re: [PATCH v4 5/9] hw/core: Add a helper to check the cache topology level Message-ID: <20241022154436.000028af@Huawei.com> In-Reply-To: <20241022135151.2052198-6-zhao1.liu@intel.com> References: <20241022135151.2052198-1-zhao1.liu@intel.com> <20241022135151.2052198-6-zhao1.liu@intel.com> Organization: Huawei Technologies Research and Development (UK) Ltd. X-Mailer: Claws Mail 4.1.0 (GTK 3.24.33; x86_64-w64-mingw32) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.203.177.66] X-ClientProxiedBy: lhrpeml100004.china.huawei.com (7.191.162.219) To frapeml500008.china.huawei.com (7.182.85.71) Received-SPF: pass client-ip=185.176.79.56; envelope-from=jonathan.cameron@huawei.com; helo=frasgout.his.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-riscv@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Jonathan Cameron From: Jonathan Cameron via Errors-To: qemu-riscv-bounces+qemu-riscv=archiver.kernel.org@nongnu.org Sender: qemu-riscv-bounces+qemu-riscv=archiver.kernel.org@nongnu.org Resend. Claws-mail is still chewing up the to list for unknown reasons and I forgot to fix it by hand. On Tue, 22 Oct 2024 21:51:47 +0800 Zhao Liu wrote: > Currently, we have no way to expose the arch-specific default cache > model because the cache model is sometimes related to the CPU model > (e.g., i386). > > Since the user might configure "default" level, any comparison with > "default" is meaningless before the machine knows the specific level > that "default" refers to. > > We can only check the correctness of the cache topology after the arch > loads the user-configured cache model from MachineState.smp_cache and > consumes the special "default" level by replacing it with the specific > level. > > Signed-off-by: Zhao Liu Looks like useful sanity check code to me. Reviewed-by: Jonathan Cameron 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 lists.gnu.org (lists.gnu.org [209.51.188.17]) (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 2BCE5D2C560 for ; Tue, 22 Oct 2024 14:45:04 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t3G7q-0005nT-KJ; Tue, 22 Oct 2024 10:44:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t3G7o-0005kf-1H; Tue, 22 Oct 2024 10:44:44 -0400 Received: from frasgout.his.huawei.com ([185.176.79.56]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t3G7m-0000U9-Jb; Tue, 22 Oct 2024 10:44:43 -0400 Received: from mail.maildlp.com (unknown [172.18.186.231]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4XXw0b2ftvz6JBBn; Tue, 22 Oct 2024 22:43:43 +0800 (CST) Received: from frapeml500008.china.huawei.com (unknown [7.182.85.71]) by mail.maildlp.com (Postfix) with ESMTPS id BD65B1400DB; Tue, 22 Oct 2024 22:44:38 +0800 (CST) Received: from localhost (10.203.177.66) by frapeml500008.china.huawei.com (7.182.85.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Tue, 22 Oct 2024 16:44:37 +0200 Date: Tue, 22 Oct 2024 15:44:36 +0100 To: Zhao Liu CC: "Daniel P . =?ISO-8859-1?Q?Berrang=E9?=" , "Igor Mammedov" , Eduardo Habkost , Marcel Apfelbaum , Philippe =?ISO-8859-1?Q?Ma?= =?ISO-8859-1?Q?thieu-Daud=E9?= , Yanan Wang , "Michael S.Tsirkin " , "Paolo Bonzini" , Richard Henderson , Eric Blake , "Markus Armbruster" , Marcelo Tosatti , Alex =?ISO-8859-1?Q?Benn=E9e?= , Peter Maydell , Sia Jee Heng , Alireza Sanaee , , , , , "Zhenyu Wang" , Dapeng Mi Subject: Re: [PATCH v4 5/9] hw/core: Add a helper to check the cache topology level Message-ID: <20241022154436.000028af@Huawei.com> In-Reply-To: <20241022135151.2052198-6-zhao1.liu@intel.com> References: <20241022135151.2052198-1-zhao1.liu@intel.com> <20241022135151.2052198-6-zhao1.liu@intel.com> Organization: Huawei Technologies Research and Development (UK) Ltd. X-Mailer: Claws Mail 4.1.0 (GTK 3.24.33; x86_64-w64-mingw32) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.203.177.66] X-ClientProxiedBy: lhrpeml100004.china.huawei.com (7.191.162.219) To frapeml500008.china.huawei.com (7.182.85.71) Received-SPF: pass client-ip=185.176.79.56; envelope-from=jonathan.cameron@huawei.com; helo=frasgout.his.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Jonathan Cameron From: Jonathan Cameron via Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Resend. Claws-mail is still chewing up the to list for unknown reasons and I forgot to fix it by hand. On Tue, 22 Oct 2024 21:51:47 +0800 Zhao Liu wrote: > Currently, we have no way to expose the arch-specific default cache > model because the cache model is sometimes related to the CPU model > (e.g., i386). > > Since the user might configure "default" level, any comparison with > "default" is meaningless before the machine knows the specific level > that "default" refers to. > > We can only check the correctness of the cache topology after the arch > loads the user-configured cache model from MachineState.smp_cache and > consumes the special "default" level by replacing it with the specific > level. > > Signed-off-by: Zhao Liu Looks like useful sanity check code to me. Reviewed-by: Jonathan Cameron