dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [radeon-alex:drm-next-5.2-wip 105/353] drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:97:30: sparse: incorrect type in initializer (different address spaces)
@ 2019-03-14 11:12 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2019-03-14 11:12 UTC (permalink / raw)
  To: Likun Gao; +Cc: Alex Deucher, Kevin Wang, Huang Rui, kbuild-all, dri-devel

tree:   git://people.freedesktop.org/~agd5f/linux.git drm-next-5.2-wip
head:   efb39951130465f9b034827df336c421f7e8fa6d
commit: e0c27cbc634243e85b718515e95e4880d2cfaac9 [105/353] drm/amd/powerplay: update hw fini function to relase some memory
reproduce:
        # apt-get install sparse
        git checkout e0c27cbc634243e85b718515e95e4880d2cfaac9
        make ARCH=x86_64 allmodconfig
        make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__'


sparse warnings: (new ones prefixed by >>)

>> drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:97:30: sparse: incorrect type in initializer (different address spaces) @@    expected void [noderef] <asn:2>*ptr @@    got sn:2>*ptr @@
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:97:30:    expected void [noderef] <asn:2>*ptr
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:97:30:    got void *<noident>
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:177:30: sparse: expression using sizeof(void)
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:187:29: sparse: expression using sizeof(void)
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:187:29: sparse: expression using sizeof(void)
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:189:33: sparse: expression using sizeof(void)
   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:189:33: sparse: expression using sizeof(void)
--
>> drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:156:31: sparse: cast to restricted __le32
   drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:164:25: sparse: cast to restricted __le32
   drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:164:25: sparse: cast to restricted __le32
   drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:164:25: sparse: cast to restricted __le32
   include/linux/slab.h:664:13: sparse: undefined identifier '__builtin_mul_overflow'
   drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:348:5: sparse: symbol 'smu_v11_0_get_vbios_bootup_values' was not declared. Should it be static?
   drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:424:45: sparse: cast to restricted __le32
   drivers/gpu/drm/amd/amdgpu/../powerplay/smu_v11_0.c:438:46: sparse: cast to restricted __le32
   include/linux/slab.h:664:13: sparse: call with no type!

vim +97 drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c

961c75cf Christian König 2018-08-23   81  
961c75cf Christian König 2018-08-23   82  /**
b9d8c7f2 Yong Zhao       2019-02-25   83   * amdgpu_gmc_set_pte_pde - update the page tables using CPU
b9d8c7f2 Yong Zhao       2019-02-25   84   *
b9d8c7f2 Yong Zhao       2019-02-25   85   * @adev: amdgpu_device pointer
b9d8c7f2 Yong Zhao       2019-02-25   86   * @cpu_pt_addr: cpu address of the page table
b9d8c7f2 Yong Zhao       2019-02-25   87   * @gpu_page_idx: entry in the page table to update
b9d8c7f2 Yong Zhao       2019-02-25   88   * @addr: dst addr to write into pte/pde
b9d8c7f2 Yong Zhao       2019-02-25   89   * @flags: access flags
b9d8c7f2 Yong Zhao       2019-02-25   90   *
b9d8c7f2 Yong Zhao       2019-02-25   91   * Update the page tables using CPU.
b9d8c7f2 Yong Zhao       2019-02-25   92   */
b9d8c7f2 Yong Zhao       2019-02-25   93  int amdgpu_gmc_set_pte_pde(struct amdgpu_device *adev, void *cpu_pt_addr,
b9d8c7f2 Yong Zhao       2019-02-25   94  				uint32_t gpu_page_idx, uint64_t addr,
b9d8c7f2 Yong Zhao       2019-02-25   95  				uint64_t flags)
b9d8c7f2 Yong Zhao       2019-02-25   96  {
b9d8c7f2 Yong Zhao       2019-02-25  @97  	void __iomem *ptr = (void *)cpu_pt_addr;
b9d8c7f2 Yong Zhao       2019-02-25   98  	uint64_t value;
b9d8c7f2 Yong Zhao       2019-02-25   99  
b9d8c7f2 Yong Zhao       2019-02-25  100  	/*
b9d8c7f2 Yong Zhao       2019-02-25  101  	 * The following is for PTE only. GART does not have PDEs.
b9d8c7f2 Yong Zhao       2019-02-25  102  	*/
b9d8c7f2 Yong Zhao       2019-02-25  103  	value = addr & 0x0000FFFFFFFFF000ULL;
b9d8c7f2 Yong Zhao       2019-02-25  104  	value |= flags;
b9d8c7f2 Yong Zhao       2019-02-25  105  	writeq(value, ptr + (gpu_page_idx * 8));
b9d8c7f2 Yong Zhao       2019-02-25  106  	return 0;
b9d8c7f2 Yong Zhao       2019-02-25  107  }
b9d8c7f2 Yong Zhao       2019-02-25  108  

:::::: The code at line 97 was first introduced by commit
:::::: b9d8c7f2d8d51bd382062b30a52b0bfe1750c05e drm/amdgpu: Eliminate the set_pde_pte function pointer in amdgpu_gmc_funcs

:::::: TO: Yong Zhao <Yong.Zhao@amd.com>
:::::: CC: Alex Deucher <alexander.deucher@amd.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-03-14 11:13 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-14 11:12 [radeon-alex:drm-next-5.2-wip 105/353] drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c:97:30: sparse: incorrect type in initializer (different address spaces) kbuild test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox