-
Notifications
You must be signed in to change notification settings - Fork 803
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GPIO straps verif #25868
base: master
Are you sure you want to change the base?
GPIO straps verif #25868
Conversation
74b9fcd
to
7921fc9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this PR still requires some changes.
05e6443
to
2e49144
Compare
logic strap_en; | ||
assign strap_en_i = strap_en; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, I'm not sure about the way this is using ports. Can't we just have an internal variable called strap_en
and wire that up?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case I am using the gpio_strap_en variable to initialise the strap_en_i with zero after the reset, otherwise I will have spreading X's to the input, so look at the gpio_base_test.sv
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't gpio_base_test
drive the internal value directly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes it's possible, I removed the input/outputs and it's working fine. In my mind I always though like using interface, we are required to declare input/output ports, that is the interface by definition. In this case the interface behavior more like a wrapper for these signals to be used in the testbench, instead of driving directly from the testbench top level or some other way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right (it's basically now just a struct, which is pretty standard for OT DV so far). The "proper" way to do it is probably to use a modport
. See IEEE 1800 section 25.5 for a description of how to use them.
49e465c
to
fdfba6b
Compare
f97049f
to
4e03142
Compare
Removed the assumption StrapSampleOnce_A, that does not work for cases that sample_trigger never fell or if we have more than one reset operation happening during the simulation. Signed-off-by: Marcelo Carvalho Faleiro de Almeida <[email protected]>
4e03142
to
7d1a064
Compare
New sequence to verify the straps feature and some additional description of the behaviour of this feature in the register document.