* [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd()
@ 2021-02-24 21:55 ` Randy Dunlap
0 siblings, 0 replies; 6+ messages in thread
From: Randy Dunlap @ 2021-02-24 21:55 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, kernel test robot, Daniel Vetter, Nick Desaulniers,
linux-fbdev, dri-devel, Bartlomiej Zolnierkiewicz, Sam Ravnborg,
David Airlie, Jani Nikula
The previously added stubs for aty_{ld,}st_lcd() make it
so that these functions are used regardless of the config
options that were guarding them, so remove the #ifdef/#endif
lines and make their declarations always visible.
This fixes build warnings that were reported by clang:
drivers/video/fbdev/aty/atyfb_base.c:180:6: warning: no previous prototype for function 'aty_st_lcd' [-Wmissing-prototypes]
void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
^
drivers/video/fbdev/aty/atyfb_base.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
drivers/video/fbdev/aty/atyfb_base.c:183:5: warning: no previous prototype for function 'aty_ld_lcd' [-Wmissing-prototypes]
u32 aty_ld_lcd(int index, const struct atyfb_par *par)
^
drivers/video/fbdev/aty/atyfb_base.c:183:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
u32 aty_ld_lcd(int index, const struct atyfb_par *par)
They should not be marked as static since they are used in
mach64_ct.c.
Fixes: bfa5782b9caa ("fbdev: atyfb: add stubs for aty_{ld,st}_lcd()")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Reported-by: kernel test robot <lkp@intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Nick Desaulniers <ndesaulniers@google.com>
Cc: linux-fbdev@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: David Airlie <airlied@linux.ie>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
---
drivers/video/fbdev/aty/atyfb.h | 3 ---
1 file changed, 3 deletions(-)
--- linux-next-20210219.orig/drivers/video/fbdev/aty/atyfb.h
+++ linux-next-20210219/drivers/video/fbdev/aty/atyfb.h
@@ -287,11 +287,8 @@ static inline void aty_st_8(int regindex
#endif
}
-#if defined(CONFIG_PMAC_BACKLIGHT) || defined (CONFIG_FB_ATY_GENERIC_LCD) || \
-defined (CONFIG_FB_ATY_BACKLIGHT)
extern void aty_st_lcd(int index, u32 val, const struct atyfb_par *par);
extern u32 aty_ld_lcd(int index, const struct atyfb_par *par);
-#endif
/*
* DAC operations
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd()
@ 2021-02-24 21:55 ` Randy Dunlap
0 siblings, 0 replies; 6+ messages in thread
From: Randy Dunlap @ 2021-02-24 21:55 UTC (permalink / raw)
To: linux-kernel
Cc: linux-fbdev, kernel test robot, Bartlomiej Zolnierkiewicz,
David Airlie, Daniel Vetter, Randy Dunlap, Nick Desaulniers,
dri-devel, Sam Ravnborg
The previously added stubs for aty_{ld,}st_lcd() make it
so that these functions are used regardless of the config
options that were guarding them, so remove the #ifdef/#endif
lines and make their declarations always visible.
This fixes build warnings that were reported by clang:
drivers/video/fbdev/aty/atyfb_base.c:180:6: warning: no previous prototype for function 'aty_st_lcd' [-Wmissing-prototypes]
void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
^
drivers/video/fbdev/aty/atyfb_base.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
drivers/video/fbdev/aty/atyfb_base.c:183:5: warning: no previous prototype for function 'aty_ld_lcd' [-Wmissing-prototypes]
u32 aty_ld_lcd(int index, const struct atyfb_par *par)
^
drivers/video/fbdev/aty/atyfb_base.c:183:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
u32 aty_ld_lcd(int index, const struct atyfb_par *par)
They should not be marked as static since they are used in
mach64_ct.c.
Fixes: bfa5782b9caa ("fbdev: atyfb: add stubs for aty_{ld,st}_lcd()")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Reported-by: kernel test robot <lkp@intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Nick Desaulniers <ndesaulniers@google.com>
Cc: linux-fbdev@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: David Airlie <airlied@linux.ie>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
---
drivers/video/fbdev/aty/atyfb.h | 3 ---
1 file changed, 3 deletions(-)
--- linux-next-20210219.orig/drivers/video/fbdev/aty/atyfb.h
+++ linux-next-20210219/drivers/video/fbdev/aty/atyfb.h
@@ -287,11 +287,8 @@ static inline void aty_st_8(int regindex
#endif
}
-#if defined(CONFIG_PMAC_BACKLIGHT) || defined (CONFIG_FB_ATY_GENERIC_LCD) || \
-defined (CONFIG_FB_ATY_BACKLIGHT)
extern void aty_st_lcd(int index, u32 val, const struct atyfb_par *par);
extern u32 aty_ld_lcd(int index, const struct atyfb_par *par);
-#endif
/*
* DAC operations
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd()
2021-02-24 21:55 ` Randy Dunlap
@ 2021-02-24 22:07 ` Nick Desaulniers
-1 siblings, 0 replies; 6+ messages in thread
From: Nick Desaulniers @ 2021-02-24 22:07 UTC (permalink / raw)
To: Randy Dunlap
Cc: LKML, kernel test robot, Daniel Vetter, linux-fbdev, dri-devel,
Bartlomiej Zolnierkiewicz, Sam Ravnborg, David Airlie,
Jani Nikula
On Wed, Feb 24, 2021 at 1:55 PM Randy Dunlap <rdunlap@infradead.org> wrote:
>
> The previously added stubs for aty_{ld,}st_lcd() make it
> so that these functions are used regardless of the config
> options that were guarding them, so remove the #ifdef/#endif
> lines and make their declarations always visible.
> This fixes build warnings that were reported by clang:
Yes, though I think GCC would warn similarly with W=1 builds as well,
which was set for the 0day bot report.
>
> drivers/video/fbdev/aty/atyfb_base.c:180:6: warning: no previous prototype for function 'aty_st_lcd' [-Wmissing-prototypes]
> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
> ^
> drivers/video/fbdev/aty/atyfb_base.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
>
> drivers/video/fbdev/aty/atyfb_base.c:183:5: warning: no previous prototype for function 'aty_ld_lcd' [-Wmissing-prototypes]
> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
> ^
> drivers/video/fbdev/aty/atyfb_base.c:183:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
>
> They should not be marked as static since they are used in
> mach64_ct.c.
Probably don't need to be marked extern either (since that's the
implicit default), but I don't feel strongly about it.
Thanks for sending a cleanup for this.
Acked-by: Nick Desaulniers <ndesaulniers@google.com>
>
> Fixes: bfa5782b9caa ("fbdev: atyfb: add stubs for aty_{ld,st}_lcd()")
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
> Reported-by: kernel test robot <lkp@intel.com>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Cc: Nick Desaulniers <ndesaulniers@google.com>
> Cc: linux-fbdev@vger.kernel.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
> Cc: Sam Ravnborg <sam@ravnborg.org>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> ---
> drivers/video/fbdev/aty/atyfb.h | 3 ---
> 1 file changed, 3 deletions(-)
>
> --- linux-next-20210219.orig/drivers/video/fbdev/aty/atyfb.h
> +++ linux-next-20210219/drivers/video/fbdev/aty/atyfb.h
> @@ -287,11 +287,8 @@ static inline void aty_st_8(int regindex
> #endif
> }
>
> -#if defined(CONFIG_PMAC_BACKLIGHT) || defined (CONFIG_FB_ATY_GENERIC_LCD) || \
> -defined (CONFIG_FB_ATY_BACKLIGHT)
> extern void aty_st_lcd(int index, u32 val, const struct atyfb_par *par);
> extern u32 aty_ld_lcd(int index, const struct atyfb_par *par);
> -#endif
>
> /*
> * DAC operations
--
Thanks,
~Nick Desaulniers
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd()
@ 2021-02-24 22:07 ` Nick Desaulniers
0 siblings, 0 replies; 6+ messages in thread
From: Nick Desaulniers @ 2021-02-24 22:07 UTC (permalink / raw)
To: Randy Dunlap
Cc: linux-fbdev, kernel test robot, Bartlomiej Zolnierkiewicz,
David Airlie, Daniel Vetter, LKML, dri-devel, Sam Ravnborg
On Wed, Feb 24, 2021 at 1:55 PM Randy Dunlap <rdunlap@infradead.org> wrote:
>
> The previously added stubs for aty_{ld,}st_lcd() make it
> so that these functions are used regardless of the config
> options that were guarding them, so remove the #ifdef/#endif
> lines and make their declarations always visible.
> This fixes build warnings that were reported by clang:
Yes, though I think GCC would warn similarly with W=1 builds as well,
which was set for the 0day bot report.
>
> drivers/video/fbdev/aty/atyfb_base.c:180:6: warning: no previous prototype for function 'aty_st_lcd' [-Wmissing-prototypes]
> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
> ^
> drivers/video/fbdev/aty/atyfb_base.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
>
> drivers/video/fbdev/aty/atyfb_base.c:183:5: warning: no previous prototype for function 'aty_ld_lcd' [-Wmissing-prototypes]
> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
> ^
> drivers/video/fbdev/aty/atyfb_base.c:183:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
>
> They should not be marked as static since they are used in
> mach64_ct.c.
Probably don't need to be marked extern either (since that's the
implicit default), but I don't feel strongly about it.
Thanks for sending a cleanup for this.
Acked-by: Nick Desaulniers <ndesaulniers@google.com>
>
> Fixes: bfa5782b9caa ("fbdev: atyfb: add stubs for aty_{ld,st}_lcd()")
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
> Reported-by: kernel test robot <lkp@intel.com>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Cc: Nick Desaulniers <ndesaulniers@google.com>
> Cc: linux-fbdev@vger.kernel.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
> Cc: Sam Ravnborg <sam@ravnborg.org>
> Cc: David Airlie <airlied@linux.ie>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> ---
> drivers/video/fbdev/aty/atyfb.h | 3 ---
> 1 file changed, 3 deletions(-)
>
> --- linux-next-20210219.orig/drivers/video/fbdev/aty/atyfb.h
> +++ linux-next-20210219/drivers/video/fbdev/aty/atyfb.h
> @@ -287,11 +287,8 @@ static inline void aty_st_8(int regindex
> #endif
> }
>
> -#if defined(CONFIG_PMAC_BACKLIGHT) || defined (CONFIG_FB_ATY_GENERIC_LCD) || \
> -defined (CONFIG_FB_ATY_BACKLIGHT)
> extern void aty_st_lcd(int index, u32 val, const struct atyfb_par *par);
> extern u32 aty_ld_lcd(int index, const struct atyfb_par *par);
> -#endif
>
> /*
> * DAC operations
--
Thanks,
~Nick Desaulniers
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd()
2021-02-24 22:07 ` Nick Desaulniers
@ 2021-02-24 22:17 ` Randy Dunlap
-1 siblings, 0 replies; 6+ messages in thread
From: Randy Dunlap @ 2021-02-24 22:17 UTC (permalink / raw)
To: Nick Desaulniers
Cc: LKML, kernel test robot, Daniel Vetter, linux-fbdev, dri-devel,
Bartlomiej Zolnierkiewicz, Sam Ravnborg, David Airlie,
Jani Nikula
On 2/24/21 2:07 PM, Nick Desaulniers wrote:
> On Wed, Feb 24, 2021 at 1:55 PM Randy Dunlap <rdunlap@infradead.org> wrote:
>>
>> The previously added stubs for aty_{ld,}st_lcd() make it
>> so that these functions are used regardless of the config
>> options that were guarding them, so remove the #ifdef/#endif
>> lines and make their declarations always visible.
>> This fixes build warnings that were reported by clang:
>
> Yes, though I think GCC would warn similarly with W=1 builds as well,
> which was set for the 0day bot report.
>
<knocks head> I should enable that until it hurts too much.
>>
>> drivers/video/fbdev/aty/atyfb_base.c:180:6: warning: no previous prototype for function 'aty_st_lcd' [-Wmissing-prototypes]
>> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
>> ^
>> drivers/video/fbdev/aty/atyfb_base.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
>>
>> drivers/video/fbdev/aty/atyfb_base.c:183:5: warning: no previous prototype for function 'aty_ld_lcd' [-Wmissing-prototypes]
>> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
>> ^
>> drivers/video/fbdev/aty/atyfb_base.c:183:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
>>
>> They should not be marked as static since they are used in
>> mach64_ct.c.
>
> Probably don't need to be marked extern either (since that's the
> implicit default), but I don't feel strongly about it.
Yeah, I was just leaving it as it was...
> Thanks for sending a cleanup for this.
> Acked-by: Nick Desaulniers <ndesaulniers@google.com>
>
>>
>> Fixes: bfa5782b9caa ("fbdev: atyfb: add stubs for aty_{ld,st}_lcd()")
>> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
>> Reported-by: kernel test robot <lkp@intel.com>
>> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
>> Cc: Nick Desaulniers <ndesaulniers@google.com>
>> Cc: linux-fbdev@vger.kernel.org
>> Cc: dri-devel@lists.freedesktop.org
>> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
>> Cc: Sam Ravnborg <sam@ravnborg.org>
>> Cc: David Airlie <airlied@linux.ie>
>> Cc: Jani Nikula <jani.nikula@linux.intel.com>
>> ---
>> drivers/video/fbdev/aty/atyfb.h | 3 ---
>> 1 file changed, 3 deletions(-)
--
~Randy
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd()
@ 2021-02-24 22:17 ` Randy Dunlap
0 siblings, 0 replies; 6+ messages in thread
From: Randy Dunlap @ 2021-02-24 22:17 UTC (permalink / raw)
To: Nick Desaulniers
Cc: linux-fbdev, kernel test robot, Bartlomiej Zolnierkiewicz,
David Airlie, Daniel Vetter, LKML, dri-devel, Sam Ravnborg
On 2/24/21 2:07 PM, Nick Desaulniers wrote:
> On Wed, Feb 24, 2021 at 1:55 PM Randy Dunlap <rdunlap@infradead.org> wrote:
>>
>> The previously added stubs for aty_{ld,}st_lcd() make it
>> so that these functions are used regardless of the config
>> options that were guarding them, so remove the #ifdef/#endif
>> lines and make their declarations always visible.
>> This fixes build warnings that were reported by clang:
>
> Yes, though I think GCC would warn similarly with W=1 builds as well,
> which was set for the 0day bot report.
>
<knocks head> I should enable that until it hurts too much.
>>
>> drivers/video/fbdev/aty/atyfb_base.c:180:6: warning: no previous prototype for function 'aty_st_lcd' [-Wmissing-prototypes]
>> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
>> ^
>> drivers/video/fbdev/aty/atyfb_base.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>> void aty_st_lcd(int index, u32 val, const struct atyfb_par *par)
>>
>> drivers/video/fbdev/aty/atyfb_base.c:183:5: warning: no previous prototype for function 'aty_ld_lcd' [-Wmissing-prototypes]
>> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
>> ^
>> drivers/video/fbdev/aty/atyfb_base.c:183:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
>> u32 aty_ld_lcd(int index, const struct atyfb_par *par)
>>
>> They should not be marked as static since they are used in
>> mach64_ct.c.
>
> Probably don't need to be marked extern either (since that's the
> implicit default), but I don't feel strongly about it.
Yeah, I was just leaving it as it was...
> Thanks for sending a cleanup for this.
> Acked-by: Nick Desaulniers <ndesaulniers@google.com>
>
>>
>> Fixes: bfa5782b9caa ("fbdev: atyfb: add stubs for aty_{ld,st}_lcd()")
>> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
>> Reported-by: kernel test robot <lkp@intel.com>
>> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
>> Cc: Nick Desaulniers <ndesaulniers@google.com>
>> Cc: linux-fbdev@vger.kernel.org
>> Cc: dri-devel@lists.freedesktop.org
>> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
>> Cc: Sam Ravnborg <sam@ravnborg.org>
>> Cc: David Airlie <airlied@linux.ie>
>> Cc: Jani Nikula <jani.nikula@linux.intel.com>
>> ---
>> drivers/video/fbdev/aty/atyfb.h | 3 ---
>> 1 file changed, 3 deletions(-)
--
~Randy
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-02-24 23:03 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-24 21:55 [PATCH -next] fbdev: atyfb: always declare aty_{ld,st}_lcd() Randy Dunlap
2021-02-24 21:55 ` Randy Dunlap
2021-02-24 22:07 ` Nick Desaulniers
2021-02-24 22:07 ` Nick Desaulniers
2021-02-24 22:17 ` Randy Dunlap
2021-02-24 22:17 ` Randy Dunlap
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.