Lines Matching refs:rc

77 	int rc = 1;  in get_cur_bus_info()  local
84 rc = ibmphp_hpc_readslot(slot_cur, READ_BUSSTATUS, NULL); in get_cur_bus_info()
86 if (rc) in get_cur_bus_info()
87 return rc; in get_cur_bus_info()
107 int rc; in slot_update() local
108 rc = ibmphp_hpc_readslot(*sl, READ_ALLSTAT, NULL); in slot_update()
109 if (rc) in slot_update()
110 return rc; in slot_update()
112 rc = get_cur_bus_info(sl); in slot_update()
113 return rc; in slot_update()
239 int rc = 0; in set_attention_status() local
260 rc = -ENODEV; in set_attention_status()
265 if (rc == 0) { in set_attention_status()
268 rc = ibmphp_hpc_writeslot(pslot, cmd); in set_attention_status()
270 rc = -ENODEV; in set_attention_status()
273 rc = -ENODEV; in set_attention_status()
277 debug("set_attention_status - Exit rc[%d]\n", rc); in set_attention_status()
278 return rc; in set_attention_status()
283 int rc = -ENODEV; in get_attention_status() local
295 rc = ibmphp_hpc_readslot(pslot, READ_SLOTSTATUS, in get_attention_status()
297 if (!rc) in get_attention_status()
298 rc = ibmphp_hpc_readslot(pslot, in get_attention_status()
301 if (!rc) in get_attention_status()
308 debug("get_attention_status - Exit rc[%d] value[%x]\n", rc, *value); in get_attention_status()
309 return rc; in get_attention_status()
314 int rc = -ENODEV; in get_latch_status() local
325 rc = ibmphp_hpc_readslot(pslot, READ_SLOTSTATUS, in get_latch_status()
327 if (!rc) in get_latch_status()
334 rc, rc, *value); in get_latch_status()
335 return rc; in get_latch_status()
341 int rc = -ENODEV; in get_power_status() local
352 rc = ibmphp_hpc_readslot(pslot, READ_SLOTSTATUS, in get_power_status()
354 if (!rc) in get_power_status()
361 rc, rc, *value); in get_power_status()
362 return rc; in get_power_status()
367 int rc = -ENODEV; in get_adapter_present() local
379 rc = ibmphp_hpc_readslot(pslot, READ_SLOTSTATUS, in get_adapter_present()
381 if (!rc) { in get_adapter_present()
392 debug("get_adapter_present - Exit rc[%d] value[%x]\n", rc, *value); in get_adapter_present()
393 return rc; in get_adapter_present()
398 int rc; in get_max_bus_speed() local
423 rc = -ENODEV; in get_max_bus_speed()
426 if (!rc) in get_max_bus_speed()
429 debug("%s - Exit rc[%d] speed[%x]\n", __func__, rc, speed); in get_max_bus_speed()
430 return rc; in get_max_bus_speed()
506 int rc; in init_ops() local
544 rc = power_off(slot_cur); in init_ops()
545 if (rc) in init_ops()
546 return rc; in init_ops()
609 int rc; in ibmphp_update_slot_info() local
657 rc = pci_hp_change_slot_info(slot_cur->hotplug_slot, info); in ibmphp_update_slot_info()
659 return rc; in ibmphp_update_slot_info()
832 int rc; in is_bus_empty() local
844 rc = slot_update(&tmp_slot); in is_bus_empty()
845 if (rc) in is_bus_empty()
863 int rc; in set_bus() local
874 rc = slot_update(&slot_cur); in set_bus()
875 if (rc) in set_bus()
876 return rc; in set_bus()
1018 int rc, i, rcpr; in enable_slot() local
1028 rc = validate(slot_cur, ENABLE); in enable_slot()
1029 if (rc) { in enable_slot()
1036 rc = set_bus(slot_cur); in enable_slot()
1037 if (rc) { in enable_slot()
1048 rc = check_limitations(slot_cur); in enable_slot()
1049 if (rc) { in enable_slot()
1053 rc = -EINVAL; in enable_slot()
1057 rc = power_on(slot_cur); in enable_slot()
1059 if (rc) { in enable_slot()
1067 rc = -ENODEV; in enable_slot()
1091 rc = slot_update(&slot_cur); in enable_slot()
1092 if (rc) in enable_slot()
1095 rc = -EINVAL; in enable_slot()
1117 rc = -ENOMEM; in enable_slot()
1135 rc = -ENOMEM; in enable_slot()
1149 rc = -EFAULT; in enable_slot()
1153 rc = ibmphp_update_slot_info(slot_cur); in enable_slot()
1156 return rc; in enable_slot()
1164 rc = rcpr; in enable_slot()
1175 rc = rcpr; in enable_slot()
1190 int rc; in ibmphp_disable_slot() local
1193 rc = ibmphp_do_disable_slot(slot); in ibmphp_disable_slot()
1195 return rc; in ibmphp_disable_slot()
1200 int rc; in ibmphp_do_disable_slot() local
1212 rc = validate(slot_cur, DISABLE); in ibmphp_do_disable_slot()
1214 if (rc) in ibmphp_do_disable_slot()
1224 rc = -ENOMEM; in ibmphp_do_disable_slot()
1245 rc = ibmphp_unconfigure_card(&slot_cur, 0); in ibmphp_do_disable_slot()
1248 if (rc) { in ibmphp_do_disable_slot()
1253 rc = ibmphp_hpc_writeslot(slot_cur, HPC_SLOT_OFF); in ibmphp_do_disable_slot()
1254 if (rc) in ibmphp_do_disable_slot()
1258 rc = slot_update(&slot_cur); in ibmphp_do_disable_slot()
1259 if (rc) in ibmphp_do_disable_slot()
1262 rc = ibmphp_update_slot_info(slot_cur); in ibmphp_do_disable_slot()
1265 return rc; in ibmphp_do_disable_slot()
1272 rc = -EFAULT; in ibmphp_do_disable_slot()
1313 int rc = 0; in ibmphp_init() local
1322 rc = -ENOMEM; in ibmphp_init()
1329 rc = -ENODEV; in ibmphp_init()
1341 rc = ibmphp_access_ebda(); in ibmphp_init()
1342 if (rc) in ibmphp_init()
1346 rc = ibmphp_rsrc_init(); in ibmphp_init()
1347 if (rc) in ibmphp_init()
1353 rc = ibmphp_register_pci(); in ibmphp_init()
1354 if (rc) in ibmphp_init()
1358 rc = -ENODEV; in ibmphp_init()
1363 rc = ibmphp_hpc_start_poll_thread(); in ibmphp_init()
1364 if (rc) in ibmphp_init()
1368 return rc; in ibmphp_init()