As with 9cbf61445cda ("xen/earlycpio: Drop nextoff parameter"): While
this is imported from Linux, the parameter not being pointer-to-const is
dubious in the first place and we're not plausibly going to gain a write
through it.

Signed-off-by: Jan Beulich <jbeul...@suse.com>

--- a/xen/common/earlycpio.c
+++ b/xen/common/earlycpio.c
@@ -64,7 +64,8 @@ enum cpio_fields {
  *              the match returned an empty filename string.
  */
 
-struct cpio_data __init find_cpio_data(const char *path, void *data, size_t 
len)
+struct cpio_data __init find_cpio_data(
+       const char *path, const void *data, size_t len)
 {
        const size_t cpio_header_len = 8*C_NFIELDS - 2;
        struct cpio_data cd = { NULL, 0, "" };
--- a/xen/include/xen/earlycpio.h
+++ b/xen/include/xen/earlycpio.h
@@ -9,6 +9,6 @@ struct cpio_data {
        char name[MAX_CPIO_FILE_NAME];
 };
 
-struct cpio_data find_cpio_data(const char *path, void *data, size_t len);
+struct cpio_data find_cpio_data(const char *path, const void *data, size_t 
len);
 
 #endif /* _EARLYCPIO_H */

Reply via email to