lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ADE657CA350FB648AAC2C43247A983F001F388575247@AUSP01VMBX24.collaborationhost.net>
Date:	Mon, 22 Aug 2011 11:35:04 -0500
From:	H Hartley Sweeten <hartleys@...ionengravers.com>
To:	Axel Lin <axel.lin@...il.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
CC:	Richard Purdie <rpurdie@...ys.net>,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: RE: [PATCH] backlight: ep93xx_bl: add missing include of
 linux/module.h

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@...il.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@...ionengravers.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