Skip to contentSkip to conversation

ld.lld: error: undefined symbol: kb_cs

PATCH Applied kbuild test robot 5 participants 8 messages May 14, 2020 – Jun 9, 2020

Subsystems (3)
lore
Share & tools
lore

kbuild test robot

author build bot
#0 lore raw
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   24085f70a6e1b0cb647ec92623284641d8270637
commit: 5990cdee689c6885b27c6d969a3d58b09002b0bc lib/mpi: Fix building for powerpc with clang
date:   3 weeks ago
config: powerpc-randconfig-r034-20200514 (attached as .config)
compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project 310d32cb80a611e6384a921e85607fea05841f26)

reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# install powerpc cross compiling tool for clang build
# apt-get install binutils-powerpc-linux-gnu
git checkout 5990cdee689c6885b27c6d969a3d58b09002b0bc
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc

If you fix the issue, kindly add following tag as appropriate

All errors (new ones prefixed by >>):

>> ld.lld: error: undefined symbol: kb_cs
>>> referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28)
>>> input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a
>>> referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28)
>>> input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a
>>> referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28)
>>> input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a
>>> referenced 45 more times
--
>> ld.lld: error: undefined symbol: kb_data
>>> referenced by i8042.c:309 (drivers/input/serio/i8042.c:309)
>>> input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a
>>> referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33)
>>> input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a
>>> referenced by i8042.c:319 (drivers/input/serio/i8042.c:319)
>>> input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a
>>> referenced 15 more times

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

#1 lore raw
Quoted 3 lines · kbuild test robot
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   24085f70a6e1b0cb647ec92623284641d8270637
commit: 5990cdee689c6885b27c6d969a3d58b09002b0bc lib/mpi: Fix building for powerpc with clang

I am certain that this patch did nothing to cause this... Maybe exposed it but not the root cause.

Quoted 18 lines

date: 3 weeks ago
config: powerpc-randconfig-r034-20200514 (attached as .config)
compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project 310d32cb80a611e6384a921e85607fea05841f26) reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# install powerpc cross compiling tool for clang build
# apt-get install binutils-powerpc-linux-gnu
git checkout 5990cdee689c6885b27c6d969a3d58b09002b0bc
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc

If you fix the issue, kindly add following tag as appropriate

All errors (new ones prefixed by >>):

Quoted 1 line
Quoted 1 line

ld.lld: error: undefined symbol: kb_cs

Quoted 16 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 45 more times

--

Quoted 8 lines
Quoted 8 lines

ld.lld: error: undefined symbol: kb_data

Quoted 7 lines

referenced by i8042.c:309 (drivers/input/serio/i8042.c:309) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042.c:319 (drivers/input/serio/i8042.c:319) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 15 more times

kb_cs and kb_data are declared as extern void pointers when CONFIG_WALNUT is set, which this config does. However, it looks like the definitions of these variables were removed in
commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc"), way back in 2.6.27-rc1... So presumably, this has been broken for 12 years and nobody noticed? Probably means there is a good amount of dead code that can be removed, or we could just avoid ever selecting this driver with CONFIG_WALNUT (if it does not actually work without the special handling from i8042-ppcio.h) while removing the dead code.

Cheers,
Nathan

arch/powerpc/Kconfig +1 -1
index 924c541a9260..59b2f655e39e 100644
@@ -138,7 +138,7 @@ config PPC
 	select ARCH_HAVE_NMI_SAFE_CMPXCHG
 	select ARCH_KEEP_MEMBLOCK
 	select ARCH_MIGHT_HAVE_PC_PARPORT
-	select ARCH_MIGHT_HAVE_PC_SERIO
+	select ARCH_MIGHT_HAVE_PC_SERIO if !WALNUT
 	select ARCH_OPTIONAL_KERNEL_RWX		if ARCH_HAS_STRICT_KERNEL_RWX
 	select ARCH_SUPPORTS_ATOMIC_RMW
 	select ARCH_USE_BUILTIN_BSWAP
drivers/input/serio/i8042-ppcio.h deleted +0 -57

57 lines not on this page · raw message

drivers/input/serio/i8042.h +0 -2
index 38dc27ad3c18..eb376700dfff 100644
@@ -17,8 +17,6 @@
 #include "i8042-ip22io.h"
 #elif defined(CONFIG_SNI_RM)
 #include "i8042-snirm.h"
