All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Alexander Lobakin <aleksander.lobakin@intel.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [alobakin:idpf-libie 11/51] include/net/page_pool/helpers.h:416:2: error: call to undeclared function 'dma_check_sync'; ISO C99 and later do not support implicit function declarations
Date: Thu, 22 Feb 2024 01:08:33 +0800	[thread overview]
Message-ID: <202402220122.C8QLXl9Z-lkp@intel.com> (raw)

tree:   https://github.com/alobakin/linux idpf-libie
head:   29cca1ea6c555a8b97694e38f18926da7969dcfe
commit: 366859db976ac1f430583a7ce8a1c4e9e63d589f [11/51] page_pool: add DMA-sync-for-CPU inline helper
config: um-x86_64_defconfig (https://download.01.org/0day-ci/archive/20240222/202402220122.C8QLXl9Z-lkp@intel.com/config)
compiler: clang version 15.0.7 (https://github.com/llvm/llvm-project.git 8dfdcc7b7bf66834a761bd8de445840ef68e4d1a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240222/202402220122.C8QLXl9Z-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/202402220122.C8QLXl9Z-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from net/core/skbuff.c:41:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:11:
   In file included from arch/um/include/asm/hardirq.h:5:
   In file included from include/asm-generic/hardirq.h:17:
   In file included from include/linux/irq.h:20:
   In file included from include/linux/io.h:13:
   In file included from arch/um/include/asm/io.h:24:
   include/asm-generic/io.h:547:31: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           val = __raw_readb(PCI_IOBASE + addr);
                             ~~~~~~~~~~ ^
   include/asm-generic/io.h:560:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           val = __le16_to_cpu((__le16 __force)__raw_readw(PCI_IOBASE + addr));
                                                           ~~~~~~~~~~ ^
   include/uapi/linux/byteorder/little_endian.h:37:51: note: expanded from macro '__le16_to_cpu'
   #define __le16_to_cpu(x) ((__force __u16)(__le16)(x))
                                                     ^
   In file included from net/core/skbuff.c:41:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:11:
   In file included from arch/um/include/asm/hardirq.h:5:
   In file included from include/asm-generic/hardirq.h:17:
   In file included from include/linux/irq.h:20:
   In file included from include/linux/io.h:13:
   In file included from arch/um/include/asm/io.h:24:
   include/asm-generic/io.h:573:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
                                                           ~~~~~~~~~~ ^
   include/uapi/linux/byteorder/little_endian.h:35:51: note: expanded from macro '__le32_to_cpu'
   #define __le32_to_cpu(x) ((__force __u32)(__le32)(x))
                                                     ^
   In file included from net/core/skbuff.c:41:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:11:
   In file included from arch/um/include/asm/hardirq.h:5:
   In file included from include/asm-generic/hardirq.h:17:
   In file included from include/linux/irq.h:20:
   In file included from include/linux/io.h:13:
   In file included from arch/um/include/asm/io.h:24:
   include/asm-generic/io.h:584:33: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           __raw_writeb(value, PCI_IOBASE + addr);
                               ~~~~~~~~~~ ^
   include/asm-generic/io.h:594:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           __raw_writew((u16 __force)cpu_to_le16(value), PCI_IOBASE + addr);
                                                         ~~~~~~~~~~ ^
   include/asm-generic/io.h:604:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           __raw_writel((u32 __force)cpu_to_le32(value), PCI_IOBASE + addr);
                                                         ~~~~~~~~~~ ^
   include/asm-generic/io.h:692:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           readsb(PCI_IOBASE + addr, buffer, count);
                  ~~~~~~~~~~ ^
   include/asm-generic/io.h:700:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           readsw(PCI_IOBASE + addr, buffer, count);
                  ~~~~~~~~~~ ^
   include/asm-generic/io.h:708:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           readsl(PCI_IOBASE + addr, buffer, count);
                  ~~~~~~~~~~ ^
   include/asm-generic/io.h:717:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           writesb(PCI_IOBASE + addr, buffer, count);
                   ~~~~~~~~~~ ^
   include/asm-generic/io.h:726:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           writesw(PCI_IOBASE + addr, buffer, count);
                   ~~~~~~~~~~ ^
   include/asm-generic/io.h:735:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
           writesl(PCI_IOBASE + addr, buffer, count);
                   ~~~~~~~~~~ ^
   In file included from net/core/skbuff.c:43:
   In file included from include/linux/inet.h:42:
   In file included from include/net/net_namespace.h:43:
   In file included from include/linux/skbuff.h:28:
   include/linux/dma-mapping.h:389:2: error: call to undeclared function '__dma_sync_single_for_cpu'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration]
           __dma_sync_single_for_cpu(dev, addr + offset, size, dir);
           ^
   include/linux/dma-mapping.h:389:2: note: did you mean 'dma_sync_single_for_cpu'?
   include/linux/dma-mapping.h:235:20: note: 'dma_sync_single_for_cpu' declared here
   static inline void dma_sync_single_for_cpu(struct device *dev, dma_addr_t addr,
                      ^
   include/linux/dma-mapping.h:397:2: error: call to undeclared function '__dma_sync_single_for_device'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration]
           __dma_sync_single_for_device(dev, addr + offset, size, dir);
           ^
   include/linux/dma-mapping.h:397:2: note: did you mean 'dma_sync_single_for_device'?
   include/linux/dma-mapping.h:239:20: note: 'dma_sync_single_for_device' declared here
   static inline void dma_sync_single_for_device(struct device *dev,
                      ^
   In file included from net/core/skbuff.c:77:
>> include/net/page_pool/helpers.h:416:2: error: call to undeclared function 'dma_check_sync'; ISO C99 and later do not support implicit function declarations [-Werror,-Wimplicit-function-declaration]
           dma_sync_single_range_for_cpu(pool->p.dev,
           ^
   include/linux/dma-mapping.h:401:2: note: expanded from macro 'dma_sync_single_range_for_cpu'
           dma_check_sync(__dma_sync_single_range_for_cpu, d, a, o, s, r)
           ^
   12 warnings and 3 errors generated.


vim +/dma_check_sync +416 include/net/page_pool/helpers.h

   399	
   400	/**
   401	 * page_pool_dma_sync_for_cpu - sync Rx page for CPU after it's written by HW
   402	 * @pool: &page_pool the @page belongs to
   403	 * @page: page to sync
   404	 * @offset: offset from page start to "hard" start if using PP frags
   405	 * @dma_sync_size: size of the data written to the page
   406	 *
   407	 * Can be used as a shorthand to sync Rx pages before accessing them in the
   408	 * driver. Caller must ensure the pool was created with ``PP_FLAG_DMA_MAP``.
   409	 * Note that this version performs DMA sync unconditionally, even if the
   410	 * associated PP doesn't perform sync-for-device.
   411	 */
   412	static inline void page_pool_dma_sync_for_cpu(const struct page_pool *pool,
   413						      const struct page *page,
   414						      u32 offset, u32 dma_sync_size)
   415	{
 > 416		dma_sync_single_range_for_cpu(pool->p.dev,
   417					      page_pool_get_dma_addr(page),
   418					      offset + pool->p.offset, dma_sync_size,
   419					      page_pool_get_dma_dir(pool));
   420	}
   421	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

             reply	other threads:[~2024-02-21 17:11 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-21 17:08 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-01-14 12:20 [alobakin:idpf-libie 11/51] include/net/page_pool/helpers.h:416:2: error: call to undeclared function 'dma_check_sync'; ISO C99 and later do not support implicit function declarations kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202402220122.C8QLXl9Z-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=aleksander.lobakin@intel.com \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.