Jens Nerche <[EMAIL PROTECTED]> wrote:

> >Note the function argument types 
> >  Linux 2.0.36:   int (*get_info)(char *, char **, off_t, int, int);
> >  Linux 2.3.29:   typedef int (get_info_t)(char *, char **, off_t, int);
> >
> >2.3.29 has one argument less.

> May be. I'm referring to Kernel 2.3.39.

There is no difference between 2.3.39 and 2.3.29 in this respect.

> In linux/include/linux/proc_fs.h is written:
> 
> extern inline struct proc_dir_entry *create_proc_info_entry(const char *name,
>       mode_t mode, struct proc_dir_entry *base, get_info_t *get_info)
> 
> Means: four parameters, last is get_info_t *. 

You are misunderstanding.  I am talking about the parameters to 
the function passed as 'get_info', *not* the create_proc_info_entry 
function itself.

Note that get_info_t is of course *still* a function pointer type,
look at the typedef. *Those* arguments are the problem.

To repeat: this a real bug, and can only be fixed by solving the
real problem; *any* 'solution' using a type cast is broken.

Bye,
Ulrich
 

Reply via email to