diff mbox series

[v1,4/4] x86/microcode: use const qualifier for microcode buffer

Message ID 934b1959c740f9ee401f2740478d61cdaa138c72.1579727989.git.elnikety@amazon.com (mailing list archive)
State New, archived
Headers show
Series x86/microcode: Improve documentation and code | expand

Commit Message

Eslam Elnikety Jan. 22, 2020, 10:30 p.m. UTC
The buffer holding the microcode bits should be marked as const.

Signed-off-by: Eslam Elnikety <elnikety@amazon.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
---
 xen/arch/x86/microcode.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/xen/arch/x86/microcode.c b/xen/arch/x86/microcode.c
index a662a7f438..0639551173 100644
--- a/xen/arch/x86/microcode.c
+++ b/xen/arch/x86/microcode.c
@@ -88,7 +88,7 @@  static enum {
  * memory.
  */
 struct ucode_mod_blob {
-    void *data;
+    const void *data;
     size_t size;
 };
 
@@ -753,7 +753,7 @@  int microcode_update_one(bool start_update)
 int __init early_microcode_update_cpu(void)
 {
     int rc = 0;
-    void *data = NULL;
+    const void *data = NULL;
     size_t len;
     struct microcode_patch *patch;