Lines Matching full:rc

74 	long rc;  in plpar_pte_enter()  local
77 rc = plpar_hcall(H_ENTER, retbuf, flags, hpte_group, hpte_v, hpte_r); in plpar_pte_enter()
81 return rc; in plpar_pte_enter()
88 long rc; in plpar_pte_remove() local
91 rc = plpar_hcall(H_REMOVE, retbuf, flags, ptex, avpn); in plpar_pte_remove()
96 return rc; in plpar_pte_remove()
104 long rc; in plpar_pte_remove_raw() local
107 rc = plpar_hcall_raw(H_REMOVE, retbuf, flags, ptex, avpn); in plpar_pte_remove_raw()
112 return rc; in plpar_pte_remove_raw()
118 long rc; in plpar_pte_read() local
121 rc = plpar_hcall(H_READ, retbuf, flags, ptex); in plpar_pte_read()
126 return rc; in plpar_pte_read()
133 long rc; in plpar_pte_read_raw() local
136 rc = plpar_hcall_raw(H_READ, retbuf, flags, ptex); in plpar_pte_read_raw()
141 return rc; in plpar_pte_read_raw()
151 long rc; in plpar_pte_read_4() local
154 rc = plpar_hcall9(H_READ, retbuf, flags | H_READ_4, ptex); in plpar_pte_read_4()
158 return rc; in plpar_pte_read_4()
169 long rc; in plpar_pte_read_4_raw() local
172 rc = plpar_hcall9_raw(H_READ, retbuf, flags | H_READ_4, ptex); in plpar_pte_read_4_raw()
176 return rc; in plpar_pte_read_4_raw()
200 long rc; in plpar_tce_get() local
203 rc = plpar_hcall(H_GET_TCE, retbuf, liobn, ioba); in plpar_tce_get()
207 return rc; in plpar_tce_get()
308 long rc; in plpar_get_cpu_characteristics() local
310 rc = plpar_hcall(H_GET_CPU_CHARACTERISTICS, retbuf); in plpar_get_cpu_characteristics()
311 if (rc == H_SUCCESS) { in plpar_get_cpu_characteristics()
316 return rc; in plpar_get_cpu_characteristics()
323 long rc; in plpar_guest_create() local
327 rc = plpar_hcall(H_GUEST_CREATE, retbuf, flags, token); in plpar_guest_create()
328 if (rc == H_SUCCESS) in plpar_guest_create()
331 if (rc == H_BUSY) { in plpar_guest_create()
336 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_create()
338 msleep(get_longbusy_msecs(rc)); in plpar_guest_create()
339 rc = H_BUSY; in plpar_guest_create()
342 } while (rc == H_BUSY); in plpar_guest_create()
344 return rc; in plpar_guest_create()
351 long rc; in plpar_guest_create_vcpu() local
354 rc = plpar_hcall_norets(H_GUEST_CREATE_VCPU, 0, guest_id, vcpu_id); in plpar_guest_create_vcpu()
356 if (rc == H_BUSY) in plpar_guest_create_vcpu()
359 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_create_vcpu()
360 msleep(get_longbusy_msecs(rc)); in plpar_guest_create_vcpu()
361 rc = H_BUSY; in plpar_guest_create_vcpu()
364 } while (rc == H_BUSY); in plpar_guest_create_vcpu()
366 return rc; in plpar_guest_create_vcpu()
377 long rc; in plpar_guest_set_state() local
380 rc = plpar_hcall(H_GUEST_SET_STATE, retbuf, flags, guest_id, in plpar_guest_set_state()
383 if (rc == H_BUSY) { in plpar_guest_set_state()
388 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_set_state()
389 mdelay(get_longbusy_msecs(rc)); in plpar_guest_set_state()
393 if (rc == H_INVALID_ELEMENT_ID) in plpar_guest_set_state()
395 else if (rc == H_INVALID_ELEMENT_SIZE) in plpar_guest_set_state()
397 else if (rc == H_INVALID_ELEMENT_VALUE) in plpar_guest_set_state()
403 return rc; in plpar_guest_set_state()
414 long rc; in plpar_guest_get_state() local
417 rc = plpar_hcall(H_GUEST_GET_STATE, retbuf, flags, guest_id, in plpar_guest_get_state()
420 if (rc == H_BUSY) { in plpar_guest_get_state()
425 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_get_state()
426 mdelay(get_longbusy_msecs(rc)); in plpar_guest_get_state()
430 if (rc == H_INVALID_ELEMENT_ID) in plpar_guest_get_state()
432 else if (rc == H_INVALID_ELEMENT_SIZE) in plpar_guest_get_state()
434 else if (rc == H_INVALID_ELEMENT_VALUE) in plpar_guest_get_state()
440 return rc; in plpar_guest_get_state()
448 long rc; in plpar_guest_run_vcpu() local
450 rc = plpar_hcall(H_GUEST_RUN_VCPU, retbuf, flags, guest_id, vcpu_id); in plpar_guest_run_vcpu()
451 if (rc == H_SUCCESS) in plpar_guest_run_vcpu()
453 else if (rc == H_INVALID_ELEMENT_ID) in plpar_guest_run_vcpu()
455 else if (rc == H_INVALID_ELEMENT_SIZE) in plpar_guest_run_vcpu()
457 else if (rc == H_INVALID_ELEMENT_VALUE) in plpar_guest_run_vcpu()
460 return rc; in plpar_guest_run_vcpu()
465 long rc; in plpar_guest_delete() local
468 rc = plpar_hcall_norets(H_GUEST_DELETE, flags, guest_id); in plpar_guest_delete()
469 if (rc == H_BUSY) in plpar_guest_delete()
472 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_delete()
473 msleep(get_longbusy_msecs(rc)); in plpar_guest_delete()
474 rc = H_BUSY; in plpar_guest_delete()
477 } while (rc == H_BUSY); in plpar_guest_delete()
479 return rc; in plpar_guest_delete()
486 long rc; in plpar_guest_set_capabilities() local
489 rc = plpar_hcall(H_GUEST_SET_CAPABILITIES, retbuf, flags, capabilities); in plpar_guest_set_capabilities()
490 if (rc == H_BUSY) in plpar_guest_set_capabilities()
493 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_set_capabilities()
494 msleep(get_longbusy_msecs(rc)); in plpar_guest_set_capabilities()
495 rc = H_BUSY; in plpar_guest_set_capabilities()
497 } while (rc == H_BUSY); in plpar_guest_set_capabilities()
499 return rc; in plpar_guest_set_capabilities()
506 long rc; in plpar_guest_get_capabilities() local
509 rc = plpar_hcall(H_GUEST_GET_CAPABILITIES, retbuf, flags); in plpar_guest_get_capabilities()
510 if (rc == H_BUSY) in plpar_guest_get_capabilities()
513 if (H_IS_LONG_BUSY(rc)) { in plpar_guest_get_capabilities()
514 msleep(get_longbusy_msecs(rc)); in plpar_guest_get_capabilities()
515 rc = H_BUSY; in plpar_guest_get_capabilities()
517 } while (rc == H_BUSY); in plpar_guest_get_capabilities()
519 if (rc == H_SUCCESS) in plpar_guest_get_capabilities()
522 return rc; in plpar_guest_get_capabilities()
540 long rc; in pseries_rpt_invalidate() local
544 rc = plpar_hcall_norets(H_RPT_INVALIDATE, pid, target, type, in pseries_rpt_invalidate()
546 if (rc == H_BUSY) { in pseries_rpt_invalidate()
549 } else if (rc == H_SUCCESS) in pseries_rpt_invalidate()
550 return rc; in pseries_rpt_invalidate()
558 rc = plpar_hcall_norets(H_RPT_INVALIDATE, pid, target, in pseries_rpt_invalidate()
560 if (rc == H_BUSY) { in pseries_rpt_invalidate()
563 } else if (rc == H_SUCCESS) in pseries_rpt_invalidate()
564 return rc; in pseries_rpt_invalidate()