From patchwork Thu Oct 14 07:50:40 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rikard Falkeborn X-Patchwork-Id: 12557891 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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 23171C433EF for ; Thu, 14 Oct 2021 07:51:01 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A157260FF2 for ; Thu, 14 Oct 2021 07:51:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org A157260FF2 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 279BB940026; Thu, 14 Oct 2021 03:51:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 228E594001C; Thu, 14 Oct 2021 03:51:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 117C4940026; Thu, 14 Oct 2021 03:51:00 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0069.hostedemail.com [216.40.44.69]) by kanga.kvack.org (Postfix) with ESMTP id F3FFA94001C for ; Thu, 14 Oct 2021 03:50:59 -0400 (EDT) Received: from smtpin26.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id A8C348249980 for ; Thu, 14 Oct 2021 07:50:59 +0000 (UTC) X-FDA: 78694271838.26.838980E Received: from mail-lf1-f54.google.com (mail-lf1-f54.google.com [209.85.167.54]) by imf25.hostedemail.com (Postfix) with ESMTP id 1A3BFB000181 for ; Thu, 14 Oct 2021 07:50:57 +0000 (UTC) Received: by mail-lf1-f54.google.com with SMTP id u21so19933720lff.8 for ; Thu, 14 Oct 2021 00:50:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=RooZ5eoba+oXLkBGPbwUHBPuClbthLKLvnxYPQXohMk=; b=FEKnyGyCwlbBalVAvc+mEfhAa7h3OML4gx+nqy8kRNBiK6EA1u3Zf/ZOGcLv5qkMFA hGOz+R4o6d8lO/r42yKvLdLsVLLOkcIfe+LsyusnIhVRxd2wyYI9WgHEAzZsiUQDNA1Q +98mtguOfOSEFUgLnZ/OmGUVbBUTSpVjm3sRunkR6ZeIquwel5aR+It+eF62j+BrvxXm FVUdmWnoEzL5v/2yHS2T9kXKdp7Mb3yaqc4M924Evc6J+UT1e/MhgDU6rSUx62DUWrXs vre9++Me3m8lcE9yaKvPXmG+ZQIUTah8IE2HFtBdBt+J5BhKEttmsEeJzYNBLGG8UYQs AJdw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=RooZ5eoba+oXLkBGPbwUHBPuClbthLKLvnxYPQXohMk=; b=Gr8guYjp5HY25bKypU1XqWf5bPTm9cwS4itwPvMwOMNY/7rbrer1EfNOWZJiFAd7tL oFInQbcAcwO4qAk2UYCLjQ0D8qKop+vhjYzmASc99W3HYiylQjjbecRefeHt/TR4zO5L s0//jI7/rz8afnZ3+kq/Pwot6JNIPJIhm9LMCuJQJ+S0/nVZzCfIaDmQKxs1UYMmpSGs imgiXQbYzRm0cqtyiNcyRRtUBQ9CrJNlsrr6eyxdJX26QJT9uNE7xhtcDsK8MEc+iGmX te24VCJeeXPW7ig0TgRctggXpf0tKfMxHeJHFSG4IYg33VkgZmR+aZlT1fltqSs3k5km RNhw== X-Gm-Message-State: AOAM531smj3HVKrzbDQtPm+VqABaZYFdo6pSWPG4DXfqnQ/SCypZTZMd 8rT61w4KRXTxksYQR083/rA= X-Google-Smtp-Source: ABdhPJyvO63fd+K2+k9W+rncLMl5j0D2kP4AtW3RWmxBm71jlgXrePyelKff7oeRPYjkJlzRCSnlsw== X-Received: by 2002:a05:6512:314b:: with SMTP id s11mr3873277lfi.206.1634197857807; Thu, 14 Oct 2021 00:50:57 -0700 (PDT) Received: from localhost.localdomain (h-158-174-22-5.NA.cust.bahnhof.se. [158.174.22.5]) by smtp.gmail.com with ESMTPSA id t82sm172281lff.50.2021.10.14.00.50.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Oct 2021 00:50:57 -0700 (PDT) From: Rikard Falkeborn To: SeongJae Park , Andrew Morton , Naoya Horiguchi Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Rikard Falkeborn Subject: [PATCH 0/2] mm: constify static mm_walk_ops Date: Thu, 14 Oct 2021 09:50:40 +0200 Message-Id: <20211014075042.17174-1-rikard.falkeborn@gmail.com> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: 1A3BFB000181 X-Stat-Signature: 533zr8bwdj7aq9awu7ze1nayijmd4gw7 Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=FEKnyGyC; spf=pass (imf25.hostedemail.com: domain of rikard.falkeborn@gmail.com designates 209.85.167.54 as permitted sender) smtp.mailfrom=rikard.falkeborn@gmail.com; dmarc=pass (policy=none) header.from=gmail.com X-HE-Tag: 1634197857-517235 X-Bogosity: Ham, tests=bogofilter, spamicity=0.010646, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Constify a few instances of static struct mm_walk_ops that are never modified. The only usage of them is to pass their address to walk_page_range() which has a pointer to const struct mm_walk_ops as argument. Making them const allows the compiler to put them in read-only memory. Rikard Falkeborn (2): mm/damon/vaddr: constify static mm_walk_ops mm/memory_failure: constify static mm_walk_ops mm/damon/vaddr.c | 4 ++-- mm/memory-failure.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-)