From patchwork Wed Aug 18 11:49:56 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Menzel X-Patchwork-Id: 12444155 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 37EB9C4338F for ; Wed, 18 Aug 2021 11:50:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 102D46108F for ; Wed, 18 Aug 2021 11:50:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233640AbhHRLur (ORCPT ); Wed, 18 Aug 2021 07:50:47 -0400 Received: from mx3.molgen.mpg.de ([141.14.17.11]:50173 "EHLO mx1.molgen.mpg.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S229889AbhHRLuq (ORCPT ); Wed, 18 Aug 2021 07:50:46 -0400 Received: from ersatz.molgen.mpg.de (g258.RadioFreeInternet.molgen.mpg.de [141.14.13.3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: pmenzel) by mx.molgen.mpg.de (Postfix) with ESMTPSA id DA74661E5FE33; Wed, 18 Aug 2021 13:50:09 +0200 (CEST) From: Paul Menzel To: Paolo Bonzini , Sean Christopherson , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , Thomas Gleixner , Ingo Molnar , Borislav Petkov , x86@kernel.org, "H. Peter Anvin" Cc: Paul Menzel , kvm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] x86: kvm: Demote level of already loaded message from error to info Date: Wed, 18 Aug 2021 13:49:56 +0200 Message-Id: <20210818114956.7171-1-pmenzel@molgen.mpg.de> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org In scripts, running modprobe kvm_amd 2>/dev/null modprobe kvm_intel 2>/dev/null to ensure the modules are loaded causes Linux to log errors. $ dmesg --level=err [ 0.641747] [Firmware Bug]: TSC_DEADLINE disabled due to Errata; please update microcode to version: 0x3a (or later) [ 40.196868] kvm: already loaded the other module [ 40.219857] kvm: already loaded the other module [ 55.501362] kvm [1177]: vcpu0, guest rIP: 0xffffffff96e5b644 disabled perfctr wrmsr: 0xc2 data 0xffff [ 56.397974] kvm [1418]: vcpu0, guest rIP: 0xffffffff81046158 disabled perfctr wrmsr: 0xc1 data 0xabcd [1007981.827781] kvm: already loaded the other module [1008000.394089] kvm: already loaded the other module [1008030.706999] kvm: already loaded the other module [1020396.054470] kvm: already loaded the other module [1020405.614774] kvm: already loaded the other module [1020410.140069] kvm: already loaded the other module [1020704.049231] kvm: already loaded the other module As one of the two KVM modules is already loaded, KVM is functioning, and their is no error condition. Therefore, demote the log message level to informational. Signed-off-by: Paul Menzel Reported-by: Paul Menzel Signed-off-by: Sean Christopherson --- arch/x86/kvm/x86.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index e5d5c5ed7dd4..411c58ae0c97 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -8372,7 +8372,7 @@ int kvm_arch_init(void *opaque) int r; if (kvm_x86_ops.hardware_enable) { - printk(KERN_ERR "kvm: already loaded the other module\n"); + printk(KERN_INFO "kvm: already loaded the other module\n"); r = -EEXIST; goto out; }