habanalabs: unmap PCI bars upon iATU failure
authorOfir Bitton <obitton@habana.ai>
Thu, 16 Jul 2020 10:33:52 +0000 (13:33 +0300)
committerOded Gabbay <oded.gabbay@gmail.com>
Sat, 22 Aug 2020 09:47:56 +0000 (12:47 +0300)
commitf1aae40e8dbd2655e3b10cae381a1e8292b19d57
treee6a50ed54d217c0cb7276828a632f4f78cdf53be
parent51072c0f5b5e98a035c6f63b83ba2afedbb7accd
habanalabs: unmap PCI bars upon iATU failure

In case the driver fails to configure the PCI controller iATU, it needs to
unmap the PCI bars before exiting so if the driver is removed, the bars
won't be left mapped.

Signed-off-by: Ofir Bitton <obitton@habana.ai>
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com>
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
drivers/misc/habanalabs/common/pci.c