-#elif defined(CONFIG_PPC)
-#include "i8042-ppcio.h"
 #elif defined(CONFIG_SPARC)
 #include "i8042-sparcio.h"
 #elif defined(CONFIG_X86) || defined(CONFIG_IA64)
#2 lore raw

Remove WALNUT hacks in serio/i8042 (was Re: ld.lld: error: undefined symbol: kb_cs)

[ Cc += linuxppc-dev ]

Quoted 43 lines · Nathan Chancellor
Quoted 3 lines · kbuild test robot
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   24085f70a6e1b0cb647ec92623284641d8270637
commit: 5990cdee689c6885b27c6d969a3d58b09002b0bc lib/mpi: Fix building for powerpc with clang

I am certain that this patch did nothing to cause this... Maybe exposed it but not the root cause.

Quoted 18 lines

date: 3 weeks ago
config: powerpc-randconfig-r034-20200514 (attached as .config)
compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project 310d32cb80a611e6384a921e85607fea05841f26) reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# install powerpc cross compiling tool for clang build
# apt-get install binutils-powerpc-linux-gnu
git checkout 5990cdee689c6885b27c6d969a3d58b09002b0bc
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc

If you fix the issue, kindly add following tag as appropriate

All errors (new ones prefixed by >>):

Quoted 1 line
Quoted 1 line

ld.lld: error: undefined symbol: kb_cs

Quoted 16 lines
Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 45 more times

--

Quoted 8 lines
Quoted 8 lines

ld.lld: error: undefined symbol: kb_data

Quoted 7 lines

referenced by i8042.c:309 (drivers/input/serio/i8042.c:309) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042.c:319 (drivers/input/serio/i8042.c:319) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 15 more times

Quoted 6 lines

kb_cs and kb_data are declared as extern void pointers when CONFIG_WALNUT is set, which this config does. However, it looks like the definitions of these variables were removed in
commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc"), way back in 2.6.27-rc1... So presumably, this has been broken for 12 years and nobody noticed?

Hmm, nice. 12 years is a pretty typical time frame for finding bugs in the powerpc tree ... o_O

Our ppc40x_defconfig has CONFIG_SERIO=m, but explicitly disables CONFIG_SERIO_I8042. And walnut_defconfig disables CONFIG_SERIO.

So I guess it has a PS2 controller but most folks didn't use it?

Quoted 4 lines

Probably means there is a good amount of dead
code that can be removed, or we could just avoid ever selecting this driver with CONFIG_WALNUT (if it does not actually work without the special handling from i8042-ppcio.h) while removing the dead code.

I'm inclined to let the driver be selected, rather than carry a wart for it. I doubt anyone will ever turn it on explicitly, and if they do they can have fun debugging it.

arch/powerpc/Kconfig config PPC · line 144

Quoted 13 lines
arch/powerpc/Kconfig +1 -1
index 924c541a9260..59b2f655e39e 100644
@@ -138,7 +138,7 @@ config PPC
 	select ARCH_HAVE_NMI_SAFE_CMPXCHG
 	select ARCH_KEEP_MEMBLOCK
 	select ARCH_MIGHT_HAVE_PC_PARPORT
-	select ARCH_MIGHT_HAVE_PC_SERIO
+	select ARCH_MIGHT_HAVE_PC_SERIO if !WALNUT
 	select ARCH_OPTIONAL_KERNEL_RWX		if ARCH_HAS_STRICT_KERNEL_RWX
 	select ARCH_SUPPORTS_ATOMIC_RMW
 	select ARCH_USE_BUILTIN_BSWAP

So I'd drop this hunk.

Quoted 68 lines
drivers/input/serio/i8042-ppcio.h deleted +0 -57
deleted file mode 100644
index 391f94d9e47d..000000000000
@@ -1,57 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-only */
-#ifndef _I8042_PPCIO_H
-#define _I8042_PPCIO_H
-
-
-#if defined(CONFIG_WALNUT)
-
-#define I8042_KBD_IRQ 25
-#define I8042_AUX_IRQ 26
-
-#define I8042_KBD_PHYS_DESC "walnutps2/serio0"
-#define I8042_AUX_PHYS_DESC "walnutps2/serio1"
-#define I8042_MUX_PHYS_DESC "walnutps2/serio%d"
-
-extern void *kb_cs;
-extern void *kb_data;
-
-#define I8042_COMMAND_REG (*(int *)kb_cs)
-#define I8042_DATA_REG (*(int *)kb_data)
-
-static inline int i8042_read_data(void)
-{
-	return readb(kb_data);
-}
-
-static inline int i8042_read_status(void)
-{
-	return readb(kb_cs);
-}
-
-static inline void i8042_write_data(int val)
-{
-	writeb(val, kb_data);
-}
-
-static inline void i8042_write_command(int val)
-{
-	writeb(val, kb_cs);
-}
-
-static inline int i8042_platform_init(void)
-{
-	i8042_reset = I8042_RESET_ALWAYS;
-	return 0;
-}
-
-static inline void i8042_platform_exit(void)
-{
-}
-
-#else
-
-#include "i8042-io.h"
-
-#endif
-
-#endif /* _I8042_PPCIO_H */
drivers/input/serio/i8042.h +0 -0
index 38dc27ad3c18..eb376700dfff 100644

