Bug 210055 - staging: ralink-gdma: build error due to unmet dependency for DMA_ENGINE by DMA_RALINK
Summary: staging: ralink-gdma: build error due to unmet dependency for DMA_ENGINE by D...
Status: NEW
Alias: None
Product: Drivers
Classification: Unclassified
Component: Staging (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: drivers_staging@kernel-bugs.osdl.org
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-04 18:05 UTC by Necip Fazil Yildiran
Modified: 2020-11-04 18:05 UTC (History)
3 users (show)

See Also:
Kernel Version: 5.10-rc1
Subsystem:
Regression: No
Bisected commit-id:


Attachments
reproduce.tar.gz (104.59 KB, application/gzip)
2020-11-04 18:05 UTC, Necip Fazil Yildiran
Details

Description Necip Fazil Yildiran 2020-11-04 18:05:49 UTC
Created attachment 293477 [details]
reproduce.tar.gz

Attachment (reproduce.tar.gz) content:
 - sample.config: Config file to reproduce the bug.
 - build_out.txt: Output of Kbuild including the error messages.

When DMA_RALINK is enabled and DMADEVICES is disabled, it results in the
following Kbuild warnings:

WARNING: unmet direct dependencies detected for DMA_ENGINE
  Depends on [n]: DMADEVICES [=n]
  Selected by [y]:
  - DMA_RALINK [=y] && STAGING [=y] && RALINK [=y] && !SOC_RT288X [=n]

WARNING: unmet direct dependencies detected for DMA_VIRTUAL_CHANNELS
  Depends on [n]: DMADEVICES [=n]
  Selected by [y]:
  - DMA_RALINK [=y] && STAGING [=y] && RALINK [=y] && !SOC_RT288X [=n]

Building the kernel fails due to this unmet direct dependency issue as follows:

[...]
/home/necip/0day/gcc-9.3.0-nolibc/mips-linux/bin/mips-linux-ld: drivers/staging/ralink-gdma/ralink-gdma.o: in function `gdma_dma_remove':
ralink-gdma.c:(.text+0x1d4): undefined reference to `dma_async_device_unregister'
[...]
Makefile:1162: recipe for target 'vmlinux' failed
make: *** [vmlinux] Error 1

Steps to reproduce the bug for v5.10-rc1:
  1. wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
  2. chmod +x ~/bin/make.cross
  3. tar -xvf reproduce.tar.gz # sample.config and build_out.txt
  4. cp sample.config path/to/linux-source-v5.10-rc1/.config
  5. cd path/to/linux-source-v5.10-rc1/
  6. ~/bin/make.cross ARCH=mips clean
  7. ~/bin/make.cross ARCH=mips olddefconfig # unmet direct dependency warning
  8. ~/bin/make.cross ARCH=mips # should have a build error

The output for the steps [6-8] can be found in build_out.txt.

Thanks,
Necip

Note You need to log in before you can comment on or make changes to this bug.