[linuxppc:next-test 43/86] arch/powerpc/kernel/vdso64/gettimeofday.S:29: Error: unrecognized opcode: `get_datapage'
by kernel test robot
tree: https://github.com/linuxppc/linux next-test
head: a0e12ec27095fc3f3c3d94c86fccf08ffb58d9de
commit: ec53bfbca2559623d146321f8b3da4ec65379fff [43/86] powerpc/vdso64: Switch from __get_datapage() to get_datapage inline macro
config: powerpc-defconfig (attached as .config)
compiler: powerpc64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout ec53bfbca2559623d146321f8b3da4ec65379fff
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Note: the linuxppc/next-test HEAD a0e12ec27095fc3f3c3d94c86fccf08ffb58d9de builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
arch/powerpc/kernel/vdso64/gettimeofday.S: Assembler messages:
>> arch/powerpc/kernel/vdso64/gettimeofday.S:29: Error: unrecognized opcode: `get_datapage'
arch/powerpc/kernel/vdso64/gettimeofday.S:74: Error: unrecognized opcode: `get_datapage'
arch/powerpc/kernel/vdso64/gettimeofday.S:191: Error: unrecognized opcode: `get_datapage'
arch/powerpc/kernel/vdso64/gettimeofday.S:224: Error: unrecognized opcode: `get_datapage'
vim +29 arch/powerpc/kernel/vdso64/gettimeofday.S
14
15 .text
16 /*
17 * Exact prototype of gettimeofday
18 *
19 * int __kernel_gettimeofday(struct timeval *tv, struct timezone *tz);
20 *
21 */
22 V_FUNCTION_BEGIN(__kernel_gettimeofday)
23 .cfi_startproc
24 mflr r12
25 .cfi_register lr,r12
26
27 mr r11,r3 /* r11 holds tv */
28 mr r10,r4 /* r10 holds tz */
> 29 get_datapage r3, r0
30 cmpldi r11,0 /* check if tv is NULL */
31 beq 2f
32 lis r7,1000000@ha /* load up USEC_PER_SEC */
33 addi r7,r7,1000000@l
34 bl V_LOCAL_FUNC(__do_get_tspec) /* get sec/us from tb & kernel */
35 std r4,TVAL64_TV_SEC(r11) /* store sec in tv */
36 std r5,TVAL64_TV_USEC(r11) /* store usec in tv */
37 2: cmpldi r10,0 /* check if tz is NULL */
38 beq 1f
39 lwz r4,CFG_TZ_MINUTEWEST(r3)/* fill tz */
40 lwz r5,CFG_TZ_DSTTIME(r3)
41 stw r4,TZONE_TZ_MINWEST(r10)
42 stw r5,TZONE_TZ_DSTTIME(r10)
43 1: mtlr r12
44 crclr cr0*4+so
45 li r3,0 /* always success */
46 blr
47 .cfi_endproc
48 V_FUNCTION_END(__kernel_gettimeofday)
49
50
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
[radeon-alex:amd-staging-drm-next 628/1015] drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v10_3.c:268:17: sparse: sparse: cast removes address space '<asn:1>' of expression
by kernel test robot
tree: git://people.freedesktop.org/~agd5f/linux.git amd-staging-drm-next
head: 3c831e196bd7543977d4acd506064636809f1dcf
commit: 10be8791067fc672e44fcaa7afb886390909a0c0 [628/1015] drm/amdkfd: Support Sienna_Cichlid KFD v4
config: x86_64-randconfig-s022-20200710 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-14) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.2-37-gc9676a3b-dirty
git checkout 10be8791067fc672e44fcaa7afb886390909a0c0
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v10_3.c:268:17: sparse: sparse: cast removes address space '<asn:1>' of expression
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v10_3.c:270:17: sparse: sparse: cast removes address space '<asn:1>' of expression
vim +268 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v10_3.c
192
193 static int hqd_load_v10_3(struct kgd_dev *kgd, void *mqd, uint32_t pipe_id,
194 uint32_t queue_id, uint32_t __user *wptr,
195 uint32_t wptr_shift, uint32_t wptr_mask,
196 struct mm_struct *mm)
197 {
198 struct amdgpu_device *adev = get_amdgpu_device(kgd);
199 struct v10_compute_mqd *m;
200 uint32_t *mqd_hqd;
201 uint32_t reg, hqd_base, data;
202
203 m = get_mqd(mqd);
204
205 pr_debug("Load hqd of pipe %d queue %d\n", pipe_id, queue_id);
206 acquire_queue(kgd, pipe_id, queue_id);
207
208 /* HIQ is set during driver init period with vmid set to 0*/
209 if (m->cp_hqd_vmid == 0) {
210 uint32_t value, mec, pipe;
211
212 mec = (pipe_id / adev->gfx.mec.num_pipe_per_mec) + 1;
213 pipe = (pipe_id % adev->gfx.mec.num_pipe_per_mec);
214
215 pr_debug("kfd: set HIQ, mec:%d, pipe:%d, queue:%d.\n",
216 mec, pipe, queue_id);
217 value = RREG32(SOC15_REG_OFFSET(GC, 0, mmRLC_CP_SCHEDULERS));
218 value = REG_SET_FIELD(value, RLC_CP_SCHEDULERS, scheduler1,
219 ((mec << 5) | (pipe << 3) | queue_id | 0x80));
220 WREG32(SOC15_REG_OFFSET(GC, 0, mmRLC_CP_SCHEDULERS), value);
221 }
222
223 /* HQD registers extend from CP_MQD_BASE_ADDR to CP_HQD_EOP_WPTR_MEM. */
224 mqd_hqd = &m->cp_mqd_base_addr_lo;
225 hqd_base = SOC15_REG_OFFSET(GC, 0, mmCP_MQD_BASE_ADDR);
226
227 for (reg = hqd_base;
228 reg <= SOC15_REG_OFFSET(GC, 0, mmCP_HQD_PQ_WPTR_HI); reg++)
229 WREG32(reg, mqd_hqd[reg - hqd_base]);
230
231
232 /* Activate doorbell logic before triggering WPTR poll. */
233 data = REG_SET_FIELD(m->cp_hqd_pq_doorbell_control,
234 CP_HQD_PQ_DOORBELL_CONTROL, DOORBELL_EN, 1);
235 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_PQ_DOORBELL_CONTROL), data);
236
237 if (wptr) {
238 /* Don't read wptr with get_user because the user
239 * context may not be accessible (if this function
240 * runs in a work queue). Instead trigger a one-shot
241 * polling read from memory in the CP. This assumes
242 * that wptr is GPU-accessible in the queue's VMID via
243 * ATC or SVM. WPTR==RPTR before starting the poll so
244 * the CP starts fetching new commands from the right
245 * place.
246 *
247 * Guessing a 64-bit WPTR from a 32-bit RPTR is a bit
248 * tricky. Assume that the queue didn't overflow. The
249 * number of valid bits in the 32-bit RPTR depends on
250 * the queue size. The remaining bits are taken from
251 * the saved 64-bit WPTR. If the WPTR wrapped, add the
252 * queue size.
253 */
254 uint32_t queue_size =
255 2 << REG_GET_FIELD(m->cp_hqd_pq_control,
256 CP_HQD_PQ_CONTROL, QUEUE_SIZE);
257 uint64_t guessed_wptr = m->cp_hqd_pq_rptr & (queue_size - 1);
258
259 if ((m->cp_hqd_pq_wptr_lo & (queue_size - 1)) < guessed_wptr)
260 guessed_wptr += queue_size;
261 guessed_wptr += m->cp_hqd_pq_wptr_lo & ~(queue_size - 1);
262 guessed_wptr += (uint64_t)m->cp_hqd_pq_wptr_hi << 32;
263
264 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_PQ_WPTR_LO),
265 lower_32_bits(guessed_wptr));
266 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_PQ_WPTR_HI),
267 upper_32_bits(guessed_wptr));
> 268 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_PQ_WPTR_POLL_ADDR),
269 lower_32_bits((uint64_t)wptr));
270 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_PQ_WPTR_POLL_ADDR_HI),
271 upper_32_bits((uint64_t)wptr));
272 pr_debug("%s setting CP_PQ_WPTR_POLL_CNTL1 to %x\n", __func__,
273 (uint32_t)get_queue_mask(adev, pipe_id, queue_id));
274 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_PQ_WPTR_POLL_CNTL1),
275 (uint32_t)get_queue_mask(adev, pipe_id, queue_id));
276 }
277
278 /* Start the EOP fetcher */
279 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_EOP_RPTR),
280 REG_SET_FIELD(m->cp_hqd_eop_rptr,
281 CP_HQD_EOP_RPTR, INIT_FETCHER, 1));
282
283 data = REG_SET_FIELD(m->cp_hqd_active, CP_HQD_ACTIVE, ACTIVE, 1);
284 WREG32(SOC15_REG_OFFSET(GC, 0, mmCP_HQD_ACTIVE), data);
285
286 release_queue(kgd);
287
288 return 0;
289 }
290
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
arch/arm/kvm/../../../virt/kvm/kvm_main.c:633:12: warning: no previous prototype for 'kvm_arch_post_init_vm'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 1df0d8960499e58963fd6c8ac75e544f2b417b29
commit: 1aa9b9572b10529c2e64e2b8f44025d86e124308 kvm: x86: mmu: Recovery of shattered NX large pages
date: 8 months ago
config: arm-axm55xx_defconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 1aa9b9572b10529c2e64e2b8f44025d86e124308
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> arch/arm/kvm/../../../virt/kvm/kvm_main.c:633:12: warning: no previous prototype for 'kvm_arch_post_init_vm' [-Wmissing-prototypes]
633 | int __weak kvm_arch_post_init_vm(struct kvm *kvm)
| ^~~~~~~~~~~~~~~~~~~~~
>> arch/arm/kvm/../../../virt/kvm/kvm_main.c:642:13: warning: no previous prototype for 'kvm_arch_pre_destroy_vm' [-Wmissing-prototypes]
642 | void __weak kvm_arch_pre_destroy_vm(struct kvm *kvm)
| ^~~~~~~~~~~~~~~~~~~~~~~
vim +/kvm_arch_post_init_vm +633 arch/arm/kvm/../../../virt/kvm/kvm_main.c
628
629 /*
630 * Called after the VM is otherwise initialized, but just before adding it to
631 * the vm_list.
632 */
> 633 int __weak kvm_arch_post_init_vm(struct kvm *kvm)
634 {
635 return 0;
636 }
637
638 /*
639 * Called just after removing the VM from the vm_list, but before doing any
640 * other destruction.
641 */
> 642 void __weak kvm_arch_pre_destroy_vm(struct kvm *kvm)
643 {
644 }
645
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
arch/microblaze/include/asm/cmpxchg.h:19:50: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 1df0d8960499e58963fd6c8ac75e544f2b417b29
commit: 80591e61a0f7e88deaada69844e4a31280c4a38f kbuild: tell sparse about the $ARCH
date: 8 months ago
config: microblaze-randconfig-s031-20200711 (attached as .config)
compiler: microblaze-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.2-37-gc9676a3b-dirty
git checkout 80591e61a0f7e88deaada69844e4a31280c4a38f
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=microblaze
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> arch/microblaze/include/asm/cmpxchg.h:19:50: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
>> arch/microblaze/include/asm/cmpxchg.h:19:50: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
>> arch/microblaze/include/asm/cmpxchg.h:19:50: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
>> arch/microblaze/include/asm/cmpxchg.h:19:50: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
include/asm-generic/cmpxchg-local.h:30:42: sparse: sparse: cast truncates bits from constant value (deadbeef becomes ef)
include/asm-generic/cmpxchg-local.h:34:44: sparse: sparse: cast truncates bits from constant value (deadbeef becomes beef)
vim +19 arch/microblaze/include/asm/cmpxchg.h
c40d04df152a11 David Howells 2012-03-28 8
c40d04df152a11 David Howells 2012-03-28 9 static inline unsigned long __xchg(unsigned long x, volatile void *ptr,
c40d04df152a11 David Howells 2012-03-28 10 int size)
c40d04df152a11 David Howells 2012-03-28 11 {
c40d04df152a11 David Howells 2012-03-28 12 unsigned long ret;
c40d04df152a11 David Howells 2012-03-28 13 unsigned long flags;
c40d04df152a11 David Howells 2012-03-28 14
c40d04df152a11 David Howells 2012-03-28 15 switch (size) {
c40d04df152a11 David Howells 2012-03-28 16 case 1:
c40d04df152a11 David Howells 2012-03-28 17 local_irq_save(flags);
c40d04df152a11 David Howells 2012-03-28 18 ret = *(volatile unsigned char *)ptr;
c40d04df152a11 David Howells 2012-03-28 @19 *(volatile unsigned char *)ptr = x;
c40d04df152a11 David Howells 2012-03-28 20 local_irq_restore(flags);
c40d04df152a11 David Howells 2012-03-28 21 break;
c40d04df152a11 David Howells 2012-03-28 22
c40d04df152a11 David Howells 2012-03-28 23 case 4:
c40d04df152a11 David Howells 2012-03-28 24 local_irq_save(flags);
c40d04df152a11 David Howells 2012-03-28 25 ret = *(volatile unsigned long *)ptr;
c40d04df152a11 David Howells 2012-03-28 26 *(volatile unsigned long *)ptr = x;
c40d04df152a11 David Howells 2012-03-28 27 local_irq_restore(flags);
c40d04df152a11 David Howells 2012-03-28 28 break;
c40d04df152a11 David Howells 2012-03-28 29 default:
c40d04df152a11 David Howells 2012-03-28 30 __bad_xchg(ptr, size), ret = 0;
c40d04df152a11 David Howells 2012-03-28 31 break;
c40d04df152a11 David Howells 2012-03-28 32 }
c40d04df152a11 David Howells 2012-03-28 33
c40d04df152a11 David Howells 2012-03-28 34 return ret;
c40d04df152a11 David Howells 2012-03-28 35 }
c40d04df152a11 David Howells 2012-03-28 36
:::::: The code at line 19 was first introduced by commit
:::::: c40d04df152a1111c5bbcb632278394dabd2b73d Disintegrate asm/system.h for Microblaze
:::::: TO: David Howells <dhowells(a)redhat.com>
:::::: CC: David Howells <dhowells(a)redhat.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
[radeon-alex:amd-staging-drm-next 468/1015] drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c:172:15: sparse: sparse: incorrect type in argument 1 (different address spaces)
by kernel test robot
tree: git://people.freedesktop.org/~agd5f/linux.git amd-staging-drm-next
head: 3c831e196bd7543977d4acd506064636809f1dcf
commit: 3a2b9affb4c366dac8a088156c644cf329701816 [468/1015] drm/amdkfd: Track SDMA utilization per process
config: x86_64-randconfig-s022-20200710 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-14) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.2-37-gc9676a3b-dirty
git checkout 3a2b9affb4c366dac8a088156c644cf329701816
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c:140:6: sparse: sparse: symbol 'increment_queue_count' was not declared. Should it be static?
drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c:148:6: sparse: sparse: symbol 'decrement_queue_count' was not declared. Should it be static?
>> drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c:172:15: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] <asn:1> * @@ got unsigned long long [usertype] * @@
>> drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c:172:15: sparse: expected void const volatile [noderef] <asn:1> *
drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c:172:15: sparse: got unsigned long long [usertype] *
vim +172 drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_device_queue_manager.c
139
> 140 void increment_queue_count(struct device_queue_manager *dqm,
141 enum kfd_queue_type type)
142 {
143 dqm->active_queue_count++;
144 if (type == KFD_QUEUE_TYPE_COMPUTE || type == KFD_QUEUE_TYPE_DIQ)
145 dqm->active_cp_queue_count++;
146 }
147
148 void decrement_queue_count(struct device_queue_manager *dqm,
149 enum kfd_queue_type type)
150 {
151 dqm->active_queue_count--;
152 if (type == KFD_QUEUE_TYPE_COMPUTE || type == KFD_QUEUE_TYPE_DIQ)
153 dqm->active_cp_queue_count--;
154 }
155
156 int read_sdma_queue_counter(struct queue *q, uint64_t *val)
157 {
158 int ret;
159 uint64_t tmp = 0;
160
161 if (!q || !val)
162 return -EINVAL;
163 /*
164 * SDMA activity counter is stored at queue's RPTR + 0x8 location.
165 */
166 if (!access_ok((const void __user *)((uint64_t)q->properties.read_ptr +
167 sizeof(uint64_t)), sizeof(uint64_t))) {
168 pr_err("Can't access sdma queue activity counter\n");
169 return -EFAULT;
170 }
171
> 172 ret = get_user(tmp, (uint64_t *)((uint64_t)(q->properties.read_ptr) +
173 sizeof(uint64_t)));
174 if (!ret) {
175 *val = tmp;
176 }
177
178 return ret;
179 }
180
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
arch/arm/kvm/../../../virt/kvm/arm/arm.c:147:5: warning: no previous prototype for 'kvm_arch_create_vcpu_debugfs'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 1df0d8960499e58963fd6c8ac75e544f2b417b29
commit: 741cbbae0768b828be2d48331eb371a4f08bbea8 KVM: remove kvm_arch_has_vcpu_debugfs()
date: 11 months ago
config: arm-axm55xx_defconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 741cbbae0768b828be2d48331eb371a4f08bbea8
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> arch/arm/kvm/../../../virt/kvm/arm/arm.c:147:5: warning: no previous prototype for 'kvm_arch_create_vcpu_debugfs' [-Wmissing-prototypes]
147 | int kvm_arch_create_vcpu_debugfs(struct kvm_vcpu *vcpu)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/kvm_arch_create_vcpu_debugfs +147 arch/arm/kvm/../../../virt/kvm/arm/arm.c
749cf76c5a363e arch/arm/kvm/arm.c Christoffer Dall 2013-01-20 146
235539b48a2357 arch/arm/kvm/arm.c Luiz Capitulino 2016-09-07 @147 int kvm_arch_create_vcpu_debugfs(struct kvm_vcpu *vcpu)
235539b48a2357 arch/arm/kvm/arm.c Luiz Capitulino 2016-09-07 148 {
235539b48a2357 arch/arm/kvm/arm.c Luiz Capitulino 2016-09-07 149 return 0;
235539b48a2357 arch/arm/kvm/arm.c Luiz Capitulino 2016-09-07 150 }
235539b48a2357 arch/arm/kvm/arm.c Luiz Capitulino 2016-09-07 151
:::::: The code at line 147 was first introduced by commit
:::::: 235539b48a2357da28f52d66d04bec04f3dcb9dd kvm: add stubs for arch specific debugfs support
:::::: TO: Luiz Capitulino <lcapitulino(a)redhat.com>
:::::: CC: Paolo Bonzini <pbonzini(a)redhat.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
Re: [PATCH v7 08/12] device core: Introduce DMA range map, supplanting dma_pfn_offset
by kernel test robot
Hi Jim,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on pci/next]
[also build test ERROR on robh/for-next sunxi/sunxi/for-next linuxtv-media/master usb/usb-testing linus/master v5.8-rc4 next-20200710]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Jim-Quinlan/PCI-brcmstb-enable-P...
base: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next
config: m68k-randconfig-r035-20200710 (attached as .config)
compiler: m68k-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=m68k
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/of/device.c: In function 'of_dma_configure':
>> drivers/of/device.c:116:37: error: dereferencing pointer to incomplete type 'const struct bus_dma_region'
116 | for (dma_start = ~(dma_addr_t)0; r->size; r++) {
| ^~
>> drivers/of/device.c:116:46: error: increment of pointer to an incomplete type 'const struct bus_dma_region'
116 | for (dma_start = ~(dma_addr_t)0; r->size; r++) {
| ^~
In file included from drivers/of/device.c:8:
At top level:
include/linux/dma-mapping.h:498:12: warning: 'dma_attach_offset_range' defined but not used [-Wunused-function]
498 | static int dma_attach_offset_range(struct device *dev, phys_addr_t cpu_start,
| ^~~~~~~~~~~~~~~~~~~~~~~
--
drivers/of/address.c: In function 'dma_create_offset_map':
>> drivers/of/address.c:929:37: error: dereferencing pointer to incomplete type 'struct bus_dma_region'
929 | r = kcalloc(num_ranges + 1, sizeof(*r), GFP_KERNEL);
| ^~
>> drivers/of/address.c:950:4: error: increment of pointer to an incomplete type 'struct bus_dma_region'
950 | r++;
| ^~
In file included from include/linux/pci-dma-compat.h:8,
from include/linux/pci.h:2415,
from drivers/of/address.c:11:
At top level:
include/linux/dma-mapping.h:498:12: warning: 'dma_attach_offset_range' defined but not used [-Wunused-function]
498 | static int dma_attach_offset_range(struct device *dev, phys_addr_t cpu_start,
| ^~~~~~~~~~~~~~~~~~~~~~~
vim +116 drivers/of/device.c
74
75 /**
76 * of_dma_configure - Setup DMA configuration
77 * @dev: Device to apply DMA configuration
78 * @np: Pointer to OF node having DMA configuration
79 * @force_dma: Whether device is to be set up by of_dma_configure() even if
80 * DMA capability is not explicitly described by firmware.
81 *
82 * Try to get devices's DMA configuration from DT and update it
83 * accordingly.
84 *
85 * If platform code needs to use its own special DMA configuration, it
86 * can use a platform bus notifier and handle BUS_NOTIFY_ADD_DEVICE events
87 * to fix up DMA configuration.
88 */
89 int of_dma_configure(struct device *dev, struct device_node *np, bool force_dma)
90 {
91 const struct iommu_ops *iommu;
92 const struct bus_dma_region *map;
93 dma_addr_t dma_start = 0;
94 u64 mask, end, size = 0;
95 bool coherent;
96 int ret;
97
98 map = of_dma_get_range(np);
99 ret = PTR_ERR_OR_ZERO(map);
100 if (ret < 0) {
101 /*
102 * For legacy reasons, we have to assume some devices need
103 * DMA configuration regardless of whether "dma-ranges" is
104 * correctly specified or not.
105 */
106 if (!force_dma)
107 return ret == -ENODEV ? 0 : ret;
108
109 dma_start = 0;
110 map = NULL;
111 } else if (map) {
112 const struct bus_dma_region *r = map;
113 dma_addr_t dma_end = 0;
114
115 /* Determine the overall bounds of all DMA regions */
> 116 for (dma_start = ~(dma_addr_t)0; r->size; r++) {
117 /* Take lower and upper limits */
118 if (r->dma_start < dma_start)
119 dma_start = r->dma_start;
120 if (r->dma_start + r->size > dma_end)
121 dma_end = r->dma_start + r->size;
122 }
123 size = dma_end - dma_start;
124
125 /*
126 * Add a work around to treat the size as mask + 1 in case
127 * it is defined in DT as a mask.
128 */
129 if (size & 1) {
130 dev_warn(dev, "Invalid size 0x%llx for dma-range(s)\n", size);
131 size = size + 1;
132 }
133
134 if (!size) {
135 dev_err(dev, "Adjusted size 0x%llx invalid\n", size);
136 kfree(map);
137 return -EINVAL;
138 }
139 }
140
141 /*
142 * If @dev is expected to be DMA-capable then the bus code that created
143 * it should have initialised its dma_mask pointer by this point. For
144 * now, we'll continue the legacy behaviour of coercing it to the
145 * coherent mask if not, but we'll no longer do so quietly.
146 */
147 if (!dev->dma_mask) {
148 dev_warn(dev, "DMA mask not set\n");
149 dev->dma_mask = &dev->coherent_dma_mask;
150 }
151
152 if (!size && dev->coherent_dma_mask)
153 size = max(dev->coherent_dma_mask, dev->coherent_dma_mask + 1);
154 else if (!size)
155 size = 1ULL << 32;
156
157 /*
158 * Limit coherent and dma mask based on size and default mask
159 * set by the driver.
160 */
161 end = dma_start + size - 1;
162 mask = DMA_BIT_MASK(ilog2(end) + 1);
163 dev->coherent_dma_mask &= mask;
164 *dev->dma_mask &= mask;
165 /* ...but only set bus limit if we found valid dma-ranges earlier */
166 if (!ret)
167 dev->bus_dma_limit = end;
168
169 coherent = of_dma_is_coherent(np);
170 dev_dbg(dev, "device is%sdma coherent\n",
171 coherent ? " " : " not ");
172
173 iommu = of_iommu_configure(dev, np);
174 if (PTR_ERR(iommu) == -EPROBE_DEFER) {
175 kfree(map);
176 return -EPROBE_DEFER;
177 }
178
179 dev_dbg(dev, "device is%sbehind an iommu\n",
180 iommu ? " " : " not ");
181
182 arch_setup_dma_ops(dev, dma_start, size, iommu, coherent);
183
184 dev->dma_range_map = map;
185 return 0;
186 }
187 EXPORT_SYMBOL_GPL(of_dma_configure);
188
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
[vhost:config-endian 33/36] drivers/vdpa/vdpa_sim/vdpa_sim.c:335:21: sparse: sparse: incorrect type in assignment (different base types)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git config-endian
head: 6aef2378a564fea8e69c0419d94dc3ad9b4b7a99
commit: 0cf222ef876b95893406eebe685e595d88de0950 [33/36] virtio_net: correct tags for config space fields
config: parisc-randconfig-s032-20200710 (attached as .config)
compiler: hppa-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.2-37-gc9676a3b-dirty
git checkout 0cf222ef876b95893406eebe685e595d88de0950
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=parisc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/vdpa/vdpa_sim/vdpa_sim.c:335:21: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __virtio16 [usertype] mtu @@ got int @@
>> drivers/vdpa/vdpa_sim/vdpa_sim.c:335:21: sparse: expected restricted __virtio16 [usertype] mtu
>> drivers/vdpa/vdpa_sim/vdpa_sim.c:335:21: sparse: got int
>> drivers/vdpa/vdpa_sim/vdpa_sim.c:336:24: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted __virtio16 [usertype] status @@ got int @@
>> drivers/vdpa/vdpa_sim/vdpa_sim.c:336:24: sparse: expected restricted __virtio16 [usertype] status
drivers/vdpa/vdpa_sim/vdpa_sim.c:336:24: sparse: got int
vim +335 drivers/vdpa/vdpa_sim/vdpa_sim.c
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 306
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 307 static struct vdpasim *vdpasim_create(void)
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 308 {
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 309 struct virtio_net_config *config;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 310 struct vdpasim *vdpasim;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 311 struct device *dev;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 312 int ret = -ENOMEM;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 313
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 314 vdpasim = vdpa_alloc_device(struct vdpasim, vdpa, NULL,
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 315 &vdpasim_net_config_ops);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 316 if (!vdpasim)
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 317 goto err_alloc;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 318
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 319 INIT_WORK(&vdpasim->work, vdpasim_work);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 320 spin_lock_init(&vdpasim->lock);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 321
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 322 dev = &vdpasim->vdpa.dev;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 323 dev->coherent_dma_mask = DMA_BIT_MASK(64);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 324 set_dma_ops(dev, &vdpasim_dma_ops);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 325
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 326 vdpasim->iommu = vhost_iotlb_alloc(2048, 0);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 327 if (!vdpasim->iommu)
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 328 goto err_iommu;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 329
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 330 vdpasim->buffer = kmalloc(PAGE_SIZE, GFP_KERNEL);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 331 if (!vdpasim->buffer)
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 332 goto err_iommu;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 333
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 334 config = &vdpasim->config;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 @335 config->mtu = 1500;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 @336 config->status = VIRTIO_NET_S_LINK_UP;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 337 eth_random_addr(config->mac);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 338
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 339 vringh_set_iotlb(&vdpasim->vqs[0].vring, vdpasim->iommu);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 340 vringh_set_iotlb(&vdpasim->vqs[1].vring, vdpasim->iommu);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 341
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 342 vdpasim->vdpa.dma_dev = dev;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 343 ret = vdpa_register_device(&vdpasim->vdpa);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 344 if (ret)
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 345 goto err_iommu;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 346
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 347 return vdpasim;
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 348
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 349 err_iommu:
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 350 put_device(dev);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 351 err_alloc:
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 352 return ERR_PTR(ret);
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 353 }
2c53d0f64c06f4 drivers/virtio/vdpa/vdpa_sim/vdpa_sim.c Jason Wang 2020-03-26 354
:::::: The code at line 335 was first introduced by commit
:::::: 2c53d0f64c06f4580588ef16f50f63a112117a02 vdpasim: vDPA device simulator
:::::: TO: Jason Wang <jasowang(a)redhat.com>
:::::: CC: Michael S. Tsirkin <mst(a)redhat.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months
[riscv:for-next 11/12] arch/riscv/include/asm/kexec.h:38:1: warning: 'extern' is not at beginning of declaration
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git for-next
head: 04d2b1ac88e94574429a62839bc0e982cebb854c
commit: f85daef543eb3e98e28905ddb813151443911571 [11/12] RISC-V: Add kexec support
config: riscv-allyesconfig (attached as .config)
compiler: riscv64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout f85daef543eb3e98e28905ddb813151443911571
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=riscv
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
In file included from include/linux/kexec.h:28,
from arch/riscv/kernel/machine_kexec.c:7:
>> arch/riscv/include/asm/kexec.h:38:1: warning: 'extern' is not at beginning of declaration [-Wold-style-declaration]
38 | const extern unsigned char riscv_kexec_relocate[];
| ^~~~~
arch/riscv/include/asm/kexec.h:39:1: warning: 'extern' is not at beginning of declaration [-Wold-style-declaration]
39 | const extern unsigned int riscv_kexec_relocate_size;
| ^~~~~
>> arch/riscv/kernel/machine_kexec.c:128:6: warning: no previous prototype for 'machine_shutdown' [-Wmissing-prototypes]
128 | void machine_shutdown(void)
| ^~~~~~~~~~~~~~~~
>> arch/riscv/kernel/machine_kexec.c:150:1: warning: no previous prototype for 'machine_crash_shutdown' [-Wmissing-prototypes]
150 | machine_crash_shutdown(struct pt_regs *regs)
| ^~~~~~~~~~~~~~~~~~~~~~
vim +/extern +38 arch/riscv/include/asm/kexec.h
37
> 38 const extern unsigned char riscv_kexec_relocate[];
39 const extern unsigned int riscv_kexec_relocate_size;
40
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years, 2 months