Module: xenomai-jki
Branch: queues/proc
Commit: 46bdade132572b98cbd808df2dc99ba8db90a0e4
URL:    
http://git.xenomai.org/?p=xenomai-jki.git;a=commit;h=46bdade132572b98cbd808df2dc99ba8db90a0e4

Author: Jan Kiszka <jan.kis...@siemens.com>
Date:   Tue Apr  6 18:12:17 2010 +0200

hal: Mark file ops of rthal_add_proc_seq const

Older kernels do not have this tag but do not touch them as well, so
perform a type cast when assigning them to proc_dir_entry.

Signed-off-by: Jan Kiszka <jan.kis...@siemens.com>

---

 include/asm-generic/hal.h |    2 +-
 ksrc/arch/generic/hal.c   |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/asm-generic/hal.h b/include/asm-generic/hal.h
index 84c1a4d..61da1b7 100644
--- a/include/asm-generic/hal.h
+++ b/include/asm-generic/hal.h
@@ -554,7 +554,7 @@ struct proc_dir_entry *rthal_add_proc_leaf(const char *name,
                                           struct proc_dir_entry *parent);
 
 struct proc_dir_entry *rthal_add_proc_seq(const char *name,
-                                         struct file_operations *fops,
+                                         const struct file_operations *fops,
                                          size_t size,
                                          struct proc_dir_entry *parent);
 #endif /* CONFIG_PROC_FS */
diff --git a/ksrc/arch/generic/hal.c b/ksrc/arch/generic/hal.c
index 8a5ec39..c2239ca 100644
--- a/ksrc/arch/generic/hal.c
+++ b/ksrc/arch/generic/hal.c
@@ -748,7 +748,7 @@ struct proc_dir_entry *rthal_add_proc_leaf(const char *name,
 EXPORT_SYMBOL_GPL(rthal_add_proc_leaf);
 
 struct proc_dir_entry *rthal_add_proc_seq(const char *name,
-                                         struct file_operations *fops,
+                                         const struct file_operations *fops,
                                          size_t size,
                                          struct proc_dir_entry *parent)
 {
@@ -758,7 +758,7 @@ struct proc_dir_entry *rthal_add_proc_seq(const char *name,
        if (entry == NULL)
                return NULL;
 
-       entry->proc_fops = fops;
+       entry->proc_fops = (struct file_operations *)fops;
        wrap_proc_dir_entry_owner(entry);
 
        if (size)


_______________________________________________
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git

Reply via email to