Using negative cache index
Stefan Kalkowski
stefan.kalkowski at ...1...
Mon Oct 22 12:49:52 CEST 2012
Hi Ildar,
On 18.10.2012 11:29, Ildar wrote:
>
> Test case is intensive usage of block driver:
>
> If "devices[idx]->cache()->insert(addr, req);" function called from
> genode_block_request when Req_cache::_cache array is full, the
> Req_cache::_find(0) return -1, and data don't added to Req_cache::_cache
> array. Next "devices[idx]->cache()->remove(session->tx()->packet_content(packet),
> &req)"
> function call from "genode_block_collect_responses" will delete data
> from Req_cache::_cache array but Req_cache::_find(packet) will return
> -1 because previous "Req_cache::insert"
> call not inserted item to Req_cache::_cache array and this bug appears.
>
well that should never happen that the request cache is smaller than the
request-queue size of the block-session. If we just try to cover the
error case of insert/remove from the cache we'll get integrity problems
in Linux because single blocks won't get read correctly, or won't get
written. I've fixed that problem by always dimensioning the cache
according to the block-session's queue size. Please refer to issue #426
in our issue tracker.
Btw. would you mind to report, and discuss such issues in our issue
tracker. Of course, general discussions, design issues, and so on
furthermore are best placed on the mailing list.
Regards
Stefan
--
Stefan Kalkowski
Genode Labs
http://www.genode-labs.com/ ยท http://genode.org/
More information about the users
mailing list