drivers/input/serio/i8042.h line 22

Quoted 8 lines
drivers/input/serio/i8042.h +0 -2
@@ -17,8 +17,6 @@
 #include "i8042-ip22io.h"
 #elif defined(CONFIG_SNI_RM)
 #include "i8042-snirm.h"
-#elif defined(CONFIG_PPC)
-#include "i8042-ppcio.h"
 #elif defined(CONFIG_SPARC)
 #include "i8042-sparcio.h"
 #elif defined(CONFIG_X86) || defined(CONFIG_IA64)

#elif defined(CONFIG_UNICORE32)
#include "i8042-unicore32io.h"
#else
#include "i8042-io.h"
#endif

The rest of the context is ^

Which makes it clear that your removal of the entire file results in no change when WALNUT=n.

I'm not sure if anyone really maintains that code, but this is all PPC really so I think we could merge it.

Do you want to send a proper SOB'ed patch?

cheers

#3 lore raw

PATCH 1/1 input: i8042: Remove special PowerPC handling

This causes a build error with CONFIG_WALNUT because kb_cs and kb_data were removed in commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc").

ld.lld: error: undefined symbol: kb_cs

Quoted 6 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a

ld.lld: error: undefined symbol: kb_data

Quoted 7 lines

referenced by i8042.c:309 (drivers/input/serio/i8042.c:309) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042.c:319 (drivers/input/serio/i8042.c:319) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 15 more times

Presumably since nobody has noticed this for the last 12 years, there is not anyone actually trying to use this driver so we can just remove this special walnut code and use the generic header so it builds for all configurations.

Fixes 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc")
---
 drivers/input/serio/i8042-ppcio.h | 57 -------------------------------
 drivers/input/serio/i8042.h       |  2 --
 2 files changed, 59 deletions(-)
 delete mode 100644 drivers/input/serio/i8042-ppcio.h
drivers/input/serio/i8042-ppcio.h deleted +0 -57
deleted file mode 100644
index 391f94d9e47d..000000000000
@@ -1,57 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-only */
-#ifndef _I8042_PPCIO_H
-#define _I8042_PPCIO_H
-
-
-#if defined(CONFIG_WALNUT)
-
-#define I8042_KBD_IRQ 25
-#define I8042_AUX_IRQ 26
-
-#define I8042_KBD_PHYS_DESC "walnutps2/serio0"
-#define I8042_AUX_PHYS_DESC "walnutps2/serio1"
-#define I8042_MUX_PHYS_DESC "walnutps2/serio%d"
-
-extern void *kb_cs;
-extern void *kb_data;
-
-#define I8042_COMMAND_REG (*(int *)kb_cs)
-#define I8042_DATA_REG (*(int *)kb_data)
-
-static inline int i8042_read_data(void)
-{
-	return readb(kb_data);
-}
-
-static inline int i8042_read_status(void)
-{
-	return readb(kb_cs);
-}
-
-static inline void i8042_write_data(int val)
-{
-	writeb(val, kb_data);
-}
-
-static inline void i8042_write_command(int val)
-{
-	writeb(val, kb_cs);
-}
-
-static inline int i8042_platform_init(void)
-{
-	i8042_reset = I8042_RESET_ALWAYS;
-	return 0;
-}
-
-static inline void i8042_platform_exit(void)
-{
-}
-
-#else
-
-#include "i8042-io.h"
-
-#endif
-
-#endif /* _I8042_PPCIO_H */
drivers/input/serio/i8042.h +0 -2
index 38dc27ad3c18..eb376700dfff 100644
@@ -17,8 +17,6 @@
 #include "i8042-ip22io.h"
 #elif defined(CONFIG_SNI_RM)
 #include "i8042-snirm.h"
