Lines Matching full:guest
117 rc = cxl_h_collect_vpd_adapter(adapter->guest->handle, in guest_collect_vpd()
120 rc = cxl_h_collect_vpd(afu->guest->handle, 0, in guest_collect_vpd()
158 return cxl_h_collect_int_info(ctx->afu->guest->handle, ctx->process_token, info); in guest_get_irq_info()
186 rc = cxl_h_read_error_state(afu->guest->handle, &state); in afu_read_error_state()
203 rc = cxl_h_get_fn_error_interrupt(afu->guest->handle, &serr); in guest_slice_irq_err()
214 rc = cxl_h_ack_fn_error_interrupt(afu->guest->handle, serr); in guest_slice_irq_err()
228 for (i = 0; i < adapter->guest->irq_nranges; i++) { in irq_alloc_range()
229 cur = &adapter->guest->irq_avail[i]; in irq_alloc_range()
235 pr_devel("guest: allocate IRQs %#x->%#x\n", in irq_alloc_range()
252 for (i = 0; i < adapter->guest->irq_nranges; i++) { in irq_free_range()
253 cur = &adapter->guest->irq_avail[i]; in irq_free_range()
258 pr_devel("guest: release IRQs %#x->%#x\n", in irq_free_range()
281 rc = cxl_h_reset_adapter(adapter->guest->handle); in guest_reset()
297 spin_lock(&adapter->guest->irq_alloc_lock); in guest_alloc_one_irq()
300 spin_unlock(&adapter->guest->irq_alloc_lock); in guest_alloc_one_irq()
306 spin_lock(&adapter->guest->irq_alloc_lock); in guest_release_one_irq()
308 spin_unlock(&adapter->guest->irq_alloc_lock); in guest_release_one_irq()
318 spin_lock(&adapter->guest->irq_alloc_lock); in guest_alloc_irq_ranges()
334 spin_unlock(&adapter->guest->irq_alloc_lock); in guest_alloc_irq_ranges()
340 spin_unlock(&adapter->guest->irq_alloc_lock); in guest_alloc_irq_ranges()
349 spin_lock(&adapter->guest->irq_alloc_lock); in guest_release_irq_ranges()
352 spin_unlock(&adapter->guest->irq_alloc_lock); in guest_release_irq_ranges()
381 return cxl_h_control_faults(ctx->afu->guest->handle, ctx->process_token, in guest_ack_irq()
434 rc = cxl_h_get_config(afu->guest->handle, cr_idx, offset, in _guest_afu_cr_readXX()
505 /* config record is not writable from guest */ in guest_afu_cr_write32()
511 /* config record is not writable from guest */ in guest_afu_cr_write16()
517 /* config record is not writable from guest */ in guest_afu_cr_write8()
581 idx = ctx->irqs.offset[r] + i - adapter->guest->irq_base_offset; in attach_afu_directed()
591 rc = cxl_h_attach_process(ctx->afu->guest->handle, elem, in attach_afu_directed()
643 if (cxl_h_detach_process(ctx->afu->guest->handle, ctx->process_token)) in detach_afu_directed()
670 kfree(afu->guest); in guest_release_afu()
690 rc = cxl_h_get_afu_err(afu->guest->handle, in guest_afu_read_err_buffer()
808 return cxl_h_reset_afu(afu->guest->handle); in guest_afu_reset()
813 if (!(afu->p2n_mmio = ioremap(afu->guest->p2n_phys, afu->guest->p2n_size))) { in guest_map_slice_regs()
835 if (afu->guest->previous_state == cur_state) in afu_update_state()
842 afu->guest->previous_state = cur_state; in afu_update_state()
859 afu->guest->previous_state = 0; in afu_update_state()
863 afu->guest->previous_state = cur_state; in afu_update_state()
870 afu->guest->previous_state = cur_state; in afu_update_state()
933 if (!(afu->guest = kzalloc(sizeof(struct cxl_afu_guest), GFP_KERNEL))) { in cxl_guest_init_afu()
995 * of the AFU using "afu" stored in the guest structure. in cxl_guest_init_afu()
997 afu->guest->parent = afu; in cxl_guest_init_afu()
998 afu->guest->handle_err = true; in cxl_guest_init_afu()
999 INIT_DELAYED_WORK(&afu->guest->work_err, afu_handle_errstate); in cxl_guest_init_afu()
1000 schedule_delayed_work(&afu->guest->work_err, msecs_to_jiffies(1000)); in cxl_guest_init_afu()
1019 kfree(afu->guest); in cxl_guest_init_afu()
1031 afu->guest->handle_err = false; in cxl_guest_remove_afu()
1032 flush_delayed_work(&afu->guest->work_err); in cxl_guest_remove_afu()
1054 if (adapter->guest) { in free_adapter()
1055 if (adapter->guest->irq_avail) { in free_adapter()
1056 for (i = 0; i < adapter->guest->irq_nranges; i++) { in free_adapter()
1057 cur = &adapter->guest->irq_avail[i]; in free_adapter()
1060 kfree(adapter->guest->irq_avail); in free_adapter()
1062 kfree(adapter->guest->status); in free_adapter()
1063 kfree(adapter->guest); in free_adapter()
1074 if (strlen(adapter->guest->status) && in properties_look_ok()
1075 strcmp(adapter->guest->status, "okay")) { in properties_look_ok()
1112 if (!(adapter->guest = kzalloc(sizeof(struct cxl_guest), GFP_KERNEL))) { in cxl_guest_init_adapter()
1118 adapter->guest->pdev = pdev; in cxl_guest_init_adapter()
1172 pdev = adapter->guest->pdev; in cxl_guest_reload_module()