Skip to contentSkip to conversation

net: fec: fix build error at m68k platform

PATCH Applied Frank Li 4 participants 4 messages Oct 3, 2014 – Oct 6, 2014

Subsystems (3)

v1 of 2 Applied Latest is v2 →

lore
Share & tools
lore

Frank Li

author
#0 lore raw

PATCH 1/1 net: fec: fix build error at m68k platform

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 1b7bde6d659d30f171259cc2dfba8e5dab34e735

  # save the attached .config to linux build tree
  make.cross ARCH=m68k

All error/warnings:

drivers/net/ethernet/freescale/fec_main.c: In function 'fec_enet_rx_queue':

Quoted 1 line
Quoted 1 line

drivers/net/ethernet/freescale/fec_main.c:1470:3: error: implicit declaration of function 'prefetch' [-Werror=implicit-function-declaration]

      prefetch(skb->data - NET_IP_ALIGN);
      ^

cc1: some warnings being treated as errors

missed included prefetch.h

---
 drivers/net/ethernet/freescale/fec_main.c | 1 +
 1 file changed, 1 insertion(+)
drivers/net/ethernet/freescale/fec_main.c +1 -0
index 1f07db8..e190eb0 100644
@@ -57,6 +57,7 @@
 #include <linux/regulator/consumer.h>
 #include <linux/if_vlan.h>
 #include <linux/pinctrl/consumer.h>
+#include <linux/prefetch.h>
 
 #include <asm/cacheflush.h>
 
Signature · 1 line
1.9.1
#1 lore raw
Quoted 5 lines · Frank Li

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 1b7bde6d659d30f171259cc2dfba8e5dab34e735

  # save the attached .config to linux build tree

There is no attached config ;-)

Quoted 5 lines

make.cross ARCH=m68k

All error/warnings:

drivers/net/ethernet/freescale/fec_main.c: In function 'fec_enet_rx_queue':

Quoted 8 lines
Quoted 1 line
Quoted 1 line

drivers/net/ethernet/freescale/fec_main.c:1470:3: error: implicit declaration of function 'prefetch' [-Werror=implicit-function-declaration]

      prefetch(skb->data - NET_IP_ALIGN);
      ^

cc1: some warnings being treated as errors

missed included prefetch.h

It seems you missed the Reported-by: kbuild test robot <[email protected]> tag.

#2 lore raw
Quoted 8 lines · Fabio Estevam
Quoted 5 lines · Frank Li

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 1b7bde6d659d30f171259cc2dfba8e5dab34e735

  # save the attached .config to linux build tree

There is no attached config ;-)

It is copy from kbuild report.

Can I change to
config: m68k-m5275evb_defconfig (attached as .config)

Quoted 11 lines
Quoted 11 lines

make.cross ARCH=m68k

All error/warnings:

drivers/net/ethernet/freescale/fec_main.c: In function 'fec_enet_rx_queue':

Quoted 1 line
Quoted 1 line

drivers/net/ethernet/freescale/fec_main.c:1470:3: error: implicit declaration of function 'prefetch' [-Werror=implicit-function-declaration]

      prefetch(skb->data - NET_IP_ALIGN);
      ^

cc1: some warnings being treated as errors

Quoted 6 lines
Quoted 3 lines

missed included prefetch.h

It seems you missed the Reported-by: kbuild test robot <[email protected]> tag.

Okay I can add it.

maintainer Applied
#3 lore raw
In reply to Frank Li

From: Frank Li <[email protected]>
Date: Fri, 3 Oct 2014 12:00:31 -0700

Quoted 10 lines

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 1b7bde6d659d30f171259cc2dfba8e5dab34e735

  # save the attached .config to linux build tree
  make.cross ARCH=m68k

All error/warnings:

drivers/net/ethernet/freescale/fec_main.c: In function 'fec_enet_rx_queue':

Quoted 8 lines
Quoted 1 line
Quoted 1 line

drivers/net/ethernet/freescale/fec_main.c:1470:3: error: implicit declaration of function 'prefetch' [-Werror=implicit-function-declaration]

      prefetch(skb->data - NET_IP_ALIGN);
      ^

cc1: some warnings being treated as errors

missed included prefetch.h

Applied, thanks Frank.