2002-01-29 22:12:34

by Mingming Cao

[permalink] [raw]
Subject: Could not compile md/raid5.c and md/multipath.c in 2.5.3-pre3

Hello,

While compiling the clean 2.5.3-pre3 kernel I found the
drivers/md/raid5.c and drivers/md/multipatch.c could not get compiled.
Here is the compiling error for raid5.c:

......
-D__KERNEL__ -I/home/ming/views/253-pre3/include -Wall
-Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer
-fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2
-march=i686 -c -o raid5.o raid5.c
In file included from raid5.c:23:
/home/ming/views/253-pre3/include/linux/raid/raid5.h:218: parse error
before `md_wait_queue_head_t'
/home/ming/views/253-pre3/include/linux/raid/raid5.h:218: warning: no
semicolon
at end of struct or union
/home/ming/views/253-pre3/include/linux/raid/raid5.h:222: parse error
before `device_lock'
......


This failure also happened for 2.5.2 kernel. Both of raid5.c and
multipatch.c use some data structures defined in md_compatible.h, which
was included in md.h before but does not exist under include/linux/raid
for now. Could someone fix this?



--
Mingming Cao


2002-01-30 01:21:04

by Evgeniy Polyakov

[permalink] [raw]
Subject: Re: Could not compile md/raid5.c and md/multipath.c in 2.5.3-pre3

On Tue, 29 Jan 2002 14:09:54 -0800
Mingming cao <[email protected]> wrote:

> Hello,

Good time of day.

> -march=i686 -c -o raid5.o raid5.c
> In file included from raid5.c:23:
> /home/ming/views/253-pre3/include/linux/raid/raid5.h:218: parse error
> before `md_wait_queue_head_t'
> /home/ming/views/253-pre3/include/linux/raid/raid5.h:218: warning: no
> semicolon
> at end of struct or union
> /home/ming/views/253-pre3/include/linux/raid/raid5.h:222: parse error
> before `device_lock'
> ......
> for now. Could someone fix this?

I hope this patch will help you.

This patch is also cc'ed to Ingo Molnar, who is one of the maintainers of
multiple discs support. Is it right, Ingo?
Or noone should annoy anyone with such things?

> --
> Mingming Cao


Evgeniy Polyakov ( s0mbre ).


Attachments:
include_linux_raid_md.diff (392.00 B)

2002-01-30 02:04:34

by Mingming Cao

[permalink] [raw]
Subject: Re: Could not compile md/raid5.c and md/multipath.c in 2.5.3-pre3

Evgeniy Polyakov wrote:
>
> On Tue, 29 Jan 2002 14:09:54 -0800
> Mingming cao <[email protected]> wrote:
>
> > Hello,
>
> Good time of day.
>
> > -march=i686 -c -o raid5.o raid5.c
> > In file included from raid5.c:23:
> > /home/ming/views/253-pre3/include/linux/raid/raid5.h:218: parse error
> > before `md_wait_queue_head_t'
> > /home/ming/views/253-pre3/include/linux/raid/raid5.h:218: warning: no
> > semicolon
> > at end of struct or union
> > /home/ming/views/253-pre3/include/linux/raid/raid5.h:222: parse error
> > before `device_lock'
> > ......
> > for now. Could someone fix this?
>
> I hope this patch will help you.
>
> This patch is also cc'ed to Ingo Molnar, who is one of the maintainers of
> multiple discs support. Is it right, Ingo?
> Or noone should annoy anyone with such things?
>
Hello Evgeniy,

I omitted similar compile errors in the last email. raid5.c and
multipath.c referenced a lot data structures defined in
md_compatible.h, besides the two you added in your fix......

Thank you for your help.
--
Mingming Cao
IBM Linux Technology Center
503-578-5024 IBM T/L: 775-5024
[email protected]
http://www.ibm.com/linux/ltc

2002-01-30 02:27:26

by Evgeniy Polyakov

[permalink] [raw]
Subject: Re: Could not compile md/raid5.c and md/multipath.c in 2.5.3-pre3

On Tue, 29 Jan 2002 18:02:29 -0800
Mingming cao <[email protected]> wrote:

> I omitted similar compile errors in the last email. raid5.c and
> multipath.c referenced a lot data structures defined in
> md_compatible.h, besides the two you added in your fix......

As you mention md_compatible.h does not exist, it was introduced in 2.5.2
patch only in drivers/md/xor.c. But in at least pre5 all structures were
correctly defined in various md_{p,u,k}.h files. I've tried to find others
undefined symbols, but cann't. So i suggest you to upgrade a bit to pre6
or pre5 kernel ;), apply my litle patch and remove mention of
md_compatible.h in drivers/md/xor.c. And feel free to write all others
erorrs, if they will appear again.

> Thank you for your help.

Good luck.

> --
> Mingming Cao


Evgeniy Polyakov ( s0mbre ).