Hi Yunsheng,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on net-next/master]
[also build test ERROR on net/master linus/master v5.14-rc1 next-20210714]
[cannot apply to sparc-next/master]
[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/Yunsheng-Lin/add-frag-page-suppo...
base:
https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git
5e437416ff66981d8154687cfdf7de50b1d82bfc
config: sparc-defconfig (attached as .config)
compiler: sparc-linux-gcc (GCC) 9.3.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://github.com/0day-ci/linux/commit/247943d70c2069ca3fa3a272f3eb26b46...
git remote add linux-review
https://github.com/0day-ci/linux
git fetch --no-tags linux-review
Yunsheng-Lin/add-frag-page-support-in-page-pool/20210714-173612
git checkout 247943d70c2069ca3fa3a272f3eb26b463e17f4d
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=sparc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from include/linux/skbuff.h:40,
from include/linux/if_ether.h:19,
from include/linux/etherdevice.h:20,
from arch/sparc/kernel/idprom.c:13:
include/net/page_pool.h: In function 'page_pool_get_dma_addr':
> include/net/page_pool.h:209:7: error: left shift count >=
width of type [-Werror=shift-count-overflow]
209 | ret <<= 32;
| ^~~
include/net/page_pool.h: In function 'page_pool_set_dma_addr':
> include/net/page_pool.h:220:8: error: right shift count >=
width of type [-Werror=shift-count-overflow]
220 | addr >>= 32;
| ^~~
cc1: all warnings being treated as errors
vim +209 include/net/page_pool.h
200
201 #define PAGE_POOL_DMA_USE_PP_FRAG_COUNT \
202 (sizeof(dma_addr_t) > sizeof(unsigned long))
203
204 static inline dma_addr_t page_pool_get_dma_addr(struct page *page)
205 {
206 dma_addr_t ret = page->dma_addr;
207
208 if (PAGE_POOL_DMA_USE_PP_FRAG_COUNT) {
209 ret <<= 32;
210 ret |=
atomic_long_read(&page->pp_frag_count) & PAGE_MASK;
211 }
212
213 return ret;
214 }
215
216 static inline void page_pool_set_dma_addr(struct page *page, dma_addr_t addr)
217 {
218 if (PAGE_POOL_DMA_USE_PP_FRAG_COUNT) {
219 atomic_long_set(&page->pp_frag_count, addr & PAGE_MASK);
220 addr >>= 32;
221 }
222
223 page->dma_addr = addr;
224 }
225
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org