From patchwork Fri Oct 25 14:14:50 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Hildenbrand X-Patchwork-Id: 13850767 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 366B6D0C617 for ; Fri, 25 Oct 2024 14:15:51 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C0D206B009F; Fri, 25 Oct 2024 10:15:50 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id BBCC06B00A0; Fri, 25 Oct 2024 10:15:50 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A84AF6B00A1; Fri, 25 Oct 2024 10:15:50 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 88BD66B009F for ; Fri, 25 Oct 2024 10:15:50 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 44546C0B20 for ; Fri, 25 Oct 2024 14:15:29 +0000 (UTC) X-FDA: 82712322294.01.D8C45DA Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf02.hostedemail.com (Postfix) with ESMTP id 02CC280010 for ; Fri, 25 Oct 2024 14:15:10 +0000 (UTC) Authentication-Results: imf02.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=cEDhe00H; spf=pass (imf02.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1729865670; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=dV9SC24YC4T4aWYHNQCxY+WbG2Bhk/i+Kj0AtdnRckY=; b=JCyEee8ksX1qquyethE2MU/Qy/7gHCbp8ga+dyzP+lrfCEAzrkeqcOlVhU8tBA0AfXj1su knNmRufpNI+uaPP3+hgbtGYO5B7eCHGH+vjqxrfLIlnfvfHOezMHkJNbyoXfPTZTb/1rVw wgY7ZO5AZ++Dm096YsVzEN4p0FDuQ68= ARC-Authentication-Results: i=1; imf02.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=cEDhe00H; spf=pass (imf02.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1729865670; a=rsa-sha256; cv=none; b=3TJMT9saWlVz78kuvKXBDLucvC562uI6zlS1aT0QBLnRO/Exld9xoxS1jgU+Xvc/ePFBiH od+Tyv7Pjkc4JnP9Ebp1x0CyCMi5BzY4sEP9KktQIIaDQ/aSLAygkNWnua0+0pH7YQlTPe ZUJAZMi+TBHjPud18llpwiyBvQ6vucQ= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1729865748; 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=dV9SC24YC4T4aWYHNQCxY+WbG2Bhk/i+Kj0AtdnRckY=; b=cEDhe00HXmJZl+m+L29VjX96XiHVTe9gCnjtuFBwEtxKyzunfVxLp6NcI04BJj16fKWeFl szPCWQfK2OoxcccXKNEi3KJ0KBbXfOeIuuyYpgJCd91l4jwjW+SFDT5QDyIMZYqof4IeRl LTiS1ZLtqgbxkdKZ+ZZeWG3fMx/ghv4= Received: from mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-427-hNG7DXsQMK2z95OHSVmGKQ-1; Fri, 25 Oct 2024 10:15:44 -0400 X-MC-Unique: hNG7DXsQMK2z95OHSVmGKQ-1 Received: from mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.12]) (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 mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 8C14C1955DCD; Fri, 25 Oct 2024 14:15:42 +0000 (UTC) Received: from t14s.redhat.com (unknown [10.22.65.27]) by mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 499AE1955F30; Fri, 25 Oct 2024 14:15:35 +0000 (UTC) From: David Hildenbrand To: linux-kernel@vger.kernel.org Cc: linux-mm@kvack.org, linux-s390@vger.kernel.org, virtualization@lists.linux.dev, linux-doc@vger.kernel.org, kvm@vger.kernel.org, David Hildenbrand , Heiko Carstens , Vasily Gorbik , Alexander Gordeev , Christian Borntraeger , Sven Schnelle , Thomas Huth , Cornelia Huck , Janosch Frank , Claudio Imbrenda , "Michael S. Tsirkin" , Jason Wang , Xuan Zhuo , =?utf-8?q?Eugenio_P=C3=A9rez?= , Eric Farman , Andrew Morton , Jonathan Corbet , Mario Casquero Subject: [PATCH v3 5/7] lib/Kconfig.debug: default STRICT_DEVMEM to "y" on s390 Date: Fri, 25 Oct 2024 16:14:50 +0200 Message-ID: <20241025141453.1210600-6-david@redhat.com> In-Reply-To: <20241025141453.1210600-1-david@redhat.com> References: <20241025141453.1210600-1-david@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.12 X-Rspamd-Server: rspam03 X-Rspam-User: X-Rspamd-Queue-Id: 02CC280010 X-Stat-Signature: rzaym7egpdfgzbgez4p49trsm6ayrppm X-HE-Tag: 1729865710-558134 X-HE-Meta: U2FsdGVkX1+IXhdqKCIs7qVcsymS1ogZeOuIukwn483XeMtGZz/oSolWZbUsPhj5AMd8qWgzbyI+0c1UbSvrd/ju991q8+ShbYpisXC+Q3SMLHnSaxarJJZlPpZDsdUbxayRyzWI8Dm5BJeKnS9c+g//l9WeyxZ3sEPlVnmFxWN6891fuQElAlAW/RRp3NOugy/NtQg5kGtwPQFZPuSms2Cn+etsprasmXe+yRnzOPhzjysFKuS/NI/IPEa2/jhSPS5MgAsiLKCqVM1tJh/IuDDoMSKLYcWLJl7BzGZWKLb28+YS+uhnhZizji2Bz+smc0OqLCCnM1X/jl+fJ8QlOFn1GdD2Hfazdo2VaC+o7KIH5a5eagDaSsNOZtOb2LqPUqfLkHsgtPDG/SKkJZXEy4Rs/t2B2er41u+E8BVa/IJOxrKoGxuag72JAaP2xrLKc4nWZY9ijFlkaPfGya+qi12obpQ8YU73nmgdCP1TWt+Nl8tUoZgvdkmEldUQsE+VRv06UfU//lsVeComzA8fIPCj15fj9yNJihRTTJPAWLdIgx2fnjbDHFcvN2IW/QNgHog8/ip2ZjccO7cA+k0mMg2uXal4jetMT/RwyD4xb18w1k9tGLY/GET+5ofUHsPBrrmTNafriYzYgjyrrCaPDV1+AmxgLrppTDUioAGNbwsGUTKCi104Oga5vYFVU2yyV4W28pjqtSf+DAgqs4r4GBuavQ/IJRzMahczrmq+BH+gnyo+ajhrzyT88XWRyhtlFSQDKgYN+cadINfmkkrXO1DgPuz3iNYGXLHY+ccoS9cXQHZBezaaELePZi//G8Gp8b0d8ACesFX5uvmyopPlgTkgqhjDPivH4hPYGj1bprQP504qRaDJ/4vkxDRZsXG6k0lwMjRcr6JdIFglyMsfvpwUDSrd14f9tSEbb1FnL/Oy8fbpNcAHoffGj2j/ThBP3t/Z08W1C0iOYaci85w o6foYwQT 0xFV3XEm5Lw/npoMBfJQSgKVteul359IrvdDR4UbFjk0SaB0UBIvQ0xTLUliJuDnt6JmYOK+FXJliQOqc4MorEZkC3cf7LqxkJb9Ww6yRjBWLijxdIgEQ89BNTgk4GTK6/ZdGIWQoUtGXr9fDy40omED67yO+f5x+IftiIBUu/TvNLGw8G5Z3tVtGcUOeo0UOlEVlQhtt93dphp+vh5NEt9FNdK4yIr3LKJ8SWganIti8bJw4q8sGwCs52rsnjq0t+pQ6CFpXbh1nj1JukkGkxO/hR+s4OYe0Y4364VWSnesRrXZu3KHajffW4pyA+TYxJM66Ds29xOMkPRsVtMDJOGk5cXB/NRHT7Fw1NxyinYCD5CcuD24h+HHrg5YvmJwuvuqtRD7gpQZfxdo= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: virtio-mem currently depends on !DEVMEM | STRICT_DEVMEM. Let's default STRICT_DEVMEM to "y" just like we do for arm64 and x86. There could be ways in the future to filter access to virtio-mem device memory even without STRICT_DEVMEM, but for now let's just keep it simple. Tested-by: Mario Casquero Acked-by: Heiko Carstens Signed-off-by: David Hildenbrand --- lib/Kconfig.debug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index 7312ae7c3cc5..fcad505e7c8b 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -1905,7 +1905,7 @@ config STRICT_DEVMEM bool "Filter access to /dev/mem" depends on MMU && DEVMEM depends on ARCH_HAS_DEVMEM_IS_ALLOWED || GENERIC_LIB_DEVMEM_IS_ALLOWED - default y if PPC || X86 || ARM64 + default y if PPC || X86 || ARM64 || S390 help If this option is disabled, you allow userspace (root) access to all of memory, including kernel and userspace memory. Accidental