From 52d2e9c142c0079bba51011bb95301c986ff11bb Mon Sep 17 00:00:00 2001
From: Simon Glass <sjg@chromium.org>
Date: Wed, 23 Dec 2020 08:11:26 -0700
Subject: [PATCH] x86: apl: Use const for driver operations

Update these declarations to const to ensure that the data ends up in the
rodata section.

Signed-off-by: Simon Glass <sjg@chromium.org>
---
 arch/x86/cpu/apollolake/pmc.c    | 2 +-
 arch/x86/cpu/intel_common/p2sb.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/x86/cpu/apollolake/pmc.c b/arch/x86/cpu/apollolake/pmc.c
index 290b2cb3e7..c40065ab8c 100644
--- a/arch/x86/cpu/apollolake/pmc.c
+++ b/arch/x86/cpu/apollolake/pmc.c
@@ -205,7 +205,7 @@ static int apl_pmc_probe(struct udevice *dev)
 	return 0;
 }
 
-static struct acpi_pmc_ops apl_pmc_ops = {
+static const struct acpi_pmc_ops apl_pmc_ops = {
 	.init			= apl_pmc_fill_power_state,
 	.prev_sleep_state	= apl_prev_sleep_state,
 	.disable_tco		= apl_disable_tco,
diff --git a/arch/x86/cpu/intel_common/p2sb.c b/arch/x86/cpu/intel_common/p2sb.c
index e6edab0b05..3765eeeab0 100644
--- a/arch/x86/cpu/intel_common/p2sb.c
+++ b/arch/x86/cpu/intel_common/p2sb.c
@@ -180,7 +180,7 @@ static int p2sb_child_post_bind(struct udevice *dev)
 	return 0;
 }
 
-struct p2sb_ops p2sb_ops = {
+static const struct p2sb_ops p2sb_ops = {
 	.set_hide	= intel_p2sb_set_hide,
 };
 
-- 
2.39.5