tenstorrent / tt-umd

User-Mode Driver for Tenstorrent hardware
Apache License 2.0
9 stars 5 forks source link

Move PCIDevice functions to PCIDevice class #155

Closed broskoTT closed 3 weeks ago

broskoTT commented 3 weeks ago

Some of the functions which clearly accept PCIDevice pointer were located in tt_silicon_driver, but they obviously should be part of the PCIDevice class. Those same functions are also arch specific, so they'll probably be moved to new class TTDevice according to https://docs.google.com/drawings/d/1-m1azdsBqMA0A6ATYRMfkhyeuOJuGCEI62N5a96LXj0/edit

I've also changed two functions, broadcast_pcie_tensix_risc_reset and get_power_state_arc_msg to accept chip_id rather than PCIDevice pointer. These were private members, so no API change.

Related to #142