From nobody Thu Nov 28 10:59:01 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1693831571; cv=none; d=zohomail.com; s=zohoarc; b=B0/WjPDCBvElrniHbZDRfe01a4hQAfRMnkquwNngs/Lnz/h6q7oD8K86zHcVUMzn38+3Fq+EeBd7t7CBzr9lgcgvJAmx4LKTnsdzdbV790d0S/lg1s4qjZ3Twn6kDDcjdyDzSJF1WEl6eEtmAXi27Q3cRFNpc6h6XUWwpYwY0M0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1693831571; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=9c1++OFXiKHirX3uQNfDd/RXZK+lEL70eHdHIGvdol4=; b=YTx5v9HEDdvLNHgT1av4Z8ylX0g1sAdYfne3RM5tP8cmEVDh2oOuEbAIBw6ycRRrJsjyxxLopYvsv4iYgQ63HYPYd6KUfCw1mKRpdlr7k5JlRw3P465fqi53IugoLnGZW5E9WSA4iecL1utG9slW9hx/gB3CYABfLceC/oVAi48= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1693831571593468.9488193732998; Mon, 4 Sep 2023 05:46:11 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qd8wq-0003kf-HE; Mon, 04 Sep 2023 08:44:56 -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 1qd8wS-0002Y9-VJ for qemu-devel@nongnu.org; Mon, 04 Sep 2023 08:44:36 -0400 Received: from mail-lj1-x22d.google.com ([2a00:1450:4864:20::22d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qd8wP-0004ks-4H for qemu-devel@nongnu.org; Mon, 04 Sep 2023 08:44:31 -0400 Received: by mail-lj1-x22d.google.com with SMTP id 38308e7fff4ca-2bcc4347d2dso20034271fa.0 for ; Mon, 04 Sep 2023 05:44:28 -0700 (PDT) Received: from m1x-phil.lan ([176.187.209.227]) by smtp.gmail.com with ESMTPSA id f15-20020a1709067f8f00b009934855d8f1sm6127181ejr.34.2023.09.04.05.44.25 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Mon, 04 Sep 2023 05:44:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1693831467; x=1694436267; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=9c1++OFXiKHirX3uQNfDd/RXZK+lEL70eHdHIGvdol4=; b=fWk/Zq3ceQ7UglWsyYHnFamB0IOzavOkRrA4EjYZGAHdfTPMrV7c9E4sDCqPH/+HWI M3cu+rqvJ4zrVI7Oiwu8ho8g9L8KlJhXSqNSicL+ooarZ+bGE/UoKYJ+wrVFegscKE6I 6gk6/+FzHoqjZakkgi/yWhtUKHy7zj5035b4Js21fQBkXZdb2cpWIyx8I4YtJW2ROjA2 Ic55XjrlPML0gTzqavSGxFDNHi37d8b+WVnD2XwlvRYJhrM7YS4h7YNdSspBeP73EBWN pGWpT2+i9UJnxqHBR+lsodFOh7ns4pzbhdMCCOmLvoag/ELIEl5PUEsTtb1hHrjYKq/4 sr/A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693831467; x=1694436267; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=9c1++OFXiKHirX3uQNfDd/RXZK+lEL70eHdHIGvdol4=; b=Ap1VDdxCwjAcAbJzVwksu1wRDndEtaRw7SEFNcW0fggNMIk8itraMgQ7b8MCpxczwK VpZWE4JvvaEAnswY21covSlxtx+XumcvMoKDbHO9znWq53eivf9C2Uj/0Iv5mk5umIwC MakJPu7a4sn0Th5Z/TFmQva674V97w1BBIPgbYo1NSHFF/LqQE34ZQVEKptqdqnm/oI5 RKDnJkYCIvr2vcvGku53xPAXC0m4WOtovxWax+0w7phHLeUMBDd3xNRaMlRWK8iV4QSr ZmCTZ/zLadXhRTnZElCV5WKR90PzzQ90vLP/tVLa2WEUFj04U2Un2F+Dk00C5I4dwHdt 3gLg== X-Gm-Message-State: AOJu0Yyhbn1skzyRVMA+I3BDgpQhE714IwBR3ZVQkhV9YxNGaMchIFQ1 PcG6TQ5MRr0lTJIyMVXqOYtrzrcrC7lHll0YqjM= X-Google-Smtp-Source: AGHT+IEWA9agBIka4/UEdzmAwtfRA+imBetPWuYVWeGSiJIg5JmAaXx74MtNWsYTkyhrhZ9vNtQo1Q== X-Received: by 2002:a2e:908a:0:b0:2bc:fce1:54d3 with SMTP id l10-20020a2e908a000000b002bcfce154d3mr7414408ljg.41.1693831467132; Mon, 04 Sep 2023 05:44:27 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Richard Henderson , Paolo Bonzini , Marcelo Tosatti , "Michael S. Tsirkin" , kvm@vger.kernel.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PATCH 10/13] sysemu/kvm: Restrict kvm_arch_get_supported_cpuid/msr() to x86 targets Date: Mon, 4 Sep 2023 14:43:21 +0200 Message-ID: <20230904124325.79040-11-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230904124325.79040-1-philmd@linaro.org> References: <20230904124325.79040-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::22d; envelope-from=philmd@linaro.org; helo=mail-lj1-x22d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1693831573500100007 kvm_arch_get_supported_cpuid() / kvm_arch_get_supported_msr_feature() are only defined for x86 targets (in target/i386/kvm/kvm.c). Their declarations are pointless on other targets. Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- include/sysemu/kvm.h | 5 ----- target/i386/kvm/kvm_i386.h | 3 +++ 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/include/sysemu/kvm.h b/include/sysemu/kvm.h index ebdca41052..a578961a5e 100644 --- a/include/sysemu/kvm.h +++ b/include/sysemu/kvm.h @@ -464,11 +464,6 @@ int kvm_vm_check_extension(KVMState *s, unsigned int e= xtension); kvm_vcpu_ioctl(cpu, KVM_ENABLE_CAP, &cap); \ }) =20 -uint32_t kvm_arch_get_supported_cpuid(KVMState *env, uint32_t function, - uint32_t index, int reg); -uint64_t kvm_arch_get_supported_msr_feature(KVMState *s, uint32_t index); - - void kvm_set_sigmask_len(KVMState *s, unsigned int sigmask_len); =20 int kvm_physical_memory_addr_from_host(KVMState *s, void *ram_addr, diff --git a/target/i386/kvm/kvm_i386.h b/target/i386/kvm/kvm_i386.h index ff309bad25..b78e2feb49 100644 --- a/target/i386/kvm/kvm_i386.h +++ b/target/i386/kvm/kvm_i386.h @@ -40,6 +40,9 @@ bool kvm_hyperv_expand_features(X86CPU *cpu, Error **errp= ); void kvm_arch_reset_vcpu(X86CPU *cs); void kvm_arch_after_reset_vcpu(X86CPU *cpu); void kvm_arch_do_init_vcpu(X86CPU *cs); +uint32_t kvm_arch_get_supported_cpuid(KVMState *env, uint32_t function, + uint32_t index, int reg); +uint64_t kvm_arch_get_supported_msr_feature(KVMState *s, uint32_t index); =20 void kvm_set_max_apic_id(uint32_t max_apic_id); void kvm_request_xsave_components(X86CPU *cpu, uint64_t mask); --=20 2.41.0