ubus example memory slave sequence

3 posts / 0 new
Last post
ubxes
Offline
Academy Total Access User
Joined: 12/09/2011
Posts: 2
ubus example memory slave sequence

Hi

I'm trying to get started with UVM...
Use the memory model approach in the ubus example, I couldn't get the write working in my code.
In the example, the post_do function uses req.data to update the memory. It seems to me though that this field is never filled with the written data: The pre_do task allocates a new array upon a valid address phase, but only puts data there if it is a read access.

Obviously I miss some lines here, because the example seems to work fine. How does the written data get into req.data?

Thanks for the help
emanuel

PS: If somebody can recommend a good book or similar about UVM, I would appreciate that a lot.

ubxes
Offline
Academy Total Access User
Joined: 12/09/2011
Posts: 2
Re: ubus example memory slave sequence

I guess grep gave me the answer:
Line 97 in ubus_slave_driver: resp.data[i] = vif.sig_data;

Somehow confusing that the driver actually samples data.

Regards,
emanuel

mperyer
Offline
Verification Forum Moderator
Joined: 07/24/2010
Posts: 146
Re: ubus example memory slave sequence

Please take a look at the Verification Academy on-line cookbook:

http://verificationacademy.com/uvm-ovm

It has code examples that you can download, these illustrate the best practices described in the book.

There are also some videos on UVM that you can watch - See Academy Modules, they may also be of help.