DRM debugfs cleanup take 3
Subsystems (26)
Hi guys,
I've messed up the last send out. Cleanup up some issues reported by people with the accel drivers (duplicated files) and rebased the result.
Apart from that the same approach we already discussed previously.
Please review and comment,
Christian.
PATCH 1/7 drm: remove drm_dev_set_unique
Not used by any drivers any more, the only use case in drm_dev_init() can be inlined now.
--- drivers/gpu/drm/drm_drv.c | 26 ++++---------------------- include/drm/drm_drv.h | 2 -- 2 files changed, 4 insertions(+), 24 deletions(-)
drivers/gpu/drm/drm_drv.c +4 -22
@@ -691,9 +691,11 @@ static int drm_dev_init(struct drm_device *dev, } } - ret =drm_dev_set_unique (dev,dev_name (parent)); -if (ret) + dev->unique =drmm_kstrdup (dev,dev_name (parent),GFP_KERNEL ); +if (!dev->unique) { + ret = -ENOMEM ; goto err; + }return 0 ;
@@ -1000,26 +1002,6 @@ void drm_dev_unregister(struct drm_device *dev) }EXPORT_SYMBOL (drm_dev_unregister); -/** -* drm_dev_set_unique - Set the unique name of a DRM device -* @dev: device of which to set the unique name -* @name: unique name -* -* Sets the unique name of a DRM device using the specified string. This is -* already done by drm_dev_init(), drivers should only override the default -* unique name for backwards compatibility reasons. -* -* Return: 0 on success or a negative error code on failure. -*/ -int drm_dev_set_unique (struct drm_device *dev,const char *name) -{ -drmm_kfree (dev, dev->unique); - dev->unique =drmm_kstrdup (dev, name,GFP_KERNEL ); - -return dev->unique ?0 : -ENOMEM ; -} -EXPORT_SYMBOL (drm_dev_set_unique); -/* * DRM Core * The DRM core module initializes all global DRM objects and makes them
include/drm/drm_drv.h +0 -2
@@ -584,8 +584,6 @@ static inline bool drm_drv_uses_atomic_modeset(struct drm_device *dev) } -int drm_dev_set_unique (struct drm_device *dev,const char *name); -/* TODO: Inline drm_firmware_drivers_only() in all its callers. */ static inline bool drm_firmware_drivers_only (void ) {
Signature · 1 line
2.34.1
Re: [PATCH 1/7] drm: remove drm_dev_set_unique
Quoted 4 lines · Christian König
Not used by any drivers any more, the only use case in
drm_dev_init()can be inlined now.Signed-off-by Christian König <[email protected]>
PATCH 2/7 drm/tegra: allow compile test on !ARM
In reply to Christian KönigThis compile tests on x86 just perfectly fine.
--- drivers/gpu/drm/tegra/Kconfig | 2 +- drivers/gpu/host1x/Kconfig | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/tegra/Kconfig +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0-only config DRM_TEGRA tristate "NVIDIA Tegra DRM" - depends on ARCH_TEGRA || (ARM && COMPILE_TEST) + depends on ARCH_TEGRA || COMPILE_TEST depends on COMMON_CLK depends on DRM depends on OF
drivers/gpu/host1x/Kconfig +1 -1
@@ -5,7 +5,7 @@ config TEGRA_HOST1X_CONTEXT_BUS config TEGRA_HOST1X tristate "NVIDIA Tegra host1x driver" - depends on ARCH_TEGRA || (ARM && COMPILE_TEST) + depends on ARCH_TEGRA || COMPILE_TEST select DMA_SHARED_BUFFER select TEGRA_HOST1X_CONTEXT_BUS select IOMMU_IOVA
Signature · 1 line
2.34.1
kernel test robot
build botRe: [Intel-gfx] [PATCH 2/7] drm/tegra: allow compile test on !ARM
I love your patch! Yet something to improve:
Hi Christian,
I love your patch! Yet something to improve:
[auto build test ERROR on drm-misc/drm-misc-next]
[cannot apply to drm-tip/drm-tip]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Christian-K-nig/drm-tegra-allow-compile-test-on-ARM/20230316-172205 base: git://anongit.freedesktop.org/drm/drm-misc drm-misc-next patch link: https://lore.kernel.org/r/20230316082035.567520-3-christian.koenig%40amd.com patch subject: [Intel-gfx] [PATCH 2/7] drm/tegra: allow compile test on !ARM config: mips-allmodconfig (https://download.01.org/0day-ci/archive/20230317/[email protected]/config) compiler: mips-linux-gcc (GCC) 12.1.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/intel-lab-lkp/linux/commit/8a2dbd34b0290b78a1ac2252d451abbcbcd50666
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Christian-K-nig/drm-tegra-allow-compile-test-on-ARM/20230316-172205
git checkout 8a2dbd34b0290b78a1ac2252d451abbcbcd50666
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=mips olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash drivers/gpu/drm/tegra/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <[email protected]>
| Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
drivers/gpu/drm/tegra/gem.c: In function 'tegra_bo_mmap':
>> drivers/gpu/drm/tegra/gem.c:188:24: error: implicit declaration of function 'vmap'; did you mean 'kmap'? [-Werror=implicit-function-declaration]
188 | return vmap(obj->pages, obj->num_pages, VM_MAP,
| ^~~~
| kmap
>> drivers/gpu/drm/tegra/gem.c:188:57: error: 'VM_MAP' undeclared (first use in this function); did you mean 'VM_MTE'?
188 | return vmap(obj->pages, obj->num_pages, VM_MAP,
| ^~~~~~
| VM_MTE
drivers/gpu/drm/tegra/gem.c:188:57: note: each undeclared identifier is reported only once for each function it appears in
drivers/gpu/drm/tegra/gem.c: In function 'tegra_bo_munmap':
>> drivers/gpu/drm/tegra/gem.c:203:17: error: implicit declaration of function 'vunmap'; did you mean 'kunmap'? [-Werror=implicit-function-declaration]
203 | vunmap(addr);
| ^~~~~~
| kunmap
drivers/gpu/drm/tegra/gem.c: In function 'tegra_bo_mmap':
drivers/gpu/drm/tegra/gem.c:191:1: error: control reaches end of non-void function [-Werror=return-type]
191 | }
| ^
cc1: some warnings being treated as errors
--
drivers/gpu/drm/tegra/fb.c: In function 'tegra_fbdev_probe':
>> drivers/gpu/drm/tegra/fb.c:276:29: error: implicit declaration of function 'vmap'; did you mean 'kmap'? [-Werror=implicit-function-declaration]
276 | bo->vaddr = vmap(bo->pages, bo->num_pages, VM_MAP,
| ^~~~
| kmap
>> drivers/gpu/drm/tegra/fb.c:276:60: error: 'VM_MAP' undeclared (first use in this function); did you mean 'VM_MTE'?
276 | bo->vaddr = vmap(bo->pages, bo->num_pages, VM_MAP,
| ^~~~~~
| VM_MTE
drivers/gpu/drm/tegra/fb.c:276:60: note: each undeclared identifier is reported only once for each function it appears in
drivers/gpu/drm/tegra/fb.c: In function 'tegra_fbdev_exit':
>> drivers/gpu/drm/tegra/fb.c:359:25: error: implicit declaration of function 'vunmap'; did you mean 'kunmap'? [-Werror=implicit-function-declaration]
359 | vunmap(bo->vaddr);
| ^~~~~~
| kunmapcc1: some warnings being treated as errors
vim +188 drivers/gpu/drm/tegra/gem.c
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 175
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 176 static void *tegra_bo_mmap(struct host1x_bo *bo)
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 177 {
3be8274341499cf drivers/gpu/host1x/drm/gem.c Thierry Reding 2013-09-24 178 struct tegra_bo *obj = host1x_to_tegra_bo(bo);
7938f4218168ae9 drivers/gpu/drm/tegra/gem.c Lucas De Marchi 2022-02-04 179 struct iosys_map map;
6619ccf1bb1d0eb drivers/gpu/drm/tegra/gem.c Thomas Zimmermann 2020-09-25 180 int ret;
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 181
6619ccf1bb1d0eb drivers/gpu/drm/tegra/gem.c Thomas Zimmermann 2020-09-25 182 if (obj->vaddr) {
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 183 return obj->vaddr;
6619ccf1bb1d0eb drivers/gpu/drm/tegra/gem.c Thomas Zimmermann 2020-09-25 184 } else if (obj->gem.import_attach) {
f66d48c8cc8d996 drivers/gpu/drm/tegra/gem.c Dmitry Osipenko 2022-10-17 185 ret = dma_buf_vmap_unlocked(obj->gem.import_attach->dmabuf, &map);
6619ccf1bb1d0eb drivers/gpu/drm/tegra/gem.c Thomas Zimmermann 2020-09-25 186 return ret ? NULL : map.vaddr;
6619ccf1bb1d0eb drivers/gpu/drm/tegra/gem.c Thomas Zimmermann 2020-09-25 187 } else {
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 @188 return vmap(obj->pages, obj->num_pages, VM_MAP,
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 189 pgprot_writecombine(PAGE_KERNEL));
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 190 }
6619ccf1bb1d0eb drivers/gpu/drm/tegra/gem.c Thomas Zimmermann 2020-09-25 191 }
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 192
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 193 static void tegra_bo_munmap(struct host1x_bo *bo, void *addr)
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 194 {
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 195 struct tegra_bo *obj = host1x_to_tegra_bo(bo);
7938f4218168ae9 drivers/gpu/drm/tegra/gem.c Lucas De Marchi 2022-02-04 196 struct iosys_map map = IOSYS_MAP_INIT_VADDR(addr);
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 197
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 198 if (obj->vaddr)
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 199 return;
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 200 else if (obj->gem.import_attach)
f66d48c8cc8d996 drivers/gpu/drm/tegra/gem.c Dmitry Osipenko 2022-10-17 201 dma_buf_vunmap_unlocked(obj->gem.import_attach->dmabuf, &map);
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 202 else
7ecada3cc44798c drivers/gpu/drm/tegra/gem.c Arto Merilainen 2016-11-08 @203 vunmap(addr);
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 204 }
de2ba664c30fcdb drivers/gpu/host1x/drm/gem.c Arto Merilainen 2013-03-22 205 Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests
PATCH 3/7 drm/debugfs: stop calling debugfs_init() for the render node
In reply to Christian KönigWe want to remove per minor debugfs directories. Start by stopping drivers from adding anything inside of those.
--- drivers/gpu/drm/drm_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/drm_debugfs.c +1 -1
@@ -242,7 +242,7 @@ int drm_debugfs_init(struct drm_minor *minor, int minor_id,drm_client_debugfs_init (minor); } -if (dev->driver->debugfs_init) +if (dev->driver->debugfs_init && dev->render != minor) dev->driver->debugfs_init (minor);list_for_each_entry_safe (entry, tmp, &dev->debugfs_list, list) {
Signature · 1 line
2.34.1
PATCH 4/7 drm/debugfs: rework debugfs directory creation v2
In reply to Christian KönigInstead of the per minor directories only create a single debugfs directory for the whole device directly when the device is initialized.
For DRM devices each minor gets a symlink to the per device directory for now until we can be sure that this isn't useful any more in any way.
Accel devices create only the per device directory and also drops the mid layer callback to create driver specific files.
v2: cleanup accel component as well
--- drivers/accel/drm_accel.c | 30 ++++++++------- drivers/gpu/drm/drm_atomic.c | 4 +- drivers/gpu/drm/drm_client.c | 4 +- drivers/gpu/drm/drm_crtc_internal.h | 2 +- drivers/gpu/drm/drm_debugfs.c | 60 ++++++++++++++++++----------- drivers/gpu/drm/drm_drv.c | 18 +++++++-- drivers/gpu/drm/drm_framebuffer.c | 4 +- drivers/gpu/drm/drm_internal.h | 16 +++++--- include/drm/drm_accel.h | 9 ++++- include/drm/drm_client.h | 2 +- include/drm/drm_device.h | 7 ++++ include/drm/drm_drv.h | 8 ++++ include/drm/drm_file.h | 1 + 13 files changed, 110 insertions(+), 55 deletions(-)
drivers/accel/drm_accel.c +17 -13
@@ -79,29 +79,33 @@ static const struct drm_info_list accel_debugfs_list[] = {#define ACCEL_DEBUGFS_ENTRIES ARRAY_SIZE(accel_debugfs_list)/** -* accel_debugfs_init() - Initialize debugfs for accel minor +* accel_debugfs_init() - Register debugfs for accel minor +* @dev: Pointer to the device instance. +* +* This function creates a root directory for the device in debugfs. +*/ +void accel_debugfs_init (struct drm_device *dev) +{ +drm_debugfs_dev_init (dev, accel_debugfs_root); +} + +/** +* accel_debugfs_register() - Register debugfs for device * @minor: Pointer to the drm_minor instance. * @minor_id: The minor's id * -* This function initializes the drm minor's debugfs members and creates -* a root directory for the minor in debugfs. It also creates common files -* for accelerators and calls the driver's debugfs init callback. +* Creates common files for accelerators. */ -void accel_debugfs_init (struct drm_minor *minor,int minor_id) +void accel_debugfs_register (struct drm_device *dev) { -struct drm_device *dev = minor->dev; -char name[64 ]; +struct drm_minor *minor = dev->accel;INIT_LIST_HEAD (&minor->debugfs_list);mutex_init (&minor->debugfs_lock); -sprintf (name,"%d" , minor_id); - minor->debugfs_root =debugfs_create_dir (name, accel_debugfs_root); + minor->debugfs_root = dev->debugfs_root;drm_debugfs_create_files (accel_debugfs_list,ACCEL_DEBUGFS_ENTRIES , - minor->debugfs_root, minor); - -if (dev->driver->debugfs_init) - dev->driver->debugfs_init (minor); + dev->debugfs_root, minor); }/**
drivers/gpu/drm/drm_atomic.c +2 -2
@@ -1771,9 +1771,9 @@ static const struct drm_debugfs_info drm_atomic_debugfs_list[] = { {"state", drm_state_info, 0}, }; -void drm_atomic_debugfs_init(struct drm_minor *minor) +void drm_atomic_debugfs_init(struct drm_device *dev) { - drm_debugfs_add_files(minor->dev, drm_atomic_debugfs_list, + drm_debugfs_add_files(dev, drm_atomic_debugfs_list, ARRAY_SIZE(drm_atomic_debugfs_list)); } #endif
drivers/gpu/drm/drm_client.c +2 -2
@@ -514,9 +514,9 @@ static const struct drm_debugfs_info drm_client_debugfs_list[] = { { "internal_clients", drm_client_debugfs_internal_clients, 0 }, }; -void drm_client_debugfs_init(struct drm_minor *minor) +void drm_client_debugfs_init(struct drm_device *dev) { - drm_debugfs_add_files(minor->dev, drm_client_debugfs_list, + drm_debugfs_add_files(dev, drm_client_debugfs_list, ARRAY_SIZE(drm_client_debugfs_list)); } #endif
drivers/gpu/drm/drm_crtc_internal.h +1 -1
@@ -232,7 +232,7 @@ int drm_mode_dirtyfb_ioctl(struct drm_device *dev,/* drm_atomic.c */ #ifdef CONFIG_DEBUG_FS struct drm_minor ; -void drm_atomic_debugfs_init (struct drm_minor *minor); +void drm_atomic_debugfs_init (struct drm_device *dev);#endif int __drm_atomic_helper_disable_plane(struct drm_plane *plane,
drivers/gpu/drm/drm_debugfs.c +37 -23
104 lines not on this page · raw message
drivers/gpu/drm/drm_drv.c +14 -4
@@ -172,10 +172,9 @@ static int drm_minor_register(struct drm_device *dev, unsigned int type)if (!minor)return 0 ; -if (minor->type ==DRM_MINOR_ACCEL ) { -accel_debugfs_init (minor, minor->index); - }else { - ret =drm_debugfs_init (minor, minor->index, drm_debugfs_root); +if (minor->type !=DRM_MINOR_ACCEL ) { + ret =drm_debugfs_register (minor, minor->index, + drm_debugfs_root);if (ret) {DRM_ERROR ("DRM: Failed to initialize /sys/kernel/debug/dri.\n" ); goto err_debugfs;
@@ -697,6 +696,11 @@ static int drm_dev_init(struct drm_device *dev, goto err; } +if (drm_core_check_feature (dev,DRIVER_COMPUTE_ACCEL )) +accel_debugfs_init (dev); +else +drm_debugfs_dev_init (dev, drm_debugfs_root); +return 0 ; err:
@@ -916,6 +920,11 @@ int drm_dev_register(struct drm_device *dev, unsigned long flags)if (drm_dev_needs_global_mutex (dev))mutex_lock (&drm_global_mutex); +if (drm_core_check_feature (dev,DRIVER_COMPUTE_ACCEL )) +accel_debugfs_register (dev); +else +drm_debugfs_dev_register (dev); + ret =drm_minor_register (dev,DRM_MINOR_RENDER );if (ret) goto err_minors;
@@ -999,6 +1008,7 @@ void drm_dev_unregister(struct drm_device *dev)drm_minor_unregister (dev,DRM_MINOR_ACCEL );drm_minor_unregister (dev,DRM_MINOR_PRIMARY );drm_minor_unregister (dev,DRM_MINOR_RENDER ); +drm_debugfs_dev_fini (dev); }EXPORT_SYMBOL (drm_dev_unregister);
drivers/gpu/drm/drm_framebuffer.c +2 -2
@@ -1222,9 +1222,9 @@ static const struct drm_debugfs_info drm_framebuffer_debugfs_list[] = { { "framebuffer", drm_framebuffer_info, 0 }, }; -void drm_framebuffer_debugfs_init(struct drm_minor *minor) +void drm_framebuffer_debugfs_init(struct drm_device *dev) { - drm_debugfs_add_files(minor->dev, drm_framebuffer_debugfs_list, + drm_debugfs_add_files(dev, drm_framebuffer_debugfs_list, ARRAY_SIZE(drm_framebuffer_debugfs_list)); } #endif
drivers/gpu/drm/drm_internal.h +11 -5
@@ -180,8 +180,10 @@ void drm_gem_vunmap(struct drm_gem_object *obj, struct iosys_map *map);/* drm_debugfs.c drm_debugfs_crc.c */ #if defined(CONFIG_DEBUG_FS ) -int drm_debugfs_init (struct drm_minor *minor,int minor_id, -struct dentry *root); +void drm_debugfs_dev_fini (struct drm_device *dev); +void drm_debugfs_dev_register (struct drm_device *dev); +int drm_debugfs_register (struct drm_minor *minor,int minor_id, +struct dentry *root);void drm_debugfs_cleanup (struct drm_minor *minor);void drm_debugfs_late_register (struct drm_device *dev);void drm_debugfs_connector_add (struct drm_connector *connector);
@@ -190,8 +192,12 @@ void drm_debugfs_crtc_add(struct drm_crtc *crtc);void drm_debugfs_crtc_remove (struct drm_crtc *crtc);void drm_debugfs_crtc_crc_add (struct drm_crtc *crtc);#else -static inline int drm_debugfs_init (struct drm_minor *minor,int minor_id, -struct dentry *root) +static drm_debugfs_dev_register(struct drm_device *dev) +{ +} + +static inline int drm_debugfs_register (struct drm_minor *minor,int minor_id, +struct dentry *root) {return 0 ; }
@@ -257,4 +263,4 @@ int drm_syncobj_query_ioctl(struct drm_device *dev, void *data,/* drm_framebuffer.c */ void drm_framebuffer_print_info (struct drm_printer *p,unsigned int indent,const struct drm_framebuffer *fb); -void drm_framebuffer_debugfs_init (struct drm_minor *minor); +void drm_framebuffer_debugfs_init (struct drm_device *dev);
include/drm/drm_accel.h +7 -2
@@ -58,7 +58,8 @@ int accel_minor_alloc(void);void accel_minor_replace (struct drm_minor *minor,int index);void accel_set_device_instance_params (struct device *kdev,int index);int accel_open (struct inode *inode,struct file *filp); -void accel_debugfs_init (struct drm_minor *minor,int minor_id); +void accel_debugfs_init (struct drm_device *dev); +void accel_debugfs_register (struct drm_device *dev);#else
@@ -89,7 +90,11 @@ static inline void accel_set_device_instance_params(struct device *kdev, int ind { } -static inline void accel_debugfs_init (struct drm_minor *minor,int minor_id) +static inline void accel_debugfs_init (struct drm_device *dev) +{ +} + +static inline void accel_debugfs_register (struct drm_device *dev) { }
include/drm/drm_client.h +1 -1
@@ -195,6 +195,6 @@ int drm_client_modeset_dpms(struct drm_client_dev *client, int mode); drm_for_each_connector_iter(connector, iter) \if (connector->connector_type !=DRM_MODE_CONNECTOR_WRITEBACK ) -void drm_client_debugfs_init(struct drm_minor *minor); +void drm_client_debugfs_init(struct drm_device *dev);#endif
include/drm/drm_device.h +7 -0
@@ -311,6 +311,13 @@ struct drm_device {*/ struct drm_fb_helper *fb_helper; +/** +* @debugfs_root: +* +* Root directory for debugfs files. +*/ +struct dentry *debugfs_root; +/** * @debugfs_mutex: *
include/drm/drm_drv.h +8 -0
@@ -590,4 +590,12 @@ static inline bool drm_firmware_drivers_only(void) return video_firmware_drivers_only(); } +#if defined(CONFIG_DEBUG_FS ) +void drm_debugfs_dev_init (struct drm_device *dev,struct dentry *root); +#else +static void drm_debugfs_dev_init (struct drm_device *dev,struct dentry *root) +{ +} +#endif +#endif
include/drm/drm_file.h +1 -0
@@ -78,6 +78,7 @@ struct drm_minor {struct device *kdev;/* Linux device */ struct drm_device *dev; +struct dentry *debugfs_symlink;struct dentry *debugfs_root;struct list_head debugfs_list;
Signature · 1 line
2.34.1
kernel test robot
build botRe: [Intel-gfx] [PATCH 4/7] drm/debugfs: rework debugfs directory creation v2
I love your patch! Yet something to improve:
Hi Christian,
I love your patch! Yet something to improve:
[auto build test ERROR on drm-misc/drm-misc-next]
[also build test ERROR on drm-intel/for-linux-next drm-intel/for-linux-next-fixes linus/master v6.3-rc2 next-20230316] [cannot apply to drm-tip/drm-tip tegra/for-next]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Christian-K-nig/drm-tegra-allow-compile-test-on-ARM/20230316-172205 base: git://anongit.freedesktop.org/drm/drm-misc drm-misc-next patch link: https://lore.kernel.org/r/20230316082035.567520-5-christian.koenig%40amd.com patch subject: [Intel-gfx] [PATCH 4/7] drm/debugfs: rework debugfs directory creation v2 config: ia64-defconfig (https://download.01.org/0day-ci/archive/20230317/[email protected]/config) compiler: ia64-linux-gcc (GCC) 12.1.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/intel-lab-lkp/linux/commit/a3ad5ec323e8f1864cc8b721dbb154f0e0e2919d
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Christian-K-nig/drm-tegra-allow-compile-test-on-ARM/20230316-172205 git checkout a3ad5ec323e8f1864cc8b721dbb154f0e0e2919d
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=ia64 olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=ia64 SHELL=/bin/bash drivers/gpu/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <[email protected]>
| Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
In file included from drivers/gpu/drm/drm_atomic.c:47:
>> drivers/gpu/drm/drm_internal.h:195:8: error: return type defaults to 'int' [-Werror=implicit-int]
195 | static drm_debugfs_dev_register(struct drm_device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_internal.h:195:8: warning: 'drm_debugfs_dev_register' defined but not used [-Wunused-function] In file included from drivers/gpu/drm/drm_atomic.c:38:
include/drm/drm_drv.h:596:13: warning: 'drm_debugfs_dev_init' defined but not used [-Wunused-function]
596 | static void drm_debugfs_dev_init(struct drm_device *dev, struct dentry *root)
| ^~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from drivers/gpu/drm/drm_drv.c:50:
>> drivers/gpu/drm/drm_internal.h:195:8: error: return type defaults to 'int' [-Werror=implicit-int]
195 | static drm_debugfs_dev_register(struct drm_device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_drv.c: In function 'drm_dev_unregister':
>> drivers/gpu/drm/drm_drv.c:1011:9: error: implicit declaration of function 'drm_debugfs_dev_fini'; did you mean 'drm_debugfs_dev_init'? [-Werror=implicit-function-declaration]
1011 | drm_debugfs_dev_fini(dev);
| ^~~~~~~~~~~~~~~~~~~~
| drm_debugfs_dev_init
drivers/gpu/drm/drm_internal.h: In function 'drm_debugfs_dev_register':
drivers/gpu/drm/drm_internal.h:197:1: error: control reaches end of non-void function [-Werror=return-type]
197 | }
| ^
cc1: some warnings being treated as errors
--
In file included from drivers/gpu/drm/drm_managed.c:18:
>> drivers/gpu/drm/drm_internal.h:195:8: error: return type defaults to 'int' [-Werror=implicit-int] 195 | static drm_debugfs_dev_register(struct drm_device *dev)
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_internal.h:195:8: warning: 'drm_debugfs_dev_register' defined but not used [-Wunused-function]
cc1: some warnings being treated as errors
vim +/int +195 drivers/gpu/drm/drm_internal.h
180
181 /* drm_debugfs.c drm_debugfs_crc.c */
182 #if defined(CONFIG_DEBUG_FS)
183 void drm_debugfs_dev_fini(struct drm_device *dev);
184 void drm_debugfs_dev_register(struct drm_device *dev);
185 int drm_debugfs_register(struct drm_minor *minor, int minor_id,
186 struct dentry *root);
187 void drm_debugfs_cleanup(struct drm_minor *minor);
188 void drm_debugfs_late_register(struct drm_device *dev);
189 void drm_debugfs_connector_add(struct drm_connector *connector);
190 void drm_debugfs_connector_remove(struct drm_connector *connector);
191 void drm_debugfs_crtc_add(struct drm_crtc *crtc);
192 void drm_debugfs_crtc_remove(struct drm_crtc *crtc);
193 void drm_debugfs_crtc_crc_add(struct drm_crtc *crtc);
194 #else
> 195 static drm_debugfs_dev_register(struct drm_device *dev)
196 {
197 }
198
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests
Re: [PATCH 4/7] drm/debugfs: rework debugfs directory creation v2
In reply to Christian KönigQuoted 6 lines · Christian König
Instead of the per minor directories only create a single debugfs directory for the whole device directly when the device is initialized.
For DRM devices each minor gets a symlink to the per device directory for now until we can be sure that this isn't useful any more in any way.
Quoted 8 lines
Accel devices create only the per device directory and also drops the mid layer callback to create driver specific files.
v2: cleanup accel component as well
Signed-off-by Christian König <[email protected]>--- drivers/accel/drm_accel.c | 30 ++++++++-------
PATCH 5/7 drm/debugfs: remove dev->debugfs_list and debugfs_mutex v2
In reply to Christian KönigThe mutex was completely pointless in the first place since any parallel adding of files to this list would result in random behavior since the list is filled and consumed multiple times.
Completely drop that approach and just create the files directly but return -ENODEV while opening the file when the minors are not registered yet.
v2: rebase on debugfs directory rework, limit access before minors are
registered.
--- drivers/gpu/drm/drm_debugfs.c | 27 ++------------------------- drivers/gpu/drm/drm_drv.c | 3 --- drivers/gpu/drm/drm_internal.h | 5 ----- drivers/gpu/drm/drm_mode_config.c | 2 -- include/drm/drm_device.h | 15 --------------- 5 files changed, 2 insertions(+), 50 deletions(-)
drivers/gpu/drm/drm_debugfs.c +2 -25
@@ -245,7 +245,6 @@ int drm_debugfs_register(struct drm_minor *minor, int minor_id, struct dentry *root) {struct drm_device *dev = minor->dev; -struct drm_debugfs_entry *entry, *tmp;char name[64 ];INIT_LIST_HEAD (&minor->debugfs_list);
@@ -260,30 +259,9 @@ int drm_debugfs_register(struct drm_minor *minor, int minor_id,if (dev->driver->debugfs_init && dev->render != minor) dev->driver->debugfs_init (minor); -list_for_each_entry_safe (entry, tmp, &dev->debugfs_list, list) { -debugfs_create_file (entry->file.name,0444 , - minor->debugfs_root, entry, &drm_debugfs_entry_fops); -list_del (&entry->list); - } -return 0 ; } -void drm_debugfs_late_register (struct drm_device *dev) -{ -struct drm_minor *minor = dev->primary; -struct drm_debugfs_entry *entry, *tmp; - -if (!minor) -return ; - -list_for_each_entry_safe (entry, tmp, &dev->debugfs_list, list) { -debugfs_create_file (entry->file.name,0444 , - minor->debugfs_root, entry, &drm_debugfs_entry_fops); -list_del (&entry->list); - } -} -int drm_debugfs_remove_files (const struct drm_info_list *files,int count,struct drm_minor *minor) {
@@ -353,9 +331,8 @@ void drm_debugfs_add_file(struct drm_device *dev, const char *name, entry->file.data = data; entry->dev = dev; -mutex_lock (&dev->debugfs_mutex); -list_add (&entry->list, &dev->debugfs_list); -mutex_unlock (&dev->debugfs_mutex); +debugfs_create_file (name,0444 , dev->debugfs_root, entry, + &drm_debugfs_entry_fops); }EXPORT_SYMBOL (drm_debugfs_add_file);
drivers/gpu/drm/drm_drv.c +0 -3
@@ -597,7 +597,6 @@ static void drm_dev_init_release(struct drm_device *dev, void *res)mutex_destroy (&dev->clientlist_mutex);mutex_destroy (&dev->filelist_mutex);mutex_destroy (&dev->struct_mutex); -mutex_destroy (&dev->debugfs_mutex);drm_legacy_destroy_members (dev); }
@@ -638,14 +637,12 @@ static int drm_dev_init(struct drm_device *dev,INIT_LIST_HEAD (&dev->filelist_internal);INIT_LIST_HEAD (&dev->clientlist);INIT_LIST_HEAD (&dev->vblank_event_list); -INIT_LIST_HEAD (&dev->debugfs_list);spin_lock_init (&dev->event_lock);mutex_init (&dev->struct_mutex);mutex_init (&dev->filelist_mutex);mutex_init (&dev->clientlist_mutex);mutex_init (&dev->master_mutex); -mutex_init (&dev->debugfs_mutex); ret =drmm_add_action_or_reset (dev, drm_dev_init_release,NULL );if (ret)
drivers/gpu/drm/drm_internal.h +0 -5
@@ -185,7 +185,6 @@ void drm_debugfs_dev_register(struct drm_device *dev);int drm_debugfs_register (struct drm_minor *minor,int minor_id,struct dentry *root);void drm_debugfs_cleanup (struct drm_minor *minor); -void drm_debugfs_late_register (struct drm_device *dev);void drm_debugfs_connector_add (struct drm_connector *connector);void drm_debugfs_connector_remove (struct drm_connector *connector);void drm_debugfs_crtc_add (struct drm_crtc *crtc);
@@ -206,10 +205,6 @@ static inline void drm_debugfs_cleanup(struct drm_minor *minor) { } -static inline void drm_debugfs_late_register (struct drm_device *dev) -{ -} -static inline void drm_debugfs_connector_add (struct drm_connector *connector) { }
drivers/gpu/drm/drm_mode_config.c +0 -2
@@ -54,8 +54,6 @@ int drm_modeset_register_all(struct drm_device *dev)if (ret) goto err_connector; -drm_debugfs_late_register (dev); -return 0 ; err_connector:
include/drm/drm_device.h +0 -15
@@ -318,21 +318,6 @@ struct drm_device {*/ struct dentry *debugfs_root; -/** -* @debugfs_mutex: -* -* Protects &debugfs_list access. -*/ -struct mutex debugfs_mutex; - -/** -* @debugfs_list: -* -* List of debugfs files to be created by the DRM device. The files -* must be added during drm_dev_register(). -*/ -struct list_head debugfs_list; -/* Everything below here is for legacy driver, never use! */ /* private: */ #if IS_ENABLED (CONFIG_DRM_LEGACY )
Signature · 1 line
2.34.1
PATCH 6/7 drm/debugfs: rework drm_debugfs_create_files implementation
In reply to Christian KönigUse managed memory allocation for this. That allows us to not keep track of all the files any more.
--- drivers/accel/drm_accel.c | 2 - drivers/gpu/drm/drm_debugfs.c | 75 +++++++++------------------------- drivers/gpu/drm/drm_drv.c | 2 - drivers/gpu/drm/drm_internal.h | 5 --- drivers/gpu/drm/tegra/dc.c | 9 +++- drivers/gpu/drm/tegra/dsi.c | 1 + drivers/gpu/drm/tegra/hdmi.c | 3 +- drivers/gpu/drm/tegra/sor.c | 1 + include/drm/drm_debugfs.h | 4 +- include/drm/drm_file.h | 4 -- 10 files changed, 34 insertions(+), 72 deletions(-)
drivers/accel/drm_accel.c +0 -2
@@ -100,8 +100,6 @@ void accel_debugfs_register(struct drm_device *dev) {struct drm_minor *minor = dev->accel; -INIT_LIST_HEAD (&minor->debugfs_list); -mutex_init (&minor->debugfs_lock); minor->debugfs_root = dev->debugfs_root; drm_debugfs_create_files(accel_debugfs_list, ACCEL_DEBUGFS_ENTRIES,
drivers/gpu/drm/drm_debugfs.c +20 -55
104 lines not on this page · raw message
drivers/gpu/drm/drm_drv.c +0 -2
@@ -198,7 +198,6 @@ static int drm_minor_register(struct drm_device *dev, unsigned int type)return 0 ; err_debugfs: -drm_debugfs_cleanup (minor);return ret; }
@@ -222,7 +221,6 @@ static void drm_minor_unregister(struct drm_device *dev, unsigned int type)device_del (minor->kdev);dev_set_drvdata (minor->kdev,NULL );/* safety belt */ -drm_debugfs_cleanup (minor); }/*
drivers/gpu/drm/drm_internal.h +0 -5
@@ -184,7 +184,6 @@ void drm_debugfs_dev_fini(struct drm_device *dev);void drm_debugfs_dev_register (struct drm_device *dev);int drm_debugfs_register (struct drm_minor *minor,int minor_id,struct dentry *root); -void drm_debugfs_cleanup (struct drm_minor *minor);void drm_debugfs_connector_add (struct drm_connector *connector);void drm_debugfs_connector_remove (struct drm_connector *connector);void drm_debugfs_crtc_add (struct drm_crtc *crtc);
@@ -201,10 +200,6 @@ static inline int drm_debugfs_register(struct drm_minor *minor, int minor_id,return 0 ; } -static inline void drm_debugfs_cleanup (struct drm_minor *minor) -{ -} -static inline void drm_debugfs_connector_add (struct drm_connector *connector) { }
drivers/gpu/drm/tegra/dc.c +8 -1
@@ -1745,8 +1745,15 @@ static void tegra_dc_early_unregister(struct drm_crtc *crtc)unsigned int count =ARRAY_SIZE (debugfs_files);struct drm_minor *minor = crtc->dev->primary;struct tegra_dc *dc =to_tegra_dc (crtc); +struct dentry *root; + +#ifdef CONFIG_DEBUG_FS + root = crtc->debugfs_entry; +#else + root =NULL ; +#endif -drm_debugfs_remove_files (dc->debugfs_files, count, minor); +drm_debugfs_remove_files (dc->debugfs_files, count, root, minor);kfree (dc->debugfs_files); dc->debugfs_files =NULL ; }
drivers/gpu/drm/tegra/dsi.c +1 -0
@@ -256,6 +256,7 @@ static void tegra_dsi_early_unregister(struct drm_connector *connector)struct tegra_dsi *dsi =to_dsi (output);drm_debugfs_remove_files (dsi->debugfs_files, count, + connector->debugfs_entry, connector->dev->primary);kfree (dsi->debugfs_files); dsi->debugfs_files =NULL ;
drivers/gpu/drm/tegra/hdmi.c +2 -1
@@ -1114,7 +1114,8 @@ static void tegra_hdmi_early_unregister(struct drm_connector *connector)unsigned int count =ARRAY_SIZE (debugfs_files);struct tegra_hdmi *hdmi =to_hdmi (output); -drm_debugfs_remove_files (hdmi->debugfs_files, count, minor); +drm_debugfs_remove_files (hdmi->debugfs_files, count, + connector->debugfs_entry, minor);kfree (hdmi->debugfs_files); hdmi->debugfs_files =NULL ; }
drivers/gpu/drm/tegra/sor.c +1 -0
@@ -1707,6 +1707,7 @@ static void tegra_sor_early_unregister(struct drm_connector *connector)struct tegra_sor *sor =to_sor (output);drm_debugfs_remove_files (sor->debugfs_files, count, + connector->debugfs_entry, connector->dev->primary);kfree (sor->debugfs_files); sor->debugfs_files =NULL ;
include/drm/drm_debugfs.h +2 -2
@@ -126,8 +126,8 @@ struct drm_debugfs_entry {void drm_debugfs_create_files (const struct drm_info_list *files,int count,struct dentry *root,struct drm_minor *minor); -int drm_debugfs_remove_files (const struct drm_info_list *files, -int count,struct drm_minor *minor); +int drm_debugfs_remove_files (const struct drm_info_list *files,int count, +struct dentry *root,struct drm_minor *minor);void drm_debugfs_add_file (struct drm_device *dev,const char *name,int (*show)(struct seq_file *,void *),void *data);
include/drm/drm_file.h +0 -4
@@ -78,11 +78,7 @@ struct drm_minor {struct device *kdev;/* Linux device */ struct drm_device *dev; -struct dentry *debugfs_symlink;struct dentry *debugfs_root; - -struct list_head debugfs_list; -struct mutex debugfs_lock;/* Protects debugfs_list. */ };/**
Signature · 1 line
2.34.1
PATCH 7/7 drm/debugfs: remove debugfs_root pointer from minor
In reply to Christian KönigWe only keept that around for API compatibility with drivers. Clean all this up and use the per device debugfs directory.
--- drivers/accel/drm_accel.c | 2 -- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 3 +-- .../gpu/drm/amd/amdgpu/amdgpu_fw_attestation.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 3 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 3 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 4 +--- drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c | 5 ++--- drivers/gpu/drm/amd/amdgpu/amdgpu_rap.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 6 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 3 +-- .../gpu/drm/amd/amdgpu/amdgpu_securedisplay.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 3 +-- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 3 +-- .../amd/display/amdgpu_dm/amdgpu_dm_debugfs.c | 2 +- drivers/gpu/drm/amd/pm/amdgpu_pm.c | 3 +-- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 2 +- drivers/gpu/drm/arm/malidp_drv.c | 2 +- drivers/gpu/drm/armada/armada_debugfs.c | 2 +- drivers/gpu/drm/drm_debugfs.c | 3 --- drivers/gpu/drm/drm_mipi_dbi.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 2 +- .../gpu/drm/i915/display/intel_display_debugfs.c | 4 ++-- drivers/gpu/drm/i915/display/intel_dmc.c | 2 +- drivers/gpu/drm/i915/display/intel_fbc.c | 2 +- drivers/gpu/drm/i915/display/intel_hotplug.c | 4 ++-- drivers/gpu/drm/i915/display/skl_watermark.c | 2 +- drivers/gpu/drm/i915/gt/intel_gt_debugfs.c | 4 ++-- drivers/gpu/drm/i915/gt/uc/intel_guc_log.c | 2 +- drivers/gpu/drm/i915/gvt/debugfs.c | 6 +++--- drivers/gpu/drm/i915/i915_debugfs.c | 6 +++--- drivers/gpu/drm/i915/i915_debugfs_params.c | 2 +- drivers/gpu/drm/i915/pxp/intel_pxp_debugfs.c | 4 ++-- drivers/gpu/drm/msm/adreno/a5xx_debugfs.c | 4 ++-- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 2 +- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 2 +- drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c | 2 +- drivers/gpu/drm/msm/dp/dp_debug.c | 2 +- drivers/gpu/drm/msm/msm_debugfs.c | 16 ++++++++-------- drivers/gpu/drm/msm/msm_perf.c | 2 +- drivers/gpu/drm/msm/msm_rd.c | 2 +- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 6 +++--- drivers/gpu/drm/omapdrm/omap_debugfs.c | 4 ++-- drivers/gpu/drm/pl111/pl111_debugfs.c | 2 +- drivers/gpu/drm/qxl/qxl_debugfs.c | 4 ++-- drivers/gpu/drm/qxl/qxl_ttm.c | 4 ++-- drivers/gpu/drm/radeon/r100.c | 6 +++--- drivers/gpu/drm/radeon/r300.c | 2 +- drivers/gpu/drm/radeon/r420.c | 2 +- drivers/gpu/drm/radeon/r600.c | 2 +- drivers/gpu/drm/radeon/radeon_fence.c | 2 +- drivers/gpu/drm/radeon/radeon_gem.c | 2 +- drivers/gpu/drm/radeon/radeon_ib.c | 2 +- drivers/gpu/drm/radeon/radeon_pm.c | 2 +- drivers/gpu/drm/radeon/radeon_ring.c | 2 +- drivers/gpu/drm/radeon/radeon_ttm.c | 2 +- drivers/gpu/drm/radeon/rs400.c | 2 +- drivers/gpu/drm/radeon/rv515.c | 2 +- drivers/gpu/drm/sti/sti_cursor.c | 2 +- drivers/gpu/drm/sti/sti_drv.c | 4 ++-- drivers/gpu/drm/sti/sti_dvo.c | 2 +- drivers/gpu/drm/sti/sti_gdp.c | 2 +- drivers/gpu/drm/sti/sti_hda.c | 2 +- drivers/gpu/drm/sti/sti_hdmi.c | 2 +- drivers/gpu/drm/sti/sti_hqvdp.c | 2 +- drivers/gpu/drm/sti/sti_mixer.c | 2 +- drivers/gpu/drm/sti/sti_tvout.c | 2 +- drivers/gpu/drm/sti/sti_vid.c | 2 +- drivers/gpu/drm/tegra/drm.c | 2 +- drivers/gpu/drm/tilcdc/tilcdc_drv.c | 2 +- drivers/gpu/drm/tiny/arcpgu.c | 2 +- drivers/gpu/drm/vc4/vc4_hvs.c | 2 +- drivers/gpu/drm/virtio/virtgpu_debugfs.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 2 +- drivers/gpu/drm/vmwgfx/vmwgfx_gem.c | 2 +- include/drm/drm_file.h | 2 -- 76 files changed, 103 insertions(+), 120 deletions(-)
drivers/accel/drm_accel.c +0 -2
@@ -100,8 +100,6 @@ void accel_debugfs_register(struct drm_device *dev) {struct drm_minor *minor = dev->accel; - minor->debugfs_root = dev->debugfs_root; -drm_debugfs_create_files (accel_debugfs_list,ACCEL_DEBUGFS_ENTRIES , dev->debugfs_root, minor); }
drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c +2 -2
@@ -1454,7 +1454,7 @@ static const char *debugfs_regs_names[] = {int amdgpu_debugfs_regs_init (struct amdgpu_device *adev) {struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *ent, *root = minor->debugfs_root; +struct dentry *ent, *root = minor->dev->debugfs_root;unsigned int i;for (i =0 ; i <ARRAY_SIZE (debugfs_regs); i++) {
@@ -1926,7 +1926,7 @@ static const struct file_operations amdgpu_reset_dump_register_list = {int amdgpu_debugfs_init (struct amdgpu_device *adev) { -struct dentry *root =adev_to_drm (adev)->primary->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;struct dentry *ent;int r, i;
drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c +1 -2
@@ -918,8 +918,7 @@ static void amdgpu_debugfs_reset_work(struct work_struct *work)void amdgpu_debugfs_fence_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;debugfs_create_file ("amdgpu_fence_info" ,0444 , root, adev, &amdgpu_debugfs_fence_info_fops);
drivers/gpu/drm/amd/amdgpu/amdgpu_fw_attestation.c +1 -1
@@ -137,7 +137,7 @@ void amdgpu_fw_attestation_debugfs_init(struct amdgpu_device *adev)debugfs_create_file ("amdgpu_fw_attestation" ,S_IRUSR , -adev_to_drm (adev)->primary->debugfs_root, +adev_to_drm (adev)->debugfs_root, adev, &amdgpu_fw_attestation_debugfs_ops); }
drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +1 -2
@@ -994,8 +994,7 @@ DEFINE_SHOW_ATTRIBUTE(amdgpu_debugfs_gem_info);void amdgpu_debugfs_gem_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;debugfs_create_file ("amdgpu_gem_info" ,0444 , root, adev, &amdgpu_debugfs_gem_info_fops);
drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c +1 -2
@@ -457,8 +457,7 @@ DEFINE_SHOW_ATTRIBUTE(amdgpu_debugfs_sa_info);void amdgpu_debugfs_sa_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;debugfs_create_file ("amdgpu_sa_info" ,0444 , root, adev, &amdgpu_debugfs_sa_info_fops);
drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c +1 -3
@@ -1704,11 +1704,9 @@ DEFINE_SHOW_ATTRIBUTE(amdgpu_debugfs_firmware_info);void amdgpu_debugfs_firmware_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;debugfs_create_file ("amdgpu_firmware_info" ,0444 , root, adev, &amdgpu_debugfs_firmware_info_fops); -#endif }
drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c +2 -3
@@ -373,9 +373,8 @@ static ssize_t ta_if_invoke_debugfs_write(struct file *fp, const char *buf, sizevoid amdgpu_ta_if_debugfs_init (struct amdgpu_device *adev) { -struct drm_minor *minor =adev_to_drm (adev)->primary; - -struct dentry *dir =debugfs_create_dir ("ta_if" , minor->debugfs_root); +struct dentry *root =adev_to_drm (adev)->debugfs_root; +struct dentry *dir =debugfs_create_dir ("ta_if" , root);debugfs_create_file ("ta_load" ,0200 , dir, adev, &ta_load_debugfs_fops);
drivers/gpu/drm/amd/amdgpu/amdgpu_rap.c +3 -3
@@ -117,12 +117,12 @@ static const struct file_operations amdgpu_rap_debugfs_ops = {void amdgpu_rap_debugfs_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; +struct dentry *root =adev_to_drm (adev)->debugfs_root;if (!adev->psp.rap_context.context.initialized)return ; -debugfs_create_file ("rap_test" ,S_IWUSR , minor->debugfs_root, - adev, &amdgpu_rap_debugfs_ops); +debugfs_create_file ("rap_test" ,S_IWUSR , root, adev, + &amdgpu_rap_debugfs_ops);#endif }
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +3 -3
@@ -1440,10 +1440,10 @@ static int amdgpu_ras_sysfs_remove_all(struct amdgpu_device *adev)static struct dentry *amdgpu_ras_debugfs_create_ctrl_node (struct amdgpu_device *adev) {struct amdgpu_ras *con =amdgpu_ras_get_context (adev); -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *dir; +struct dentry *root =adev_to_drm (adev)->debugfs_root; +struct dentry *dir; - dir =debugfs_create_dir (RAS_FS_NAME , minor->debugfs_root); + dir =debugfs_create_dir (RAS_FS_NAME , root);debugfs_create_file ("ras_ctrl" ,S_IWUGO |S_IRUGO , dir, adev, &amdgpu_ras_debugfs_ctrl_ops); debugfs_create_file("ras_eeprom_reset", S_IWUGO | S_IRUGO, dir, adev,
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c +1 -2
@@ -484,8 +484,7 @@ void amdgpu_debugfs_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;char name[32 ];sprintf (name,"amdgpu_ring_%s" , ring->name);
drivers/gpu/drm/amd/amdgpu/amdgpu_securedisplay.c +1 -1
@@ -177,7 +177,7 @@ void amdgpu_securedisplay_debugfs_init(struct amdgpu_device *adev)if (!adev->psp.securedisplay_context.context.initialized)return ; -debugfs_create_file ("securedisplay_test" ,S_IWUSR ,adev_to_drm (adev)->primary->debugfs_root, +debugfs_create_file ("securedisplay_test" ,S_IWUSR ,adev_to_drm (adev)->debugfs_root, adev, &amdgpu_securedisplay_debugfs_ops);#endif }
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +1 -2
@@ -2371,8 +2371,7 @@ static const struct file_operations amdgpu_ttm_iomem_fops = {void amdgpu_ttm_debugfs_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;debugfs_create_file_size ("amdgpu_vram" ,0444 , root, adev, &amdgpu_ttm_vram_fops, adev->gmc.mc_vram_size);
drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c +1 -2
@@ -1102,8 +1102,7 @@ void amdgpu_debugfs_vcn_fwlog_init(struct amdgpu_device *adev, uint8_t i, struct amdgpu_vcn_inst *vcn) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;char name[32 ];sprintf (name,"amdgpu_vcn_%d_fwlog" , i);
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_debugfs.c +1 -1
@@ -3647,7 +3647,7 @@ void dtn_debugfs_init(struct amdgpu_device *adev) };struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root = minor->dev->debugfs_root;debugfs_create_file ("amdgpu_mst_topology" ,0444 , root, adev, &mst_topo_fops);
drivers/gpu/drm/amd/pm/amdgpu_pm.c +1 -2
@@ -3626,8 +3626,7 @@ static const struct file_operations amdgpu_debugfs_pm_prv_buffer_fops = {void amdgpu_debugfs_pm_init (struct amdgpu_device *adev) {#if defined(CONFIG_DEBUG_FS ) -struct drm_minor *minor =adev_to_drm (adev)->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root =adev_to_drm (adev)->debugfs_root;if (!adev->pm.dpm_enabled)return ;
drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c +1 -1
@@ -3185,7 +3185,7 @@ void amdgpu_smu_stb_debug_fs_init(struct amdgpu_device *adev)debugfs_create_file_size ("amdgpu_smu_stb_dump" ,S_IRUSR , -adev_to_drm (adev)->primary->debugfs_root, +adev_to_drm (adev)->debugfs_root, adev, &smu_stb_debugfs_fops, smu->stb_context.stb_buf_size);
drivers/gpu/drm/arm/malidp_drv.c +1 -1
@@ -552,7 +552,7 @@ static void malidp_debugfs_init(struct drm_minor *minor)malidp_error_stats_init (&malidp->de_errors);malidp_error_stats_init (&malidp->se_errors);spin_lock_init (&malidp->errors_lock); -debugfs_create_file ("debug" ,S_IRUGO |S_IWUSR , minor->debugfs_root, +debugfs_create_file ("debug" ,S_IRUGO |S_IWUSR , minor->dev->debugfs_root, minor->dev, &malidp_debugfs_fops); }
drivers/gpu/drm/armada/armada_debugfs.c +1 -1
@@ -105,7 +105,7 @@ static struct drm_info_list armada_debugfs_list[] = {int armada_drm_debugfs_init (struct drm_minor *minor) {drm_debugfs_create_files (armada_debugfs_list,ARMADA_DEBUGFS_ENTRIES , - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);return 0 ; }
drivers/gpu/drm/drm_debugfs.c +0 -3
@@ -264,9 +264,6 @@ int drm_debugfs_register(struct drm_minor *minor, int minor_id,sprintf (name,"%d" , minor_id);debugfs_create_symlink (name, root, dev->unique); -/* TODO: Only for compatibility with drivers */ - minor->debugfs_root = dev->debugfs_root; -if (dev->driver->debugfs_init && dev->render != minor) dev->driver->debugfs_init (minor);
drivers/gpu/drm/drm_mipi_dbi.c +1 -1
@@ -1454,7 +1454,7 @@ void mipi_dbi_debugfs_init(struct drm_minor *minor)if (dbidev->dbi.read_commands) mode |=S_IRUGO ; -debugfs_create_file ("command" , mode, minor->debugfs_root, dbidev, +debugfs_create_file ("command" , mode, minor->dev->debugfs_root, dbidev, &mipi_dbi_debugfs_command_fops); }EXPORT_SYMBOL (mipi_dbi_debugfs_init);
drivers/gpu/drm/etnaviv/etnaviv_drv.c +1 -1
@@ -243,7 +243,7 @@ static void etnaviv_debugfs_init(struct drm_minor *minor) {drm_debugfs_create_files (etnaviv_debugfs_list,ARRAY_SIZE (etnaviv_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }#endif
drivers/gpu/drm/i915/display/intel_display_debugfs.c +2 -2
@@ -1610,14 +1610,14 @@ void intel_display_debugfs_register(struct drm_i915_private *i915)for (i =0 ; i <ARRAY_SIZE (intel_display_debugfs_files); i++) {debugfs_create_file (intel_display_debugfs_files[i].name,S_IRUGO |S_IWUSR , - minor->debugfs_root, + minor->dev->debugfs_root,to_i915 (minor->dev), intel_display_debugfs_files[i].fops); }drm_debugfs_create_files (intel_display_debugfs_list,ARRAY_SIZE (intel_display_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);intel_dmc_debugfs_register (i915);intel_fbc_debugfs_register (i915);
drivers/gpu/drm/i915/display/intel_dmc.c +1 -1
@@ -1148,6 +1148,6 @@ void intel_dmc_debugfs_register(struct drm_i915_private *i915) {struct drm_minor *minor = i915->drm.primary; -debugfs_create_file ("i915_dmc_info" ,0444 , minor->debugfs_root, +debugfs_create_file ("i915_dmc_info" ,0444 , minor->dev->debugfs_root, i915, &intel_dmc_debugfs_status_fops); }
drivers/gpu/drm/i915/display/intel_fbc.c +1 -1
@@ -1839,5 +1839,5 @@ void intel_fbc_debugfs_register(struct drm_i915_private *i915) fbc = i915->display.fbc[INTEL_FBC_A ];if (fbc) -intel_fbc_debugfs_add (fbc, minor->debugfs_root); +intel_fbc_debugfs_add (fbc, minor->dev->debugfs_root); }
drivers/gpu/drm/i915/display/intel_hotplug.c +2 -2
@@ -936,8 +936,8 @@ void intel_hpd_debugfs_register(struct drm_i915_private *i915) {struct drm_minor *minor = i915->drm.primary; -debugfs_create_file ("i915_hpd_storm_ctl" ,0644 , minor->debugfs_root, +debugfs_create_file ("i915_hpd_storm_ctl" ,0644 , minor->dev->debugfs_root, i915, &i915_hpd_storm_ctl_fops); -debugfs_create_file ("i915_hpd_short_storm_ctl" ,0644 , minor->debugfs_root, +debugfs_create_file ("i915_hpd_short_storm_ctl" ,0644 , minor->dev->debugfs_root, i915, &i915_hpd_short_storm_ctl_fops); }
drivers/gpu/drm/i915/display/skl_watermark.c +1 -1
@@ -3548,6 +3548,6 @@ void skl_watermark_ipc_debugfs_register(struct drm_i915_private *i915)if (!HAS_IPC (i915))return ; -debugfs_create_file ("i915_ipc_status" ,0644 , minor->debugfs_root, i915, +debugfs_create_file ("i915_ipc_status" ,0644 , minor->dev->debugfs_root, i915, &skl_watermark_ipc_status_fops); }
drivers/gpu/drm/i915/gt/intel_gt_debugfs.c +2 -2
@@ -84,10 +84,10 @@ void intel_gt_debugfs_register(struct intel_gt *gt) {struct dentry *root; -if (!gt->i915->drm.primary->debugfs_root) +if (!gt->i915->drm.debugfs_root)return ; - root =debugfs_create_dir ("gt" , gt->i915->drm.primary->debugfs_root); + root =debugfs_create_dir ("gt" , gt->i915->drm.debugfs_root);if (IS_ERR (root))return ;
drivers/gpu/drm/i915/gt/uc/intel_guc_log.c +1 -1
@@ -544,7 +544,7 @@ static int guc_log_relay_create(struct intel_guc_log *log) n_subbufs =8 ; guc_log_relay_chan =relay_open ("guc_log" , - dev_priv->drm.primary->debugfs_root, + dev_priv->drm.debugfs_root, subbuf_size, n_subbufs, &relay_callbacks, dev_priv);if (!guc_log_relay_chan) {
drivers/gpu/drm/i915/gvt/debugfs.c +3 -3
@@ -195,7 +195,7 @@ void intel_gvt_debugfs_remove_vgpu(struct intel_vgpu *vgpu)struct intel_gvt *gvt = vgpu->gvt;struct drm_minor *minor = gvt->gt->i915->drm.primary; -if (minor->debugfs_root && gvt->debugfs_root) { +if (minor->dev->debugfs_root && gvt->debugfs_root) {debugfs_remove_recursive (vgpu->debugfs); vgpu->debugfs =NULL ; }
@@ -209,7 +209,7 @@ void intel_gvt_debugfs_init(struct intel_gvt *gvt) {struct drm_minor *minor = gvt->gt->i915->drm.primary; - gvt->debugfs_root =debugfs_create_dir ("gvt" , minor->debugfs_root); + gvt->debugfs_root =debugfs_create_dir ("gvt" , minor->dev->debugfs_root);debugfs_create_ulong ("num_tracked_mmio" ,0444 , gvt->debugfs_root, &gvt->mmio.num_tracked_mmio);
@@ -223,7 +223,7 @@ void intel_gvt_debugfs_clean(struct intel_gvt *gvt) {struct drm_minor *minor = gvt->gt->i915->drm.primary; -if (minor->debugfs_root) { +if (minor->dev->debugfs_root) {debugfs_remove_recursive (gvt->debugfs_root); gvt->debugfs_root =NULL ; }
drivers/gpu/drm/i915/i915_debugfs.c +3 -3
@@ -784,17 +784,17 @@ void i915_debugfs_register(struct drm_i915_private *dev_priv)i915_debugfs_params (dev_priv); -debugfs_create_file ("i915_forcewake_user" ,S_IRUSR , minor->debugfs_root, +debugfs_create_file ("i915_forcewake_user" ,S_IRUSR , minor->dev->debugfs_root,to_i915 (minor->dev), &i915_forcewake_fops);for (i =0 ; i <ARRAY_SIZE (i915_debugfs_files); i++) {debugfs_create_file (i915_debugfs_files[i].name,S_IRUGO |S_IWUSR , - minor->debugfs_root, + minor->dev->debugfs_root,to_i915 (minor->dev), i915_debugfs_files[i].fops); }drm_debugfs_create_files (i915_debugfs_list,ARRAY_SIZE (i915_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }
drivers/gpu/drm/i915/i915_debugfs_params.c +1 -1
@@ -248,7 +248,7 @@ struct dentry *i915_debugfs_params(struct drm_i915_private *i915)struct i915_params *params = &i915->params;struct dentry *dir; - dir =debugfs_create_dir ("i915_params" , minor->debugfs_root); + dir =debugfs_create_dir ("i915_params" , minor->dev->debugfs_root);if (IS_ERR (dir))return dir;
drivers/gpu/drm/i915/pxp/intel_pxp_debugfs.c +2 -2
@@ -72,10 +72,10 @@ void intel_pxp_debugfs_register(struct intel_pxp *pxp)return ; minor = pxp->ctrl_gt->i915->drm.primary; -if (!minor->debugfs_root) +if (!minor->dev->debugfs_root)return ; - pxproot =debugfs_create_dir ("pxp" , minor->debugfs_root); + pxproot =debugfs_create_dir ("pxp" , minor->dev->debugfs_root);if (IS_ERR (pxproot))return ;
drivers/gpu/drm/msm/adreno/a5xx_debugfs.c +2 -2
@@ -152,8 +152,8 @@ void a5xx_debugfs_init(struct msm_gpu *gpu, struct drm_minor *minor)drm_debugfs_create_files (a5xx_debugfs_list,ARRAY_SIZE (a5xx_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); -debugfs_create_file_unsafe ("reset" ,S_IWUGO , minor->debugfs_root, dev, +debugfs_create_file_unsafe ("reset" ,S_IWUGO , minor->dev->debugfs_root, dev, &reset_fops); }
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c +1 -1
@@ -2137,7 +2137,7 @@ static int _dpu_encoder_init_debugfs(struct drm_encoder *drm_enc)/* create overall sub-directory for the encoder */ dpu_enc->debugfs_root =debugfs_create_dir (name, - drm_enc->dev->primary->debugfs_root); + drm_enc->dev->debugfs_root);/* don't error check these */ debugfs_create_file("status", 0600,
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c +1 -1
@@ -269,7 +269,7 @@ static int dpu_kms_debugfs_init(struct msm_kms *kms, struct drm_minor *minor) dev = dpu_kms->dev; priv = dev->dev_private; - entry =debugfs_create_dir ("debug" , minor->debugfs_root); + entry =debugfs_create_dir ("debug" , minor->dev->debugfs_root);debugfs_create_x32 (DPU_DEBUGFS_HWMASKNAME ,0600 , entry, p);
drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c +1 -1
@@ -253,7 +253,7 @@ static int mdp5_kms_debugfs_init(struct msm_kms *kms, struct drm_minor *minor) {drm_debugfs_create_files (mdp5_debugfs_list,ARRAY_SIZE (mdp5_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);return 0 ; }
drivers/gpu/drm/msm/dp/dp_debug.c +1 -1
@@ -213,7 +213,7 @@ static void dp_debug_init(struct dp_debug *dp_debug, struct drm_minor *minor)snprintf (path,sizeof (path),"msm_dp-%s" , debug->connector->name); - debug->root =debugfs_create_dir (path, minor->debugfs_root); + debug->root =debugfs_create_dir (path, minor->dev->debugfs_root);debugfs_create_file ("dp_debug" ,0444 , debug->root, debug, &dp_debug_fops);
drivers/gpu/drm/msm/msm_debugfs.c +8 -8
@@ -309,21 +309,21 @@ void msm_debugfs_init(struct drm_minor *minor)drm_debugfs_create_files (msm_debugfs_list,ARRAY_SIZE (msm_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); -debugfs_create_file ("gpu" ,S_IRUSR , minor->debugfs_root, +debugfs_create_file ("gpu" ,S_IRUSR , minor->dev->debugfs_root, dev, &msm_gpu_fops); -debugfs_create_file ("kms" ,S_IRUSR , minor->debugfs_root, +debugfs_create_file ("kms" ,S_IRUSR , minor->dev->debugfs_root, dev, &msm_kms_fops); -debugfs_create_u32 ("hangcheck_period_ms" ,0600 , minor->debugfs_root, +debugfs_create_u32 ("hangcheck_period_ms" ,0600 , minor->dev->debugfs_root, &priv->hangcheck_period); -debugfs_create_bool ("disable_err_irq" ,0600 , minor->debugfs_root, +debugfs_create_bool ("disable_err_irq" ,0600 , minor->dev->debugfs_root, &priv->disable_err_irq); -debugfs_create_file ("shrink" ,S_IRWXU , minor->debugfs_root, +debugfs_create_file ("shrink" ,S_IRWXU , minor->dev->debugfs_root, dev, &shrink_fops); gpu_devfreq =debugfs_create_dir ("devfreq" , minor->debugfs_root);
@@ -341,9 +341,9 @@ void msm_debugfs_init(struct drm_minor *minor) priv->kms->funcs->debugfs_init (priv->kms, minor);#ifdef CONFIG_FAULT_INJECTION -fault_create_debugfs_attr ("fail_gem_alloc" , minor->debugfs_root, +fault_create_debugfs_attr ("fail_gem_alloc" , minor->dev->debugfs_root, &fail_gem_alloc); -fault_create_debugfs_attr ("fail_gem_iova" , minor->debugfs_root, +fault_create_debugfs_attr ("fail_gem_iova" , minor->dev->debugfs_root, &fail_gem_iova);#endif }
drivers/gpu/drm/msm/msm_perf.c +1 -1
@@ -214,7 +214,7 @@ int msm_perf_debugfs_init(struct drm_minor *minor)mutex_init (&perf->read_lock); priv->perf = perf; -debugfs_create_file ("perf" ,S_IFREG |S_IRUGO , minor->debugfs_root, +debugfs_create_file ("perf" ,S_IFREG |S_IRUGO , minor->dev->debugfs_root, perf, &perf_debugfs_fops);return 0 ; }
drivers/gpu/drm/msm/msm_rd.c +1 -1
@@ -261,7 +261,7 @@ static struct msm_rd_state *rd_init(struct drm_minor *minor, const char *name)init_waitqueue_head (&rd->fifo_event); -debugfs_create_file (name,S_IFREG |S_IRUGO , minor->debugfs_root, rd, +debugfs_create_file (name,S_IFREG |S_IRUGO , minor->dev->debugfs_root, rd, &rd_debugfs_fops);return rd;
drivers/gpu/drm/nouveau/nouveau_debugfs.c +3 -3
@@ -233,18 +233,18 @@ nouveau_drm_debugfs_init(struct drm_minor *minor)for (i =0 ; i <ARRAY_SIZE (nouveau_debugfs_files); i++) {debugfs_create_file (nouveau_debugfs_files[i].name,S_IRUGO |S_IWUSR , - minor->debugfs_root, minor->dev, + minor->dev->debugfs_root, minor->dev, nouveau_debugfs_files[i].fops); }drm_debugfs_create_files (nouveau_debugfs_list,NOUVEAU_DEBUGFS_ENTRIES , - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);/* Set the size of the vbios since we know it, and it's confusing to * userspace if it wants to seek() but the file has a length of 0 */ - dentry =debugfs_lookup ("vbios.rom" , minor->debugfs_root); + dentry =debugfs_lookup ("vbios.rom" , minor->dev->debugfs_root);if (!dentry)return ;
drivers/gpu/drm/omapdrm/omap_debugfs.c +2 -2
@@ -85,12 +85,12 @@ void omap_debugfs_init(struct drm_minor *minor) {drm_debugfs_create_files (omap_debugfs_list,ARRAY_SIZE (omap_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);if (dmm_is_available ())drm_debugfs_create_files (omap_dmm_debugfs_list,ARRAY_SIZE (omap_dmm_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }#endif
drivers/gpu/drm/pl111/pl111_debugfs.c +1 -1
@@ -55,5 +55,5 @@ pl111_debugfs_init(struct drm_minor *minor) {drm_debugfs_create_files (pl111_debugfs_list,ARRAY_SIZE (pl111_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }
drivers/gpu/drm/qxl/qxl_debugfs.c +2 -2
@@ -90,7 +90,7 @@ qxl_debugfs_init(struct drm_minor *minor)struct qxl_device *dev =to_qxl (minor->dev);drm_debugfs_create_files (qxl_debugfs_list,QXL_DEBUGFS_ENTRIES , - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);qxl_ttm_debugfs_init (dev);#endif
@@ -120,7 +120,7 @@ void qxl_debugfs_add_files(struct qxl_device *qdev, qdev->debugfs_count = i;#if defined(CONFIG_DEBUG_FS )drm_debugfs_create_files (files, nfiles, - qdev->ddev.primary->debugfs_root, + qdev->ddev.debugfs_root, qdev->ddev.primary);#endif }
drivers/gpu/drm/qxl/qxl_ttm.c +2 -2
@@ -238,9 +238,9 @@ void qxl_ttm_debugfs_init(struct qxl_device *qdev)#if defined(CONFIG_DEBUG_FS )ttm_resource_manager_create_debugfs (ttm_manager_type (&qdev->mman.bdev,TTM_PL_VRAM ), - qdev->ddev.primary->debugfs_root,"qxl_mem_mm" ); + qdev->ddev.debugfs_root,"qxl_mem_mm" );ttm_resource_manager_create_debugfs (ttm_manager_type (&qdev->mman.bdev,TTM_PL_PRIV ), - qdev->ddev.primary->debugfs_root,"qxl_surf_mm" ); + qdev->ddev.debugfs_root,"qxl_surf_mm" );#endif }
drivers/gpu/drm/radeon/r100.c +3 -3
@@ -3058,7 +3058,7 @@ DEFINE_SHOW_ATTRIBUTE(r100_debugfs_mc_info);void r100_debugfs_rbbm_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("r100_rbbm_info" ,0444 , root, rdev, &r100_debugfs_rbbm_info_fops);
@@ -3068,7 +3068,7 @@ void r100_debugfs_rbbm_init(struct radeon_device *rdev)void r100_debugfs_cp_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("r100_cp_ring_info" ,0444 , root, rdev, &r100_debugfs_cp_ring_info_fops);
@@ -3080,7 +3080,7 @@ void r100_debugfs_cp_init(struct radeon_device *rdev)void r100_debugfs_mc_info_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("r100_mc_info" ,0444 , root, rdev, &r100_debugfs_mc_info_fops);
drivers/gpu/drm/radeon/r300.c +1 -1
@@ -615,7 +615,7 @@ DEFINE_SHOW_ATTRIBUTE(rv370_debugfs_pcie_gart_info);static void rv370_debugfs_pcie_gart_info_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("rv370_pcie_gart_info" ,0444 , root, rdev, &rv370_debugfs_pcie_gart_info_fops);
drivers/gpu/drm/radeon/r420.c +1 -1
@@ -492,7 +492,7 @@ DEFINE_SHOW_ATTRIBUTE(r420_debugfs_pipes_info);void r420_debugfs_pipes_info_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("r420_pipes_info" ,0444 , root, rdev, &r420_debugfs_pipes_info_fops);
drivers/gpu/drm/radeon/r600.c +1 -1
@@ -4358,7 +4358,7 @@ DEFINE_SHOW_ATTRIBUTE(r600_debugfs_mc_info);static void r600_debugfs_mc_info_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("r600_mc_info" ,0444 , root, rdev, &r600_debugfs_mc_info_fops);
drivers/gpu/drm/radeon/radeon_fence.c +1 -1
@@ -1004,7 +1004,7 @@ DEFINE_DEBUGFS_ATTRIBUTE(radeon_debugfs_gpu_reset_fops,void radeon_debugfs_fence_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("radeon_gpu_reset" ,0444 , root, rdev, &radeon_debugfs_gpu_reset_fops);
drivers/gpu/drm/radeon/radeon_gem.c +1 -1
@@ -892,7 +892,7 @@ DEFINE_SHOW_ATTRIBUTE(radeon_debugfs_gem_info);void radeon_gem_debugfs_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("radeon_gem_info" ,0444 , root, rdev, &radeon_debugfs_gem_info_fops);
drivers/gpu/drm/radeon/radeon_ib.c +1 -1
@@ -307,7 +307,7 @@ DEFINE_SHOW_ATTRIBUTE(radeon_debugfs_sa_info);static void radeon_debugfs_sa_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("radeon_sa_info" ,0444 , root, rdev, &radeon_debugfs_sa_info_fops);
drivers/gpu/drm/radeon/radeon_pm.c +1 -1
@@ -1954,7 +1954,7 @@ DEFINE_SHOW_ATTRIBUTE(radeon_debugfs_pm_info);static void radeon_debugfs_pm_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("radeon_pm_info" ,0444 , root, rdev, &radeon_debugfs_pm_info_fops);
drivers/gpu/drm/radeon/radeon_ring.c +1 -1
@@ -548,7 +548,7 @@ static void radeon_debugfs_ring_init(struct radeon_device *rdev, struct radeon_r {#if defined(CONFIG_DEBUG_FS )const char *ring_name =radeon_debugfs_ring_idx_to_name (ring->idx); -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;if (ring_name) debugfs_create_file(ring_name, 0444, root, ring,
drivers/gpu/drm/radeon/radeon_ttm.c +1 -1
@@ -899,7 +899,7 @@ static void radeon_ttm_debugfs_init(struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS )struct drm_minor *minor = rdev->ddev->primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root = minor->dev->debugfs_root;debugfs_create_file ("radeon_vram" ,0444 , root, rdev, &radeon_ttm_vram_fops);
drivers/gpu/drm/radeon/rs400.c +1 -1
@@ -378,7 +378,7 @@ DEFINE_SHOW_ATTRIBUTE(rs400_debugfs_gart_info);static void rs400_debugfs_pcie_gart_info_init (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("rs400_gart_info" ,0444 , root, rdev, &rs400_debugfs_gart_info_fops);
drivers/gpu/drm/radeon/rv515.c +1 -1
@@ -255,7 +255,7 @@ DEFINE_SHOW_ATTRIBUTE(rv515_debugfs_ga_info);void rv515_debugfs (struct radeon_device *rdev) {#if defined(CONFIG_DEBUG_FS ) -struct dentry *root = rdev->ddev->primary->debugfs_root; +struct dentry *root = rdev->ddev->debugfs_root;debugfs_create_file ("rv515_pipes_info" ,0444 , root, rdev, &rv515_debugfs_pipes_info_fops);
drivers/gpu/drm/sti/sti_cursor.c +1 -1
@@ -142,7 +142,7 @@ static void cursor_debugfs_init(struct sti_cursor *cursor,drm_debugfs_create_files (cursor_debugfs_files,ARRAY_SIZE (cursor_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }static void sti_cursor_argb8888_to_clut8 (struct sti_cursor *cursor,u32 *src)
drivers/gpu/drm/sti/sti_drv.c +2 -2
@@ -95,9 +95,9 @@ static void sti_drm_dbg_init(struct drm_minor *minor) {drm_debugfs_create_files (sti_drm_dbg_list,ARRAY_SIZE (sti_drm_dbg_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); -debugfs_create_file ("fps_show" ,S_IRUGO |S_IWUSR , minor->debugfs_root, +debugfs_create_file ("fps_show" ,S_IRUGO |S_IWUSR , minor->dev->debugfs_root, minor->dev, &sti_drm_fps_fops);DRM_INFO ("%s: debugfs installed\n" ,DRIVER_NAME );
drivers/gpu/drm/sti/sti_dvo.c +1 -1
@@ -205,7 +205,7 @@ static void dvo_debugfs_init(struct sti_dvo *dvo, struct drm_minor *minor)drm_debugfs_create_files (dvo_debugfs_files,ARRAY_SIZE (dvo_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }static void sti_dvo_disable (struct drm_bridge *bridge)
drivers/gpu/drm/sti/sti_gdp.c +1 -1
@@ -347,7 +347,7 @@ static int gdp_debugfs_init(struct sti_gdp *gdp, struct drm_minor *minor)drm_debugfs_create_files (gdp_debugfs_files, nb_files, - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);return 0 ; }
drivers/gpu/drm/sti/sti_hda.c +1 -1
@@ -377,7 +377,7 @@ static void hda_debugfs_init(struct sti_hda *hda, struct drm_minor *minor)drm_debugfs_create_files (hda_debugfs_files,ARRAY_SIZE (hda_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }/**
drivers/gpu/drm/sti/sti_hdmi.c +1 -1
@@ -743,7 +743,7 @@ static void hdmi_debugfs_init(struct sti_hdmi *hdmi, struct drm_minor *minor)drm_debugfs_create_files (hdmi_debugfs_files,ARRAY_SIZE (hdmi_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }static void sti_hdmi_disable (struct drm_bridge *bridge)
drivers/gpu/drm/sti/sti_hqvdp.c +1 -1
@@ -650,7 +650,7 @@ static void hqvdp_debugfs_init(struct sti_hqvdp *hqvdp, struct drm_minor *minor)drm_debugfs_create_files (hqvdp_debugfs_files,ARRAY_SIZE (hqvdp_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }/**
drivers/gpu/drm/sti/sti_mixer.c +1 -1
@@ -202,7 +202,7 @@ void sti_mixer_debugfs_init(struct sti_mixer *mixer, struct drm_minor *minor)drm_debugfs_create_files (mixer_debugfs_files, nb_files, - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }void sti_mixer_set_background_status (struct sti_mixer *mixer,bool enable)
drivers/gpu/drm/sti/sti_tvout.c +1 -1
@@ -579,7 +579,7 @@ static void tvout_debugfs_init(struct sti_tvout *tvout, struct drm_minor *minor)drm_debugfs_create_files (tvout_debugfs_files,ARRAY_SIZE (tvout_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }static void sti_tvout_encoder_dpms (struct drm_encoder *encoder,int mode)
drivers/gpu/drm/sti/sti_vid.c +1 -1
@@ -133,7 +133,7 @@ void vid_debugfs_init(struct sti_vid *vid, struct drm_minor *minor)drm_debugfs_create_files (vid_debugfs_files,ARRAY_SIZE (vid_debugfs_files), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); } void sti_vid_commit(struct sti_vid *vid,
drivers/gpu/drm/tegra/drm.c +1 -1
@@ -876,7 +876,7 @@ static void tegra_debugfs_init(struct drm_minor *minor) {drm_debugfs_create_files (tegra_debugfs_list,ARRAY_SIZE (tegra_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }#endif
drivers/gpu/drm/tilcdc/tilcdc_drv.c +1 -1
@@ -468,7 +468,7 @@ static void tilcdc_debugfs_init(struct drm_minor *minor)drm_debugfs_create_files (tilcdc_debugfs_list,ARRAY_SIZE (tilcdc_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor);list_for_each_entry (mod, &module_list, list)if (mod->funcs->debugfs_init)
drivers/gpu/drm/tiny/arcpgu.c +1 -1
@@ -357,7 +357,7 @@ static void arcpgu_debugfs_init(struct drm_minor *minor) {drm_debugfs_create_files (arcpgu_debugfs_list,ARRAY_SIZE (arcpgu_debugfs_list), - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }#endif
drivers/gpu/drm/vc4/vc4_hvs.c +1 -1
@@ -769,7 +769,7 @@ int vc4_hvs_debugfs_init(struct drm_minor *minor)if (!vc4->is_vc5)debugfs_create_bool ("hvs_load_tracker" ,S_IRUGO |S_IWUSR , - minor->debugfs_root, + minor->dev->debugfs_root, &vc4->load_tracker_enabled);drm_debugfs_add_file (drm,"hvs_dlists" , vc4_hvs_debugfs_dlist,NULL );
drivers/gpu/drm/virtio/virtgpu_debugfs.c +1 -1
@@ -107,5 +107,5 @@ virtio_gpu_debugfs_init(struct drm_minor *minor) {drm_debugfs_create_files (virtio_gpu_debugfs_list,VIRTIO_GPU_DEBUGFS_ENTRIES , - minor->debugfs_root, minor); + minor->dev->debugfs_root, minor); }
drivers/gpu/drm/vmwgfx/vmwgfx_drv.c +1 -1
@@ -1409,7 +1409,7 @@ static void vmw_remove(struct pci_dev *pdev)static void vmw_debugfs_resource_managers_init (struct vmw_private *vmw) {struct drm_minor *minor = vmw->drm.primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root = minor->dev->debugfs_root;ttm_resource_manager_create_debugfs (ttm_manager_type (&vmw->bdev,TTM_PL_SYSTEM ), root,"system_ttm" );
drivers/gpu/drm/vmwgfx/vmwgfx_gem.c +1 -1
@@ -267,7 +267,7 @@ void vmw_debugfs_gem_init(struct vmw_private *vdev) {#if defined(CONFIG_DEBUG_FS )struct drm_minor *minor = vdev->drm.primary; -struct dentry *root = minor->debugfs_root; +struct dentry *root = minor->dev->debugfs_root;debugfs_create_file ("vmwgfx_gem_info" ,0444 , root, vdev, &vmw_debugfs_gem_info_fops);
include/drm/drm_file.h +0 -2
@@ -77,8 +77,6 @@ struct drm_minor {int type;/* Control or render or accel */ struct device *kdev;/* Linux device */ struct drm_device *dev; - -struct dentry *debugfs_root; };/**
Signature · 1 line
2.34.1
kernel test robot
build botRe: [PATCH 7/7] drm/debugfs: remove debugfs_root pointer from minor
I love your patch! Yet something to improve:
Hi Christian,
I love your patch! Yet something to improve:
[auto build test ERROR on drm-misc/drm-misc-next]
[also build test ERROR on drm-intel/for-linux-next-fixes linus/master v6.3-rc2] [cannot apply to drm-tip/drm-tip drm-intel/for-linux-next tegra/for-next next-20230316] [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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Christian-K-nig/drm-tegra-allow-compile-test-on-ARM/20230316-172205 base: git://anongit.freedesktop.org/drm/drm-misc drm-misc-next patch link: https://lore.kernel.org/r/20230316082035.567520-8-christian.koenig%40amd.com patch subject: [PATCH 7/7] drm/debugfs: remove debugfs_root pointer from minor config: s390-allyesconfig (https://download.01.org/0day-ci/archive/20230316/[email protected]/config) compiler: s390-linux-gcc (GCC) 12.1.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/intel-lab-lkp/linux/commit/70b21b15c200ec426c806bf2aa03083e3b19dd41
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Christian-K-nig/drm-tegra-allow-compile-test-on-ARM/20230316-172205 git checkout 70b21b15c200ec426c806bf2aa03083e3b19dd41
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=s390 olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=s390 SHELL=/bin/bash drivers/gpu/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <[email protected]>
| Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
drivers/gpu/drm/msm/msm_debugfs.c: In function 'msm_debugfs_init':
>> drivers/gpu/drm/msm/msm_debugfs.c:329:58: error: 'struct drm_minor' has no member named 'debugfs_root'
329 | gpu_devfreq = debugfs_create_dir("devfreq", minor->debugfs_root);
| ^~vim +329 drivers/gpu/drm/msm/msm_debugfs.c
edcd60ce243d16 Rob Clark 2016-03-16 303
7ce84471e3c72e Wambui Karuga 2020-03-10 304 void msm_debugfs_init(struct drm_minor *minor)
edcd60ce243d16 Rob Clark 2016-03-16 305 {
edcd60ce243d16 Rob Clark 2016-03-16 306 struct drm_device *dev = minor->dev;
bc5289eed48176 Rob Clark 2016-10-26 307 struct msm_drm_private *priv = dev->dev_private;
6563f60f14cbb3 Rob Clark 2023-01-10 308 struct dentry *gpu_devfreq;
edcd60ce243d16 Rob Clark 2016-03-16 309
9e2fd463ec346d Wambui Karuga 2020-03-10 310 drm_debugfs_create_files(msm_debugfs_list,
edcd60ce243d16 Rob Clark 2016-03-16 311 ARRAY_SIZE(msm_debugfs_list),
70b21b15c200ec Christian König 2023-03-16 312 minor->dev->debugfs_root, minor);
edcd60ce243d16 Rob Clark 2016-03-16 313
70b21b15c200ec Christian König 2023-03-16 314 debugfs_create_file("gpu", S_IRUSR, minor->dev->debugfs_root,
4f776f4511c7f7 Jordan Crouse 2018-07-24 315 dev, &msm_gpu_fops);
4f776f4511c7f7 Jordan Crouse 2018-07-24 316
70b21b15c200ec Christian König 2023-03-16 317 debugfs_create_file("kms", S_IRUSR, minor->dev->debugfs_root,
c1760555884b7f Rob Clark 2021-12-15 318 dev, &msm_kms_fops);
c1760555884b7f Rob Clark 2021-12-15 319 70b21b15c200ec Christian König 2023-03-16 320 debugfs_create_u32("hangcheck_period_ms", 0600, minor->dev->debugfs_root,1d2fa58e0dda33 Samuel Iglesias Gonsalvez 2021-06-07 321 &priv->hangcheck_period);1d2fa58e0dda33 Samuel Iglesias Gonsalvez 2021-06-07 32270b21b15c200ec Christian König 2023-03-16 323 debugfs_create_bool("disable_err_irq", 0600, minor->dev->debugfs_root,
5edf2750d998b7 Rob Clark 2021-11-09 324 &priv->disable_err_irq);
5edf2750d998b7 Rob Clark 2021-11-09 325
70b21b15c200ec Christian König 2023-03-16 326 debugfs_create_file("shrink", S_IRWXU, minor->dev->debugfs_root,
5434941fd45d30 Rob Clark 2021-06-14 327 dev, &shrink_fops);
5434941fd45d30 Rob Clark 2021-06-14 328
6563f60f14cbb3 Rob Clark 2023-01-10 @329 gpu_devfreq = debugfs_create_dir("devfreq", minor->debugfs_root);
6563f60f14cbb3 Rob Clark 2023-01-10 330
6563f60f14cbb3 Rob Clark 2023-01-10 331 debugfs_create_bool("idle_clamp",0600, gpu_devfreq,
6563f60f14cbb3 Rob Clark 2023-01-10 332 &priv->gpu_clamp_to_idle);
6563f60f14cbb3 Rob Clark 2023-01-10 333
6563f60f14cbb3 Rob Clark 2023-01-10 334 debugfs_create_u32("upthreshold",0600, gpu_devfreq,
6563f60f14cbb3 Rob Clark 2023-01-10 335 &priv->gpu_devfreq_config.upthreshold);
6563f60f14cbb3 Rob Clark 2023-01-10 336
6563f60f14cbb3 Rob Clark 2023-01-10 337 debugfs_create_u32("downdifferential",0600, gpu_devfreq,
6563f60f14cbb3 Rob Clark 2023-01-10 338 &priv->gpu_devfreq_config.downdifferential);
6563f60f14cbb3 Rob Clark 2023-01-10 339
7ce84471e3c72e Wambui Karuga 2020-03-10 340 if (priv->kms && priv->kms->funcs->debugfs_init)
7ce84471e3c72e Wambui Karuga 2020-03-10 341 priv->kms->funcs->debugfs_init(priv->kms, minor);
6d29709de8028c Rob Clark 2022-08-07 342 Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests
Patchwork
CI[Intel-gfx] ✗ Fi.CI.BUILD: failure for series starting with [1/7] drm: remove drm_dev_set_unique
In reply to Christian König== Series Details ==
== Series Details ==
Series: series starting with [1/7] drm: remove drm_dev_set_unique
URL : https://patchwork.freedesktop.org/series/115239/
State : failure
== Summary ==
Error: patch https://patchwork.freedesktop.org/api/1.0/series/115239/revisions/1/mbox/ not applied
Applying: drm: remove drm_dev_set_unique
Applying: drm/tegra: allow compile test on !ARM
Applying: drm/debugfs: stop calling debugfs_init() for the render node
Applying: drm/debugfs: rework debugfs directory creation v2
Applying: drm/debugfs: remove dev->debugfs_list and debugfs_mutex v2
Applying: drm/debugfs: rework drm_debugfs_create_files implementation
Applying: drm/debugfs: remove debugfs_root pointer from minor
error: sha1 information is lacking or useless (drivers/gpu/drm/drm_debugfs.c).
error: could not build fake ancestor
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0007 drm/debugfs: remove debugfs_root pointer from minor
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
Jani Nikula
maintainerRe: [Intel-gfx] ✗ Fi.CI.BUILD: failure for series starting with [1/7] drm: remove drm_dev_set_unique
Quoted 8 lines · Patchwork
== Series Details ==
Series: series starting with [1/7] drm: remove
drm_dev_set_unique
URL : https://patchwork.freedesktop.org/series/115239/
State : failure== Summary ==
Quoted 15 lines
Error: patch https://patchwork.freedesktop.org/api/1.0/series/115239/revisions/1/mbox/ not applied
Applying: drm: removedrm_dev_set_unique
Applying: drm/tegra: allow compile test on !ARM
Applying: drm/debugfs: stop callingdebugfs_init()for the render node
Applying: drm/debugfs: rework debugfs directory creation v2
Applying: drm/debugfs: removedev->debugfs_listanddebugfs_mutexv2
Applying: drm/debugfs: reworkdrm_debugfs_create_filesimplementation
Applying: drm/debugfs: removedebugfs_rootpointer from minor
error: sha1 information is lacking or useless (drivers/gpu/drm/drm_debugfs.c).
error: could not build fake ancestor
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0007 drm/debugfs: removedebugfs_rootpointer from minor
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
Please send a series based on drm-tip to get a CI run on this.
BR,
Jani.
Signature · 1 line
Jani Nikula, Intel Open Source Graphics Center
Re: [Intel-gfx] ✗ Fi.CI.BUILD: failure for series starting with [1/7] drm: remove drm_dev_set_unique
Am 22.03.23 um 12:58 schrieb Jani Nikula:
Quoted 24 lines · Patchwork
Quoted 8 lines
== Series Details ==
Series: series starting with [1/7] drm: remove
drm_dev_set_unique
URL : https://patchwork.freedesktop.org/series/115239/
State : failure== Summary ==
Quoted 15 lines
Error: patch https://patchwork.freedesktop.org/api/1.0/series/115239/revisions/1/mbox/ not applied
Applying: drm: removedrm_dev_set_unique
Applying: drm/tegra: allow compile test on !ARM
Applying: drm/debugfs: stop callingdebugfs_init()for the render node
Applying: drm/debugfs: rework debugfs directory creation v2
Applying: drm/debugfs: removedev->debugfs_listanddebugfs_mutexv2
Applying: drm/debugfs: reworkdrm_debugfs_create_filesimplementation
Applying: drm/debugfs: removedebugfs_rootpointer from minor
error: sha1 information is lacking or useless (drivers/gpu/drm/drm_debugfs.c).
error: could not build fake ancestor
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0007 drm/debugfs: removedebugfs_rootpointer from minor
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
Quoted 1 line
Please send a series based on drm-tip to get a CI run on this.
I have already been working on this. Should go out in an hour or so.
Thanks,
Christian.
Quoted 5 lines
BR,
Jani.
Quoted 5 lines · Christian König
Hi guys,
I've messed up the last send out. Cleanup up some issues reported by people with the accel drivers (duplicated files) and rebased the result.
Apart from that the same approach we already discussed previously.
I tested the whole set with accel/ivpu driver and everything works as expected.
Regards
Stanislaw