Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp3194466rdb; Tue, 6 Feb 2024 09:43:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IGn6djVLJKplwPemkugHS6e++fkL2jMBzeNginw4qijgNJ9JCjIWcvjrrqM5tNFQsL3EZSU X-Received: by 2002:a17:903:278c:b0:1d9:11dd:1443 with SMTP id jw12-20020a170903278c00b001d911dd1443mr2047061plb.56.1707241402982; Tue, 06 Feb 2024 09:43:22 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707241402; cv=pass; d=google.com; s=arc-20160816; b=Ht2my001hZnTa8q7BDnD6HAZNYdyOYKg3j0Sz1oLSDd5ASdaBDihqVqYz5HukkH+EZ 8sZ8ePALW+5tiulkuSVRUwuT5CXaxB2lcXeCaaEqqeMMDgLngxfJag7b3CbCOkA1V7oy q/3dxbogL94ruXItVI0i74splBGQG9E7XeIDx6OjKx0l9s7b3I90Of9mUnIqvQ7Az88k Ncra5t8MRQAo/ExbcTFxkQDCCtL6Ym8aKtasv5G3HvXgyiI28yGRA8BrdoZqCQ+cN9hK /JAni4t7/qL4Xij/Wkqv9n8ZdJzd4UbkQpli2ya725BcINxdPDJQuZpzWCyIB4NF8Cmf CAMg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=DiAeFErACPu2Qq/VSwmzn5NIHI5rZO8DYF37cTAxg+8=; fh=Pu7wO6f3SbxzFUJLhdUNy2Ny6Hs7GwvmrhE/+BgYyTA=; b=LDwUktcQgk7Dgl4lGMypp/4fj0dVkDfCYlpM6EkssDAOSK7IklM1VQ8y/IgB5rBwEb li4ngLRF78xpKyoGfCAxvdLb+7aG3bOyXXWYH/YsgeOMtWIm5oI6MT+4RR6lhZb8NQGj SAkWNCTMmha95SkZlqBCYsqfg7mVMU733xtIABniZGDfk3YSlDDTckzodU7ev3NPbayh dhPAbqrPO+XnbMpLyvdDpk0A2qQVPxwghUM5W/fVuYaiPsEmaHUSwiUzNJvW0dK6DwdT dzBdkSa2Jaov7cWu+ZITDrsys6zXsQWfiBAXGMwYypOq2lUAg0vxjMq73fWMjYZMle2I h/7g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=C1MOs9an; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of linux-kernel+bounces-55414-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-55414-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com X-Forwarded-Encrypted: i=1; AJvYcCWV+O/Um9BqKVrBcNo2ExMtiVlAwzaIVKMScuoqebhNH3XydXQMon9+D61yig9XVwomkrNBkFC/lnFRzfbyHzcbkE1QwUkErqcPaYgzlA== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id z6-20020a170903018600b001d9656a267dsi2003744plg.519.2024.02.06.09.43.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Feb 2024 09:43:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-55414-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=C1MOs9an; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of linux-kernel+bounces-55414-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-55414-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 7D4B128B51F for ; Tue, 6 Feb 2024 17:42:51 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1765C1B94B; Tue, 6 Feb 2024 17:40:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="C1MOs9an" Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (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 B827719470 for ; Tue, 6 Feb 2024 17:40:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707241210; cv=none; b=PVv2Mwlou2Sake20O3YiOZg8KEehnFewvIcDbYx7pPfdev+IGnQCrvxuTJlKMzLTodYMIBhx6vR+Axx1ofOp43vXFmuDFJqvG8n/IS61f1RCD84iWybIYKDnFN6g2V0lq7Nqb5SB2JacfhEssGBTNJTZYUO0RxiFScMOWDVY0Fw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707241210; c=relaxed/simple; bh=OqaVifQS+nxzCD21b4s8rJ7JH6j5ozOv9bSA598QaaY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=E4F16/X6nsCTgjLFe2US3IMvjQn+ff97o0P9u4nwyCgTJhxXgkI4X80w7LPEOT/y0okvl9w7s3XKKbyhpr7/+U7g7MnRYOBQHb6NE9Vs5sYJWjxqIkxKR0+isp2B36hMmEUylKjnBYbUOkY0KHJz0Z1kMZbEL93+MgBNNisVlQY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=C1MOs9an; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1707241207; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DiAeFErACPu2Qq/VSwmzn5NIHI5rZO8DYF37cTAxg+8=; b=C1MOs9anrQSsXFRlV/Bfj8OEba6wS8eDNuYaWzmIl1sgnBKiP0vlspln4ajXN1NOo6n6EY 0IQIhLuNXcGk/NS9oBZB0dPTqR+KxsUpwUdN1oqJ1+5YNAgIwk1HbpyMIpAy8Im9xZp/PS y7rSrHgzDmgmOXTf+cY0oVL8yRoClfQ= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-527-Leok8IbMPaWMhJaxElOyGA-1; Tue, 06 Feb 2024 12:40:02 -0500 X-MC-Unique: Leok8IbMPaWMhJaxElOyGA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (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) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 98959879843; Tue, 6 Feb 2024 17:40:00 +0000 (UTC) Received: from vschneid-thinkpadt14sgen2i.remote.csb (unknown [10.39.193.2]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5B9882026D06; Tue, 6 Feb 2024 17:39:56 +0000 (UTC) From: Valentin Schneider To: linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-arch@vger.kernel.org, x86@kernel.org Cc: Sean Christopherson , Josh Poimboeuf , Thomas Gleixner , Borislav Petkov , Peter Zijlstra , Pawan Gupta , Ingo Molnar , Dave Hansen , "H. Peter Anvin" , Paolo Bonzini , Wanpeng Li , Vitaly Kuznetsov , Arnd Bergmann , Jason Baron , Steven Rostedt , Ard Biesheuvel , Frederic Weisbecker , "Paul E. McKenney" , Feng Tang , Andrew Morton , "Mike Rapoport (IBM)" , Vlastimil Babka , David Hildenbrand , "ndesaulniers@google.com" , Michael Kelley , "Masami Hiramatsu (Google)" Subject: [PATCH v2 3/5] x86/kvm: Make kvm_async_pf_enabled __ro_after_init Date: Tue, 6 Feb 2024 18:39:09 +0100 Message-ID: <20240206173911.4131670-4-vschneid@redhat.com> In-Reply-To: <20240206173911.4131670-1-vschneid@redhat.com> References: <20240206173911.4131670-1-vschneid@redhat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.4 kvm_async_pf_enabled is only ever enabled in __init kvm_guest_init(), so mark it as __ro_after_init. Reviewed-by: Sean Christopherson Signed-off-by: Valentin Schneider Acked-by: Josh Poimboeuf --- arch/x86/kernel/kvm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c index dfe9945b9bece..8f48ce7adfb28 100644 --- a/arch/x86/kernel/kvm.c +++ b/arch/x86/kernel/kvm.c @@ -44,7 +44,7 @@ #include #include -DEFINE_STATIC_KEY_FALSE(kvm_async_pf_enabled); +DEFINE_STATIC_KEY_FALSE_RO(kvm_async_pf_enabled); static int kvmapf = 1; -- 2.43.0