From patchwork Thu Apr 25 03:12:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Zhao Liu X-Patchwork-Id: 791985 Delivered-To: patch@linaro.org Received: by 2002:a5d:4884:0:b0:346:15ad:a2a with SMTP id g4csp1169242wrq; Wed, 24 Apr 2024 19:59:45 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVsRo/Cwb5mh2kjwlThayoCAZZd2o5w6xyts1aaZg0aGpWFLZfKDQwujOgsQqhgFTDyCDMekKPI1+CYOmQYsOjU X-Google-Smtp-Source: AGHT+IFV9Zc9S09ecB17SzTD2Z38Ex1QDM7qX/hRSErJlYlYfEL74rxqOD5BgTN2q67WjC0h5DOQ X-Received: by 2002:ac8:59d3:0:b0:439:bb99:8312 with SMTP id f19-20020ac859d3000000b00439bb998312mr4427000qtf.6.1714013985462; Wed, 24 Apr 2024 19:59:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1714013985; cv=none; d=google.com; s=arc-20160816; b=tRLtn8hJjIJlK7GlIVJ2o4FO7TkjkPkLzE5ph6eZMX3MZbEmsZkEFBNJ6l3X5toWPG 4Shv898iVlUujrhxb0D6chrsQiXumYjD7ZL7A99Txu9lmSfP5O9nSFB0Muh9yx0zTfSt SoAp8+WdzjyI2LI29qnpqc8mSg8Rlwhd+mi86TXQVuaL8AvkKtGH3SGxFXoQbMaHg5pR F1dsTO3KXBX3ew8fcIZ9xDoCvKTftvEs25B+cuI1F4Aqvxg76OF6IcIWJjI+doC8TKI9 KY34sxYbD27T0ZieNa/bCabfTRqAK84jNzIGzkHQkZ8RdwYxJDEL5myzCQOVnWm/Docd NKjQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=+nzjerLpwsv7Q+GAsSqkKFSc+Z/ovhSWspBMcAf5j6E=; fh=AJUZDLb7oJB/h+jOd10OsOml9lIf25pIHs+eqlpfxo8=; b=nxq4uEaP1YtWFaQ6c4G92eL5lEB0UKWO6uG2W0Q6X594pvL+NrYRzZ2Sn8oalF4q2j 60wPsvDrDNs+W7e9+LKh131fQoG0BPqq0NBmRUgjhMs0lsUk0Lf1qjiueNLvTPAKPjIr c0Id8YiiQAgPJg8h9Qr/xcz9XNDoDFozXaJlefPsaELh7tIb82G7gVD/gqk0YA+spGFg oR+eVAKx3GDtp05ZG98mvj5Ee6K4aVvy8iQ8gIlwcn6u8u6lIzB45sSp65pUTQWR9qGP SCGEHE9Rv7CPaXFVReVNXQdvrCO0JzAWIU80ktjQVXVxwCpl+0SCZoPGYRMO4myZBT7V YRZA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=becJzPYR; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id a8-20020a05622a064800b004348564b72bsi13663297qtb.226.2024.04.24.19.59.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 24 Apr 2024 19:59:45 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=becJzPYR; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rzpK9-0006ne-M6; Wed, 24 Apr 2024 22:59:01 -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 1rzpK0-0006jx-HN; Wed, 24 Apr 2024 22:58:52 -0400 Received: from mgamail.intel.com ([198.175.65.21]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rzpJy-00055w-UA; Wed, 24 Apr 2024 22:58:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1714013931; x=1745549931; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=PJPFCA7BY25YZOOud8GjsPozRvVnyadtZVhQM8SLIwM=; b=becJzPYRLgmrO7zKjSd/KCojvGG9I8uztaPlWOQFb2KLJfhFVijpFQGM v4fo55jMWRiMwuJisD+dcYbymqgCFDuYzswTHCy8IdxNg2F9fUhBVxING vvim4ojhjqDWiePuUzN6K2rgDrlIHuldI0TKeCMvgC+2TVPSUX8LmcwSz WV9RbRPt85nNPJUUng5o042qPBttb1iy5l9wKcBfYqk5X1fOoOG2ONBtN Y6jkgEN3luiME4CtzJ1RAKTa66P+d5J5XNN78LuACQm1CydZ/43FrKeV9 0tKhv6x0ADHV8LoZbJDmsZ+UJZi9TtRsiQOlD/0QY1Q1r/DfYNr0dI+Qi w==; X-CSE-ConnectionGUID: rItFOClmTX+RY/8CGGSSVA== X-CSE-MsgGUID: jZDnOEcNTrORRb90f/HxLg== X-IronPort-AV: E=McAfee;i="6600,9927,11054"; a="9605653" X-IronPort-AV: E=Sophos;i="6.07,228,1708416000"; d="scan'208";a="9605653" Received: from orviesa001.jf.intel.com ([10.64.159.141]) by orvoesa113.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Apr 2024 19:58:50 -0700 X-CSE-ConnectionGUID: F/aid7veQRill52Gdylhvw== X-CSE-MsgGUID: glA8qC35Qc6/uWVLMFd3NA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,228,1708416000"; d="scan'208";a="62395684" Received: from liuzhao-optiplex-7080.sh.intel.com ([10.239.160.36]) by orviesa001.jf.intel.com with ESMTP; 24 Apr 2024 19:58:47 -0700 From: Zhao Liu To: Thomas Huth , David Hildenbrand , Richard Henderson , Ilya Leoshkevich , Halil Pasic , Christian Borntraeger , =?utf-8?q?Philippe_Mathi?= =?utf-8?q?eu-Daud=C3=A9?= Cc: qemu-s390x@nongnu.org, qemu-devel@nongnu.org, Zhao Liu Subject: [PATCH v2 3/7] target/s390x: Remove KVM stubs in cpu_models.h Date: Thu, 25 Apr 2024 11:12:28 +0800 Message-Id: <20240425031232.1586401-4-zhao1.liu@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240425031232.1586401-1-zhao1.liu@intel.com> References: <20240425031232.1586401-1-zhao1.liu@intel.com> MIME-Version: 1.0 Received-SPF: pass client-ip=198.175.65.21; envelope-from=zhao1.liu@intel.com; helo=mgamail.intel.com X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.668, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, 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: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org From: Philippe Mathieu-Daudé Since the calls are elided when KVM is not available, we can remove the stubs (which are never compiled). Inspired-by: Thomas Huth > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Zhao Liu Signed-off-by: Zhao Liu --- target/s390x/cpu_models.h | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/target/s390x/cpu_models.h b/target/s390x/cpu_models.h index d7b89129891a..a89c2a15ab54 100644 --- a/target/s390x/cpu_models.h +++ b/target/s390x/cpu_models.h @@ -114,23 +114,8 @@ static inline uint64_t s390_cpuid_from_cpu_model(const S390CPUModel *model) S390CPUDef const *s390_find_cpu_def(uint16_t type, uint8_t gen, uint8_t ec_ga, S390FeatBitmap features); -#ifdef CONFIG_KVM bool kvm_s390_cpu_models_supported(void); void kvm_s390_get_host_cpu_model(S390CPUModel *model, Error **errp); void kvm_s390_apply_cpu_model(const S390CPUModel *model, Error **errp); -#else -static inline void kvm_s390_get_host_cpu_model(S390CPUModel *model, - Error **errp) -{ -} -static inline void kvm_s390_apply_cpu_model(const S390CPUModel *model, - Error **errp) -{ -} -static inline bool kvm_s390_cpu_models_supported(void) -{ - return false; -} -#endif #endif /* TARGET_S390X_CPU_MODELS_H */