Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1431282 > unrolled thread

undefined reference to `printk'

Started bykbuild test robot <fengguang.wu@intel.com>
First post2016-06-26 03:30 +0200
Last post2016-06-27 07:20 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  undefined reference to `printk' kbuild test robot <fengguang.wu@intel.com> - 2016-06-26 03:30 +0200
    Re: undefined reference to `printk' Yoshinori Sato <ysato@users.sourceforge.jp> - 2016-06-27 07:20 +0200

#1431282 — undefined reference to `printk'

Fromkbuild test robot <fengguang.wu@intel.com>
Date2016-06-26 03:30 +0200
Subjectundefined reference to `printk'
Message-ID<rO73A-4EC-5@gated-at.bofh.it>

[Multipart message — attachments visible in raw view] — view raw

Hi,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   da2f6aba4a21f8da3331e5251a117c52764da579
commit: 5d2acfc7b974bbd3858b4dd3f2cdc6362dd8843a kconfig: make allnoconfig disable options behind EMBEDDED and EXPERT
date:   2 years, 3 months ago
config: m32r-allnoconfig (attached as .config)
compiler: m32r-linux-gcc (GCC) 4.9.0
reproduce:
        wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 5d2acfc7b974bbd3858b4dd3f2cdc6362dd8843a
        # save the attached .config to linux build tree
        make.cross ARCH=m32r 

All errors (new ones prefixed by >>):

   arch/m32r/kernel/built-in.o: In function `default_eit_handler':
>> (.text+0x3f8): undefined reference to `printk'
   arch/m32r/kernel/built-in.o: In function `default_eit_handler':
   (.text+0x3f8): relocation truncated to fit: R_M32R_26_PCREL_RELA against undefined symbol `printk'

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[toc] | [next] | [standalone]


#1431720

FromYoshinori Sato <ysato@users.sourceforge.jp>
Date2016-06-27 07:20 +0200
Message-ID<rOx7H-4m7-1@gated-at.bofh.it>
In reply to#1431282
I think fix it.
default_eit_handler rewritten in C, it is best way.
But it test difficult.

Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
---
 arch/m32r/kernel/entry.S | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/m32r/kernel/entry.S b/arch/m32r/kernel/entry.S
index c639bfa..a71105c 100644
--- a/arch/m32r/kernel/entry.S
+++ b/arch/m32r/kernel/entry.S
@@ -419,6 +419,12 @@ ENTRY(default_eit_handler)
 infinit:
 	bra	infinit
 
+#ifndef CONFIG_PRINTK
+printk:
+	jmp	lr
+	.fillinsn
+#endif
+
 #ifdef CONFIG_ MMU
 /*
  * Access Exception handler
2.7.0

On Sun, 26 Jun 2016 10:19:50 +0900,
kbuild test robot wrote:
> 
> Hi,
> 
> FYI, the error/warning still remains.
> 
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head:   da2f6aba4a21f8da3331e5251a117c52764da579
> commit: 5d2acfc7b974bbd3858b4dd3f2cdc6362dd8843a kconfig: make allnoconfig disable options behind EMBEDDED and EXPERT
> date:   2 years, 3 months ago
> config: m32r-allnoconfig (attached as .config)
> compiler: m32r-linux-gcc (GCC) 4.9.0
> reproduce:
>         wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         git checkout 5d2acfc7b974bbd3858b4dd3f2cdc6362dd8843a
>         # save the attached .config to linux build tree
>         make.cross ARCH=m32r 
> 
> All errors (new ones prefixed by >>):
> 
>    arch/m32r/kernel/built-in.o: In function `default_eit_handler':
> >> (.text+0x3f8): undefined reference to `printk'
>    arch/m32r/kernel/built-in.o: In function `default_eit_handler':
>    (.text+0x3f8): relocation truncated to fit: R_M32R_26_PCREL_RELA against undefined symbol `printk'
> 
> ---
> 0-DAY kernel test infrastructure                Open Source Technology Center
> https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

-- 
Yoshinori Sato
<ysato@users.sourceforge.jp>

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web