* [leon-rdma:dmabuf-vfio 39/44] arch/powerpc/platforms/ps3/system-bus.c:594:3: warning: non-void function 'ps3_ioc0_map_phys' should return a value
@ 2025-09-19 21:10 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-09-19 21:10 UTC (permalink / raw)
To: Leon Romanovsky; +Cc: llvm, oe-kbuild-all
tree: https://git.kernel.org/pub/scm/linux/kernel/git/leon/linux-rdma.git dmabuf-vfio
head: d42f66e173967159357a213dd04777137478de3b
commit: 05219b5f489decdb1f4b89b4eeaf14206d2a3f39 [39/44] powerpc: Convert to physical address DMA mapping
config: powerpc-allyesconfig (https://download.01.org/0day-ci/archive/20250920/202509200518.VAevT8GF-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 7c861bcedf61607b6c087380ac711eb7ff918ca6)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250920/202509200518.VAevT8GF-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202509200518.VAevT8GF-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from <built-in>:3:
In file included from include/linux/compiler_types.h:171:
include/linux/compiler-clang.h:28:9: warning: '__SANITIZE_ADDRESS__' macro redefined [-Wmacro-redefined]
28 | #define __SANITIZE_ADDRESS__
| ^
<built-in>:352:9: note: previous definition is here
352 | #define __SANITIZE_ADDRESS__ 1
| ^
>> arch/powerpc/platforms/ps3/system-bus.c:594:3: warning: non-void function 'ps3_ioc0_map_phys' should return a value [-Wreturn-mismatch]
594 | return;
| ^
2 warnings generated.
vim +/ps3_ioc0_map_phys +594 arch/powerpc/platforms/ps3/system-bus.c
581
582 static dma_addr_t ps3_ioc0_map_phys(struct device *_dev, phys_addr_t phys,
583 size_t size,
584 enum dma_data_direction direction,
585 unsigned long attrs)
586 {
587 struct ps3_system_bus_device *dev = ps3_dev_to_system_bus_dev(_dev);
588 int result;
589 dma_addr_t bus_addr;
590 u64 iopte_flag;
591 void *ptr = phys_to_virt(phys);
592
593 if (attrs & DMA_ATTR_MMIO)
> 594 return;
595
596 iopte_flag = CBE_IOPTE_M;
597 switch (direction) {
598 case DMA_BIDIRECTIONAL:
599 iopte_flag |= CBE_IOPTE_PP_R | CBE_IOPTE_PP_W | CBE_IOPTE_SO_RW;
600 break;
601 case DMA_TO_DEVICE:
602 iopte_flag |= CBE_IOPTE_PP_R | CBE_IOPTE_SO_R;
603 break;
604 case DMA_FROM_DEVICE:
605 iopte_flag |= CBE_IOPTE_PP_W | CBE_IOPTE_SO_RW;
606 break;
607 default:
608 /* not happened */
609 BUG();
610 }
611 result = ps3_dma_map(dev->d_region, (unsigned long)ptr, size,
612 &bus_addr, iopte_flag);
613
614 if (result) {
615 pr_debug("%s:%d: ps3_dma_map failed (%d)\n",
616 __func__, __LINE__, result);
617 }
618 return bus_addr;
619 }
620
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-09-19 21:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-19 21:10 [leon-rdma:dmabuf-vfio 39/44] arch/powerpc/platforms/ps3/system-bus.c:594:3: warning: non-void function 'ps3_ioc0_map_phys' should return a value 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.