drivers/vfio/pci/vfio_pci_nvlink2.c:100:9: error: implicit declaration of function 'mm_iommu_put'; did you mean
by kernel test robot
Hi Chen,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 585e5b17b92dead8a3aca4e3c9876fbca5f7e0ba
commit: ee8642162a9edd40daafd3fb894e3fd3f909e361 drm/nouveau: fix build error without CONFIG_IOMMU_API
date: 10 months ago
config: powerpc-randconfig-r032-20201109 (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
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout ee8642162a9edd40daafd3fb894e3fd3f909e361
# 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>
All errors (new ones prefixed by >>):
drivers/vfio/pci/vfio_pci_nvlink2.c: In function 'vfio_pci_nvgpu_release':
>> drivers/vfio/pci/vfio_pci_nvlink2.c:100:9: error: implicit declaration of function 'mm_iommu_put'; did you mean 'mm_iommu_init'? [-Werror=implicit-function-declaration]
100 | ret = mm_iommu_put(data->mm, data->mem);
| ^~~~~~~~~~~~
| mm_iommu_init
drivers/vfio/pci/vfio_pci_nvlink2.c: In function 'vfio_pci_nvgpu_mmap':
>> drivers/vfio/pci/vfio_pci_nvlink2.c:163:14: error: implicit declaration of function 'mm_iommu_newdev' [-Werror=implicit-function-declaration]
163 | ret = (int) mm_iommu_newdev(data->mm, data->useraddr,
| ^~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +100 drivers/vfio/pci/vfio_pci_nvlink2.c
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 91
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 92 static void vfio_pci_nvgpu_release(struct vfio_pci_device *vdev,
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 93 struct vfio_pci_region *region)
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 94 {
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 95 struct vfio_pci_nvgpu_data *data = region->data;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 96 long ret;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 97
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 98 /* If there were any mappings at all... */
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 99 if (data->mm) {
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 @100 ret = mm_iommu_put(data->mm, data->mem);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 101 WARN_ON(ret);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 102
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 103 mmdrop(data->mm);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 104 }
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 105
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 106 vfio_unregister_notifier(&data->gpdev->dev, VFIO_GROUP_NOTIFY,
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 107 &data->group_notifier);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 108
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 109 pnv_npu2_unmap_lpar_dev(data->gpdev);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 110
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 111 kfree(data);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 112 }
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 113
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 114 static vm_fault_t vfio_pci_nvgpu_mmap_fault(struct vm_fault *vmf)
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 115 {
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 116 vm_fault_t ret;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 117 struct vm_area_struct *vma = vmf->vma;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 118 struct vfio_pci_region *region = vma->vm_private_data;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 119 struct vfio_pci_nvgpu_data *data = region->data;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 120 unsigned long vmf_off = (vmf->address - vma->vm_start) >> PAGE_SHIFT;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 121 unsigned long nv2pg = data->gpu_hpa >> PAGE_SHIFT;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 122 unsigned long vm_pgoff = vma->vm_pgoff &
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 123 ((1U << (VFIO_PCI_OFFSET_SHIFT - PAGE_SHIFT)) - 1);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 124 unsigned long pfn = nv2pg + vm_pgoff + vmf_off;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 125
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 126 ret = vmf_insert_pfn(vma, vmf->address, pfn);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 127 trace_vfio_pci_nvgpu_mmap_fault(data->gpdev, pfn << PAGE_SHIFT,
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 128 vmf->address, ret);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 129
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 130 return ret;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 131 }
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 132
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 133 static const struct vm_operations_struct vfio_pci_nvgpu_mmap_vmops = {
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 134 .fault = vfio_pci_nvgpu_mmap_fault,
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 135 };
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 136
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 137 static int vfio_pci_nvgpu_mmap(struct vfio_pci_device *vdev,
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 138 struct vfio_pci_region *region, struct vm_area_struct *vma)
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 139 {
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 140 int ret;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 141 struct vfio_pci_nvgpu_data *data = region->data;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 142
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 143 if (data->useraddr)
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 144 return -EPERM;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 145
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 146 if (vma->vm_end - vma->vm_start > data->size)
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 147 return -EINVAL;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 148
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 149 vma->vm_private_data = region;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 150 vma->vm_flags |= VM_PFNMAP;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 151 vma->vm_ops = &vfio_pci_nvgpu_mmap_vmops;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 152
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 153 /*
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 154 * Calling mm_iommu_newdev() here once as the region is not
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 155 * registered yet and therefore right initialization will happen now.
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 156 * Other places will use mm_iommu_find() which returns
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 157 * registered @mem and does not go gup().
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 158 */
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 159 data->useraddr = vma->vm_start;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 160 data->mm = current->mm;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 161
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 162 atomic_inc(&data->mm->mm_count);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 @163 ret = (int) mm_iommu_newdev(data->mm, data->useraddr,
e66e02c4d96d335 Peng Hao 2019-07-02 164 vma_pages(vma), data->gpu_hpa, &data->mem);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 165
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 166 trace_vfio_pci_nvgpu_mmap(vdev->pdev, data->gpu_hpa, data->useraddr,
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 167 vma->vm_end - vma->vm_start, ret);
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 168
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 169 return ret;
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 170 }
7f92891778dff62 Alexey Kardashevskiy 2018-12-20 171
:::::: The code at line 100 was first introduced by commit
:::::: 7f92891778dff62303c070ac81de7b7d80de331a vfio_pci: Add NVIDIA GV100GL [Tesla V100 SXM2] subdriver
:::::: TO: Alexey Kardashevskiy <aik(a)ozlabs.ru>
:::::: CC: Michael Ellerman <mpe(a)ellerman.id.au>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
[radeon-alex:drm-next 77/94] drivers/gpu/drm/amd/amdgpu/smuio_v11_0.c:38:6: warning: no previous prototype for function 'smuio_v11_0_update_rom_clock_gating'
by kernel test robot
tree: git://people.freedesktop.org/~agd5f/linux.git drm-next
head: d99bd826bd53b4dd02219834e6fff7833c3c1ba0
commit: d1ffa512c635d5df81e18f2686b5e5060ca03f18 [77/94] drm/amdgpu: implement smuio v11_0 callbacks
config: x86_64-randconfig-a005-20201113 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 9e0c35655b6e8186baef8840b26ba4090503b554)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git remote add radeon-alex git://people.freedesktop.org/~agd5f/linux.git
git fetch --no-tags radeon-alex drm-next
git checkout d1ffa512c635d5df81e18f2686b5e5060ca03f18
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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 >>):
>> drivers/gpu/drm/amd/amdgpu/smuio_v11_0.c:38:6: warning: no previous prototype for function 'smuio_v11_0_update_rom_clock_gating' [-Wmissing-prototypes]
void smuio_v11_0_update_rom_clock_gating(struct amdgpu_device *adev, bool enable)
^
drivers/gpu/drm/amd/amdgpu/smuio_v11_0.c:38:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void smuio_v11_0_update_rom_clock_gating(struct amdgpu_device *adev, bool enable)
^
static
>> drivers/gpu/drm/amd/amdgpu/smuio_v11_0.c:59:6: warning: no previous prototype for function 'smuio_v11_0_get_clock_gating_state' [-Wmissing-prototypes]
void smuio_v11_0_get_clock_gating_state(struct amdgpu_device *adev, u32 *flags)
^
drivers/gpu/drm/amd/amdgpu/smuio_v11_0.c:59:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void smuio_v11_0_get_clock_gating_state(struct amdgpu_device *adev, u32 *flags)
^
static
2 warnings generated.
vim +/smuio_v11_0_update_rom_clock_gating +38 drivers/gpu/drm/amd/amdgpu/smuio_v11_0.c
37
> 38 void smuio_v11_0_update_rom_clock_gating(struct amdgpu_device *adev, bool enable)
39 {
40 u32 def, data;
41
42 /* enable/disable ROM CG is not supported on APU */
43 if (adev->flags & AMD_IS_APU)
44 return;
45
46 def = data = RREG32_SOC15(SMUIO, 0, mmCGTT_ROM_CLK_CTRL0);
47
48 if (enable && (adev->cg_flags & AMD_CG_SUPPORT_ROM_MGCG))
49 data &= ~(CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE0_MASK |
50 CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE1_MASK);
51 else
52 data |= CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE0_MASK |
53 CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE1_MASK;
54
55 if (def != data)
56 WREG32_SOC15(SMUIO, 0, mmCGTT_ROM_CLK_CTRL0, data);
57 }
58
> 59 void smuio_v11_0_get_clock_gating_state(struct amdgpu_device *adev, u32 *flags)
60 {
61 u32 data;
62
63 /* CGTT_ROM_CLK_CTRL0 is not available for APU */
64 if (adev->flags & AMD_IS_APU)
65 return;
66
67 data = RREG32_SOC15(SMUIO, 0, mmCGTT_ROM_CLK_CTRL0);
68 if (!(data & CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE0_MASK))
69 *flags |= AMD_CG_SUPPORT_ROM_MGCG;
70 }
71
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
[chrome-os:chromeos-4.19 27/50] drivers/gpu/drm/drm_hdcp.c:235:6: warning: no previous prototype for 'drm_hdcp_request_srm'
by kernel test robot
tree: https://chromium.googlesource.com/chromiumos/third_party/kernel chromeos-4.19
head: b9a3f5405fb3783912a70780b9f51b8942feed91
commit: 9602e2b071719b0f1e22a3a9ea2f5f3a6ba8f272 [27/50] UPSTREAM: drm: revocation check at drm subsystem
config: powerpc-ppc6xx_defconfig (attached as .config)
compiler: powerpc-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 remote add chrome-os https://chromium.googlesource.com/chromiumos/third_party/kernel
git fetch --no-tags chrome-os chromeos-4.19
git checkout 9602e2b071719b0f1e22a3a9ea2f5f3a6ba8f272
# 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>
All warnings (new ones prefixed by >>):
>> drivers/gpu/drm/drm_hdcp.c:235:6: warning: no previous prototype for 'drm_hdcp_request_srm' [-Wmissing-prototypes]
235 | void drm_hdcp_request_srm(struct drm_device *drm_dev)
| ^~~~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/drm_hdcp.c:317:5: warning: no previous prototype for 'drm_setup_hdcp_srm' [-Wmissing-prototypes]
317 | int drm_setup_hdcp_srm(struct class *drm_class)
| ^~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/drm_hdcp.c:327:6: warning: no previous prototype for 'drm_teardown_hdcp_srm' [-Wmissing-prototypes]
327 | void drm_teardown_hdcp_srm(struct class *drm_class)
| ^~~~~~~~~~~~~~~~~~~~~
vim +/drm_hdcp_request_srm +235 drivers/gpu/drm/drm_hdcp.c
234
> 235 void drm_hdcp_request_srm(struct drm_device *drm_dev)
236 {
237 char fw_name[36] = "display_hdcp_srm.bin";
238 const struct firmware *fw;
239
240 int ret;
241
242 ret = request_firmware_direct(&fw, (const char *)fw_name,
243 drm_dev->dev);
244 if (ret < 0)
245 goto exit;
246
247 if (fw->size && fw->data)
248 drm_hdcp_srm_update(fw->data, fw->size);
249
250 exit:
251 release_firmware(fw);
252 }
253
254 /**
255 * drm_hdcp_check_ksvs_revoked - Check the revoked status of the IDs
256 *
257 * @drm_dev: drm_device for which HDCP revocation check is requested
258 * @ksvs: List of KSVs (HDCP receiver IDs)
259 * @ksv_count: KSV count passed in through @ksvs
260 *
261 * This function reads the HDCP System renewability Message(SRM Table)
262 * from userspace as a firmware and parses it for the revoked HDCP
263 * KSVs(Receiver IDs) detected by DCP LLC. Once the revoked KSVs are known,
264 * revoked state of the KSVs in the list passed in by display drivers are
265 * decided and response is sent.
266 *
267 * SRM should be presented in the name of "display_hdcp_srm.bin".
268 *
269 * Returns:
270 * TRUE on any of the KSV is revoked, else FALSE.
271 */
272 bool drm_hdcp_check_ksvs_revoked(struct drm_device *drm_dev, u8 *ksvs,
273 u32 ksv_count)
274 {
275 u32 rev_ksv_cnt, cnt, i, j;
276 u8 *rev_ksv_list;
277
278 if (!srm_data)
279 return false;
280
281 mutex_lock(&srm_data->mutex);
282 drm_hdcp_request_srm(drm_dev);
283
284 rev_ksv_cnt = srm_data->revoked_ksv_cnt;
285 rev_ksv_list = srm_data->revoked_ksv_list;
286
287 /* If the Revoked ksv list is empty */
288 if (!rev_ksv_cnt || !rev_ksv_list) {
289 mutex_unlock(&srm_data->mutex);
290 return false;
291 }
292
293 for (cnt = 0; cnt < ksv_count; cnt++) {
294 rev_ksv_list = srm_data->revoked_ksv_list;
295 for (i = 0; i < rev_ksv_cnt; i++) {
296 for (j = 0; j < DRM_HDCP_KSV_LEN; j++)
297 if (ksvs[j] != rev_ksv_list[j]) {
298 break;
299 } else if (j == (DRM_HDCP_KSV_LEN - 1)) {
300 DRM_DEBUG("Revoked KSV is ");
301 drm_hdcp_print_ksv(ksvs);
302 mutex_unlock(&srm_data->mutex);
303 return true;
304 }
305 /* Move the offset to next KSV in the revoked list */
306 rev_ksv_list += DRM_HDCP_KSV_LEN;
307 }
308
309 /* Iterate to next ksv_offset */
310 ksvs += DRM_HDCP_KSV_LEN;
311 }
312 mutex_unlock(&srm_data->mutex);
313 return false;
314 }
315 EXPORT_SYMBOL_GPL(drm_hdcp_check_ksvs_revoked);
316
> 317 int drm_setup_hdcp_srm(struct class *drm_class)
318 {
319 srm_data = kzalloc(sizeof(*srm_data), GFP_KERNEL);
320 if (!srm_data)
321 return -ENOMEM;
322 mutex_init(&srm_data->mutex);
323
324 return 0;
325 }
326
> 327 void drm_teardown_hdcp_srm(struct class *drm_class)
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
Re: [PATCH 19/19] mips/vdso: Migrate to user_landing
by kernel test robot
Hi Dmitry,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on c34f157421f6905e6b4a79a312e9175dce2bc607]
url: https://github.com/0day-ci/linux/commits/Dmitry-Safonov/Add-generic-user_...
base: c34f157421f6905e6b4a79a312e9175dce2bc607
config: mips-randconfig-p002-20201109 (attached as .config)
compiler: mips-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/0day-ci/linux/commit/cf47146993b3d1866163ee1815829d9e7...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Dmitry-Safonov/Add-generic-user_landing-tracking/20201109-090354
git checkout cf47146993b3d1866163ee1815829d9e76b48807
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=mips
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/mips/kernel/signal.c:439:5: warning: no previous prototype for 'setup_sigcontext' [-Wmissing-prototypes]
439 | int setup_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc)
| ^~~~~~~~~~~~~~~~
arch/mips/kernel/signal.c:516:5: warning: no previous prototype for 'restore_sigcontext' [-Wmissing-prototypes]
516 | int restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc)
| ^~~~~~~~~~~~~~~~~~
arch/mips/kernel/signal.c:630:17: warning: no previous prototype for 'sys_sigreturn' [-Wmissing-prototypes]
630 | asmlinkage void sys_sigreturn(void)
| ^~~~~~~~~~~~~
arch/mips/kernel/signal.c:667:17: warning: no previous prototype for 'sys_rt_sigreturn' [-Wmissing-prototypes]
667 | asmlinkage void sys_rt_sigreturn(void)
| ^~~~~~~~~~~~~~~~
In file included from include/linux/mmzone.h:21,
from include/linux/gfp.h:6,
from include/linux/mm.h:10,
from arch/mips/kernel/signal.c:15:
arch/mips/kernel/signal.c: In function 'handle_signal':
include/linux/mm_types.h:500:31: error: 'TASK_SIZE_MAX' undeclared (first use in this function); did you mean 'TASK_SIZE_OF'?
500 | #define UNMAPPED_USER_LANDING TASK_SIZE_MAX
| ^~~~~~~~~~~~~
arch/mips/kernel/signal.c:814:14: note: in expansion of macro 'UNMAPPED_USER_LANDING'
814 | if (land == UNMAPPED_USER_LANDING)
| ^~~~~~~~~~~~~~~~~~~~~
include/linux/mm_types.h:500:31: note: each undeclared identifier is reported only once for each function it appears in
500 | #define UNMAPPED_USER_LANDING TASK_SIZE_MAX
| ^~~~~~~~~~~~~
arch/mips/kernel/signal.c:814:14: note: in expansion of macro 'UNMAPPED_USER_LANDING'
814 | if (land == UNMAPPED_USER_LANDING)
| ^~~~~~~~~~~~~~~~~~~~~
>> arch/mips/kernel/signal.c:848:34: warning: passing argument 1 of 'abi->setup_rt_frame' makes pointer from integer without a cast [-Wint-conversion]
848 | ret = abi->setup_rt_frame(land + abi->vdso->off_rt_sigreturn,
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| long unsigned int
arch/mips/kernel/signal.c:848:34: note: expected 'void *' but argument is of type 'long unsigned int'
>> arch/mips/kernel/signal.c:851:31: warning: passing argument 1 of 'abi->setup_frame' makes pointer from integer without a cast [-Wint-conversion]
851 | ret = abi->setup_frame(land + abi->vdso->off_sigreturn,
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| long unsigned int
arch/mips/kernel/signal.c:851:31: note: expected 'void *' but argument is of type 'long unsigned int'
arch/mips/kernel/signal.c: At top level:
arch/mips/kernel/signal.c:898:17: warning: no previous prototype for 'do_notify_resume' [-Wmissing-prototypes]
898 | asmlinkage void do_notify_resume(struct pt_regs *regs, void *unused,
| ^~~~~~~~~~~~~~~~
vim +848 arch/mips/kernel/signal.c
806
807 static void handle_signal(struct ksignal *ksig, struct pt_regs *regs)
808 {
809 unsigned long land = (unsigned long)current->mm->user_landing;
810 sigset_t *oldset = sigmask_to_save();
811 int ret = 1;
812 struct mips_abi *abi = current->thread.abi;
813
814 if (land == UNMAPPED_USER_LANDING)
815 goto err;
816 /*
817 * If we were emulating a delay slot instruction, exit that frame such
818 * that addresses in the sigframe are as expected for userland and we
819 * don't have a problem if we reuse the thread's frame for an
820 * instruction within the signal handler.
821 */
822 dsemul_thread_rollback(regs);
823
824 if (regs->regs[0]) {
825 switch(regs->regs[2]) {
826 case ERESTART_RESTARTBLOCK:
827 case ERESTARTNOHAND:
828 regs->regs[2] = EINTR;
829 break;
830 case ERESTARTSYS:
831 if (!(ksig->ka.sa.sa_flags & SA_RESTART)) {
832 regs->regs[2] = EINTR;
833 break;
834 }
835 fallthrough;
836 case ERESTARTNOINTR:
837 regs->regs[7] = regs->regs[26];
838 regs->regs[2] = regs->regs[0];
839 regs->cp0_epc -= 4;
840 }
841
842 regs->regs[0] = 0; /* Don't deal with this again. */
843 }
844
845 rseq_signal_deliver(ksig, regs);
846
847 if (sig_uses_siginfo(&ksig->ka, abi))
> 848 ret = abi->setup_rt_frame(land + abi->vdso->off_rt_sigreturn,
849 ksig, regs, oldset);
850 else
> 851 ret = abi->setup_frame(land + abi->vdso->off_sigreturn,
852 ksig, regs, oldset);
853
854 err:
855 signal_setup_done(ret, ksig, 0);
856 }
857
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
[PATCH] lib: zstd: fix semicolon.cocci warnings
by kernel test robot
From: kernel test robot <lkp(a)intel.com>
lib/zstd/compress/zstd_compress.c:3248:24-25: Unneeded semicolon
Remove unneeded semicolon.
Generated by: scripts/coccinelle/misc/semicolon.cocci
CC: Nick Terrell <terrelln(a)fb.com>
Reported-by: kernel test robot <lkp(a)intel.com>
Signed-off-by: kernel test robot <lkp(a)intel.com>
---
url: https://github.com/0day-ci/linux/commits/Nick-Terrell/lib-zstd-Add-zstd-c...
base: https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git master
zstd_compress.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/lib/zstd/compress/zstd_compress.c
+++ b/lib/zstd/compress/zstd_compress.c
@@ -3245,7 +3245,7 @@ size_t ZSTD_compress(void* dst, size_t d
ZSTD_CCtx* cctx = ZSTD_createCCtx();
RETURN_ERROR_IF(!cctx, memory_allocation, "ZSTD_createCCtx failed");
result = ZSTD_compressCCtx(cctx, dst, dstCapacity, src, srcSize, compressionLevel);
- ZSTD_freeCCtx(cctx);;
+ ZSTD_freeCCtx(cctx);
return result;
}
1 year, 10 months
Re: [PATCH 2/2] drm/mediatek: Use struct dma_buf_map in GEM vmap ops
by kernel test robot
Hi Thomas,
I love your patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[also build test WARNING on v5.10-rc3]
[cannot apply to next-20201112]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Thomas-Zimmermann/drm-Build-fixe...
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git f8394f232b1eab649ce2df5c5f15b0e528c92091
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/0day-ci/linux/commit/1e81f225d3ffc9e951faab8deb96ef620...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Thomas-Zimmermann/drm-Build-fixes-for-msm-and-mediatek/20201109-183736
git checkout 1e81f225d3ffc9e951faab8deb96ef6209db7742
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm64
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 drivers/gpu/drm/mediatek/mtk_drm_crtc.c:23:
>> drivers/gpu/drm/mediatek/mtk_drm_gem.h:48:63: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
48 | int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.h:49:66: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
49 | void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
--
In file included from drivers/gpu/drm/mediatek/mtk_drm_drv.c:32:
>> drivers/gpu/drm/mediatek/mtk_drm_gem.h:48:63: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
48 | int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.h:49:66: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
49 | void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_drv.c:316:24: warning: no previous prototype for 'mtk_drm_gem_prime_import' [-Wmissing-prototypes]
316 | struct drm_gem_object *mtk_drm_gem_prime_import(struct drm_device *dev,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_drv.c:337:20: error: initialization of 'void * (*)(struct drm_gem_object *)' from incompatible pointer type 'int (*)(struct drm_gem_object *, struct dma_buf_map *)' [-Werror=incompatible-pointer-types]
337 | .gem_prime_vmap = mtk_drm_gem_prime_vmap,
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_drv.c:337:20: note: (near initialization for 'mtk_drm_driver.gem_prime_vmap')
drivers/gpu/drm/mediatek/mtk_drm_drv.c:338:22: error: initialization of 'void (*)(struct drm_gem_object *, void *)' from incompatible pointer type 'void (*)(struct drm_gem_object *, struct dma_buf_map *)' [-Werror=incompatible-pointer-types]
338 | .gem_prime_vunmap = mtk_drm_gem_prime_vunmap,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_drv.c:338:22: note: (near initialization for 'mtk_drm_driver.gem_prime_vunmap')
cc1: some warnings being treated as errors
--
In file included from drivers/gpu/drm/mediatek/mtk_drm_gem.c:14:
>> drivers/gpu/drm/mediatek/mtk_drm_gem.h:48:63: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
48 | int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.h:49:66: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
49 | void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.c:232:63: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
232 | int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.c:232:5: error: conflicting types for 'mtk_drm_gem_prime_vmap'
232 | int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/mediatek/mtk_drm_gem.c:14:
drivers/gpu/drm/mediatek/mtk_drm_gem.h:48:5: note: previous declaration of 'mtk_drm_gem_prime_vmap' was here
48 | int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.c: In function 'mtk_drm_gem_prime_vmap':
drivers/gpu/drm/mediatek/mtk_drm_gem.c:259:2: error: implicit declaration of function 'dma_buf_map_set_vaddr' [-Werror=implicit-function-declaration]
259 | dma_buf_map_set_vaddr(map, mtk_gem->kvaddr);
| ^~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.c: At top level:
drivers/gpu/drm/mediatek/mtk_drm_gem.c:264:66: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
264 | void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.c:264:6: error: conflicting types for 'mtk_drm_gem_prime_vunmap'
264 | void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/mediatek/mtk_drm_gem.c:14:
drivers/gpu/drm/mediatek/mtk_drm_gem.h:49:6: note: previous declaration of 'mtk_drm_gem_prime_vunmap' was here
49 | void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mediatek/mtk_drm_gem.c: In function 'mtk_drm_gem_prime_vunmap':
drivers/gpu/drm/mediatek/mtk_drm_gem.c:267:19: error: dereferencing pointer to incomplete type 'struct dma_buf_map'
267 | void *vaddr = map->vaddr;
| ^~
cc1: some warnings being treated as errors
vim +48 drivers/gpu/drm/mediatek/mtk_drm_gem.h
36
37 void mtk_drm_gem_free_object(struct drm_gem_object *gem);
38 struct mtk_drm_gem_obj *mtk_drm_gem_create(struct drm_device *dev, size_t size,
39 bool alloc_kmap);
40 int mtk_drm_gem_dumb_create(struct drm_file *file_priv, struct drm_device *dev,
41 struct drm_mode_create_dumb *args);
42 int mtk_drm_gem_mmap(struct file *filp, struct vm_area_struct *vma);
43 int mtk_drm_gem_mmap_buf(struct drm_gem_object *obj,
44 struct vm_area_struct *vma);
45 struct sg_table *mtk_gem_prime_get_sg_table(struct drm_gem_object *obj);
46 struct drm_gem_object *mtk_gem_prime_import_sg_table(struct drm_device *dev,
47 struct dma_buf_attachment *attach, struct sg_table *sg);
> 48 int mtk_drm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
49 void mtk_drm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
50
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
[radeon-alex:drm-next 76/94] drivers/gpu/drm/amd/amdgpu/smuio_v9_0.c:38:6: warning: no previous prototype for function 'smuio_v9_0_update_rom_clock_gating'
by kernel test robot
tree: git://people.freedesktop.org/~agd5f/linux.git drm-next
head: d99bd826bd53b4dd02219834e6fff7833c3c1ba0
commit: 09aac699c3992c5ce12e82d3c9d1e4e19e1bd090 [76/94] drm/amdgpu: implement smuio v9_0 callbacks
config: x86_64-randconfig-a005-20201113 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 9e0c35655b6e8186baef8840b26ba4090503b554)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git remote add radeon-alex git://people.freedesktop.org/~agd5f/linux.git
git fetch --no-tags radeon-alex drm-next
git checkout 09aac699c3992c5ce12e82d3c9d1e4e19e1bd090
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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 >>):
>> drivers/gpu/drm/amd/amdgpu/smuio_v9_0.c:38:6: warning: no previous prototype for function 'smuio_v9_0_update_rom_clock_gating' [-Wmissing-prototypes]
void smuio_v9_0_update_rom_clock_gating(struct amdgpu_device *adev, bool enable)
^
drivers/gpu/drm/amd/amdgpu/smuio_v9_0.c:38:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void smuio_v9_0_update_rom_clock_gating(struct amdgpu_device *adev, bool enable)
^
static
>> drivers/gpu/drm/amd/amdgpu/smuio_v9_0.c:59:6: warning: no previous prototype for function 'smuio_v9_0_get_clock_gating_state' [-Wmissing-prototypes]
void smuio_v9_0_get_clock_gating_state(struct amdgpu_device *adev, u32 *flags)
^
drivers/gpu/drm/amd/amdgpu/smuio_v9_0.c:59:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void smuio_v9_0_get_clock_gating_state(struct amdgpu_device *adev, u32 *flags)
^
static
2 warnings generated.
vim +/smuio_v9_0_update_rom_clock_gating +38 drivers/gpu/drm/amd/amdgpu/smuio_v9_0.c
37
> 38 void smuio_v9_0_update_rom_clock_gating(struct amdgpu_device *adev, bool enable)
39 {
40 u32 def, data;
41
42 /* enable/disable ROM CG is not supported on APU */
43 if (adev->flags & AMD_IS_APU)
44 return;
45
46 def = data = RREG32_SOC15(SMUIO, 0, mmCGTT_ROM_CLK_CTRL0);
47
48 if (enable && (adev->cg_flags & AMD_CG_SUPPORT_ROM_MGCG))
49 data &= ~(CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE0_MASK |
50 CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE1_MASK);
51 else
52 data |= CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE0_MASK |
53 CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE1_MASK;
54
55 if (def != data)
56 WREG32_SOC15(SMUIO, 0, mmCGTT_ROM_CLK_CTRL0, data);
57 }
58
> 59 void smuio_v9_0_get_clock_gating_state(struct amdgpu_device *adev, u32 *flags)
60 {
61 u32 data;
62
63 /* CGTT_ROM_CLK_CTRL0 is not availabe for APUs */
64 if (adev->flags & AMD_IS_APU)
65 return;
66
67 data = RREG32_SOC15(SMUIO, 0, mmCGTT_ROM_CLK_CTRL0);
68 if (!(data & CGTT_ROM_CLK_CTRL0__SOFT_OVERRIDE0_MASK))
69 *flags |= AMD_CG_SUPPORT_ROM_MGCG;
70 }
71
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
Re: [PATCH 1/2] drm/msm: Use struct dma_buf_map in GEM vmap ops
by kernel test robot
Hi Thomas,
I love your patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[also build test WARNING on v5.10-rc3]
[cannot apply to next-20201112]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Thomas-Zimmermann/drm-Build-fixe...
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git f8394f232b1eab649ce2df5c5f15b0e528c92091
config: arm-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
# https://github.com/0day-ci/linux/commit/23efc78fd2f5e71dabe163eec64d60989...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Thomas-Zimmermann/drm-Build-fixes-for-msm-and-mediatek/20201109-183736
git checkout 23efc78fd2f5e71dabe163eec64d609891160175
# 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 >>):
In file included from drivers/gpu/drm/msm/msm_gpu.h:16,
from drivers/gpu/drm/msm/adreno/adreno_gpu.h:15,
from drivers/gpu/drm/msm/adreno/adreno_device.c:9:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/msm_gem.h:12,
from drivers/gpu/drm/msm/adreno/a6xx_gpu.c:5:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/adreno/a6xx_gpu.c:33:6: warning: no previous prototype for 'a6xx_idle' [-Wmissing-prototypes]
33 | bool a6xx_idle(struct msm_gpu *gpu, struct msm_ringbuffer *ring)
| ^~~~~~~~~
--
In file included from drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.h:10,
from drivers/gpu/drm/msm/disp/mdp5/mdp5_crtc.c:17:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/disp/mdp5/mdp5_crtc.c:579:5: warning: no previous prototype for 'mdp5_crtc_setup_pipeline' [-Wmissing-prototypes]
579 | int mdp5_crtc_setup_pipeline(struct drm_crtc *crtc,
| ^~~~~~~~~~~~~~~~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c:17:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c:297:5: warning: no previous prototype for 'mdp5_disable' [-Wmissing-prototypes]
297 | int mdp5_disable(struct mdp5_kms *mdp5_kms)
| ^~~~~~~~~~~~
drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c:317:5: warning: no previous prototype for 'mdp5_enable' [-Wmissing-prototypes]
317 | int mdp5_enable(struct mdp5_kms *mdp5_kms)
| ^~~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h:15,
from drivers/gpu/drm/msm/disp/dpu1/dpu_core_perf.c:15:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_core_perf.c: In function '_dpu_core_perf_calc_crtc':
drivers/gpu/drm/msm/disp/dpu1/dpu_core_perf.c:113:25: warning: variable 'dpu_cstate' set but not used [-Wunused-but-set-variable]
113 | struct dpu_crtc_state *dpu_cstate;
| ^~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:17:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c: In function 'dpu_encoder_virt_mode_set':
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:981:31: warning: variable 'num_dspp' set but not used [-Wunused-but-set-variable]
981 | int num_lm, num_ctl, num_pp, num_dspp;
| ^~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:976:30: warning: variable 'topology' set but not used [-Wunused-but-set-variable]
976 | struct msm_display_topology topology;
| ^~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c: In function '_dpu_encoder_virt_enable_helper':
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:1099:26: warning: variable 'priv' set but not used [-Wunused-but-set-variable]
1099 | struct msm_drm_private *priv;
| ^~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c: In function 'dpu_encoder_virt_disable':
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:1210:18: warning: variable 'dpu_kms' set but not used [-Wunused-but-set-variable]
1210 | struct dpu_kms *dpu_kms;
| ^~~~~~~
--
In file included from drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h:11,
from drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:9:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:122:19: warning: initialized field overwritten [-Woverride-init]
122 | .max_linewidth = 4096,
| ^~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:122:19: note: (near initialization for 'sm8250_dpu_caps.max_linewidth')
In file included from drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c:11:
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog_format.h:7:23: warning: 'qcom_compressed_supported_formats' defined but not used [-Wunused-const-variable=]
7 | static const uint32_t qcom_compressed_supported_formats[] = {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c:18:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
In file included from drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c:22:
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog_format.h:48:23: warning: 'plane_formats_yuv' defined but not used [-Wunused-const-variable=]
48 | static const uint32_t plane_formats_yuv[] = {
| ^~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog_format.h:17:23: warning: 'plane_formats' defined but not used [-Wunused-const-variable=]
17 | static const uint32_t plane_formats[] = {
| ^~~~~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/msm_drv.c:21:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.c:123:15: warning: no previous prototype for '_msm_ioremap' [-Wmissing-prototypes]
123 | void __iomem *_msm_ioremap(struct platform_device *pdev, const char *name,
| ^~~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.c:1016:24: error: initialization of 'void * (*)(struct drm_gem_object *)' from incompatible pointer type 'int (*)(struct drm_gem_object *, struct dma_buf_map *)' [-Werror=incompatible-pointer-types]
1016 | .gem_prime_vmap = msm_gem_prime_vmap,
| ^~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.c:1016:24: note: (near initialization for 'msm_driver.gem_prime_vmap')
drivers/gpu/drm/msm/msm_drv.c:1017:24: error: initialization of 'void (*)(struct drm_gem_object *, void *)' from incompatible pointer type 'void (*)(struct drm_gem_object *, struct dma_buf_map *)' [-Werror=incompatible-pointer-types]
1017 | .gem_prime_vunmap = msm_gem_prime_vunmap,
| ^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.c:1017:24: note: (near initialization for 'msm_driver.gem_prime_vunmap')
cc1: some warnings being treated as errors
--
In file included from drivers/gpu/drm/msm/msm_fence.c:9:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_fence.c: In function 'msm_fence_context_alloc':
drivers/gpu/drm/msm/msm_fence.c:23:2: warning: 'strncpy' specified bound 32 equals destination size [-Wstringop-truncation]
23 | strncpy(fctx->name, name, sizeof(fctx->name));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
In file included from drivers/gpu/drm/msm/msm_gem_prime.c:11:
>> drivers/gpu/drm/msm/msm_drv.h:299:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_drv.h:300:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_gem_prime.c:25:59: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
25 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_gem_prime.c:25:5: error: conflicting types for 'msm_gem_prime_vmap'
25 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/msm/msm_gem_prime.c:11:
drivers/gpu/drm/msm/msm_drv.h:299:5: note: previous declaration of 'msm_gem_prime_vmap' was here
299 | int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/msm_gem_prime.c: In function 'msm_gem_prime_vmap':
drivers/gpu/drm/msm/msm_gem_prime.c:32:2: error: implicit declaration of function 'dma_buf_map_set_vaddr' [-Werror=implicit-function-declaration]
32 | dma_buf_map_set_vaddr(map, vaddr);
| ^~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/msm_gem_prime.c: At top level:
drivers/gpu/drm/msm/msm_gem_prime.c:37:62: warning: 'struct dma_buf_map' declared inside parameter list will not be visible outside of this definition or declaration
37 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~
drivers/gpu/drm/msm/msm_gem_prime.c:37:6: error: conflicting types for 'msm_gem_prime_vunmap'
37 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map)
| ^~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/msm/msm_gem_prime.c:11:
drivers/gpu/drm/msm/msm_drv.h:300:6: note: previous declaration of 'msm_gem_prime_vunmap' was here
300 | void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
| ^~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
..
vim +299 drivers/gpu/drm/msm/msm_drv.h
275
276 int msm_gem_mmap_obj(struct drm_gem_object *obj,
277 struct vm_area_struct *vma);
278 int msm_gem_mmap(struct file *filp, struct vm_area_struct *vma);
279 vm_fault_t msm_gem_fault(struct vm_fault *vmf);
280 uint64_t msm_gem_mmap_offset(struct drm_gem_object *obj);
281 int msm_gem_get_iova(struct drm_gem_object *obj,
282 struct msm_gem_address_space *aspace, uint64_t *iova);
283 int msm_gem_get_and_pin_iova_range(struct drm_gem_object *obj,
284 struct msm_gem_address_space *aspace, uint64_t *iova,
285 u64 range_start, u64 range_end);
286 int msm_gem_get_and_pin_iova(struct drm_gem_object *obj,
287 struct msm_gem_address_space *aspace, uint64_t *iova);
288 uint64_t msm_gem_iova(struct drm_gem_object *obj,
289 struct msm_gem_address_space *aspace);
290 void msm_gem_unpin_iova(struct drm_gem_object *obj,
291 struct msm_gem_address_space *aspace);
292 struct page **msm_gem_get_pages(struct drm_gem_object *obj);
293 void msm_gem_put_pages(struct drm_gem_object *obj);
294 int msm_gem_dumb_create(struct drm_file *file, struct drm_device *dev,
295 struct drm_mode_create_dumb *args);
296 int msm_gem_dumb_map_offset(struct drm_file *file, struct drm_device *dev,
297 uint32_t handle, uint64_t *offset);
298 struct sg_table *msm_gem_prime_get_sg_table(struct drm_gem_object *obj);
> 299 int msm_gem_prime_vmap(struct drm_gem_object *obj, struct dma_buf_map *map);
300 void msm_gem_prime_vunmap(struct drm_gem_object *obj, struct dma_buf_map *map);
301 int msm_gem_prime_mmap(struct drm_gem_object *obj, struct vm_area_struct *vma);
302 struct drm_gem_object *msm_gem_prime_import_sg_table(struct drm_device *dev,
303 struct dma_buf_attachment *attach, struct sg_table *sg);
304 int msm_gem_prime_pin(struct drm_gem_object *obj);
305 void msm_gem_prime_unpin(struct drm_gem_object *obj);
306 void *msm_gem_get_vaddr(struct drm_gem_object *obj);
307 void *msm_gem_get_vaddr_active(struct drm_gem_object *obj);
308 void msm_gem_put_vaddr(struct drm_gem_object *obj);
309 int msm_gem_madvise(struct drm_gem_object *obj, unsigned madv);
310 int msm_gem_sync_object(struct drm_gem_object *obj,
311 struct msm_fence_context *fctx, bool exclusive);
312 void msm_gem_active_get(struct drm_gem_object *obj, struct msm_gpu *gpu);
313 void msm_gem_active_put(struct drm_gem_object *obj);
314 int msm_gem_cpu_prep(struct drm_gem_object *obj, uint32_t op, ktime_t *timeout);
315 int msm_gem_cpu_fini(struct drm_gem_object *obj);
316 void msm_gem_free_object(struct drm_gem_object *obj);
317 int msm_gem_new_handle(struct drm_device *dev, struct drm_file *file,
318 uint32_t size, uint32_t flags, uint32_t *handle, char *name);
319 struct drm_gem_object *msm_gem_new(struct drm_device *dev,
320 uint32_t size, uint32_t flags);
321 struct drm_gem_object *msm_gem_new_locked(struct drm_device *dev,
322 uint32_t size, uint32_t flags);
323 void *msm_gem_kernel_new(struct drm_device *dev, uint32_t size,
324 uint32_t flags, struct msm_gem_address_space *aspace,
325 struct drm_gem_object **bo, uint64_t *iova);
326 void *msm_gem_kernel_new_locked(struct drm_device *dev, uint32_t size,
327 uint32_t flags, struct msm_gem_address_space *aspace,
328 struct drm_gem_object **bo, uint64_t *iova);
329 void msm_gem_kernel_put(struct drm_gem_object *bo,
330 struct msm_gem_address_space *aspace, bool locked);
331 struct drm_gem_object *msm_gem_import(struct drm_device *dev,
332 struct dma_buf *dmabuf, struct sg_table *sgt);
333 void msm_gem_free_work(struct work_struct *work);
334
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months
[radeon-alex:drm-next 12/94] drivers/gpu/drm/amd/amdgpu/../display/dc/dcn21/dcn21_dccg.c:46:6: warning: no previous prototype for function 'dccg21_update_dpp_dto'
by kernel test robot
tree: git://people.freedesktop.org/~agd5f/linux.git drm-next
head: d99bd826bd53b4dd02219834e6fff7833c3c1ba0
commit: c07cbc1f04ecba00f99e313de3190db5e7438e81 [12/94] drm/amd/display: update dpp dto phase and modulo.
config: arm64-randconfig-r003-20201113 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 9e0c35655b6e8186baef8840b26ba4090503b554)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
git remote add radeon-alex git://people.freedesktop.org/~agd5f/linux.git
git fetch --no-tags radeon-alex drm-next
git checkout c07cbc1f04ecba00f99e313de3190db5e7438e81
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64
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 >>):
>> drivers/gpu/drm/amd/amdgpu/../display/dc/dcn21/dcn21_dccg.c:46:6: warning: no previous prototype for function 'dccg21_update_dpp_dto' [-Wmissing-prototypes]
void dccg21_update_dpp_dto(struct dccg *dccg, int dpp_inst, int req_dppclk)
^
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn21/dcn21_dccg.c:46:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void dccg21_update_dpp_dto(struct dccg *dccg, int dpp_inst, int req_dppclk)
^
static
1 warning generated.
vim +/dccg21_update_dpp_dto +46 drivers/gpu/drm/amd/amdgpu/../display/dc/dcn21/dcn21_dccg.c
30
31 #define TO_DCN_DCCG(dccg)\
32 container_of(dccg, struct dcn_dccg, base)
33
34 #define REG(reg) \
35 (dccg_dcn->regs->reg)
36
37 #undef FN
38 #define FN(reg_name, field_name) \
39 dccg_dcn->dccg_shift->field_name, dccg_dcn->dccg_mask->field_name
40
41 #define CTX \
42 dccg_dcn->base.ctx
43 #define DC_LOGGER \
44 dccg->ctx->logger
45
> 46 void dccg21_update_dpp_dto(struct dccg *dccg, int dpp_inst, int req_dppclk)
47 {
48 struct dcn_dccg *dccg_dcn = TO_DCN_DCCG(dccg);
49
50 if (dccg->ref_dppclk) {
51 int ref_dppclk = dccg->ref_dppclk;
52 int modulo = ref_dppclk / 10000;
53
54 if (req_dppclk) {
55 int phase;
56
57 /*
58 * program DPP DTO phase and modulo as below
59 * phase = dpp_pipe_clk_mhz / 10
60 * module = dpp_global_clk_mhz / 10
61 * dmub FW will read phase value to
62 * determine minimum dpp clk and notify smu
63 * to set clks for more power saving in PSR state
64 */
65 phase = (req_dppclk + 9999) / 10000;
66
67 if (phase > 0xff) {
68 ASSERT(false);
69 phase = 0xff;
70 }
71
72 REG_SET_2(DPPCLK_DTO_PARAM[dpp_inst], 0,
73 DPPCLK0_DTO_PHASE, phase,
74 DPPCLK0_DTO_MODULO, modulo);
75 REG_UPDATE(DPPCLK_DTO_CTRL,
76 DPPCLK_DTO_ENABLE[dpp_inst], 1);
77 } else {
78 /*
79 * set phase to 10 if dpp isn't used to
80 * prevent hard hang if access dpp register
81 * on unused pipe
82 */
83 REG_SET_2(DPPCLK_DTO_PARAM[dpp_inst], 0,
84 DPPCLK0_DTO_PHASE, 10,
85 DPPCLK0_DTO_MODULO, modulo);
86
87 REG_UPDATE(DPPCLK_DTO_CTRL,
88 DPPCLK_DTO_ENABLE[dpp_inst], 0);
89 }
90 }
91
92 dccg->pipe_dppclk_khz[dpp_inst] = req_dppclk;
93 }
94
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 10 months