diff mbox

[v3,11/18] livepatch: tests: Move the .name value to .rodata

Message ID 1473626125-13683-12-git-send-email-konrad.wilk@oracle.com (mailing list archive)
State New, archived
Headers show

Commit Message

Konrad Rzeszutek Wilk Sept. 11, 2016, 8:35 p.m. UTC
Right now the contents of 'name' are all located in
the .data section. We want them in the .rodata section
so change the type to have const on them.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
---
Cc: Andrew Cooper <andrew.cooper3@citrix.com>
Cc: Jan Beulich <jbeulich@suse.com>

v3: First submission.
---
 xen/test/livepatch/xen_bye_world.c     | 2 +-
 xen/test/livepatch/xen_hello_world.c   | 2 +-
 xen/test/livepatch/xen_replace_world.c | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)
diff mbox

Patch

diff --git a/xen/test/livepatch/xen_bye_world.c b/xen/test/livepatch/xen_bye_world.c
index b75e0b1..2700f0e 100644
--- a/xen/test/livepatch/xen_bye_world.c
+++ b/xen/test/livepatch/xen_bye_world.c
@@ -11,7 +11,7 @@ 
 
 #include <public/sysctl.h>
 
-static char bye_world_patch_this_fnc[] = "xen_extra_version";
+static const char bye_world_patch_this_fnc[] = "xen_extra_version";
 extern const char *xen_bye_world(void);
 
 struct livepatch_func __section(".livepatch.funcs") livepatch_xen_bye_world = {
diff --git a/xen/test/livepatch/xen_hello_world.c b/xen/test/livepatch/xen_hello_world.c
index 472fe2e..3cd059f 100644
--- a/xen/test/livepatch/xen_hello_world.c
+++ b/xen/test/livepatch/xen_hello_world.c
@@ -12,7 +12,7 @@ 
 
 #include <public/sysctl.h>
 
-static char hello_world_patch_this_fnc[] = "xen_extra_version";
+static const char hello_world_patch_this_fnc[] = "xen_extra_version";
 extern const char *xen_hello_world(void);
 /*
  * .bss is only cleared once - during upload. Apply/revert/apply will result
diff --git a/xen/test/livepatch/xen_replace_world.c b/xen/test/livepatch/xen_replace_world.c
index a2a221a..78a8f52 100644
--- a/xen/test/livepatch/xen_replace_world.c
+++ b/xen/test/livepatch/xen_replace_world.c
@@ -10,7 +10,7 @@ 
 
 #include <public/sysctl.h>
 
-static char xen_replace_world_name[] = "xen_extra_version";
+static const char xen_replace_world_name[] = "xen_extra_version";
 extern const char *xen_replace_world(void);
 
 struct livepatch_func __section(".livepatch.funcs") livepatch_xen_replace_world = {