-#elif defined(CONFIG_PPC)
-#include "i8042-ppcio.h"
 #elif defined(CONFIG_SPARC)
 #include "i8042-sparcio.h"
 #elif defined(CONFIG_X86) || defined(CONFIG_IA64)

base-commit: 72bc15d0018ebfbc9c389539d636e2e9a9002b3b

Signature · 1 line
2.27.0.rc0
reviewer Acked-by on v1 1/1
#4 lore raw

Re: [PATCH] input: i8042: Remove special PowerPC handling

[ + Dmitry & linux-input ]

Quoted 26 lines · Nathan Chancellor

This causes a build error with CONFIG_WALNUT because kb_cs and kb_data were removed in commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc").

ld.lld: error: undefined symbol: kb_cs

Quoted 6 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a

ld.lld: error: undefined symbol: kb_data

Quoted 7 lines

referenced by i8042.c:309 (drivers/input/serio/i8042.c:309) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042.c:319 (drivers/input/serio/i8042.c:319) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 15 more times

Presumably since nobody has noticed this for the last 12 years, there is not anyone actually trying to use this driver so we can just remove this special walnut code and use the generic header so it builds for all configurations.

Quoted 8 lines
Fixes 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc")
---
 drivers/input/serio/i8042-ppcio.h | 57 -------------------------------
 drivers/input/serio/i8042.h       |  2 --
 2 files changed, 59 deletions(-)
 delete mode 100644 drivers/input/serio/i8042-ppcio.h

This LGTM.

I assumed drivers/input/serio would be pretty quiet, but there's actually some commits to it in linux-next. So perhaps this should go via the input tree.

Dmitry do you want to take this, or should I take it via powerpc?

Original patch is here:
https://lore.kernel.org/lkml/[email protected]

cheers

Quoted 80 lines
drivers/input/serio/i8042-ppcio.h deleted +0 -57
deleted file mode 100644
index 391f94d9e47d..000000000000
@@ -1,57 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-only */
-#ifndef _I8042_PPCIO_H
-#define _I8042_PPCIO_H
-
-
-#if defined(CONFIG_WALNUT)
-
-#define I8042_KBD_IRQ 25
-#define I8042_AUX_IRQ 26
-
-#define I8042_KBD_PHYS_DESC "walnutps2/serio0"
-#define I8042_AUX_PHYS_DESC "walnutps2/serio1"
-#define I8042_MUX_PHYS_DESC "walnutps2/serio%d"
-
-extern void *kb_cs;
-extern void *kb_data;
-
-#define I8042_COMMAND_REG (*(int *)kb_cs)
-#define I8042_DATA_REG (*(int *)kb_data)
-
-static inline int i8042_read_data(void)
-{
-	return readb(kb_data);
-}
-
-static inline int i8042_read_status(void)
-{
-	return readb(kb_cs);
-}
-
-static inline void i8042_write_data(int val)
-{
-	writeb(val, kb_data);
-}
-
-static inline void i8042_write_command(int val)
-{
-	writeb(val, kb_cs);
-}
-
-static inline int i8042_platform_init(void)
-{
-	i8042_reset = I8042_RESET_ALWAYS;
-	return 0;
-}
-
-static inline void i8042_platform_exit(void)
-{
-}
-
-#else
-
-#include "i8042-io.h"
-
-#endif
-
-#endif /* _I8042_PPCIO_H */
drivers/input/serio/i8042.h +0 -2
index 38dc27ad3c18..eb376700dfff 100644
@@ -17,8 +17,6 @@
 #include "i8042-ip22io.h"
 #elif defined(CONFIG_SNI_RM)
 #include "i8042-snirm.h"
-#elif defined(CONFIG_PPC)
-#include "i8042-ppcio.h"
 #elif defined(CONFIG_SPARC)
 #include "i8042-sparcio.h"
 #elif defined(CONFIG_X86) || defined(CONFIG_IA64)

base-commit: 72bc15d0018ebfbc9c389539d636e2e9a9002b3b

Signature · 1 line
2.27.0.rc0
maintainer Acked-by
#5 lore raw

Re: [PATCH] input: i8042: Remove special PowerPC handling

Hi Michael,

Quoted 42 lines · Michael Ellerman

[ + Dmitry & linux-input ]

Quoted 26 lines · Nathan Chancellor

