diff options
author | Koby Elbaz <kelbaz@habana.ai> | 2021-05-03 23:03:15 +0300 |
---|---|---|
committer | Oded Gabbay <ogabbay@kernel.org> | 2021-06-18 15:23:39 +0300 |
commit | 8121736bbf3d5cbd3dcae1e8a40c31fff5713427 (patch) | |
tree | b2447f0eb1001937382a6a2748a8949623fd6bbc /drivers/misc/habanalabs/goya | |
parent | e67a60400ffc75f52705ae8cac937fd8f00e153a (diff) | |
download | linux-8121736bbf3d5cbd3dcae1e8a40c31fff5713427.tar.bz2 |
habanalabs/gaudi: use scratchpad regs instead of GIC controller
Due to new security restrictions, GIC controller can no
longer be accessed from user/kernel.
To monitor that, a new status bit will be read from preboot
caps, indicating whether direct access to GIC is blocked.
In case it is blocked, driver will use scratchpad registers
instead of using GIC interface on two main scenarios:
The first of which LKD triggers interrupts to F/W through GIC,
and the second of when LKD configures all engines/QMANs
to write to GIC when they want to report an error.
From F/W perspective, it will poll on all SPs, and once IRQ
number is retrieved, SP register is cleared, and it will perform the
write to the GIC to trigger the IRQ handler.
Signed-off-by: Koby Elbaz <kelbaz@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'drivers/misc/habanalabs/goya')
-rw-r--r-- | drivers/misc/habanalabs/goya/goya.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/misc/habanalabs/goya/goya.c b/drivers/misc/habanalabs/goya/goya.c index f1bd8e826304..3d7a760cf2ba 100644 --- a/drivers/misc/habanalabs/goya/goya.c +++ b/drivers/misc/habanalabs/goya/goya.c @@ -464,6 +464,7 @@ int goya_get_fixed_properties(struct hl_device *hdev) prop->fw_cpu_boot_dev_sts0_valid = false; prop->fw_cpu_boot_dev_sts1_valid = false; prop->hard_reset_done_by_fw = false; + prop->gic_interrupts_enable = true; return 0; } |