From: Luke Kenneth Casson Leighton Date: Wed, 1 Dec 2021 11:53:27 +0000 (+0000) Subject: add Regspecs get_io_spec function X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=072d4d2f4ca5f585827b8ecbb5bf0ab18eb7f1c3;p=soc.git add Regspecs get_io_spec function --- diff --git a/src/soc/fu/regspec.py b/src/soc/fu/regspec.py index f6d90d9e..6804c593 100644 --- a/src/soc/fu/regspec.py +++ b/src/soc/fu/regspec.py @@ -65,6 +65,11 @@ class RegSpecAPI: """ self.rwid = rwid + def get_io_spec(self, direction, i): + if direction: # input (read specs) + return self.get_in_spec(i) + return self.get_out_spec(i) + def get_in_spec(self, i): return self.rwid[0][i]