commit
3b42355b82
@ -2760,6 +2760,7 @@ int list_caches(unsigned int list_format, bool by_id_path)
|
|||||||
char status_buf[CACHE_STATE_LENGHT];
|
char status_buf[CACHE_STATE_LENGHT];
|
||||||
const char *tmp_status;
|
const char *tmp_status;
|
||||||
char mode_string[12];
|
char mode_string[12];
|
||||||
|
char cache_ctrl_dev[MAX_STR_LEN];
|
||||||
float cache_flush_prog;
|
float cache_flush_prog;
|
||||||
float core_flush_prog;
|
float core_flush_prog;
|
||||||
|
|
||||||
@ -2782,9 +2783,12 @@ int list_caches(unsigned int list_format, bool by_id_path)
|
|||||||
tmp_status = get_cache_state_name(curr_cache->state);
|
tmp_status = get_cache_state_name(curr_cache->state);
|
||||||
if (curr_cache->state & (1 << ocf_cache_state_standby)) {
|
if (curr_cache->state & (1 << ocf_cache_state_standby)) {
|
||||||
strncpy(mode_string, "-", sizeof(mode_string));
|
strncpy(mode_string, "-", sizeof(mode_string));
|
||||||
|
snprintf(cache_ctrl_dev, sizeof(cache_ctrl_dev),
|
||||||
|
"/dev/cas-cache-%d", curr_cache->id);
|
||||||
} else {
|
} else {
|
||||||
snprintf(mode_string, sizeof(mode_string), "%s",
|
snprintf(mode_string, sizeof(mode_string), "%s",
|
||||||
cache_mode_to_name(curr_cache->mode));
|
cache_mode_to_name(curr_cache->mode));
|
||||||
|
strncpy(cache_ctrl_dev, "-", sizeof(cache_ctrl_dev));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2795,7 +2799,7 @@ int list_caches(unsigned int list_format, bool by_id_path)
|
|||||||
curr_cache->device, /* device path */
|
curr_cache->device, /* device path */
|
||||||
tmp_status, /* cache status */
|
tmp_status, /* cache status */
|
||||||
mode_string, /* write policy */
|
mode_string, /* write policy */
|
||||||
"-" /* device */);
|
cache_ctrl_dev /* device */);
|
||||||
|
|
||||||
for (j = 0; j < curr_cache->core_count; ++j) {
|
for (j = 0; j < curr_cache->core_count; ++j) {
|
||||||
char* core_path;
|
char* core_path;
|
||||||
|
2
ocf
2
ocf
@ -1 +1 @@
|
|||||||
Subproject commit c176daeec118430d6d1854302b9f9603b9b084ca
|
Subproject commit 6af8d20ceef70898364b5742feba5d6b2743fb29
|
Loading…
Reference in New Issue
Block a user