Assert number of cachelines to evict

Number of cachelines to evcit can't be greater than the number of unmapped
entries in request.

Signed-off-by: Michal Mielewczyk <michal.mielewczyk@intel.com>
This commit is contained in:
Michal Mielewczyk 2021-03-16 15:37:03 +01:00
parent 4e8c037d7b
commit 71ec08c158

View File

@ -683,6 +683,8 @@ uint32_t evp_lru_req_clines(struct ocf_request *req,
++req_idx; ++req_idx;
++i; ++i;
/* Number of cachelines to evict have to match space in the request */
ENV_BUG_ON(req_idx == req->core_line_count && i != cline_no );
} }
return i; return i;