accel/habanalabs: expose debugfs files later
authorTomer Tayar <ttayar@habana.ai>
Sun, 19 Mar 2023 19:46:44 +0000 (21:46 +0200)
committerOded Gabbay <ogabbay@kernel.org>
Thu, 8 Jun 2023 09:35:54 +0000 (12:35 +0300)
commit3b9abb4fa642ee28bcd22a0398087a2d87d3c987
treed2c456fdaf3465bf223e8ee48e529ac4283c45a8
parentd8b9cea584661b30305cf341bf9f675dc0a25471
accel/habanalabs: expose debugfs files later

Currently the debugfs root folder and files for a device are created at
an early step, before the device initialization and before the char
device and sysfs files are exposed to user.
As there is no real reason not to do it together with the device
creation, postpone it to be done right afterwards.

The initialization of the debugfs entry structure is left in its
current position because it is used before creating the files.

Signed-off-by: Tomer Tayar <ttayar@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/accel/habanalabs/common/debugfs.c
drivers/accel/habanalabs/common/device.c
drivers/accel/habanalabs/common/habanalabs.h