Skip to content

Commit

Permalink
Merge pull request #596 from Open-CAS/v21.6.3-stack-overflow
Browse files Browse the repository at this point in the history
[v21.6.3] Fix for issues #988 and #997
  • Loading branch information
Robert Baldyga authored Dec 2, 2021
2 parents 9c7bf5b + 0d737c2 commit 84ce405
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/engine/engine_pt.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ int ocf_read_pt(struct ocf_request *req)
ocf_engine_traverse(req);

if (req->seq_cutoff && ocf_engine_is_dirty_all(req) &&
!req->bf_blocked) {
!req->force_pt) {
use_cache = true;
} else {
if (ocf_engine_mapped_count(req)) {
Expand Down
3 changes: 2 additions & 1 deletion src/engine/engine_rd.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ int ocf_read_generic(struct ocf_request *req)

if (env_atomic_read(&cache->pending_read_misses_list_blocked)) {
/* There are conditions to bypass IO */
req->bf_blocked = true;
req->force_pt = true;
ocf_get_io_if(ocf_cache_mode_pt)->read(req);
return 0;
}
Expand Down Expand Up @@ -254,6 +254,7 @@ int ocf_read_generic(struct ocf_request *req)
}
} else {
ocf_req_clear(req);
req->force_pt = true;
ocf_get_io_if(ocf_cache_mode_pt)->read(req);
}

Expand Down
4 changes: 2 additions & 2 deletions src/ocf_request.h
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,8 @@ struct ocf_request {
uint8_t seq_cutoff : 1;
/*!< Sequential cut off set for this request */

uint8_t bf_blocked : 1;
/*!< Backfill pending read misses list blocked */
uint8_t force_pt : 1;
/*!< Force pass-thru cache mode */

uint8_t wi_second_pass : 1;
/*!< Set after first pass of WI write is completed */
Expand Down

0 comments on commit 84ce405

Please sign in to comment.