Lines Matching refs:caps
303 struct vas_caps *caps; in vas_allocate_window() local
336 caps = &vascaps[VAS_GZIP_QOS_FEAT_TYPE]; in vas_allocate_window()
338 caps = &vascaps[VAS_GZIP_DEF_FEAT_TYPE]; in vas_allocate_window()
340 cop_feat_caps = &caps->caps; in vas_allocate_window()
394 caps->nr_open_wins_progress++; in vas_allocate_window()
430 if (!caps->nr_close_wins && !migration_in_progress) { in vas_allocate_window()
431 list_add(&txwin->win_list, &caps->list); in vas_allocate_window()
432 caps->nr_open_windows++; in vas_allocate_window()
433 caps->nr_open_wins_progress--; in vas_allocate_window()
455 caps->nr_open_wins_progress--; in vas_allocate_window()
494 struct vas_cop_feat_caps *caps; in vas_deallocate_window() local
509 caps = &vascaps[win->win_type].caps; in vas_deallocate_window()
528 atomic_dec(&caps->nr_used_credits); in vas_deallocate_window()
572 struct vas_cop_feat_caps *caps; in get_vas_capabilities() local
581 caps = &vcaps->caps; in get_vas_capabilities()
588 caps->user_mode = hv_caps->user_mode; in get_vas_capabilities()
589 if (!(caps->user_mode & VAS_COPY_PASTE_USER_MODE)) { in get_vas_capabilities()
594 caps->descriptor = be64_to_cpu(hv_caps->descriptor); in get_vas_capabilities()
595 caps->win_type = hv_caps->win_type; in get_vas_capabilities()
596 if (caps->win_type >= VAS_MAX_FEAT_TYPE) { in get_vas_capabilities()
597 pr_err("Unsupported window type %u\n", caps->win_type); in get_vas_capabilities()
600 caps->max_lpar_creds = be16_to_cpu(hv_caps->max_lpar_creds); in get_vas_capabilities()
601 caps->max_win_creds = be16_to_cpu(hv_caps->max_win_creds); in get_vas_capabilities()
602 atomic_set(&caps->nr_total_credits, in get_vas_capabilities()
605 caps->def_lpar_creds = be16_to_cpu(hv_caps->def_lpar_creds); in get_vas_capabilities()
607 if (caps->max_win_creds < DEF_WIN_CREDS) { in get_vas_capabilities()
609 DEF_WIN_CREDS, caps->max_win_creds); in get_vas_capabilities()
614 rc = sysfs_add_vas_caps(caps); in get_vas_capabilities()
635 struct vas_cop_feat_caps *caps = &vcaps->caps; in reconfig_open_windows() local
702 caps->win_type); in reconfig_open_windows()
716 win->win_type = caps->win_type; in reconfig_open_windows()
833 struct vas_cop_feat_caps *caps; in vas_reconfig_capabilties() local
844 caps = &vcaps->caps; in vas_reconfig_capabilties()
848 old_nr_creds = atomic_read(&caps->nr_total_credits); in vas_reconfig_capabilties()
850 atomic_set(&caps->nr_total_credits, new_nr_creds); in vas_reconfig_capabilties()
956 struct vas_cop_feat_caps *caps; in vas_migration_handler() local
976 caps = &vcaps->caps; in vas_migration_handler()
977 old_nr_creds = atomic_read(&caps->nr_total_credits); in vas_migration_handler()
995 atomic_read(&caps->nr_used_credits), in vas_migration_handler()
1032 atomic_set(&caps->nr_total_credits, new_nr_creds); in vas_migration_handler()