Hi Shubhankar, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on hp-parisc/for-next] [also build test WARNING on v5.12 next-20210428] [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/Shubhankar-Kuranagatti/drivers-parisc-ccio-dma-c-Added-tab-insead-of-spaces/20210428-235316 base: https://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux.git for-next config: parisc-defconfig (attached as .config) compiler: hppa-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/d69bc48f1b1d854da39ad6d1809d2a009d9d4de3 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Shubhankar-Kuranagatti/drivers-parisc-ccio-dma-c-Added-tab-insead-of-spaces/20210428-235316 git checkout d69bc48f1b1d854da39ad6d1809d2a009d9d4de3 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross W=1 ARCH=parisc If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): drivers/parisc/ccio-dma.c: In function 'ccio_alloc_range': drivers/parisc/ccio-dma.c:378:4: error: 'else' without a previous 'if' 378 | } else if (pages_needed <= 16) { | ^~~~ drivers/parisc/ccio-dma.c:380:4: error: 'else' without a previous 'if' 380 | } else if (pages_needed <= 32) { | ^~~~ drivers/parisc/ccio-dma.c:386:4: error: 'else' without a previous 'if' 386 | } else { | ^~~~ drivers/parisc/ccio-dma.c:431:1: error: invalid storage class for function 'ccio_free_range' 431 | ccio_free_range(struct ioc *ioc, dma_addr_t iova, unsigned long pages_mapped) | ^~~~~~~~~~~~~~~ >> drivers/parisc/ccio-dma.c:430:1: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement] 430 | static void | ^~~~~~ drivers/parisc/ccio-dma.c:555:1: warning: 'inline' is not at beginning of declaration [-Wold-style-declaration] 555 | static void CCIO_INLINE | ^~~~~~ drivers/parisc/ccio-dma.c:556:1: error: invalid storage class for function 'ccio_io_pdir_entry' 556 | ccio_io_pdir_entry(u64 *pdir_ptr, space_t sid, unsigned long vba, | ^~~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:627:1: error: invalid storage class for function 'ccio_clear_io_tlb' 627 | ccio_clear_io_tlb(struct ioc *ioc, dma_addr_t iovp, size_t byte_cnt) | ^~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:660:1: error: invalid storage class for function 'ccio_mark_invalid' 660 | ccio_mark_invalid(struct ioc *ioc, dma_addr_t iova, size_t byte_cnt) | ^~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:702:1: error: invalid storage class for function 'ccio_dma_supported' 702 | ccio_dma_supported(struct device *dev, u64 mask) | ^~~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:724:1: error: invalid storage class for function 'ccio_map_single' 724 | ccio_map_single(struct device *dev, void *addr, size_t size, | ^~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:786:1: error: invalid storage class for function 'ccio_map_page' 786 | ccio_map_page(struct device *dev, struct page *page, unsigned long offset, | ^~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:803:1: error: invalid storage class for function 'ccio_unmap_page' 803 | ccio_unmap_page(struct device *dev, dma_addr_t iova, size_t size, | ^~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:845:1: error: invalid storage class for function 'ccio_alloc' 845 | ccio_alloc(struct device *dev, size_t size, dma_addr_t *dma_handle, gfp_t flag, | ^~~~~~~~~~ drivers/parisc/ccio-dma.c:879:1: error: invalid storage class for function 'ccio_free' 879 | ccio_free(struct device *dev, size_t size, void *cpu_addr, | ^~~~~~~~~ In file included from drivers/parisc/iommu-helpers.h:2, from drivers/parisc/ccio-dma.c:896: include/linux/prefetch.h:55:20: error: invalid storage class for function 'prefetch_range' 55 | static inline void prefetch_range(void *addr, size_t len) | ^~~~~~~~~~~~~~ include/linux/prefetch.h:66:20: error: invalid storage class for function 'prefetch_page_address' 66 | static inline void prefetch_page_address(struct page *page) | ^~~~~~~~~~~~~~~~~~~~~ In file included from drivers/parisc/ccio-dma.c:896: drivers/parisc/iommu-helpers.h:15:1: error: invalid storage class for function 'iommu_fill_pdir' 15 | iommu_fill_pdir(struct ioc *ioc, struct scatterlist *startsg, int nents, | ^~~~~~~~~~~~~~~ drivers/parisc/iommu-helpers.h:101:1: error: invalid storage class for function 'iommu_coalesce_chunks' 101 | iommu_coalesce_chunks(struct ioc *ioc, struct device *dev, | ^~~~~~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:908:1: error: invalid storage class for function 'ccio_map_sg' 908 | ccio_map_sg(struct device *dev, struct scatterlist *sglist, int nents, | ^~~~~~~~~~~ drivers/parisc/ccio-dma.c:987:1: error: invalid storage class for function 'ccio_unmap_sg' 987 | ccio_unmap_sg(struct device *dev, struct scatterlist *sglist, int nents, | ^~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1020:19: error: initializer element is not constant 1020 | .dma_supported = ccio_dma_supported, | ^~~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1020:19: note: (near initialization for 'ccio_ops.dma_supported') drivers/parisc/ccio-dma.c:1021:12: error: initializer element is not constant 1021 | .alloc = ccio_alloc, | ^~~~~~~~~~ drivers/parisc/ccio-dma.c:1021:12: note: (near initialization for 'ccio_ops.alloc') drivers/parisc/ccio-dma.c:1022:12: error: initializer element is not constant 1022 | .free = ccio_free, | ^~~~~~~~~ drivers/parisc/ccio-dma.c:1022:12: note: (near initialization for 'ccio_ops.free') drivers/parisc/ccio-dma.c:1023:15: error: initializer element is not constant 1023 | .map_page = ccio_map_page, | ^~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1023:15: note: (near initialization for 'ccio_ops.map_page') drivers/parisc/ccio-dma.c:1024:17: error: initializer element is not constant 1024 | .unmap_page = ccio_unmap_page, | ^~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1024:17: note: (near initialization for 'ccio_ops.unmap_page') drivers/parisc/ccio-dma.c:1025:13: error: initializer element is not constant 1025 | .map_sg = ccio_map_sg, | ^~~~~~~~~~~ drivers/parisc/ccio-dma.c:1025:13: note: (near initialization for 'ccio_ops.map_sg') drivers/parisc/ccio-dma.c:1026:15: error: initializer element is not constant 1026 | .unmap_sg = ccio_unmap_sg, | ^~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1026:15: note: (near initialization for 'ccio_ops.unmap_sg') drivers/parisc/ccio-dma.c:1033:12: error: invalid storage class for function 'ccio_proc_info' 1033 | static int ccio_proc_info(struct seq_file *m, void *p) | ^~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1099:12: error: invalid storage class for function 'ccio_proc_bitmap_info' 1099 | static int ccio_proc_bitmap_info(struct seq_file *m, void *p) | ^~~~~~~~~~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1122:21: error: invalid storage class for function 'ccio_find_ioc' 1122 | static struct ioc * ccio_find_ioc(int hw_path) | ^~~~~~~~~~~~~ drivers/parisc/ccio-dma.c:1212:12: error: invalid storage class for function 'ccio_probe' 1212 | static int ccio_probe(struct parisc_device *dev); | ^~~~~~~~~~ drivers/parisc/ccio-dma.c:1217:11: error: 'ccio_probe' undeclared (first use in this function); did you mean 'ccio_free'? 1217 | .probe = ccio_probe, | ^~~~~~~~~~ | ccio_free drivers/parisc/ccio-dma.c:1217:11: note: each undeclared identifier is reported only once for each function it appears in drivers/parisc/ccio-dma.c:1229:1: error: invalid storage class for function 'ccio_ioc_init' 1229 | ccio_ioc_init(struct ioc *ioc) vim +430 drivers/parisc/ccio-dma.c ^1da177e4c3f41 Linus Torvalds 2005-04-16 415 ^1da177e4c3f41 Linus Torvalds 2005-04-16 416 #define CCIO_FREE_MAPPINGS(ioc, res_idx, mask, size) \ ^1da177e4c3f41 Linus Torvalds 2005-04-16 417 u##size *res_ptr = (u##size *)&((ioc)->res_map[res_idx]); \ ^1da177e4c3f41 Linus Torvalds 2005-04-16 418 BUG_ON((*res_ptr & mask) != mask); \ ^1da177e4c3f41 Linus Torvalds 2005-04-16 419 *res_ptr &= ~(mask); ^1da177e4c3f41 Linus Torvalds 2005-04-16 420 ^1da177e4c3f41 Linus Torvalds 2005-04-16 421 /** ^1da177e4c3f41 Linus Torvalds 2005-04-16 422 * ccio_free_range - Free pages from the ioc's resource map. ^1da177e4c3f41 Linus Torvalds 2005-04-16 423 * @ioc: The I/O Controller. ^1da177e4c3f41 Linus Torvalds 2005-04-16 424 * @iova: The I/O Virtual Address. ^1da177e4c3f41 Linus Torvalds 2005-04-16 425 * @pages_mapped: The requested number of pages to be freed from the ^1da177e4c3f41 Linus Torvalds 2005-04-16 426 * I/O Pdir. ^1da177e4c3f41 Linus Torvalds 2005-04-16 427 * ^1da177e4c3f41 Linus Torvalds 2005-04-16 428 * This function frees the resouces allocated for the iova. ^1da177e4c3f41 Linus Torvalds 2005-04-16 429 */ ^1da177e4c3f41 Linus Torvalds 2005-04-16 @430 static void ^1da177e4c3f41 Linus Torvalds 2005-04-16 431 ccio_free_range(struct ioc *ioc, dma_addr_t iova, unsigned long pages_mapped) ^1da177e4c3f41 Linus Torvalds 2005-04-16 432 { ^1da177e4c3f41 Linus Torvalds 2005-04-16 433 unsigned long iovp = CCIO_IOVP(iova); ^1da177e4c3f41 Linus Torvalds 2005-04-16 434 unsigned int res_idx = PDIR_INDEX(iovp) >> 3; ^1da177e4c3f41 Linus Torvalds 2005-04-16 435 ^1da177e4c3f41 Linus Torvalds 2005-04-16 436 BUG_ON(pages_mapped == 0); ^1da177e4c3f41 Linus Torvalds 2005-04-16 437 BUG_ON((pages_mapped * IOVP_SIZE) > DMA_CHUNK_SIZE); ^1da177e4c3f41 Linus Torvalds 2005-04-16 438 BUG_ON(pages_mapped > BITS_PER_LONG); ^1da177e4c3f41 Linus Torvalds 2005-04-16 439 ^1da177e4c3f41 Linus Torvalds 2005-04-16 440 DBG_RES("%s(): res_idx: %d pages_mapped %d\n", a8043ecb17bd2e Harvey Harrison 2008-05-14 441 __func__, res_idx, pages_mapped); ^1da177e4c3f41 Linus Torvalds 2005-04-16 442 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org