habanalabs: check if asic secured with asic type

Fix issue in which the input to the function is_asic_secured was device
PCI_IDS number instead of the asic_type enumeration.

Signed-off-by: Ohad Sharabi <osharabi@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
This commit is contained in:
Ohad Sharabi 2021-05-11 16:02:41 +03:00 committed by Oded Gabbay
parent 3e0ca9fab1
commit 190ec49710
1 changed files with 1 additions and 1 deletions

View File

@ -309,7 +309,7 @@ int create_hdev(struct hl_device **dev, struct pci_dev *pdev,
if (pdev)
hdev->asic_prop.fw_security_disabled =
!is_asic_secured(pdev->device);
!is_asic_secured(hdev->asic_type);
else
hdev->asic_prop.fw_security_disabled = true;