diff options
author | Eric Anholt <[email protected]> | 2018-01-04 11:32:46 -0800 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2018-01-12 21:54:00 -0800 |
commit | 39ce1ab7baa6e8db1afceeee875f04190147b5d6 (patch) | |
tree | e1243b99d5757b73850a9cd7de0fefab2d19b11f /src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp | |
parent | c81cc767e4eef7a03dfeda2ed01565f3906b6f24 (diff) |
broadcom/vc5: Port the simulator to support V3D 4.1
This required moving the register accesses to a separate v3dx file, since
the register definitions for each V3D version collide. It seems that
initializing the v3d_hw from a file dictating 3.3
(v3d_simulator_wrapper.cpp) is safe, though.
Diffstat (limited to 'src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp')
-rw-r--r-- | src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp b/src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp index 1e3c5c8f8c2..5776aea20b4 100644 --- a/src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp +++ b/src/gallium/drivers/vc5/vc5_simulator_wrapper.cpp @@ -76,6 +76,13 @@ void v3d_hw_tick(struct v3d_hw *hw) return hw->tick(); } +int v3d_hw_get_version(struct v3d_hw *hw) +{ + const V3D_HUB_IDENT_T *ident = hw->get_hub_ident(); + + return ident->tech_version * 10 + ident->revision; +} + } #endif /* USE_VC5_SIMULATOR */ |