habanalabs: enable device before hw_init()
authorOded Gabbay <oded.gabbay@gmail.com>
Wed, 15 Jul 2020 18:59:32 +0000 (21:59 +0300)
committerOded Gabbay <oded.gabbay@gmail.com>
Fri, 24 Jul 2020 17:31:37 +0000 (20:31 +0300)
commit8df8cb1efc1962356c97656839ea9c41e1ed4ba9
tree1b12bb76e046441dcb98047d3f03eea8d65d346e
parenta04b7cd97eef13a489ca44c979cf91e24cfa7b55
habanalabs: enable device before hw_init()

Device is now enabled before the hw_init() because part of the
initialization requires communication with the device firmware to get
information that is required for the initialization itself

Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Reviewed-by: Tomer Tayar <ttayar@habana.ai>
drivers/misc/habanalabs/common/device.c
drivers/misc/habanalabs/common/sysfs.c