* [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h
@ 2011-08-21 14:33 Axel Lin
2011-08-21 23:39 ` Ryan Mallon
2011-08-22 16:35 ` H Hartley Sweeten
0 siblings, 2 replies; 4+ messages in thread
From: Axel Lin @ 2011-08-21 14:33 UTC (permalink / raw)
To: linux-kernel; +Cc: H Hartley Sweeten, Richard Purdie, Andrew Morton
ep93xx_bl.c uses interfaces from linux/module.h,
so it should include that file. This patch fixes below build errors.
CC [M] drivers/video/backlight/ep93xx_bl.o
drivers/video/backlight/ep93xx_bl.c:138: error: 'THIS_MODULE' undeclared here (not in a function)
drivers/video/backlight/ep93xx_bl.c:158: error: expected declaration specifiers or '...' before string constant
drivers/video/backlight/ep93xx_bl.c:158: warning: data definition has no type or storage class
drivers/video/backlight/ep93xx_bl.c:158: warning: type defaults to 'int' in declaration of 'MODULE_DESCRIPTION'
drivers/video/backlight/ep93xx_bl.c:158: warning: function declaration isn't a prototype
drivers/video/backlight/ep93xx_bl.c:159: error: expected declaration specifiers or '...' before string constant
drivers/video/backlight/ep93xx_bl.c:159: warning: data definition has no type or storage class
drivers/video/backlight/ep93xx_bl.c:159: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR'
drivers/video/backlight/ep93xx_bl.c:159: warning: function declaration isn't a prototype
drivers/video/backlight/ep93xx_bl.c:160: error: expected declaration specifiers or '...' before string constant
drivers/video/backlight/ep93xx_bl.c:160: warning: data definition has no type or storage class
drivers/video/backlight/ep93xx_bl.c:160: warning: type defaults to 'int' in declaration of 'MODULE_LICENSE'
drivers/video/backlight/ep93xx_bl.c:160: warning: function declaration isn't a prototype
drivers/video/backlight/ep93xx_bl.c:161: error: expected declaration specifiers or '...' before string constant
drivers/video/backlight/ep93xx_bl.c:161: warning: data definition has no type or storage class
drivers/video/backlight/ep93xx_bl.c:161: warning: type defaults to 'int' in declaration of 'MODULE_ALIAS'
drivers/video/backlight/ep93xx_bl.c:161: warning: function declaration isn't a prototype
make[3]: *** [drivers/video/backlight/ep93xx_bl.o] Error 1
make[2]: *** [drivers/video/backlight] Error 2
make[1]: *** [drivers/video] Error 2
make: *** [drivers] Error 2
Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
drivers/video/backlight/ep93xx_bl.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/video/backlight/ep93xx_bl.c b/drivers/video/backlight/ep93xx_bl.c
index 9f1e389..b058291 100644
--- a/drivers/video/backlight/ep93xx_bl.c
+++ b/drivers/video/backlight/ep93xx_bl.c
@@ -11,7 +11,7 @@
* BRIGHT, on the Cirrus EP9307, EP9312, and EP9315 processors.
*/
-
+#include <linux/module.h>
#include <linux/platform_device.h>
#include <linux/io.h>
#include <linux/fb.h>
--
1.7.4.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h
2011-08-21 14:33 [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h Axel Lin
@ 2011-08-21 23:39 ` Ryan Mallon
2011-08-21 23:55 ` Ryan Mallon
2011-08-22 16:35 ` H Hartley Sweeten
1 sibling, 1 reply; 4+ messages in thread
From: Ryan Mallon @ 2011-08-21 23:39 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, H Hartley Sweeten, Richard Purdie, Andrew Morton
On 22/08/11 00:33, Axel Lin wrote:
> ep93xx_bl.c uses interfaces from linux/module.h,
> so it should include that file. This patch fixes below build errors.
Thanks,
Acked-by: Ryan Mallon <rmallon@gmail.com>
> CC [M] drivers/video/backlight/ep93xx_bl.o
> drivers/video/backlight/ep93xx_bl.c:138: error: 'THIS_MODULE' undeclared here (not in a function)
> drivers/video/backlight/ep93xx_bl.c:158: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:158: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:158: warning: type defaults to 'int' in declaration of 'MODULE_DESCRIPTION'
> drivers/video/backlight/ep93xx_bl.c:158: warning: function declaration isn't a prototype
> drivers/video/backlight/ep93xx_bl.c:159: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:159: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:159: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR'
> drivers/video/backlight/ep93xx_bl.c:159: warning: function declaration isn't a prototype
> drivers/video/backlight/ep93xx_bl.c:160: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:160: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:160: warning: type defaults to 'int' in declaration of 'MODULE_LICENSE'
> drivers/video/backlight/ep93xx_bl.c:160: warning: function declaration isn't a prototype
> drivers/video/backlight/ep93xx_bl.c:161: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:161: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:161: warning: type defaults to 'int' in declaration of 'MODULE_ALIAS'
> drivers/video/backlight/ep93xx_bl.c:161: warning: function declaration isn't a prototype
> make[3]: *** [drivers/video/backlight/ep93xx_bl.o] Error 1
> make[2]: *** [drivers/video/backlight] Error 2
> make[1]: *** [drivers/video] Error 2
> make: *** [drivers] Error 2
>
> Signed-off-by: Axel Lin<axel.lin@gmail.com>
> ---
> drivers/video/backlight/ep93xx_bl.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/video/backlight/ep93xx_bl.c b/drivers/video/backlight/ep93xx_bl.c
> index 9f1e389..b058291 100644
> --- a/drivers/video/backlight/ep93xx_bl.c
> +++ b/drivers/video/backlight/ep93xx_bl.c
> @@ -11,7 +11,7 @@
> * BRIGHT, on the Cirrus EP9307, EP9312, and EP9315 processors.
> */
>
> -
> +#include<linux/module.h>
> #include<linux/platform_device.h>
> #include<linux/io.h>
> #include<linux/fb.h>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h
2011-08-21 23:39 ` Ryan Mallon
@ 2011-08-21 23:55 ` Ryan Mallon
0 siblings, 0 replies; 4+ messages in thread
From: Ryan Mallon @ 2011-08-21 23:55 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, H Hartley Sweeten, Richard Purdie, Andrew Morton
On 22/08/11 09:39, Ryan Mallon wrote:
> On 22/08/11 00:33, Axel Lin wrote:
>> ep93xx_bl.c uses interfaces from linux/module.h,
>> so it should include that file. This patch fixes below build errors.
>
> Thanks,
>
> Acked-by: Ryan Mallon <rmallon@gmail.com>
Retracted. Please see my reply to the ep93xx framebuffer patch.
~Ryan
>
>> CC [M] drivers/video/backlight/ep93xx_bl.o
>> drivers/video/backlight/ep93xx_bl.c:138: error: 'THIS_MODULE'
>> undeclared here (not in a function)
>> drivers/video/backlight/ep93xx_bl.c:158: error: expected declaration
>> specifiers or '...' before string constant
>> drivers/video/backlight/ep93xx_bl.c:158: warning: data definition has
>> no type or storage class
>> drivers/video/backlight/ep93xx_bl.c:158: warning: type defaults to
>> 'int' in declaration of 'MODULE_DESCRIPTION'
>> drivers/video/backlight/ep93xx_bl.c:158: warning: function
>> declaration isn't a prototype
>> drivers/video/backlight/ep93xx_bl.c:159: error: expected declaration
>> specifiers or '...' before string constant
>> drivers/video/backlight/ep93xx_bl.c:159: warning: data definition has
>> no type or storage class
>> drivers/video/backlight/ep93xx_bl.c:159: warning: type defaults to
>> 'int' in declaration of 'MODULE_AUTHOR'
>> drivers/video/backlight/ep93xx_bl.c:159: warning: function
>> declaration isn't a prototype
>> drivers/video/backlight/ep93xx_bl.c:160: error: expected declaration
>> specifiers or '...' before string constant
>> drivers/video/backlight/ep93xx_bl.c:160: warning: data definition has
>> no type or storage class
>> drivers/video/backlight/ep93xx_bl.c:160: warning: type defaults to
>> 'int' in declaration of 'MODULE_LICENSE'
>> drivers/video/backlight/ep93xx_bl.c:160: warning: function
>> declaration isn't a prototype
>> drivers/video/backlight/ep93xx_bl.c:161: error: expected declaration
>> specifiers or '...' before string constant
>> drivers/video/backlight/ep93xx_bl.c:161: warning: data definition has
>> no type or storage class
>> drivers/video/backlight/ep93xx_bl.c:161: warning: type defaults to
>> 'int' in declaration of 'MODULE_ALIAS'
>> drivers/video/backlight/ep93xx_bl.c:161: warning: function
>> declaration isn't a prototype
>> make[3]: *** [drivers/video/backlight/ep93xx_bl.o] Error 1
>> make[2]: *** [drivers/video/backlight] Error 2
>> make[1]: *** [drivers/video] Error 2
>> make: *** [drivers] Error 2
>>
>> Signed-off-by: Axel Lin<axel.lin@gmail.com>
>> ---
>> drivers/video/backlight/ep93xx_bl.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/drivers/video/backlight/ep93xx_bl.c
>> b/drivers/video/backlight/ep93xx_bl.c
>> index 9f1e389..b058291 100644
>> --- a/drivers/video/backlight/ep93xx_bl.c
>> +++ b/drivers/video/backlight/ep93xx_bl.c
>> @@ -11,7 +11,7 @@
>> * BRIGHT, on the Cirrus EP9307, EP9312, and EP9315 processors.
>> */
>>
>> -
>> +#include<linux/module.h>
>> #include<linux/platform_device.h>
>> #include<linux/io.h>
>> #include<linux/fb.h>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h
2011-08-21 14:33 [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h Axel Lin
2011-08-21 23:39 ` Ryan Mallon
@ 2011-08-22 16:35 ` H Hartley Sweeten
1 sibling, 0 replies; 4+ messages in thread
From: H Hartley Sweeten @ 2011-08-22 16:35 UTC (permalink / raw)
To: Axel Lin, linux-kernel@vger.kernel.org; +Cc: Richard Purdie, Andrew Morton
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 3315 bytes --]
On Sunday, August 21, 2011 7:33 AM, Axel Lin wrote:
>
> ep93xx_bl.c uses interfaces from linux/module.h,
> so it should include that file. This patch fixes below build errors.
>
> CC [M] drivers/video/backlight/ep93xx_bl.o
> drivers/video/backlight/ep93xx_bl.c:138: error: 'THIS_MODULE' undeclared here (not in a function)
> drivers/video/backlight/ep93xx_bl.c:158: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:158: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:158: warning: type defaults to 'int' in declaration of 'MODULE_DESCRIPTION'
> drivers/video/backlight/ep93xx_bl.c:158: warning: function declaration isn't a prototype
> drivers/video/backlight/ep93xx_bl.c:159: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:159: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:159: warning: type defaults to 'int' in declaration of 'MODULE_AUTHOR'
> drivers/video/backlight/ep93xx_bl.c:159: warning: function declaration isn't a prototype
> drivers/video/backlight/ep93xx_bl.c:160: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:160: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:160: warning: type defaults to 'int' in declaration of 'MODULE_LICENSE'
> drivers/video/backlight/ep93xx_bl.c:160: warning: function declaration isn't a prototype
> drivers/video/backlight/ep93xx_bl.c:161: error: expected declaration specifiers or '...' before string constant
> drivers/video/backlight/ep93xx_bl.c:161: warning: data definition has no type or storage class
> drivers/video/backlight/ep93xx_bl.c:161: warning: type defaults to 'int' in declaration of 'MODULE_ALIAS'
> drivers/video/backlight/ep93xx_bl.c:161: warning: function declaration isn't a prototype
> make[3]: *** [drivers/video/backlight/ep93xx_bl.o] Error 1
> make[2]: *** [drivers/video/backlight] Error 2
> make[1]: *** [drivers/video] Error 2
> make: *** [drivers] Error 2
>
> Signed-off-by: Axel Lin <axel.lin@gmail.com>
> ---
> drivers/video/backlight/ep93xx_bl.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/video/backlight/ep93xx_bl.c b/drivers/video/backlight/ep93xx_bl.c
> index 9f1e389..b058291 100644
> --- a/drivers/video/backlight/ep93xx_bl.c
> +++ b/drivers/video/backlight/ep93xx_bl.c
> @@ -11,7 +11,7 @@
> * BRIGHT, on the Cirrus EP9307, EP9312, and EP9315 processors.
> */
>
> -
> +#include <linux/module.h>
> #include <linux/platform_device.h>
> #include <linux/io.h>
> #include <linux/fb.h>
Ah.. This was due to commit 089f5643ba "include: replace linux/module.h with
"struct module" wherever possible".
Before that commit, including <linux/platform_device.h> would pull in <linux/device.h>
which would then pull in <linux/module.h>. Now any driver using the MODULE_ macros
needs to include <linux/module.h> directly.
Looks correct to me.
Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com>
ÿôèº{.nÇ+·®+%Ëÿ±éݶ\x17¥wÿº{.nÇ+·¥{±þG«éÿ{ayº\x1dÊÚë,j\a¢f£¢·hïêÿêçz_è®\x03(éÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?¨èÚ&£ø§~á¶iOæ¬z·vØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?I¥
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-08-22 16:35 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-21 14:33 [PATCH] backlight: ep93xx_bl: add missing include of linux/module.h Axel Lin
2011-08-21 23:39 ` Ryan Mallon
2011-08-21 23:55 ` Ryan Mallon
2011-08-22 16:35 ` H Hartley Sweeten
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox