The GPU has a timer, one of the pieces of information
we need to pass into GSP init later is the timer offset.
This series just adds support for setting up the timer
on Turing+, with hals for Turing and Hopper.
Right now it calculates the value to send to GSP but
the code to send it will be added later.
For some hardware variants sending a proper value
is required for GSP init to succeed.
Signed-off-by: Dave Airlie <[email protected]>
---
Changes in v5:
- Alexandre's review comments handled
- reworked registers/workaround logic into fsp
- fixed all the timer register handling to be non-falling.
- Link to v4:
https://lore.kernel.org/r/[email protected]
Changes in v4:
- reworked register handling
- used a timerstate.
- Link to v3:
https://lore.kernel.org/r/[email protected]
---
Dave Airlie (2):
rust: time: expose as_nanos for clock sources.
gpu: nova-core: add support for GPU timer block. (v5)
drivers/gpu/nova-core/fsp.rs | 19 ++++++-
drivers/gpu/nova-core/fsp/hal.rs | 5 ++
drivers/gpu/nova-core/fsp/hal/gh100.rs | 6 ++
drivers/gpu/nova-core/fsp/regs.rs | 28 +++++++++
drivers/gpu/nova-core/gpu.rs | 8 +++
drivers/gpu/nova-core/nova_core.rs | 1 +
drivers/gpu/nova-core/timer.rs | 38 +++++++++++++
drivers/gpu/nova-core/timer/hal.rs | 31 ++++++++++
drivers/gpu/nova-core/timer/hal/gh100.rs | 62 ++++++++++++++++++++
drivers/gpu/nova-core/timer/hal/tu102.rs | 53 +++++++++++++++++
drivers/gpu/nova-core/timer/regs.rs | 98 ++++++++++++++++++++++++++++++++
rust/kernel/time.rs | 3 +-
12 files changed, 348 insertions(+), 4 deletions(-)
---
base-commit: 7a6bc132f1b51437063c9203e7221067b40a791e
change-id: 20261102-nova-timer-f4b9de3274a1
Best regards,
--
Dave Airlie <[email protected]>