All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/3] Determine the number of DMA channels by 'dma-channels' property
@ 2022-01-14  9:17 ` Zong Li
  0 siblings, 0 replies; 13+ messages in thread
From: Zong Li @ 2022-01-14  9:17 UTC (permalink / raw)
  To: robh+dt, paul.walmsley, palmer, aou, krzysztof.kozlowski,
	conor.dooley, geert, bin.meng, green.wan, vkoul, dmaengine,
	devicetree, linux-kernel, linux-riscv
  Cc: Zong Li

The PDMA driver currently assumes there are four channels by default, it
might cause the error if there is actually less than four channels.
Change that by getting number of channel dynamically from device tree.
For backwards-compatible, it uses the default value (i.e. 4) when there
is no 'dma-channels' information in dts.

This patch set contains the dts and dt-bindings change.

Changed in v3:
 - Fix allocating wrong size
 - Return error if 'dma-channels' is larger than maximum

Changed in v2:
 - Rebase on tag v5.16
 - Use 4 as default value of dma-channels

Zong Li (3):
  riscv: dts: Add dma-channels property in dma node
  dt-bindings: Add dma-channels for pdma device node
  dmaengine: sf-pdma: Get number of channel by device tree

 .../bindings/dma/sifive,fu540-c000-pdma.yaml  |  7 +++++++
 .../boot/dts/microchip/microchip-mpfs.dtsi    |  1 +
 arch/riscv/boot/dts/sifive/fu540-c000.dtsi    |  1 +
 drivers/dma/sf-pdma/Makefile                  |  2 ++
 drivers/dma/sf-pdma/sf-pdma.c                 | 20 ++++++++++++-------
 drivers/dma/sf-pdma/sf-pdma.h                 |  8 ++------
 6 files changed, 26 insertions(+), 13 deletions(-)

-- 
2.31.1


^ permalink raw reply	[flat|nested] 13+ messages in thread
* Re: [PATCH v3 3/3] dmaengine: sf-pdma: Get number of channel by device tree
@ 2022-01-14 17:22 ` kernel test robot
  0 siblings, 0 replies; 13+ messages in thread
From: kernel test robot @ 2022-01-14 17:22 UTC (permalink / raw)
  Cc: kbuild-all, llvm

In-Reply-To: <91a8fb6dff811b36db951ee98d955ad14a2a30eb.1642151791.git.zong.li@sifive.com>
References: <91a8fb6dff811b36db951ee98d955ad14a2a30eb.1642151791.git.zong.li@sifive.com>
TO: Zong Li <zong.li@sifive.com>
TO: robh+dt@kernel.org
TO: paul.walmsley@sifive.com
TO: palmer@dabbelt.com
TO: aou@eecs.berkeley.edu
TO: krzysztof.kozlowski@canonical.com
TO: conor.dooley@microchip.com
TO: geert@linux-m68k.org
TO: bin.meng@windriver.com
TO: green.wan@sifive.com
TO: vkoul@kernel.org

Hi Zong,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on vkoul-dmaengine/next]
[also build test WARNING on v5.16]
[cannot apply to robh/for-next next-20220114]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Zong-Li/Determine-the-number-of-DMA-channels-by-dma-channels-property/20220114-172017
base:   https://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine.git next
config: x86_64-randconfig-a001 (https://download.01.org/0day-ci/archive/20220115/202201150129.P4syQvOh-lkp@intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 82c8aca93488730ce8f66101e0f3538f14b551dd)
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://github.com/0day-ci/linux/commit/efa33512fd463fd6e29750992df1d40513eb5a7c
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Zong-Li/Determine-the-number-of-DMA-channels-by-dma-channels-property/20220114-172017
        git checkout efa33512fd463fd6e29750992df1d40513eb5a7c
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/dma/

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

All warnings (new ones prefixed by >>):

>> drivers/dma/sf-pdma/sf-pdma.o: warning: objtool: dma_cookie_complete()+0x40: unreachable instruction

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

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2022-01-17  1:29 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-14  9:17 [PATCH v3 0/3] Determine the number of DMA channels by 'dma-channels' property Zong Li
2022-01-14  9:17 ` Zong Li
2022-01-14  9:17 ` [PATCH v3 1/3] riscv: dts: Add dma-channels property in dma node Zong Li
2022-01-14  9:17   ` Zong Li
2022-01-14  9:17 ` [PATCH v3 2/3] dt-bindings: Add dma-channels for pdma device node Zong Li
2022-01-14  9:17   ` Zong Li
2022-01-14  9:17 ` [PATCH v3 3/3] dmaengine: sf-pdma: Get number of channel by device tree Zong Li
2022-01-14  9:17   ` Zong Li
2022-01-14 17:32   ` kernel test robot
2022-01-14 19:16   ` kernel test robot
2022-01-17  1:29     ` Zong Li
  -- strict thread matches above, loose matches on Subject: below --
2022-01-14 17:22 kernel test robot
2022-01-14 17:22 ` kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.