arch/m68k/coldfire/device.c:511:35: error: 'MCFEDMA_BASE' undeclared here (not in a function); did you mean 'MCFDMA_BASE0'?

From: kernel test robot
Date: Wed Mar 02 2022 - 13:56:30 EST


Hi Angelo,

FYI, the error/warning still remains.

tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fb184c4af9b9f4563e7a126219389986a71d5b5b
commit: d7e9d01ac2920959b474c6363dba269a868f4db9 m68k: add ColdFire mcf5441x eDMA platform support
date: 3 years ago
config: m68k-buildonly-randconfig-r003-20220112 (https://download.01.org/0day-ci/archive/20220303/202203030252.P752DK46-lkp@xxxxxxxxx/config)
compiler: m68k-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d7e9d01ac2920959b474c6363dba269a868f4db9
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout d7e9d01ac2920959b474c6363dba269a868f4db9
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=m68k SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

In file included from include/linux/kernel.h:10,
from arch/m68k/coldfire/device.c:11:
include/linux/scatterlist.h: In function 'sg_set_buf':
arch/m68k/include/asm/page_no.h:33:51: warning: ordered comparison of pointer with null pointer [-Wextra]
33 | #define virt_addr_valid(kaddr) (((void *)(kaddr) >= (void *)PAGE_OFFSET) && \
| ^~
include/linux/compiler.h:77:45: note: in definition of macro 'unlikely'
77 | # define unlikely(x) __builtin_expect(!!(x), 0)
| ^
include/linux/scatterlist.h:143:9: note: in expansion of macro 'BUG_ON'
143 | BUG_ON(!virt_addr_valid(buf));
| ^~~~~~
include/linux/scatterlist.h:143:17: note: in expansion of macro 'virt_addr_valid'
143 | BUG_ON(!virt_addr_valid(buf));
| ^~~~~~~~~~~~~~~
arch/m68k/coldfire/device.c: At top level:
>> arch/m68k/coldfire/device.c:511:35: error: 'MCFEDMA_BASE' undeclared here (not in a function); did you mean 'MCFDMA_BASE0'?
511 | .start = MCFEDMA_BASE,
| ^~~~~~~~~~~~
| MCFDMA_BASE0
>> arch/m68k/coldfire/device.c:512:50: error: 'MCFEDMA_SIZE' undeclared here (not in a function)
512 | .end = MCFEDMA_BASE + MCFEDMA_SIZE - 1,
| ^~~~~~~~~~~~
>> arch/m68k/coldfire/device.c:516:35: error: 'MCFEDMA_IRQ_INTR0' undeclared here (not in a function)
516 | .start = MCFEDMA_IRQ_INTR0,
| ^~~~~~~~~~~~~~~~~
>> arch/m68k/coldfire/device.c:522:35: error: 'MCFEDMA_IRQ_INTR16' undeclared here (not in a function)
522 | .start = MCFEDMA_IRQ_INTR16,
| ^~~~~~~~~~~~~~~~~~
>> arch/m68k/coldfire/device.c:528:35: error: 'MCFEDMA_IRQ_INTR56' undeclared here (not in a function)
528 | .start = MCFEDMA_IRQ_INTR56,
| ^~~~~~~~~~~~~~~~~~
>> arch/m68k/coldfire/device.c:534:35: error: 'MCFEDMA_IRQ_ERR' undeclared here (not in a function)
534 | .start = MCFEDMA_IRQ_ERR,
| ^~~~~~~~~~~~~~~


vim +511 arch/m68k/coldfire/device.c

508
509 static struct resource mcf_edma_resources[] = {
510 {
> 511 .start = MCFEDMA_BASE,
> 512 .end = MCFEDMA_BASE + MCFEDMA_SIZE - 1,
513 .flags = IORESOURCE_MEM,
514 },
515 {
> 516 .start = MCFEDMA_IRQ_INTR0,
517 .end = MCFEDMA_IRQ_INTR0 + 15,
518 .flags = IORESOURCE_IRQ,
519 .name = "edma-tx-00-15",
520 },
521 {
> 522 .start = MCFEDMA_IRQ_INTR16,
523 .end = MCFEDMA_IRQ_INTR16 + 39,
524 .flags = IORESOURCE_IRQ,
525 .name = "edma-tx-16-55",
526 },
527 {
> 528 .start = MCFEDMA_IRQ_INTR56,
529 .end = MCFEDMA_IRQ_INTR56,
530 .flags = IORESOURCE_IRQ,
531 .name = "edma-tx-56-63",
532 },
533 {
> 534 .start = MCFEDMA_IRQ_ERR,
535 .end = MCFEDMA_IRQ_ERR,
536 .flags = IORESOURCE_IRQ,
537 .name = "edma-err",
538 },
539 };
540

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