2009-06-03 08:44:25

by Stephen Rothwell

[permalink] [raw]
Subject: linux-next: ubi tree build failure

Hi Artem,

Today's linux-next build (powerpc ppc44x_defconfig) failed like this:

drivers/mtd/ubi/gluebi.c: In function 'gluebi_get_device':
drivers/mtd/ubi/gluebi.c:126: error: implicit declaration of function 'IS_ERR'
drivers/mtd/ubi/gluebi.c:129: error: implicit declaration of function 'PTR_ERR'

Introduced by commit ec5c514efde253de7f28668c88bbae26d2a293de ("UBI: make
gluebi a separate module") from the ubi tree. I guess the conversion
managed to remove an implicit include of linux/err.h.

I have reverted that commit for today. I then needed to also revert
commit 518ceef0c9ca97023e45ae46aedaefa240c690a6 ("UBI: remove built-in
gluebi") to make it build again.
--
Cheers,
Stephen Rothwell [email protected]
http://www.canb.auug.org.au/~sfr/


Attachments:
(No filename) (776.00 B)
(No filename) (197.00 B)
Download all attachments

2009-06-03 08:46:40

by Artem Bityutskiy

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

Hi,

Stephen Rothwell wrote:
> Today's linux-next build (powerpc ppc44x_defconfig) failed like this:
>
> drivers/mtd/ubi/gluebi.c: In function 'gluebi_get_device':
> drivers/mtd/ubi/gluebi.c:126: error: implicit declaration of function 'IS_ERR'
> drivers/mtd/ubi/gluebi.c:129: error: implicit declaration of function 'PTR_ERR'
>
> Introduced by commit ec5c514efde253de7f28668c88bbae26d2a293de ("UBI: make
> gluebi a separate module") from the ubi tree. I guess the conversion
> managed to remove an implicit include of linux/err.h.
>
> I have reverted that commit for today. I then needed to also revert
> commit 518ceef0c9ca97023e45ae46aedaefa240c690a6 ("UBI: remove built-in
> gluebi") to make it build again.

My fault. Will be fixed shortly, thank you!

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)

2009-06-03 11:27:40

by Artem Bityutskiy

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

Stephen Rothwell wrote:
> Today's linux-next build (powerpc ppc44x_defconfig) failed like this:
>
> drivers/mtd/ubi/gluebi.c: In function 'gluebi_get_device':
> drivers/mtd/ubi/gluebi.c:126: error: implicit declaration of function 'IS_ERR'
> drivers/mtd/ubi/gluebi.c:129: error: implicit declaration of function 'PTR_ERR'

It is strange that I do not see these errors on my x86_86

> Introduced by commit ec5c514efde253de7f28668c88bbae26d2a293de ("UBI: make
> gluebi a separate module") from the ubi tree. I guess the conversion
> managed to remove an implicit include of linux/err.h.
>
> I have reverted that commit for today. I then needed to also revert
> commit 518ceef0c9ca97023e45ae46aedaefa240c690a6 ("UBI: remove built-in
> gluebi") to make it build again.

Hmm, this means bisection problems, which I'd also like to fix.
But this commit builds just fine for me as well. Would be nice
to see what are the errors.

Any suggestions what I could do to reproduce the build issues?
I'll try at least now to build this on x86 (32-bit).

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)

2009-06-03 12:56:04

by Artem Bityutskiy

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

Artem Bityutskiy wrote:
> Stephen Rothwell wrote:
>> Today's linux-next build (powerpc ppc44x_defconfig) failed like this:
>>
>> drivers/mtd/ubi/gluebi.c: In function 'gluebi_get_device':
>> drivers/mtd/ubi/gluebi.c:126: error: implicit declaration of function 'IS_ERR'
>> drivers/mtd/ubi/gluebi.c:129: error: implicit declaration of function 'PTR_ERR'
>
> It is strange that I do not see these errors on my x86_86
>
>> Introduced by commit ec5c514efde253de7f28668c88bbae26d2a293de ("UBI: make
>> gluebi a separate module") from the ubi tree. I guess the conversion
>> managed to remove an implicit include of linux/err.h.
>>
>> I have reverted that commit for today. I then needed to also revert
>> commit 518ceef0c9ca97023e45ae46aedaefa240c690a6 ("UBI: remove built-in
>> gluebi") to make it build again.
>
> Hmm, this means bisection problems, which I'd also like to fix.
> But this commit builds just fine for me as well. Would be nice
> to see what are the errors.
>
> Any suggestions what I could do to reproduce the build issues?
> I'll try at least now to build this on x86 (32-bit).

Did not see compile error on x86 as well. Anyway, I have added more
includes which seem to be missed. Hopefully this problem is fixed
now. Thanks!

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)

2009-06-03 13:07:53

by Artem Bityutskiy

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

dmitry pervushin wrote:
> On Wed, 2009-06-03 at 15:55 +0300, Artem Bityutskiy wrote:
>> Did not see compile error on x86 as well. Anyway, I have added more
>> includes which seem to be missed. Hopefully this problem is fixed
>> now. Thanks!
> however it builds ok on arm too, adding #include <linux/err.h> should
> fix this..

Yeah, just did this. Added also linux/mutex.h which we also missed.

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)

2009-06-03 13:12:36

by dmitry pervushin

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

On Wed, 2009-06-03 at 15:55 +0300, Artem Bityutskiy wrote:
> Did not see compile error on x86 as well. Anyway, I have added more
> includes which seem to be missed. Hopefully this problem is fixed
> now. Thanks!
however it builds ok on arm too, adding #include <linux/err.h> should
fix this..

2009-06-05 00:58:54

by Stephen Rothwell

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

Hi Artem,

On Wed, 03 Jun 2009 14:26:46 +0300 Artem Bityutskiy <[email protected]> wrote:
>
> Stephen Rothwell wrote:
> > Today's linux-next build (powerpc ppc44x_defconfig) failed like this:
> >
> > drivers/mtd/ubi/gluebi.c: In function 'gluebi_get_device':
> > drivers/mtd/ubi/gluebi.c:126: error: implicit declaration of function 'IS_ERR'
> > drivers/mtd/ubi/gluebi.c:129: error: implicit declaration of function 'PTR_ERR'
>
> It is strange that I do not see these errors on my x86_86

The above was a build for a 32 bit powerpc platform. This is an instance
of a general issue when an API is used without explicitly including the
header files that define the API. The needed header file may be included
by some convoluted path that depends on the architecture being built or
even the particular configuration.

> Any suggestions what I could do to reproduce the build issues?
> I'll try at least now to build this on x86 (32-bit).

Always directly include the header files for APIs you use ...

I see that this particular problem is now fixed, thanks.
--
Cheers,
Stephen Rothwell [email protected]
http://www.canb.auug.org.au/~sfr/


Attachments:
(No filename) (1.15 kB)
(No filename) (197.00 B)
Download all attachments

2009-06-05 05:55:19

by Artem Bityutskiy

[permalink] [raw]
Subject: Re: linux-next: ubi tree build failure

Stephen Rothwell wrote:
> Always directly include the header files for APIs you use ...

Yes, right, those were forgotten.

> I see that this particular problem is now fixed, thanks.

Good, thanks!

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)