Hi Stanislaw, On 2/1/23 12:20, Stanislaw Gruszka wrote:
Hi I was about to send debugfs support for ivpu and noticed that there are current changes that deprecate drm_devel->debugfs_init callback. Further I looked at this commit [1], that stated we should not use drm_minor for debugfs and sysfs. What is quite contrary to what drm accel framework did in the first place. So my question is how we should use debugfs/sysfs in accel? Use it with old fashioned minor-centric way or change the framework somehow ?
As we are trying to replace drm_debugfs_create_files() [1], it would be nice to see the accel debugfs support use the new debugfs API. This would mean using the debugfs_list from the drm_device, deprecating the debugfs_init callback, and adding the a similar code snippet to accel_debugfs_init: 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); Maybe Daniel has some more thoughts on this matter, but I guess it would be better to drop the use of the old-fashioned minor-centric implementation in accel. [1] https://cgit.freedesktop.org/drm/drm-misc/tree/Documentation/gpu/todo.rst#n511 Best Regards, - Maíra Canal
[1] https://cgit.freedesktop.org/drm/drm-misc/commit/?id=99845faae7099cd704ebf67514c1157c26960a26 Regards Stanislaw