2.4.10-pre12 sysrq.c compile error
A message that is not in the archive (sent off-list or not yet received): [email protected]
From: [email protected]
Subject: Linux PPC Developer Digest V34 #19
Date: Thu, 20 Sep 2001 00:00:59 -0500
Quoted 6 lines
Date: Wed, 19 Sep 2001 17:34:26 -0400
From: Stefan Jeglinski <[email protected]>
Subject: 2.4.10-pre12sysrq.ccompile errorrsynced mvista today,
linuxppc_2_4:
Quoted 10 lines
sysrq.c:35: conflicting types for
wakeup_bdflush' /usr/src/linuxppc_2_4/include/linux/fs.h:1347: previous declaration ofwakeup_bdflush'
make[3]: *** [sysrq.o] Error 1
make[3]: Leaving directory `/usr/src/linuxppc_2_4/drivers/char' make[2]: *** [first_rule] Error 2
make[2]: Leaving directory `/usr/src/linuxppc_2_4/drivers/char' make[1]: *** [_subdir_char] Error 2
make[1]: Leaving directory `/usr/src/linuxppc_2_4/drivers'
make: *** [_dir_drivers] Error 2
`wakeup_bdflush' was defines in two defrent files.
linuxppc_2_4_devel/drivers/char/sysrq.c (line: 35) extern void wakeup_bdflush(int);
linuxppc_2_4_devel/include/linux/fs.h (line: 1347) extern void wakeup_bdflush(void);
MATSUURA Takanori @ Division of Protein Chemistry,
Institute for Protein Research, Osaka University, Japan
E-Mail: [email protected]
Web Page: http://chux1.protein.osaka-u.ac.jp/~t-matsuu/
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
From: MATSUURA Takanori <[email protected]>
To: [email protected]
Quoted 9 lines
Quoted 8 lines
of `wakeup_bdflush'
make[3]: *** [sysrq.o] Error 1
make[3]: Leaving directory `/usr/src/linuxppc_2_4/drivers/char' make[2]: *** [first_rule] Error 2
make[2]: Leaving directory `/usr/src/linuxppc_2_4/drivers/char' make[1]: *** [_subdir_char] Error 2
make[1]: Leaving directory `/usr/src/linuxppc_2_4/drivers'
make: *** [_dir_drivers] Error 2
Quoted 8 lines
`wakeup_bdflush' was defines in two defrent files.
linuxppc_2_4_devel/drivers/char/sysrq.c(line: 35) extern voidwakeup_bdflush(int);
linuxppc_2_4_devel/include/linux/fs.h(line: 1347) extern voidwakeup_bdflush(void);
if it's same extern , it's no problem.
Different paramenter is no good.
Kaoru
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Quoted 6 lines
Quoted 6 lines
`wakeup_bdflush' was defines in two defrent files.
linuxppc_2_4_devel/drivers/char/sysrq.c(line: 35)
extern voidwakeup_bdflush(int);
Quoted 6 lines
Quoted 3 lines
linuxppc_2_4_devel/include/linux/fs.h(line: 1347) extern voidwakeup_bdflush(void);if it's same extern , it's no problem.
Different paramenter is no good.
Right. I should have supplied more info about what I have tried.
I attempted to make everything consistent each way. IOW, I have made the function definition and extern declarations all with a void argument, and also all with an int argument. In one case, the compiler error is "too many arguments in wakeup_bdflush" and in the other case the compiler error is "too few arguments in wakeup_bdflush".
I have noted numerous instances of wakeup_bdflush() and wakeup_bdflush(0) but I'm not sure this is an issue.
There's an inconsistency here that first appeared straightforward to me but now I'm not sure of the changes that are needed.
I rsynced this morning but still the same result.
Stefan Jeglinski
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Quoted 3 lines
There's an inconsistency here that first appeared straightforward to me but now I'm not sure of the changes that are needed.
Sorry, I should note that to build this kernel I'm using gcc-2.95.2-1i and accompanying parts (and I have glibc-2.1.3-5a, but I would think that irrelevant). Could the compiler be an issue?
Stefan Jeglinski
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
From: Stefan Jeglinski <[email protected]>
To: [email protected]
Subject: Re: 2.4.10-pre12 sysrq.c compile error
Date: Thu, 20 Sep 2001 10:52:13 -0400
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
`wakeup_bdflush' was defines in two defrent files.
linuxppc_2_4_devel/drivers/char/sysrq.c(line: 35)
extern voidwakeup_bdflush(int);
Quoted 8 lines
Quoted 6 lines
Quoted 3 lines
linuxppc_2_4_devel/include/linux/fs.h(line: 1347) extern voidwakeup_bdflush(void);if it's same extern , it's no problem.
Different paramenter is no good.Right. I should have supplied more info about what I have tried.
Look at fs/buffer.c line2748 where the real function is in. so That is void wakeup_bdflush(void)
Kaoru
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
From: Stefan Jeglinski <[email protected]>
To: [email protected]
Subject: Re: 2.4.10-pre12 sysrq.c compile error
Date: Thu, 20 Sep 2001 10:52:13 -0400
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
`wakeup_bdflush' was defines in two defrent files.
linuxppc_2_4_devel/drivers/char/sysrq.c(line: 35)
extern voidwakeup_bdflush(int);
change to extern void wakeup_bdflush(void);
Quoted 10 lines
Quoted 7 lines
Quoted 4 lines
linuxppc_2_4_devel/include/linux/fs.h(line: 1347) extern voidwakeup_bdflush(void);if it's same extern , it's no problem.
Different paramenter is no good.I have noted numerous instances of
wakeup_bdflush()and
wakeup_bdflush() is correct.
Kaoru
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Re: 2.4.10-pre12 sysrq.c compile error (solved)
Thanks, Kaoru!
Sorry, no patch yet. I'll do one if my next rsync doesn't have it fixed :-)
All extern declarations should be
extern void wakeup_bdflush(void);
definition should be:
void wakeup_bdflush(void);
and all calls should be:
wakeup_bdflush();
Stefan Jeglinski
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/