tty: rocket: fix incorrect forward declaration of ‘rp_init()’ [Linux 4.9.185]

tty: rocket: fix incorrect forward declaration of ‘rp_init()’ [Linux 4.9.185]

This Linux kernel change "tty: rocket: fix incorrect forward declaration of ‘rp_init()’" is included in the Linux 4.9.185 release. This change is authored by Linus Torvalds <torvalds [at] linux-foundation.org> on Mon May 6 11:28:23 2019 -0700. The commit for this change in Linux stable tree is a391af9 (patch) which is from upstream commit 423ea32. The same Linux upstream change may have been applied to various maintained Linux releases and you can find all Linux releases containing changes from upstream 423ea32.

tty: rocket: fix incorrect forward declaration of 'rp_init()'

[ Upstream commit 423ea3255424b954947d167681b71ded1b8fca53 ]

Make the forward declaration actually match the real function
definition, something that previous versions of gcc had just ignored.

This is another patch to fix new warnings from gcc-9 before I start the
merge window pulls.  I don't want to miss legitimate new warnings just
because my system update brought a new compiler with new warnings.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>

There are 2 lines of Linux source code added/deleted in this change. Code changes to Linux kernel are as follows.

 drivers/tty/rocket.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/rocket.c b/drivers/tty/rocket.c
index e8e8973..447d791 100644
--- a/drivers/tty/rocket.c
+++ b/drivers/tty/rocket.c
@@ -279,7 +279,7 @@ static int sInitController(CONTROLLER_T * CtlP, int CtlNum, ByteIO_t MudbacIO,
 module_param_array(pc104_4, ulong, NULL, 0);
 MODULE_PARM_DESC(pc104_4, "set interface types for ISA(PC104) board #4 (e.g. pc104_4=232,232,485,485,...");

-static int rp_init(void);
+static int __init rp_init(void);
 static void rp_cleanup_module(void);

 module_init(rp_init);

Leave a Reply

Your email address will not be published. Required fields are marked *