This causes a build error with CONFIG_WALNUT because kb_cs and kb_data were removed in commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc").

ld.lld: error: undefined symbol: kb_cs

Quoted 6 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a

ld.lld: error: undefined symbol: kb_data

Quoted 7 lines

referenced by i8042.c:309 (drivers/input/serio/i8042.c:309) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042.c:319 (drivers/input/serio/i8042.c:319) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 15 more times

Presumably since nobody has noticed this for the last 12 years, there is not anyone actually trying to use this driver so we can just remove this special walnut code and use the generic header so it builds for all configurations.

Quoted 8 lines
Fixes 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc")
---
 drivers/input/serio/i8042-ppcio.h | 57 -------------------------------
 drivers/input/serio/i8042.h       |  2 --
 2 files changed, 59 deletions(-)
 delete mode 100644 drivers/input/serio/i8042-ppcio.h

This LGTM.

Quoted 8 lines

I assumed drivers/input/serio would be pretty quiet, but there's actually some commits to it in linux-next. So perhaps this should go via the input tree.

Dmitry do you want to take this, or should I take it via powerpc?

Original patch is here:
https://lore.kernel.org/lkml/[email protected]

I'm fine with you taking it through powerpc.

Also, while I have your attention ;), could you please ack or take
https://lore.kernel.org/lkml/20191002214854.GA114387@dtor-ws/ as I believe this is the last user or input_polled_dev API and I would like to drop it from the tree.

Thanks!

Signature · 1 line
Dmitry
#6 lore raw

Re: [PATCH] input: i8042: Remove special PowerPC handling

Quoted 49 lines · Dmitry Torokhov

Hi Michael,

Quoted 46 lines · Michael Ellerman

[ + Dmitry & linux-input ]

Quoted 26 lines · Nathan Chancellor

This causes a build error with CONFIG_WALNUT because kb_cs and kb_data were removed in commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc").

ld.lld: error: undefined symbol: kb_cs

Quoted 6 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a

ld.lld: error: undefined symbol: kb_data

Quoted 7 lines

referenced by i8042.c:309 (drivers/input/serio/i8042.c:309) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:33 (drivers/input/serio/i8042-ppcio.h:33) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042.c:319 (drivers/input/serio/i8042.c:319) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced 15 more times

Presumably since nobody has noticed this for the last 12 years, there is not anyone actually trying to use this driver so we can just remove this special walnut code and use the generic header so it builds for all configurations.

Quoted 8 lines
Fixes 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc")
---
 drivers/input/serio/i8042-ppcio.h | 57 -------------------------------
 drivers/input/serio/i8042.h       |  2 --
 2 files changed, 59 deletions(-)
 delete mode 100644 drivers/input/serio/i8042-ppcio.h

This LGTM.

I assumed drivers/input/serio would be pretty quiet, but there's actually some commits to it in linux-next. So perhaps this should go via the input tree.

Quoted 8 lines
Quoted 4 lines

Dmitry do you want to take this, or should I take it via powerpc?

Original patch is here:
https://lore.kernel.org/lkml/[email protected]

I'm fine with you taking it through powerpc.

Thanks.

Quoted 4 lines

Also, while I have your attention ;), could you please ack or take
https://lore.kernel.org/lkml/20191002214854.GA114387@dtor-ws/ as I believe this is the last user or input_polled_dev API and I would like to drop it from the tree.

Ooof. Sorry, you are very patient :)

I have put it in my next-test.

In future feel free to send me mail off-list, or ping me on irc, if I haven't picked something up after several months!

cheers

#7 lore raw

Re: [PATCH] input: i8042: Remove special PowerPC handling

In reply to Nathan Chancellor
Quoted 5 lines · Nathan Chancellor

This causes a build error with CONFIG_WALNUT because kb_cs and kb_data were removed in commit 917f0af9e5a9 ("powerpc: Remove arch/ppc and include/asm-ppc").

ld.lld: error: undefined symbol: kb_cs

Quoted 8 lines
Quoted 6 lines

referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a referenced by i8042-ppcio.h:28 (drivers/input/serio/i8042-ppcio.h:28) input/serio/i8042.o:(__i8042_command) in archive drivers/built-in.a

[...]

Applied to powerpc/next.

[1/1] input: i8042 - Remove special PowerPC handling

      https://git.kernel.org/powerpc/c/e4f4ffa8a98c24a4ab482669b1e2b4cfce3f52f4

cheers