[radeon-alex:amd-mainline-dkms-5.2 2094/2647] include/kcl/kcl_mm.h:124:20: error: redefinition of 'mmgrab'
by kbuild test robot
tree: git://people.freedesktop.org/~agd5f/linux.git amd-mainline-dkms-5.2
head: b027ed8d9051470f4ed6bc071fcde172fe1fc595
commit: 8aff76ca3bf3120204c9ec521ebe96a5133e92f3 [2094/2647] drm/amdkcl: Test whether mmgrab is available
config: x86_64-randconfig-g002-201943 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
git checkout 8aff76ca3bf3120204c9ec521ebe96a5133e92f3
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
void drm_dev_put(struct drm_device *dev);
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: In function 'drm_dev_put':
include/kcl/kcl_drm.h:539:9: error: implicit declaration of function 'drm_dev_unref'; did you mean 'drm_dev_enter'? [-Werror=implicit-function-declaration]
return drm_dev_unref(dev);
^~~~~~~~~~~~~
drm_dev_enter
include/kcl/kcl_drm.h:539:9: warning: 'return' with a value, in function returning void
return drm_dev_unref(dev);
^~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h:537:20: note: declared here
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
include/kcl/kcl_mm.h:53:28: error: redefinition of 'memalloc_nofs_save'
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:248:28: note: previous definition of 'memalloc_nofs_save' was here
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:58:20: error: redefinition of 'memalloc_nofs_restore'
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:263:20: note: previous definition of 'memalloc_nofs_restore' was here
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:64:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:74:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:84:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:104:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:117:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
>> include/kcl/kcl_mm.h:124:20: error: redefinition of 'mmgrab'
static inline void mmgrab(struct mm_struct *mm)
^~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:34:20: note: previous definition of 'mmgrab' was here
static inline void mmgrab(struct mm_struct *mm)
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: At top level:
include/kcl/kcl_mm_types.h:10:3: error: conflicting types for 'pfn_t'
} pfn_t;
^~~~~
In file included from include/asm-generic/memory_model.h:5:0,
from arch/x86/include/asm/page.h:76,
from arch/x86/include/asm/thread_info.h:12,
from include/linux/thread_info.h:38,
from arch/x86/include/asm/preempt.h:7,
from include/linux/preempt.h:78,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/pfn.h:15:3: note: previous declaration of 'pfn_t' was here
} pfn_t;
^~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
--
void drm_dev_put(struct drm_device *dev);
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: In function 'drm_dev_put':
include/kcl/kcl_drm.h:539:9: error: implicit declaration of function 'drm_dev_unref'; did you mean 'drm_dev_enter'? [-Werror=implicit-function-declaration]
return drm_dev_unref(dev);
^~~~~~~~~~~~~
drm_dev_enter
include/kcl/kcl_drm.h:539:9: warning: 'return' with a value, in function returning void
return drm_dev_unref(dev);
^~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h:537:20: note: declared here
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
include/kcl/kcl_mm.h:53:28: error: redefinition of 'memalloc_nofs_save'
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:248:28: note: previous definition of 'memalloc_nofs_save' was here
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:58:20: error: redefinition of 'memalloc_nofs_restore'
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:263:20: note: previous definition of 'memalloc_nofs_restore' was here
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:64:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:74:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:84:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:104:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:117:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
>> include/kcl/kcl_mm.h:124:20: error: redefinition of 'mmgrab'
static inline void mmgrab(struct mm_struct *mm)
^~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:34:20: note: previous definition of 'mmgrab' was here
static inline void mmgrab(struct mm_struct *mm)
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: At top level:
include/kcl/kcl_mm_types.h:10:3: error: conflicting types for 'pfn_t'
} pfn_t;
^~~~~
In file included from include/asm-generic/memory_model.h:5:0,
from arch/x86/include/asm/page.h:76,
from arch/x86/include/asm/thread_info.h:12,
from include/linux/thread_info.h:38,
from arch/x86/include/asm/preempt.h:7,
from include/linux/preempt.h:78,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/pfn.h:15:3: note: previous declaration of 'pfn_t' was here
} pfn_t;
^~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
..
vim +/mmgrab +124 include/kcl/kcl_mm.h
122
123 #if !defined(HAVE_MMGRAB)
> 124 static inline void mmgrab(struct mm_struct *mm)
125 {
126 atomic_inc(&mm->mm_count);
127 }
128 #endif
129
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
[radeon-alex:amd-mainline-dkms-5.2 2082/2647] include/kcl/kcl_mm_types.h:10:3: error: conflicting types for 'pfn_t'
by kbuild test robot
tree: git://people.freedesktop.org/~agd5f/linux.git amd-mainline-dkms-5.2
head: b027ed8d9051470f4ed6bc071fcde172fe1fc595
commit: 3ba40228e28c15ca2dfec398cd7e5ebebdb5a9c2 [2082/2647] drm/amdkcl: Test whether vmf_insert_*() functions are available
config: x86_64-randconfig-g002-201943 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
git checkout 3ba40228e28c15ca2dfec398cd7e5ebebdb5a9c2
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:104:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:117:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: At top level:
>> include/kcl/kcl_mm_types.h:10:3: error: conflicting types for 'pfn_t'
} pfn_t;
^~~~~
In file included from include/asm-generic/memory_model.h:5:0,
from arch/x86/include/asm/page.h:76,
from arch/x86/include/asm/thread_info.h:12,
from include/linux/thread_info.h:38,
from arch/x86/include/asm/preempt.h:7,
from include/linux/preempt.h:78,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/pfn.h:15:3: note: previous declaration of 'pfn_t' was here
} pfn_t;
^~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
>> include/kcl/kcl_mm_types.h:33:13: error: conflicting types for 'vm_fault_t'
typedef int vm_fault_t;
^~~~~~~~~~
In file included from include/drm/drm_mm.h:43:0,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm_types.h:631:32: note: previous declaration of 'vm_fault_t' was here
typedef __bitwise unsigned int vm_fault_t;
^~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
>> include/kcl/kcl_mm_types.h:35:26: error: conflicting types for 'vmf_insert_mixed'
static inline vm_fault_t vmf_insert_mixed(struct vm_area_struct *vma,
^~~~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:2587:12: note: previous declaration of 'vmf_insert_mixed' was here
vm_fault_t vmf_insert_mixed(struct vm_area_struct *vma, unsigned long addr,
^~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: In function 'vmf_insert_mixed':
>> include/kcl/kcl_mm_types.h:41:8: error: implicit declaration of function 'vm_insert_mixed'; did you mean 'vmf_insert_mixed'? [-Werror=implicit-function-declaration]
err = vm_insert_mixed(vma, addr, pfn_t_to_pfn(pfn));
^~~~~~~~~~~~~~~
vmf_insert_mixed
include/kcl/kcl_mm_types.h: At top level:
>> include/kcl/kcl_mm_types.h:53:26: error: conflicting types for 'vmf_insert_pfn'
static inline vm_fault_t vmf_insert_pfn(struct vm_area_struct *vma,
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:2583:12: note: previous declaration of 'vmf_insert_pfn' was here
vm_fault_t vmf_insert_pfn(struct vm_area_struct *vma, unsigned long addr,
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: In function 'vmf_insert_pfn':
>> include/kcl/kcl_mm_types.h:56:13: error: implicit declaration of function 'vm_insert_pfn'; did you mean 'vmf_insert_pfn'? [-Werror=implicit-function-declaration]
int err = vm_insert_pfn(vma, addr, pfn);
^~~~~~~~~~~~~
vmf_insert_pfn
cc1: some warnings being treated as errors
--
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:104:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:117:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: At top level:
>> include/kcl/kcl_mm_types.h:10:3: error: conflicting types for 'pfn_t'
} pfn_t;
^~~~~
In file included from include/asm-generic/memory_model.h:5:0,
from arch/x86/include/asm/page.h:76,
from arch/x86/include/asm/thread_info.h:12,
from include/linux/thread_info.h:38,
from arch/x86/include/asm/preempt.h:7,
from include/linux/preempt.h:78,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/pfn.h:15:3: note: previous declaration of 'pfn_t' was here
} pfn_t;
^~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
>> include/kcl/kcl_mm_types.h:33:13: error: conflicting types for 'vm_fault_t'
typedef int vm_fault_t;
^~~~~~~~~~
In file included from include/drm/drm_mm.h:43:0,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm_types.h:631:32: note: previous declaration of 'vm_fault_t' was here
typedef __bitwise unsigned int vm_fault_t;
^~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
>> include/kcl/kcl_mm_types.h:35:26: error: conflicting types for 'vmf_insert_mixed'
static inline vm_fault_t vmf_insert_mixed(struct vm_area_struct *vma,
^~~~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:2587:12: note: previous declaration of 'vmf_insert_mixed' was here
vm_fault_t vmf_insert_mixed(struct vm_area_struct *vma, unsigned long addr,
^~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: In function 'vmf_insert_mixed':
>> include/kcl/kcl_mm_types.h:41:8: error: implicit declaration of function 'vm_insert_mixed'; did you mean 'vmf_insert_mixed'? [-Werror=implicit-function-declaration]
err = vm_insert_mixed(vma, addr, pfn_t_to_pfn(pfn));
^~~~~~~~~~~~~~~
vmf_insert_mixed
include/kcl/kcl_mm_types.h: At top level:
>> include/kcl/kcl_mm_types.h:53:26: error: conflicting types for 'vmf_insert_pfn'
static inline vm_fault_t vmf_insert_pfn(struct vm_area_struct *vma,
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:2583:12: note: previous declaration of 'vmf_insert_pfn' was here
vm_fault_t vmf_insert_pfn(struct vm_area_struct *vma, unsigned long addr,
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:12:0,
from <command-line>:0:
include/kcl/kcl_mm_types.h: In function 'vmf_insert_pfn':
>> include/kcl/kcl_mm_types.h:56:13: error: implicit declaration of function 'vm_insert_pfn'; did you mean 'vmf_insert_pfn'? [-Werror=implicit-function-declaration]
int err = vm_insert_pfn(vma, addr, pfn);
^~~~~~~~~~~~~
vmf_insert_pfn
drivers/gpu/drm/ttm/ttm_bo.c: In function 'ttm_bo_mem_space_debug':
drivers/gpu/drm/ttm/ttm_bo.c:101:25: error: invalid initializer
struct drm_printer p = drm_debug_printer(TTM_PFX);
^~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
..
vim +/pfn_t +10 include/kcl/kcl_mm_types.h
3
4 #include <linux/mm.h>
5 #ifdef HAVE_PFN_T
6 #include <linux/pfn_t.h>
7 #else
8 typedef struct {
9 u64 val;
> 10 } pfn_t;
11
12 #define PFN_FLAGS_MASK (((unsigned long) ~PAGE_MASK) \
13 << (BITS_PER_LONG - PAGE_SHIFT))
14 #define PFN_SG_CHAIN (1UL << (BITS_PER_LONG - 1))
15 #define PFN_SG_LAST (1UL << (BITS_PER_LONG - 2))
16 #define PFN_DEV (1UL << (BITS_PER_LONG - 3))
17 #define PFN_MAP (1UL << (BITS_PER_LONG - 4))
18
19 static inline pfn_t __pfn_to_pfn_t(unsigned long pfn, unsigned long flags)
20 {
21 pfn_t pfn_t = { .val = pfn | (flags & PFN_FLAGS_MASK), };
22
23 return pfn_t;
24 }
25
26 static inline unsigned long pfn_t_to_pfn(pfn_t pfn)
27 {
28 return pfn.val & ~PFN_FLAGS_MASK;
29 }
30 #endif
31
32 #ifndef HAVE_VMF_INSERT
> 33 typedef int vm_fault_t;
34
> 35 static inline vm_fault_t vmf_insert_mixed(struct vm_area_struct *vma,
36 unsigned long addr,
37 pfn_t pfn)
38 {
39 int err;
40 #if !defined(HAVE_PFN_T_VM_INSERT_MIXED)
> 41 err = vm_insert_mixed(vma, addr, pfn_t_to_pfn(pfn));
42 #else
43 err = vm_insert_mixed(vma, addr, pfn);
44 #endif
45 if (err == -ENOMEM)
46 return VM_FAULT_OOM;
47 if (err < 0 && err != -EBUSY)
48 return VM_FAULT_SIGBUS;
49
50 return VM_FAULT_NOPAGE;
51 }
52
> 53 static inline vm_fault_t vmf_insert_pfn(struct vm_area_struct *vma,
54 unsigned long addr, unsigned long pfn)
55 {
> 56 int err = vm_insert_pfn(vma, addr, pfn);
57
58 if (err == -ENOMEM)
59 return VM_FAULT_OOM;
60 if (err < 0 && err != -EBUSY)
61 return VM_FAULT_SIGBUS;
62
63 return VM_FAULT_NOPAGE;
64 }
65
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
[RFC PATCH] spi: cadence-quadpsi: cadence_qspi_init_timeout() can be static
by kbuild test robot
Fixes: 61e865acd941 ("spi: cadence-quadpsi: Add support for the Cadence QSPI controller")
Signed-off-by: kbuild test robot <lkp(a)intel.com>
---
spi-cadence-quadspi.c | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/drivers/spi/spi-cadence-quadspi.c b/drivers/spi/spi-cadence-quadspi.c
index bca391bfb58f9..56fb931596174 100644
--- a/drivers/spi/spi-cadence-quadspi.c
+++ b/drivers/spi/spi-cadence-quadspi.c
@@ -51,12 +51,12 @@ struct cqspi_driver_platdata {
u8 quirks;
};
-unsigned int cadence_qspi_init_timeout(const unsigned long timeout_in_ms)
+static unsigned int cadence_qspi_init_timeout(const unsigned long timeout_in_ms)
{
return jiffies + msecs_to_jiffies(timeout_in_ms);
}
-unsigned int cadence_qspi_check_timeout(const unsigned long timeout)
+static unsigned int cadence_qspi_check_timeout(const unsigned long timeout)
{
return time_before(jiffies, timeout);
}
@@ -98,7 +98,7 @@ static u32 cadence_qspi_cmd2addr(const unsigned char *addr_buf, u32 addr_width)
return addr;
}
-void enable_qspi_direct_access(void *reg_base, bool enable)
+static void enable_qspi_direct_access(void *reg_base, bool enable)
{
u32 reg;
@@ -111,7 +111,7 @@ void enable_qspi_direct_access(void *reg_base, bool enable)
writel(reg, reg_base + CQSPI_REG_CONFIG);
}
-void cadence_qspi_controller_enable(void *reg_base, bool enable)
+static void cadence_qspi_controller_enable(void *reg_base, bool enable)
{
unsigned int reg;
@@ -644,12 +644,12 @@ static int cqspi_indirect_write_execute(struct struct_cqspi *cqspi, u32 txlen,
return ret;
}
-unsigned int cadence_qspi_is_controller_ready(void *reg_base)
+static unsigned int cadence_qspi_is_controller_ready(void *reg_base)
{
return cadence_qspi_wait_idle(reg_base);
}
-void cadence_qspi_controller_init(struct struct_cqspi *cqspi)
+static void cadence_qspi_controller_init(struct struct_cqspi *cqspi)
{
struct platform_device *pdev = cqspi->pdev;
struct cqspi_platform_data *pdata = pdev->dev.platform_data;
@@ -687,7 +687,7 @@ unsigned int calculate_ticks_for_ns(u32 ref_clk_hz, u32 ns_val)
return ticks;
}
-void cadence_qspi_delay(struct struct_cqspi *cqspi, u32 ref_clk, u32 sclk_hz)
+static void cadence_qspi_delay(struct struct_cqspi *cqspi, u32 ref_clk, u32 sclk_hz)
{
struct platform_device *pdev = cqspi->pdev;
struct cqspi_platform_data *pdata = pdev->dev.platform_data;
@@ -722,7 +722,7 @@ void cadence_qspi_delay(struct struct_cqspi *cqspi, u32 ref_clk, u32 sclk_hz)
cadence_qspi_controller_enable(cqspi->iobase, 1);
}
-void cadence_qspi_switch_chipselect(struct struct_cqspi *cqspi, u32 cs)
+static void cadence_qspi_switch_chipselect(struct struct_cqspi *cqspi, u32 cs)
{
struct platform_device *pdev = cqspi->pdev;
struct cqspi_platform_data *pdata = pdev->dev.platform_data;
@@ -924,7 +924,7 @@ static int cadence_qspi_mem_process(struct struct_cqspi *cqspi,
return ret;
}
-int cadence_qspi_exec_mem_op(struct spi_mem *mem, const struct spi_mem_op *op)
+static int cadence_qspi_exec_mem_op(struct spi_mem *mem, const struct spi_mem_op *op)
{
struct struct_cqspi *cqspi = spi_master_get_devdata(mem->spi->master);
int ret;
2 years, 8 months
Re: [PATCH v2 2/2] spi: cadence-quadpsi: Add support for the Cadence QSPI controller
by kbuild test robot
Hi "Ramuthevar,Vadivel,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on spi/for-next]
[also build test WARNING on v5.4-rc5 next-20191031]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Ramuthevar-Vadivel-MuruganX/spi-...
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next
reproduce:
# apt-get install sparse
# sparse version: v0.6.1-dirty
make ARCH=x86_64 allmodconfig
make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__'
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/spi/spi-cadence-quadspi.c:54:14: sparse: sparse: symbol 'cadence_qspi_init_timeout' was not declared. Should it be static?
>> drivers/spi/spi-cadence-quadspi.c:59:14: sparse: sparse: symbol 'cadence_qspi_check_timeout' was not declared. Should it be static?
>> drivers/spi/spi-cadence-quadspi.c:105:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
>> drivers/spi/spi-cadence-quadspi.c:105:30: sparse: expected void const volatile [noderef] <asn:2> *addr
>> drivers/spi/spi-cadence-quadspi.c:105:30: sparse: got void *
>> drivers/spi/spi-cadence-quadspi.c:111:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
>> drivers/spi/spi-cadence-quadspi.c:111:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:111:30: sparse: got void *
>> drivers/spi/spi-cadence-quadspi.c:101:6: sparse: sparse: symbol 'enable_qspi_direct_access' was not declared. Should it be static?
drivers/spi/spi-cadence-quadspi.c:118:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:118:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:118:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:124:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:124:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:124:30: sparse: got void *
>> drivers/spi/spi-cadence-quadspi.c:114:6: sparse: sparse: symbol 'cadence_qspi_controller_enable' was not declared. Should it be static?
drivers/spi/spi-cadence-quadspi.c:133:21: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:133:21: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:133:21: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:151:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:151:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:151:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:161:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:161:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:161:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:174:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:174:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:174:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:177:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:177:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:177:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:186:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:186:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:186:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:198:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:198:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:198:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:206:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:206:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:206:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:208:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:208:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:208:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:212:38: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:212:38: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:212:38: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:242:45: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:242:45: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:242:45: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:251:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:251:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:251:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:257:38: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:257:38: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:257:38: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:280:39: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:280:39: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:280:39: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:287:45: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:287:45: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:287:45: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:302:45: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:302:45: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:302:45: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:313:39: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:313:39: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:313:39: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:323:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:323:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:323:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:325:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:325:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:325:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:328:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:328:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:328:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:330:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:330:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:330:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:332:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:332:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:332:30: sparse: got void *
>> drivers/spi/spi-cadence-quadspi.c:422:31: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
>> drivers/spi/spi-cadence-quadspi.c:422:31: sparse: expected void *reg_base
>> drivers/spi/spi-cadence-quadspi.c:422:31: sparse: got void [noderef] <asn:2> *iobase
>> drivers/spi/spi-cadence-quadspi.c:423:31: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected void *ahb_base @@ got void [noderef] <asvoid *ahb_base @@
>> drivers/spi/spi-cadence-quadspi.c:423:31: sparse: expected void *ahb_base
>> drivers/spi/spi-cadence-quadspi.c:423:31: sparse: got void [noderef] <asn:2> *qspi_ahb_virt
drivers/spi/spi-cadence-quadspi.c:431:28: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:431:28: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:431:28: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:432:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:432:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:432:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:433:36: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:433:36: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:433:36: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:438:25: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:438:25: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:438:25: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:440:48: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:440:48: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:440:48: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:441:44: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:441:44: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:441:44: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:445:25: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:445:25: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:445:25: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:448:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:448:33: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:448:33: sparse: got void *
>> drivers/spi/spi-cadence-quadspi.c:458:46: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void [noderef] <asn:2> *port @@ got n:2> *port @@
>> drivers/spi/spi-cadence-quadspi.c:458:46: sparse: expected void [noderef] <asn:2> *port
>> drivers/spi/spi-cadence-quadspi.c:458:46: sparse: got void *ahb_base
>> drivers/spi/spi-cadence-quadspi.c:461:62: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void [noderef] <asn:2> * @@ got n:2> * @@
>> drivers/spi/spi-cadence-quadspi.c:461:62: sparse: expected void [noderef] <asn:2> *
drivers/spi/spi-cadence-quadspi.c:461:62: sparse: got void *ahb_base
drivers/spi/spi-cadence-quadspi.c:470:41: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:470:41: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:470:41: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:480:38: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:480:38: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:480:38: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:490:28: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:490:28: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:490:28: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:492:57: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:492:57: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:492:57: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:497:28: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:497:28: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:497:28: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:500:25: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:500:25: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:500:25: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:514:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:514:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:514:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:517:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:517:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:517:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:531:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:531:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:531:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:534:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:534:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:534:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:535:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:535:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:535:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:538:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:538:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:538:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:541:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:541:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:541:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:543:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:543:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:543:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:555:31: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:555:31: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:555:31: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:556:31: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected void *ahb_base @@ got void [noderef] <asvoid *ahb_base @@
drivers/spi/spi-cadence-quadspi.c:556:31: sparse: expected void *ahb_base
drivers/spi/spi-cadence-quadspi.c:556:31: sparse: got void [noderef] <asn:2> *qspi_ahb_virt
drivers/spi/spi-cadence-quadspi.c:563:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:563:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:563:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:564:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:564:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:564:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:565:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:565:30: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:565:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:570:30: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:570:30: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:570:30: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:572:36: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:572:36: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:572:36: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:573:54: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:573:54: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:573:54: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:575:48: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:575:48: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:575:48: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:576:44: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:576:44: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:576:44: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:579:25: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:579:25: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:579:25: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:592:39: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void [noderef] <asn:2> *port @@ got n:2> *port @@
drivers/spi/spi-cadence-quadspi.c:592:39: sparse: expected void [noderef] <asn:2> *port
drivers/spi/spi-cadence-quadspi.c:592:39: sparse: got void *ahb_base
drivers/spi/spi-cadence-quadspi.c:599:41: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void [noderef] <asn:2> * @@ got n:2> * @@
drivers/spi/spi-cadence-quadspi.c:599:41: sparse: expected void [noderef] <asn:2> *
drivers/spi/spi-cadence-quadspi.c:599:41: sparse: got void *ahb_base
>> drivers/spi/spi-cadence-quadspi.c:606:28: sparse: sparse: dubious: !x & y
drivers/spi/spi-cadence-quadspi.c:621:38: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:621:38: sparse: expected void const volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:621:38: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:635:28: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:635:28: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:635:28: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:637:57: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:637:57: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:637:57: sparse: got void *
drivers/spi/spi-cadence-quadspi.c:642:33: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] <asn:2> *addr @@ got n:2> *addr @@
drivers/spi/spi-cadence-quadspi.c:642:33: sparse: expected void volatile [noderef] <asn:2> *addr
drivers/spi/spi-cadence-quadspi.c:642:33: sparse: got void *
>> drivers/spi/spi-cadence-quadspi.c:647:14: sparse: sparse: symbol 'cadence_qspi_is_controller_ready' was not declared. Should it be static?
>> drivers/spi/spi-cadence-quadspi.c:657:45: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:657:45: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:657:45: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:666:48: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:666:48: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:666:48: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:668:48: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:668:48: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:668:48: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:677:45: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:677:45: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:677:45: sparse: got void [noderef] <asn:2> *iobase
>> drivers/spi/spi-cadence-quadspi.c:652:6: sparse: sparse: symbol 'cadence_qspi_controller_init' was not declared. Should it be static?
drivers/spi/spi-cadence-quadspi.c:701:45: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:701:45: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:701:45: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:722:45: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:722:45: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:722:45: sparse: got void [noderef] <asn:2> *iobase
>> drivers/spi/spi-cadence-quadspi.c:690:6: sparse: sparse: symbol 'cadence_qspi_delay' was not declared. Should it be static?
drivers/spi/spi-cadence-quadspi.c:733:45: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:733:45: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:733:45: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:743:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:743:25: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:743:25: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:744:45: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:744:45: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:744:45: sparse: got void [noderef] <asn:2> *iobase
>> drivers/spi/spi-cadence-quadspi.c:725:6: sparse: sparse: symbol 'cadence_qspi_switch_chipselect' was not declared. Should it be static?
drivers/spi/spi-cadence-quadspi.c:870:40: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:870:40: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:870:40: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:871:42: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:871:42: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:871:42: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:874:39: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:874:39: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:874:39: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:875:40: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:875:40: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:875:40: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:880:43: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:880:43: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:880:43: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:888:42: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:888:42: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:888:42: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:896:50: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:896:50: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:896:50: sparse: got void [noderef] <asn:2> *iobase
>> drivers/spi/spi-cadence-quadspi.c:899:80: sparse: sparse: Using plain integer as NULL pointer
drivers/spi/spi-cadence-quadspi.c:907:49: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *reg_base @@ got void [noderef] <asvoid *reg_base @@
drivers/spi/spi-cadence-quadspi.c:907:49: sparse: expected void *reg_base
drivers/spi/spi-cadence-quadspi.c:907:49: sparse: got void [noderef] <asn:2> *iobase
drivers/spi/spi-cadence-quadspi.c:910:79: sparse: sparse: Using plain integer as NULL pointer
>> drivers/spi/spi-cadence-quadspi.c:927:5: sparse: sparse: symbol 'cadence_qspi_exec_mem_op' was not declared. Should it be static?
>> drivers/spi/spi-cadence-quadspi.c:1225:52: sparse: sparse: too many warnings
Please review and possibly fold the followup patch.
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
[radeon-alex:amd-mainline-dkms-5.2 2081/2647] include/kcl/kcl_mm.h:53:28: error: redefinition of 'memalloc_nofs_save'
by kbuild test robot
tree: git://people.freedesktop.org/~agd5f/linux.git amd-mainline-dkms-5.2
head: b027ed8d9051470f4ed6bc071fcde172fe1fc595
commit: efcd1418868bc7be0eb22a57497ac20eeb831ff1 [2081/2647] drm/amdkcl: Test whether memalloc_nofs_save() and memalloc_nofs_restore() functions are available
config: x86_64-randconfig-g002-201943 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
git checkout efcd1418868bc7be0eb22a57497ac20eeb831ff1
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
struct drm_gem_object *drm_gem_object_lookup(struct drm_file *filp, u32 handle);
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h:260:10: error: too many arguments to function 'drm_gem_object_lookup'
return drm_gem_object_lookup(dev, filp, handle);
^~~~~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_drm.h:9:0,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/drm/drm_gem.h:386:24: note: declared here
struct drm_gem_object *drm_gem_object_lookup(struct drm_file *filp, u32 handle);
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: At top level:
include/kcl/kcl_drm.h:269:8: error: redefinition of 'struct drm_format_name_buf'
struct drm_format_name_buf {
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:69:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/drm/drm_fourcc.h:142:8: note: originally defined here
struct drm_format_name_buf {
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: In function 'kcl_drm_gem_object_put_unlocked':
include/kcl/kcl_drm.h:301:9: error: implicit declaration of function 'drm_gem_object_unreference_unlocked'; did you mean 'drm_gem_object_put_unlocked'? [-Werror=implicit-function-declaration]
return drm_gem_object_unreference_unlocked(obj);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drm_gem_object_put_unlocked
include/kcl/kcl_drm.h:301:9: warning: 'return' with a value, in function returning void
return drm_gem_object_unreference_unlocked(obj);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h:298:20: note: declared here
static inline void kcl_drm_gem_object_put_unlocked(struct drm_gem_object *obj)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h: In function 'kcl_drm_atomic_get_old_crtc_state_before_commit':
include/kcl/kcl_drm.h:325:43: error: invalid type argument of '->' (have 'struct __drm_crtcs_state')
return state->crtcs[drm_crtc_index(crtc)]->state;
^~
include/kcl/kcl_drm.h: In function 'kcl_drm_atomic_get_new_crtc_state_after_commit':
include/kcl/kcl_drm.h:360:43: error: invalid type argument of '->' (have 'struct __drm_crtcs_state')
return state->crtcs[drm_crtc_index(crtc)]->state;
^~
include/kcl/kcl_drm.h: At top level:
include/kcl/kcl_drm.h:465:8: error: redefinition of 'struct drm_printer'
struct drm_printer {
^~~~~~~~~~~
In file included from include/drm/drm_mm.h:49:0,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/drm/drm_print.h:70:8: note: originally defined here
struct drm_printer {
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h:471:6: error: conflicting types for 'drm_printf'
void drm_printf(struct drm_printer *p, const char *f, ...);
^~~~~~~~~~
In file included from include/drm/drm_mm.h:49:0,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/drm/drm_print.h:86:6: note: previous declaration of 'drm_printf' was here
void drm_printf(struct drm_printer *p, const char *f, ...);
^~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h:537:20: error: static declaration of 'drm_dev_put' follows non-static declaration
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from include/drm/drmP.h:74:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/drm/drm_drv.h:739:6: note: previous declaration of 'drm_dev_put' was here
void drm_dev_put(struct drm_device *dev);
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: In function 'drm_dev_put':
include/kcl/kcl_drm.h:539:9: error: implicit declaration of function 'drm_dev_unref'; did you mean 'drm_dev_enter'? [-Werror=implicit-function-declaration]
return drm_dev_unref(dev);
^~~~~~~~~~~~~
drm_dev_enter
include/kcl/kcl_drm.h:539:9: warning: 'return' with a value, in function returning void
return drm_dev_unref(dev);
^~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h:537:20: note: declared here
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
>> include/kcl/kcl_mm.h:53:28: error: redefinition of 'memalloc_nofs_save'
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:248:28: note: previous definition of 'memalloc_nofs_save' was here
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
>> include/kcl/kcl_mm.h:58:20: error: redefinition of 'memalloc_nofs_restore'
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:263:20: note: previous definition of 'memalloc_nofs_restore' was here
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:64:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:74:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:84:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:104:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:117:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
--
struct drm_gem_object *drm_gem_object_lookup(struct drm_file *filp, u32 handle);
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h:260:10: error: too many arguments to function 'drm_gem_object_lookup'
return drm_gem_object_lookup(dev, filp, handle);
^~~~~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_drm.h:9:0,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/drm/drm_gem.h:386:24: note: declared here
struct drm_gem_object *drm_gem_object_lookup(struct drm_file *filp, u32 handle);
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: At top level:
include/kcl/kcl_drm.h:269:8: error: redefinition of 'struct drm_format_name_buf'
struct drm_format_name_buf {
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:69:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/drm/drm_fourcc.h:142:8: note: originally defined here
struct drm_format_name_buf {
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: In function 'kcl_drm_gem_object_put_unlocked':
include/kcl/kcl_drm.h:301:9: error: implicit declaration of function 'drm_gem_object_unreference_unlocked'; did you mean 'drm_gem_object_put_unlocked'? [-Werror=implicit-function-declaration]
return drm_gem_object_unreference_unlocked(obj);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drm_gem_object_put_unlocked
include/kcl/kcl_drm.h:301:9: warning: 'return' with a value, in function returning void
return drm_gem_object_unreference_unlocked(obj);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h:298:20: note: declared here
static inline void kcl_drm_gem_object_put_unlocked(struct drm_gem_object *obj)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h: In function 'kcl_drm_atomic_get_old_crtc_state_before_commit':
include/kcl/kcl_drm.h:325:43: error: invalid type argument of '->' (have 'struct __drm_crtcs_state')
return state->crtcs[drm_crtc_index(crtc)]->state;
^~
include/kcl/kcl_drm.h: In function 'kcl_drm_atomic_get_new_crtc_state_after_commit':
include/kcl/kcl_drm.h:360:43: error: invalid type argument of '->' (have 'struct __drm_crtcs_state')
return state->crtcs[drm_crtc_index(crtc)]->state;
^~
include/kcl/kcl_drm.h: At top level:
include/kcl/kcl_drm.h:465:8: error: redefinition of 'struct drm_printer'
struct drm_printer {
^~~~~~~~~~~
In file included from include/drm/drm_mm.h:49:0,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/drm/drm_print.h:70:8: note: originally defined here
struct drm_printer {
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h:471:6: error: conflicting types for 'drm_printf'
void drm_printf(struct drm_printer *p, const char *f, ...);
^~~~~~~~~~
In file included from include/drm/drm_mm.h:49:0,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/drm/drm_print.h:86:6: note: previous declaration of 'drm_printf' was here
void drm_printf(struct drm_printer *p, const char *f, ...);
^~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h:537:20: error: static declaration of 'drm_dev_put' follows non-static declaration
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from include/drm/drmP.h:74:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/drm/drm_drv.h:739:6: note: previous declaration of 'drm_dev_put' was here
void drm_dev_put(struct drm_device *dev);
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:6:0,
from <command-line>:0:
include/kcl/kcl_drm.h: In function 'drm_dev_put':
include/kcl/kcl_drm.h:539:9: error: implicit declaration of function 'drm_dev_unref'; did you mean 'drm_dev_enter'? [-Werror=implicit-function-declaration]
return drm_dev_unref(dev);
^~~~~~~~~~~~~
drm_dev_enter
include/kcl/kcl_drm.h:539:9: warning: 'return' with a value, in function returning void
return drm_dev_unref(dev);
^~~~~~~~~~~~~~~~~~
include/kcl/kcl_drm.h:537:20: note: declared here
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
>> include/kcl/kcl_mm.h:53:28: error: redefinition of 'memalloc_nofs_save'
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:248:28: note: previous definition of 'memalloc_nofs_save' was here
static inline unsigned int memalloc_nofs_save(void)
^~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
>> include/kcl/kcl_mm.h:58:20: error: redefinition of 'memalloc_nofs_restore'
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from include/kcl/kcl_mm.h:5:0,
from drivers/gpu/drm/ttm/backport/backport.h:8,
from <command-line>:0:
include/linux/sched/mm.h:263:20: note: previous definition of 'memalloc_nofs_restore' was here
static inline void memalloc_nofs_restore(unsigned int flags)
^~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:64:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:74:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:84:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:104:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:117:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
..
vim +/memalloc_nofs_save +53 include/kcl/kcl_mm.h
b4f7d254be169a Junwei Zhang 2016-12-23 3
952a875f0399c8 Yifan Zhang 2019-08-07 4 #if defined(HAVE_SCHED_MM_H)
952a875f0399c8 Yifan Zhang 2019-08-07 @5 #include <linux/sched/mm.h>
952a875f0399c8 Yifan Zhang 2019-08-07 6 #else
952a875f0399c8 Yifan Zhang 2019-08-07 7 #include <linux/sched.h>
952a875f0399c8 Yifan Zhang 2019-08-07 8 #endif
b4f7d254be169a Junwei Zhang 2016-12-23 9 #include <linux/mm.h>
b8a1520bda5b72 Flora Cui 2019-08-19 10 #include <linux/gfp.h>
b8a1520bda5b72 Flora Cui 2019-08-19 11 #include <kcl/kcl_overflow.h>
b4f7d254be169a Junwei Zhang 2016-12-23 12
b4f7d254be169a Junwei Zhang 2016-12-23 13 static inline int kcl_get_user_pages(struct task_struct *tsk, struct mm_struct *mm,
b4f7d254be169a Junwei Zhang 2016-12-23 14 unsigned long start, unsigned long nr_pages,
b4f7d254be169a Junwei Zhang 2016-12-23 15 int write, int force, struct page **pages,
b4f7d254be169a Junwei Zhang 2016-12-23 16 struct vm_area_struct **vmas, int *locked)
b4f7d254be169a Junwei Zhang 2016-12-23 17 {
b4f7d254be169a Junwei Zhang 2016-12-23 18 #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 9, 0) || \
b4f7d254be169a Junwei Zhang 2016-12-23 19 defined(OS_NAME_SLE_12_3) || \
b4f7d254be169a Junwei Zhang 2016-12-23 20 defined(OS_NAME_SUSE_42_3) || \
b4f7d254be169a Junwei Zhang 2016-12-23 21 defined(OS_NAME_RHEL_7_4_5)
b4f7d254be169a Junwei Zhang 2016-12-23 22 if (mm == current->mm)
b4f7d254be169a Junwei Zhang 2016-12-23 23 return get_user_pages(start, nr_pages, write, pages, vmas);
b4f7d254be169a Junwei Zhang 2016-12-23 24 else
b4f7d254be169a Junwei Zhang 2016-12-23 25 #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 10, 0) || \
b4f7d254be169a Junwei Zhang 2016-12-23 26 defined(OS_NAME_SLE_12_3) || \
b4f7d254be169a Junwei Zhang 2016-12-23 27 defined(OS_NAME_SUSE_42_3) || \
b4f7d254be169a Junwei Zhang 2016-12-23 28 defined(OS_NAME_RHEL_7_4_5)
b4f7d254be169a Junwei Zhang 2016-12-23 29 return get_user_pages_remote(tsk, mm, start, nr_pages,
b4f7d254be169a Junwei Zhang 2016-12-23 30 write, pages, vmas, locked);
b4f7d254be169a Junwei Zhang 2016-12-23 31 #else
b4f7d254be169a Junwei Zhang 2016-12-23 32 return get_user_pages_remote(tsk, mm, start, nr_pages,
b4f7d254be169a Junwei Zhang 2016-12-23 33 write, pages, vmas);
b4f7d254be169a Junwei Zhang 2016-12-23 34 #endif
b4f7d254be169a Junwei Zhang 2016-12-23 35 #elif LINUX_VERSION_CODE >= KERNEL_VERSION(4, 6, 0) || \
b4f7d254be169a Junwei Zhang 2016-12-23 36 defined(OS_NAME_SLE_12_3) || \
b4f7d254be169a Junwei Zhang 2016-12-23 37 defined(OS_NAME_SUSE_42_3)
b4f7d254be169a Junwei Zhang 2016-12-23 38 if (mm == current->mm)
b4f7d254be169a Junwei Zhang 2016-12-23 39 return get_user_pages(start, nr_pages, write, force, pages,
b4f7d254be169a Junwei Zhang 2016-12-23 40 vmas);
b4f7d254be169a Junwei Zhang 2016-12-23 41 else
b4f7d254be169a Junwei Zhang 2016-12-23 42 return get_user_pages_remote(tsk, mm, start, nr_pages,
b4f7d254be169a Junwei Zhang 2016-12-23 43 write, force, pages, vmas);
b4f7d254be169a Junwei Zhang 2016-12-23 44 #else
b4f7d254be169a Junwei Zhang 2016-12-23 45 write = !!(write & FOLL_WRITE);
b4f7d254be169a Junwei Zhang 2016-12-23 46 return get_user_pages(tsk, mm, start, nr_pages,
b4f7d254be169a Junwei Zhang 2016-12-23 47 write, force, pages, vmas);
b4f7d254be169a Junwei Zhang 2016-12-23 48 #endif
b4f7d254be169a Junwei Zhang 2016-12-23 49 }
b4f7d254be169a Junwei Zhang 2016-12-23 50
b4f7d254be169a Junwei Zhang 2016-12-23 51
efcd1418868bc7 Slava Grigorev 2019-07-11 52 #if !defined(HAVE_MEMALLOC_NOFS_SAVE)
b4f7d254be169a Junwei Zhang 2016-12-23 @53 static inline unsigned int memalloc_nofs_save(void)
b4f7d254be169a Junwei Zhang 2016-12-23 54 {
b4f7d254be169a Junwei Zhang 2016-12-23 55 return current->flags;
b4f7d254be169a Junwei Zhang 2016-12-23 56 }
b4f7d254be169a Junwei Zhang 2016-12-23 57
b4f7d254be169a Junwei Zhang 2016-12-23 @58 static inline void memalloc_nofs_restore(unsigned int flags)
b4f7d254be169a Junwei Zhang 2016-12-23 59 {
b4f7d254be169a Junwei Zhang 2016-12-23 60 }
b4f7d254be169a Junwei Zhang 2016-12-23 61 #endif
b4f7d254be169a Junwei Zhang 2016-12-23 62
:::::: The code at line 53 was first introduced by commit
:::::: b4f7d254be169a27d8759eff4cdc418427ad10a3 drm/amdkcl: [4.6] fix kcl_get_user_pages()
:::::: TO: Junwei Zhang <Jerry.Zhang(a)amd.com>
:::::: CC: Chengming Gui <Jack.Gui(a)amd.com>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
[PATCH] spi: cadence-quadpsi: fix platform_get_irq.cocci warnings
by kbuild test robot
From: kbuild test robot <lkp(a)intel.com>
drivers/spi/spi-cadence-quadspi.c:1181:2-9: line 1181 is redundant because platform_get_irq() already prints an error
Remove dev_err() messages after platform_get_irq*() failures
Generated by: scripts/coccinelle/api/platform_get_irq.cocci
Fixes: 61e865acd941 ("spi: cadence-quadpsi: Add support for the Cadence QSPI controller")
CC: Ramuthevar Vadivel Murugan <vadivel.muruganx.ramuthevar(a)linux.intel.com>
Signed-off-by: kbuild test robot <lkp(a)intel.com>
---
url: https://github.com/0day-ci/linux/commits/Ramuthevar-Vadivel-MuruganX/spi-...
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next
Please take the patch only if it's a positive warning. Thanks!
spi-cadence-quadspi.c | 1 -
1 file changed, 1 deletion(-)
--- a/drivers/spi/spi-cadence-quadspi.c
+++ b/drivers/spi/spi-cadence-quadspi.c
@@ -1178,7 +1178,6 @@ static int cadence_qspi_probe(struct pla
cqspi->irq = platform_get_irq(pdev, 0);
if (cqspi->irq < 0) {
- dev_err(dev, "platform_get_irq failed.\n");
ret = -ENXIO;
goto err_irq;
}
2 years, 8 months
Re: [PATCH v2 2/2] spi: cadence-quadpsi: Add support for the Cadence QSPI controller
by kbuild test robot
Hi "Ramuthevar,Vadivel,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on spi/for-next]
[also build test WARNING on v5.4-rc5 next-20191031]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Ramuthevar-Vadivel-MuruganX/spi-...
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/spi/spi-cadence-quadspi.c: In function 'cqspi_indirect_write_execute':
>> drivers/spi/spi-cadence-quadspi.c:606:7: warning: suggest parentheses around operand of '!' or change '&' to '&&' or '!' to '~' [-Wparentheses]
if (!(ret) & (*irq_status & CQSPI_IRQ_STATUS_ERR)) {
^~~~~~
At top level:
drivers/spi/spi-cadence-quadspi.c:359:12: warning: 'cqspi_direct_read_execute' defined but not used [-Wunused-function]
static int cqspi_direct_read_execute(struct struct_cqspi *cqspi, u8 *buf,
^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/spi/spi-cadence-quadspi.c: In function 'cadence_qspi_delay':
>> drivers/spi/spi-cadence-quadspi.c:706:5: warning: 'tshsl' is used uninitialized in this function [-Wuninitialized]
if (tshsl < tsclk)
^
coccinelle warnings: (new ones prefixed by >>)
>> drivers/spi/spi-cadence-quadspi.c:1181:2-9: line 1181 is redundant because platform_get_irq() already prints an error
Please review and possibly fold the followup patch.
vim +606 drivers/spi/spi-cadence-quadspi.c
547
548 static int cqspi_indirect_write_execute(struct struct_cqspi *cqspi, u32 txlen,
549 const u8 *txbuf, u32 flash_type)
550 {
551 struct platform_device *pdev = cqspi->pdev;
552 struct cqspi_platform_data *pdata = pdev->dev.platform_data;
553 struct cqspi_flash_pdata *f_pdata =
554 &pdata->f_pdata[cqspi->current_cs];
555 void *reg_base = cqspi->iobase;
556 void *ahb_base = cqspi->qspi_ahb_virt;
557 u32 *irq_status = &cqspi->irq_status;
558 u32 page_size = f_pdata->page_size;
559 u32 write_bytes, timeout, reg = 0;
560 int remaining = (int)txlen;
561 int ret;
562
563 writel(0xa, reg_base + CQSPI_INDIRECT_TRIGGER_ADDR_RANGE_REG);
564 writel(0x0, reg_base + CQSPI_REG_INDIRECTWRWATERMARK);
565 reg = readl(reg_base + CQSPI_REG_SIZE);
566 reg &= ~(CQSPI_REG_SIZE_PAGE_MASK << CQSPI_REG_SIZE_PAGE_LSB);
567 reg &= ~(CQSPI_REG_SIZE_BLOCK_MASK << CQSPI_REG_SIZE_BLOCK_LSB);
568 reg |= (f_pdata->page_size << CQSPI_REG_SIZE_PAGE_LSB);
569 reg |= (f_pdata->block_size << CQSPI_REG_SIZE_BLOCK_LSB);
570 writel(reg, reg_base + CQSPI_REG_SIZE);
571
572 writel(remaining, reg_base + CQSPI_REG_INDIRECTWRBYTES);
573 writel(CQSPI_REG_SRAM_PARTITION_WR, reg_base + CQSPI_REG_SRAMPARTITION);
574 /* Clear all interrupts. */
575 writel(CQSPI_IRQ_STATUS_MASK, reg_base + CQSPI_REG_IRQSTATUS);
576 writel(CQSPI_IRQ_MASK_WR, reg_base + CQSPI_REG_IRQMASK);
577 reinit_completion(&cqspi->transfer_complete);
578 writel(CQSPI_REG_INDIRECTWR_START_MASK,
579 reg_base + CQSPI_REG_INDIRECTWR);
580
581 if (cqspi->wr_delay)
582 ndelay(cqspi->wr_delay);
583
584 while (remaining > 0) {
585 size_t write_words, mod_bytes;
586
587 write_bytes = remaining > page_size ? page_size : remaining;
588 write_words = write_bytes / 4;
589 mod_bytes = write_bytes % 4;
590
591 if (write_words) {
592 iowrite32_rep(ahb_base, txbuf, write_words);
593 txbuf += (write_words * 4);
594 }
595 if (mod_bytes) {
596 unsigned int temp = 0xFFFFFFFF;
597
598 memcpy(&temp, txbuf, mod_bytes);
599 iowrite32(temp, ahb_base);
600 txbuf += mod_bytes;
601 }
602 ret = wait_event_interruptible_timeout(cqspi->waitqueue,
603 *irq_status &
604 CQSPI_IRQ_MASK_WR,
605 CQSPI_TIMEOUT_MS);
> 606 if (!(ret) & (*irq_status & CQSPI_IRQ_STATUS_ERR)) {
607 ret = -ETIMEDOUT;
608 goto failwr;
609 } else {
610 ret = 0;
611 }
612 remaining -= write_bytes;
613
614 if (remaining < 0)
615 reinit_completion(&cqspi->transfer_complete);
616 }
617
618 /* Check indirect done status */
619 timeout = cadence_qspi_init_timeout(CQSPI_TIMEOUT_MS);
620 while (cadence_qspi_check_timeout(timeout)) {
621 reg = readl(reg_base + CQSPI_REG_INDIRECTWR);
622 if (reg & CQSPI_REG_INDIRECTWR_DONE_MASK)
623 break;
624 }
625 if (!(reg & CQSPI_REG_INDIRECTWR_DONE_MASK)) {
626 dev_err(&pdev->dev, "QSPI: Indirect write error %x", reg);
627 ret = -ETIMEDOUT;
628 goto failwr;
629 }
630
631 return 0;
632
633 failwr:
634 /* Disable interrupt. */
635 writel(0, reg_base + CQSPI_REG_IRQMASK);
636 /* Clear indirect completion status */
637 writel(CQSPI_REG_INDIRECTWR_DONE_MASK, reg_base + CQSPI_REG_INDIRECTWR);
638
639 /* Cancel the indirect write */
640 if (ret)
641 writel(CQSPI_REG_INDIRECTWR_CANCEL_MASK,
642 reg_base + CQSPI_REG_INDIRECTWR);
643
644 return ret;
645 }
646
647 unsigned int cadence_qspi_is_controller_ready(void *reg_base)
648 {
649 return cadence_qspi_wait_idle(reg_base);
650 }
651
652 void cadence_qspi_controller_init(struct struct_cqspi *cqspi)
653 {
654 struct platform_device *pdev = cqspi->pdev;
655 struct cqspi_platform_data *pdata = pdev->dev.platform_data;
656
657 cadence_qspi_controller_enable(cqspi->iobase, 0);
658
659 /* Configure the remap address register, no remap */
660 writel(0, cqspi->iobase + CQSPI_REG_REMAP);
661 /* Disable all interrupts. */
662 writel(0, cqspi->iobase + CQSPI_REG_IRQMASK);
663
664 /* DAC is disabled for Intel LGM SOC */
665 if (!cqspi->dac_mode) {
666 enable_qspi_direct_access(cqspi->iobase, 0);
667 } else {
668 enable_qspi_direct_access(cqspi->iobase, 1);
669 /* TODO: for TI platform to be enabled */
670 cqspi_request_mmap_dma(cqspi);
671 }
672
673 /* Load indirect trigger address. */
674 writel(pdata->trigger_address,
675 cqspi->iobase + CQSPI_REG_INDIRECTTRIGGER);
676
677 cadence_qspi_controller_enable(cqspi->iobase, 1);
678 }
679
680 unsigned int calculate_ticks_for_ns(u32 ref_clk_hz, u32 ns_val)
681 {
682 unsigned int ticks;
683
684 ticks = ref_clk_hz / 1000; /* kHz */
685 ticks = DIV_ROUND_UP(ticks * ns_val, 1000000);
686
687 return ticks;
688 }
689
690 void cadence_qspi_delay(struct struct_cqspi *cqspi, u32 ref_clk, u32 sclk_hz)
691 {
692 struct platform_device *pdev = cqspi->pdev;
693 struct cqspi_platform_data *pdata = pdev->dev.platform_data;
694 struct cqspi_flash_pdata *f_pdata = &pdata->f_pdata[cqspi->current_cs];
695 void __iomem *iobase = cqspi->iobase;
696 const unsigned int ref_clk_hz = pdata->master_ref_clk_hz;
697 unsigned int tshsl, tchsh, tslch, tsd2d;
698 unsigned int reg;
699 unsigned int tsclk;
700
701 cadence_qspi_controller_enable(cqspi->iobase, 0);
702 /* calculate the number of ref ticks for one sclk tick */
703 tsclk = DIV_ROUND_UP(ref_clk_hz, sclk_hz);
704
705 /* this particular value must be at least one sclk */
> 706 if (tshsl < tsclk)
707 tshsl = tsclk;
708
709 tchsh = calculate_ticks_for_ns(ref_clk_hz, f_pdata->tchsh_ns);
710 tslch = calculate_ticks_for_ns(ref_clk_hz, f_pdata->tslch_ns);
711 tsd2d = calculate_ticks_for_ns(ref_clk_hz, f_pdata->tsd2d_ns);
712
713 reg = ((tshsl & CQSPI_REG_DELAY_TSHSL_MASK)
714 << CQSPI_REG_DELAY_TSHSL_LSB);
715 reg |= ((tchsh & CQSPI_REG_DELAY_TCHSH_MASK)
716 << CQSPI_REG_DELAY_TCHSH_LSB);
717 reg |= ((tslch & CQSPI_REG_DELAY_TSLCH_MASK)
718 << CQSPI_REG_DELAY_TSLCH_LSB);
719 reg |= ((tsd2d & CQSPI_REG_DELAY_TSD2D_MASK)
720 << CQSPI_REG_DELAY_TSD2D_LSB);
721 writel(reg, iobase + CQSPI_REG_DELAY);
722 cadence_qspi_controller_enable(cqspi->iobase, 1);
723 }
724
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
[radeon-alex:amd-mainline-dkms-5.2 2080/2647] include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
by kbuild test robot
tree: git://people.freedesktop.org/~agd5f/linux.git amd-mainline-dkms-5.2
head: b027ed8d9051470f4ed6bc071fcde172fe1fc595
commit: b35c23a557bb753b64082a4aa4057374bcbcca74 [2080/2647] drm/amdkcl: Test whether kref_read() function is available
config: x86_64-randconfig-g002-201943 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
git checkout b35c23a557bb753b64082a4aa4057374bcbcca74
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
include/kcl/kcl_mm.h:65:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:75:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:85:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:105:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:118:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
>> include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
>> include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
cc1: some warnings being treated as errors
--
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
include/kcl/kcl_mm.h:65:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:75:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:85:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:105:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:118:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
>> include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
>> include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
drivers/gpu/drm/ttm/ttm_bo.c: In function 'ttm_bo_mem_space_debug':
drivers/gpu/drm/ttm/ttm_bo.c:101:25: error: invalid initializer
struct drm_printer p = drm_debug_printer(TTM_PFX);
^~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
static inline void drm_dev_put(struct drm_device *dev)
^~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h: At top level:
include/kcl/kcl_mm.h:65:21: error: redefinition of 'kvmalloc'
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:635:21: note: previous definition of 'kvmalloc' was here
static inline void *kvmalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:75:21: error: redefinition of 'kvzalloc'
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:643:21: note: previous definition of 'kvzalloc' was here
static inline void *kvzalloc(size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:85:20: error: static declaration of 'kvfree' follows non-static declaration
static inline void kvfree(const void *addr)
^~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:663:13: note: previous declaration of 'kvfree' was here
extern void kvfree(const void *addr);
^~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:105:21: error: redefinition of 'kvmalloc_array'
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:648:21: note: previous definition of 'kvmalloc_array' was here
static inline void *kvmalloc_array(size_t n, size_t size, gfp_t flags)
^~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:8:0,
from <command-line>:0:
include/kcl/kcl_mm.h:118:21: error: redefinition of 'kvcalloc'
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from include/drm/drm_vma_manager.h:27:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/mm.h:658:21: note: previous definition of 'kvcalloc' was here
static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
^~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h:161:20: error: redefinition of 'dma_fence_set_error'
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from include/drm/drmP.h:58:0,
from include/kcl/kcl_drm.h:6,
from drivers/gpu/drm/ttm/backport/backport.h:6,
from <command-line>:0:
include/linux/dma-fence.h:517:20: note: previous definition of 'dma_fence_set_error' was here
static inline void dma_fence_set_error(struct dma_fence *fence,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:9:0,
from <command-line>:0:
include/kcl/kcl_fence.h: In function 'dma_fence_set_error':
include/kcl/kcl_fence.h:167:7: error: 'struct dma_fence' has no member named 'status'
fence->status = error;
^~
In file included from drivers/gpu/drm/ttm/backport/backport.h:10:0,
from <command-line>:0:
include/kcl/kcl_list.h: At top level:
include/kcl/kcl_list.h:6:20: error: redefinition of 'list_bulk_move_tail'
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from include/linux/preempt.h:11:0,
from include/linux/rcupdate.h:27,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/list.h:212:20: note: previous definition of 'list_bulk_move_tail' was here
static inline void list_bulk_move_tail(struct list_head *head,
^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
>> include/kcl/kcl_kref.h:7:28: error: redefinition of 'kref_read'
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from include/linux/kobject.h:23:0,
from include/linux/device.h:16,
from include/drm/drm_print.h:32,
from include/drm/drm_mm.h:49,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/linux/kref.h:36:28: note: previous definition of 'kref_read' was here
static inline unsigned int kref_read(const struct kref *kref)
^~~~~~~~~
In file included from drivers/gpu/drm/ttm/backport/backport.h:11:0,
from <command-line>:0:
include/kcl/kcl_kref.h: In function 'kref_read':
>> include/kcl/kcl_kref.h:9:21: error: passing argument 1 of 'atomic_read' from incompatible pointer type [-Werror=incompatible-pointer-types]
return atomic_read(&kref->refcount);
^
In file included from arch/x86/include/asm/atomic.h:265:0,
from include/linux/atomic.h:7,
from include/linux/rcupdate.h:25,
from include/linux/rbtree.h:34,
from include/drm/drm_mm.h:41,
from include/drm/drm_vma_manager.h:26,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/asm-generic/atomic-instrumented.h:24:1: note: expected 'const atomic_t * {aka const struct <anonymous> *}' but argument is of type 'const refcount_t * {aka const struct refcount_struct *}'
atomic_read(const atomic_t *v)
^~~~~~~~~~~
drivers/gpu/drm/ttm/ttm_bo_manager.c: In function 'ttm_bo_man_debug':
drivers/gpu/drm/ttm/ttm_bo_manager.c:145:26: error: passing argument 2 of 'drm_mm_print' from incompatible pointer type [-Werror=incompatible-pointer-types]
drm_mm_print(&rman->mm, printer);
^~~~~~~
In file included from include/drm/drm_vma_manager.h:26:0,
from include/kcl/kcl_drm_vma_manager.h:8,
from drivers/gpu/drm/ttm/backport/backport.h:5,
from <command-line>:0:
include/drm/drm_mm.h:547:6: note: expected 'struct drm_printer *' but argument is of type 'struct drm_printer *'
void drm_mm_print(const struct drm_mm *mm, struct drm_printer *p);
^~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/kref_read +7 include/kcl/kcl_kref.h
5
6 #if !defined(HAVE_KREF_READ)
> 7 static inline unsigned int kref_read(const struct kref *kref)
8 {
> 9 return atomic_read(&kref->refcount);
10 }
11 #endif
12
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
Re: [PATCH v3][RESEND] adp5061: Add support for battery charging enable
by kbuild test robot
Hi Alexandru,
I love your patch! Yet something to improve:
[auto build test ERROR on power-supply/for-next]
[cannot apply to v5.4-rc2 next-20191011]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Alexandru-Ardelean/adp5061-Add-s...
base: https://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply.git for-next
config: sparc64-allmodconfig (attached as .config)
compiler: sparc64-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=sparc64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All error/warnings (new ones prefixed by >>):
In file included from include/linux/kobject.h:20:0,
from include/linux/module.h:17,
from drivers/power/supply/adp5061.c:9:
>> drivers/power/supply/adp5061.c:738:44: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types]
static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
^
include/linux/sysfs.h:104:10: note: in definition of macro '__ATTR'
.show = _show, \
^~~~~
>> drivers/power/supply/adp5061.c:738:8: note: in expansion of macro 'DEVICE_ATTR'
static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
^~~~~~~~~~~
drivers/power/supply/adp5061.c:738:44: note: (near initialization for 'dev_attr_charging_enabled.show')
static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
^
include/linux/sysfs.h:104:10: note: in definition of macro '__ATTR'
.show = _show, \
^~~~~
>> drivers/power/supply/adp5061.c:738:8: note: in expansion of macro 'DEVICE_ATTR'
static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
^~~~~~~~~~~
drivers/power/supply/adp5061.c:739:6: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types]
adp5061_set_charging_enabled);
^
include/linux/sysfs.h:105:11: note: in definition of macro '__ATTR'
.store = _store, \
^~~~~~
>> drivers/power/supply/adp5061.c:738:8: note: in expansion of macro 'DEVICE_ATTR'
static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
^~~~~~~~~~~
drivers/power/supply/adp5061.c:739:6: note: (near initialization for 'dev_attr_charging_enabled.store')
adp5061_set_charging_enabled);
^
include/linux/sysfs.h:105:11: note: in definition of macro '__ATTR'
.store = _store, \
^~~~~~
>> drivers/power/supply/adp5061.c:738:8: note: in expansion of macro 'DEVICE_ATTR'
static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
^~~~~~~~~~~
cc1: some warnings being treated as errors
vim +738 drivers/power/supply/adp5061.c
737
> 738 static DEVICE_ATTR(charging_enabled, 0644, adp5061_get_charging_enabled,
739 adp5061_set_charging_enabled);
740
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months
[linux-next:master 5734/8210] mm/page_alloc.c:1956: undefined reference to `zone_pcp_update'
by kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 49afce6d47fe05ee01f1a41129b835fe4cca7eea
commit: 95ae151fc7286b8ce0e079321e95c76e5c071ca0 [5734/8210] mm, meminit: recalculate pcpu batch and high limits after init completes
config: x86_64-randconfig-g004-201943 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-14) 7.4.0
reproduce:
git checkout 95ae151fc7286b8ce0e079321e95c76e5c071ca0
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
Note: the linux-next/master HEAD 49afce6d47fe05ee01f1a41129b835fe4cca7eea builds fine.
It may have been fixed somewhere.
All errors (new ones prefixed by >>):
ld: mm/page_alloc.o: in function `page_alloc_init_late':
>> mm/page_alloc.c:1956: undefined reference to `zone_pcp_update'
vim +1956 mm/page_alloc.c
1940
1941 /* There will be num_node_state(N_MEMORY) threads */
1942 atomic_set(&pgdat_init_n_undone, num_node_state(N_MEMORY));
1943 for_each_node_state(nid, N_MEMORY) {
1944 kthread_run(deferred_init_memmap, NODE_DATA(nid), "pgdatinit%d", nid);
1945 }
1946
1947 /* Block until all are initialised */
1948 wait_for_completion(&pgdat_init_all_done_comp);
1949
1950 /*
1951 * The number of managed pages has changed due to the initialisation
1952 * so the pcpu batch and high limits needs to be updated or the limits
1953 * will be artificially small.
1954 */
1955 for_each_populated_zone(zone)
> 1956 zone_pcp_update(zone);
1957
1958 /*
1959 * We initialized the rest of the deferred pages. Permanently disable
1960 * on-demand struct page initialization.
1961 */
1962 static_branch_disable(&deferred_pages);
1963
1964 /* Reinit limits that are based on free pages after the kernel is up */
1965 files_maxfiles_init();
1966 #endif
1967
1968 /* Discard memblock private memory */
1969 memblock_discard();
1970
1971 for_each_node_state(nid, N_MEMORY)
1972 shuffle_free_memory(NODE_DATA(nid));
1973
1974 for_each_populated_zone(zone)
1975 set_zone_contiguous(zone);
1976
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
2 years, 8 months