From: Zubin Mithra <zsm@chromium.org>
To: tglx@linutronix.de, mingo@redhat.com, bp@alien8.de,
hpa@zytor.com, linux-kernel@vger.kernel.org,
linux-pci@vger.kernel.org
Cc: groeck@chromium.org, keescook@chromium.org, zsm@chromium.org
Subject: [PATCH] x86/pci: Annotate 'pci_root_ops' with __ro_after_init
Date: Mon, 5 Nov 2018 12:17:35 -0800 [thread overview]
Message-ID: <20181105201735.72026-1-zsm@chromium.org> (raw)
When CONFIG_X86_INTEL_MID is set pci_root_ops is written to inside
intel_mid_pci_init(which is marked __init) and not modified after. This
makes pci_root_ops a suitable candidate for annotating as
__ro_after_init.
Signed-off-by: Zubin Mithra <zsm@chromium.org>
---
arch/x86/pci/common.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/pci/common.c b/arch/x86/pci/common.c
index d4ec117c1142..204ee80cfa63 100644
--- a/arch/x86/pci/common.c
+++ b/arch/x86/pci/common.c
@@ -67,7 +67,7 @@ static int pci_write(struct pci_bus *bus, unsigned int devfn, int where, int siz
devfn, where, size, value);
}
-struct pci_ops pci_root_ops = {
+struct pci_ops pci_root_ops __ro_after_init = {
.read = pci_read,
.write = pci_write,
};
--
2.19.1.930.g4563a0d9d0-goog
next reply other threads:[~2018-11-05 20:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-05 20:17 Zubin Mithra [this message]
2018-11-05 21:38 ` [PATCH] x86/pci: Annotate 'pci_root_ops' with __ro_after_init Thomas Gleixner
2018-11-05 21:57 ` Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181105201735.72026-1-zsm@chromium.org \
--to=zsm@chromium.org \
--cc=bp@alien8.de \
--cc=groeck@chromium.org \
--cc=hpa@zytor.com \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.