Lines Matching defs:props
97 mfi_ld_get_props(int fd, uint8_t target_id, struct mfi_ld_props *props)
102 return (mfi_dcmd_command(fd, MFI_DCMD_LD_GET_PROP, props,
107 mfi_ld_set_props(int fd, struct mfi_ld_props *props)
111 mbox_store_ldref(mbox, &props->ld);
112 return (mfi_dcmd_command(fd, MFI_DCMD_LD_SET_PROP, props,
171 stage_cache_setting(struct mfi_ld_props *props, uint8_t new_policy,
175 props->default_cache_policy &= ~mask;
176 props->default_cache_policy |= new_policy;
185 process_cache_command(int ac, char **av, struct mfi_ld_props *props)
191 stage_cache_setting(props, MR_LD_CACHE_ALLOW_READ_CACHE |
198 stage_cache_setting(props, 0, MR_LD_CACHE_ALLOW_READ_CACHE |
203 stage_cache_setting(props, MR_LD_CACHE_ALLOW_READ_CACHE,
209 stage_cache_setting(props, MR_LD_CACHE_ALLOW_WRITE_CACHE,
217 stage_cache_setting(props, MR_LD_CACHE_WRITE_BACK,
222 stage_cache_setting(props, 0, MR_LD_CACHE_WRITE_BACK);
238 stage_cache_setting(props, policy,
260 stage_cache_setting(props, policy, MR_LD_CACHE_READ_AHEAD |
272 props->disk_cache_policy = MR_PD_CACHE_ENABLE;
274 props->disk_cache_policy = MR_PD_CACHE_DISABLE;
276 props->disk_cache_policy = MR_PD_CACHE_UNCHANGED;
291 struct mfi_ld_props props, new;
314 if (mfi_ld_get_props(fd, target_id, &props) < 0) {
325 switch (props.default_cache_policy &
343 props.default_cache_policy & MR_LD_CACHE_WRITE_BACK ?
346 props.default_cache_policy &
349 props.default_cache_policy & MR_LD_CACHE_READ_AHEAD ?
350 (props.default_cache_policy & MR_LD_CACHE_READ_ADAPTIVE ?
353 switch (props.disk_cache_policy) {
364 printf("??? %d\n", props.disk_cache_policy);
367 if (props.default_cache_policy != props.current_cache_policy)
372 new = props;
384 error = update_cache_policy(fd, &props, &new);
395 struct mfi_ld_props props;
404 if (strlen(av[2]) >= sizeof(props.name)) {
423 if (mfi_ld_get_props(fd, target_id, &props) < 0) {
431 mfi_volume_name(fd, target_id), props.name, av[2]);
432 bzero(props.name, sizeof(props.name));
433 strcpy(props.name, av[2]);
434 if (mfi_ld_set_props(fd, &props) < 0) {