* [PATCH] s390/sclp_vt220: fix unused function warning
@ 2021-09-27 21:56 Randy Dunlap
2021-09-28 8:32 ` Heiko Carstens
0 siblings, 1 reply; 2+ messages in thread
From: Randy Dunlap @ 2021-09-27 21:56 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, Heiko Carstens, Vasily Gorbik,
Christian Borntraeger, linux-s390
When CONFIG_SCLP_VT220_TTY=y and CONFIG_SCLP_VT220_CONSOLE is not set:
../drivers/s390/char/sclp_vt220.c:771:13: warning: '__sclp_vt220_flush_buffer' defined but not used [-Wunused-function]
771 | static void __sclp_vt220_flush_buffer(void)
so move this function inside the #ifdef block where it is used.
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Heiko Carstens <hca@linux.ibm.com>
Cc: Vasily Gorbik <gor@linux.ibm.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>
Cc: linux-s390@vger.kernel.org
---
Sorry, I can't determine what the Fixes: tag for this should be
(missing some git fu).
drivers/s390/char/sclp_vt220.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- linux-next-20210927.orig/drivers/s390/char/sclp_vt220.c
+++ linux-next-20210927/drivers/s390/char/sclp_vt220.c
@@ -768,6 +768,8 @@ out_driver:
}
__initcall(sclp_vt220_tty_init);
+#ifdef CONFIG_SCLP_VT220_CONSOLE
+
static void __sclp_vt220_flush_buffer(void)
{
unsigned long flags;
@@ -784,8 +786,6 @@ static void __sclp_vt220_flush_buffer(vo
spin_unlock_irqrestore(&sclp_vt220_lock, flags);
}
-#ifdef CONFIG_SCLP_VT220_CONSOLE
-
static void
sclp_vt220_con_write(struct console *con, const char *buf, unsigned int count)
{
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] s390/sclp_vt220: fix unused function warning
2021-09-27 21:56 [PATCH] s390/sclp_vt220: fix unused function warning Randy Dunlap
@ 2021-09-28 8:32 ` Heiko Carstens
0 siblings, 0 replies; 2+ messages in thread
From: Heiko Carstens @ 2021-09-28 8:32 UTC (permalink / raw)
To: Randy Dunlap
Cc: linux-kernel, Vasily Gorbik, Christian Borntraeger, linux-s390
On Mon, Sep 27, 2021 at 02:56:47PM -0700, Randy Dunlap wrote:
> When CONFIG_SCLP_VT220_TTY=y and CONFIG_SCLP_VT220_CONSOLE is not set:
>
> ../drivers/s390/char/sclp_vt220.c:771:13: warning: '__sclp_vt220_flush_buffer' defined but not used [-Wunused-function]
> 771 | static void __sclp_vt220_flush_buffer(void)
>
> so move this function inside the #ifdef block where it is used.
>
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
> Cc: Heiko Carstens <hca@linux.ibm.com>
> Cc: Vasily Gorbik <gor@linux.ibm.com>
> Cc: Christian Borntraeger <borntraeger@de.ibm.com>
> Cc: linux-s390@vger.kernel.org
> ---
> Sorry, I can't determine what the Fixes: tag for this should be
> (missing some git fu).
It's not worth spending time to figure this out.
Applied, thanks!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-09-28 8:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-09-27 21:56 [PATCH] s390/sclp_vt220: fix unused function warning Randy Dunlap
2021-09-28 8:32 ` Heiko Carstens
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox