Lines Matching refs:hostrcb

1080 			  struct ipr_hostrcb *hostrcb)  in ipr_send_hcam()  argument
1088 list_add_tail(&hostrcb->queue, &ioa_cfg->hostrcb_pending_q); in ipr_send_hcam()
1090 ipr_cmd->u.hostrcb = hostrcb; in ipr_send_hcam()
1097 ioarcb->cmd_pkt.cdb[7] = (sizeof(hostrcb->hcam) >> 8) & 0xff; in ipr_send_hcam()
1098 ioarcb->cmd_pkt.cdb[8] = sizeof(hostrcb->hcam) & 0xff; in ipr_send_hcam()
1100 ipr_init_ioadl(ipr_cmd, hostrcb->hostrcb_dma, in ipr_send_hcam()
1101 sizeof(hostrcb->hcam), IPR_IOADL_FLAGS_READ_LAST); in ipr_send_hcam()
1112 list_add_tail(&hostrcb->queue, &ioa_cfg->hostrcb_free_q); in ipr_send_hcam()
1400 struct ipr_hostrcb *hostrcb) in ipr_handle_config_change() argument
1409 cfgtew.u.cfgte64 = &hostrcb->hcam.u.ccn.u.cfgte64; in ipr_handle_config_change()
1412 cfgtew.u.cfgte = &hostrcb->hcam.u.ccn.u.cfgte; in ipr_handle_config_change()
1427 hostrcb); in ipr_handle_config_change()
1441 if (hostrcb->hcam.notify_type == IPR_HOST_RCB_NOTIF_TYPE_REM_ENTRY) { in ipr_handle_config_change()
1455 ipr_send_hcam(ioa_cfg, IPR_HCAM_CDB_OP_CODE_CONFIG_CHANGE, hostrcb); in ipr_handle_config_change()
1471 struct ipr_hostrcb *hostrcb = ipr_cmd->u.hostrcb; in ipr_process_ccn() local
1474 list_del(&hostrcb->queue); in ipr_process_ccn()
1483 ipr_send_hcam(ioa_cfg, IPR_HCAM_CDB_OP_CODE_CONFIG_CHANGE, hostrcb); in ipr_process_ccn()
1485 ipr_handle_config_change(ioa_cfg, hostrcb); in ipr_process_ccn()
1518 static void ipr_log_vpd_compact(char *prefix, struct ipr_hostrcb *hostrcb, in ipr_log_vpd_compact() argument
1533 ipr_hcam_err(hostrcb, "%s VPID/SN: %s\n", prefix, buffer); in ipr_log_vpd_compact()
1568 static void ipr_log_ext_vpd_compact(char *prefix, struct ipr_hostrcb *hostrcb, in ipr_log_ext_vpd_compact() argument
1571 ipr_log_vpd_compact(prefix, hostrcb, &vpd->vpd); in ipr_log_ext_vpd_compact()
1572 ipr_hcam_err(hostrcb, "%s WWN: %08X%08X\n", prefix, in ipr_log_ext_vpd_compact()
1599 struct ipr_hostrcb *hostrcb) in ipr_log_enhanced_cache_error() argument
1604 error = &hostrcb->hcam.u.error64.u.type_12_error; in ipr_log_enhanced_cache_error()
1606 error = &hostrcb->hcam.u.error.u.type_12_error; in ipr_log_enhanced_cache_error()
1635 struct ipr_hostrcb *hostrcb) in ipr_log_cache_error() argument
1638 &hostrcb->hcam.u.error.u.type_02_error; in ipr_log_cache_error()
1667 struct ipr_hostrcb *hostrcb) in ipr_log_enhanced_config_error() argument
1673 error = &hostrcb->hcam.u.error.u.type_13_error; in ipr_log_enhanced_config_error()
1707 struct ipr_hostrcb *hostrcb) in ipr_log_sis64_config_error() argument
1714 error = &hostrcb->hcam.u.error64.u.type_23_error; in ipr_log_sis64_config_error()
1750 struct ipr_hostrcb *hostrcb) in ipr_log_config_error() argument
1756 error = &hostrcb->hcam.u.error.u.type_03_error; in ipr_log_config_error()
1797 struct ipr_hostrcb *hostrcb) in ipr_log_enhanced_array_error() argument
1804 error = &hostrcb->hcam.u.error.u.type_14_error; in ipr_log_enhanced_array_error()
1848 struct ipr_hostrcb *hostrcb) in ipr_log_array_error() argument
1855 error = &hostrcb->hcam.u.error.u.type_04_error; in ipr_log_array_error()
1931 struct ipr_hostrcb *hostrcb) in ipr_log_enhanced_dual_ioa_error() argument
1936 error = &hostrcb->hcam.u.error64.u.type_17_error; in ipr_log_enhanced_dual_ioa_error()
1938 error = &hostrcb->hcam.u.error.u.type_17_error; in ipr_log_enhanced_dual_ioa_error()
1943 ipr_hcam_err(hostrcb, "%s [PRC: %08X]\n", error->failure_reason, in ipr_log_enhanced_dual_ioa_error()
1944 be32_to_cpu(hostrcb->hcam.u.error.prc)); in ipr_log_enhanced_dual_ioa_error()
1945 ipr_log_ext_vpd_compact("Remote IOA", hostrcb, &error->vpd); in ipr_log_enhanced_dual_ioa_error()
1947 be32_to_cpu(hostrcb->hcam.length) - in ipr_log_enhanced_dual_ioa_error()
1961 struct ipr_hostrcb *hostrcb) in ipr_log_dual_ioa_error() argument
1965 error = &hostrcb->hcam.u.error.u.type_07_error; in ipr_log_dual_ioa_error()
1969 ipr_hcam_err(hostrcb, "%s [PRC: %08X]\n", error->failure_reason, in ipr_log_dual_ioa_error()
1970 be32_to_cpu(hostrcb->hcam.u.error.prc)); in ipr_log_dual_ioa_error()
1971 ipr_log_vpd_compact("Remote IOA", hostrcb, &error->vpd); in ipr_log_dual_ioa_error()
1973 be32_to_cpu(hostrcb->hcam.length) - in ipr_log_dual_ioa_error()
2005 static void ipr_log_fabric_path(struct ipr_hostrcb *hostrcb, in ipr_log_fabric_path() argument
2022 ipr_hcam_err(hostrcb, "%s %s: IOA Port=%d\n", in ipr_log_fabric_path()
2026 ipr_hcam_err(hostrcb, "%s %s: IOA Port=%d, Phy=%d\n", in ipr_log_fabric_path()
2030 ipr_hcam_err(hostrcb, "%s %s: IOA Port=%d, Cascade=%d\n", in ipr_log_fabric_path()
2034 ipr_hcam_err(hostrcb, "%s %s: IOA Port=%d, Cascade=%d, Phy=%d\n", in ipr_log_fabric_path()
2054 static void ipr_log64_fabric_path(struct ipr_hostrcb *hostrcb, in ipr_log64_fabric_path() argument
2071 ipr_hcam_err(hostrcb, "%s %s: Resource Path=%s\n", in ipr_log64_fabric_path()
2073 ipr_format_res_path(hostrcb->ioa_cfg, in ipr_log64_fabric_path()
2081 ipr_format_res_path(hostrcb->ioa_cfg, fabric->res_path, in ipr_log64_fabric_path()
2134 static void ipr_log_path_elem(struct ipr_hostrcb *hostrcb, in ipr_log_path_elem() argument
2153 ipr_hcam_err(hostrcb, "%s %s: Phy=%d, Link rate=%s, WWN=%08X%08X\n", in ipr_log_path_elem()
2159 ipr_hcam_err(hostrcb, "%s %s: Link rate=%s, WWN=%08X%08X\n", in ipr_log_path_elem()
2164 ipr_hcam_err(hostrcb, "%s %s: Phy=%d, Link rate=%s, " in ipr_log_path_elem()
2170 ipr_hcam_err(hostrcb, "%s %s: Cascade=%d, Link rate=%s, " in ipr_log_path_elem()
2176 ipr_hcam_err(hostrcb, "%s %s: Cascade=%d, Phy=%d, Link rate=%s " in ipr_log_path_elem()
2187 ipr_hcam_err(hostrcb, "Path element=%02X: Cascade=%d Phy=%d Link rate=%s " in ipr_log_path_elem()
2201 static void ipr_log64_path_elem(struct ipr_hostrcb *hostrcb, in ipr_log64_path_elem() argument
2221 ipr_hcam_err(hostrcb, "%s %s: Resource Path=%s, Link rate=%s, WWN=%08X%08X\n", in ipr_log64_path_elem()
2223 ipr_format_res_path(hostrcb->ioa_cfg, in ipr_log64_path_elem()
2231 ipr_hcam_err(hostrcb, "Path element=%02X: Resource Path=%s, Link rate=%s " in ipr_log64_path_elem()
2233 ipr_format_res_path(hostrcb->ioa_cfg, in ipr_log64_path_elem()
2248 struct ipr_hostrcb *hostrcb) in ipr_log_fabric_error() argument
2255 error = &hostrcb->hcam.u.error.u.type_20_error; in ipr_log_fabric_error()
2257 ipr_hcam_err(hostrcb, "%s\n", error->failure_reason); in ipr_log_fabric_error()
2259 add_len = be32_to_cpu(hostrcb->hcam.length) - in ipr_log_fabric_error()
2264 ipr_log_fabric_path(hostrcb, fabric); in ipr_log_fabric_error()
2266 ipr_log_path_elem(hostrcb, cfg); in ipr_log_fabric_error()
2285 struct ipr_hostrcb *hostrcb) in ipr_log_sis64_array_error() argument
2293 error = &hostrcb->hcam.u.error64.u.type_24_error; in ipr_log_sis64_array_error()
2341 struct ipr_hostrcb *hostrcb) in ipr_log_sis64_fabric_error() argument
2348 error = &hostrcb->hcam.u.error64.u.type_30_error; in ipr_log_sis64_fabric_error()
2351 ipr_hcam_err(hostrcb, "%s\n", error->failure_reason); in ipr_log_sis64_fabric_error()
2353 add_len = be32_to_cpu(hostrcb->hcam.length) - in ipr_log_sis64_fabric_error()
2358 ipr_log64_fabric_path(hostrcb, fabric); in ipr_log_sis64_fabric_error()
2360 ipr_log64_path_elem(hostrcb, cfg); in ipr_log_sis64_fabric_error()
2379 struct ipr_hostrcb *hostrcb) in ipr_log_generic_error() argument
2381 ipr_log_hex_data(ioa_cfg, hostrcb->hcam.u.raw.data, in ipr_log_generic_error()
2382 be32_to_cpu(hostrcb->hcam.length)); in ipr_log_generic_error()
2394 struct ipr_hostrcb *hostrcb) in ipr_log_sis64_device_error() argument
2399 error = &hostrcb->hcam.u.error64.u.type_21_error; in ipr_log_sis64_device_error()
2454 struct ipr_hostrcb *hostrcb) in ipr_handle_log_data() argument
2460 if (hostrcb->hcam.notify_type != IPR_HOST_RCB_NOTIF_TYPE_ERROR_LOG_ENTRY) in ipr_handle_log_data()
2463 if (hostrcb->hcam.notifications_lost == IPR_HOST_RCB_NOTIFICATIONS_LOST) in ipr_handle_log_data()
2467 ioasc = be32_to_cpu(hostrcb->hcam.u.error64.fd_ioasc); in ipr_handle_log_data()
2469 ioasc = be32_to_cpu(hostrcb->hcam.u.error.fd_ioasc); in ipr_handle_log_data()
2475 hostrcb->hcam.u.error.fd_res_addr.bus); in ipr_handle_log_data()
2484 hostrcb->hcam.overlay_id == IPR_HOST_RCB_OVERLAY_ID_21) { in ipr_handle_log_data()
2485 error = &hostrcb->hcam.u.error64.u.type_21_error; in ipr_handle_log_data()
2492 ipr_hcam_err(hostrcb, "%s\n", ipr_error_table[error_index].error); in ipr_handle_log_data()
2499 if (be32_to_cpu(hostrcb->hcam.length) > sizeof(hostrcb->hcam.u.raw)) in ipr_handle_log_data()
2500 hostrcb->hcam.length = cpu_to_be32(sizeof(hostrcb->hcam.u.raw)); in ipr_handle_log_data()
2502 switch (hostrcb->hcam.overlay_id) { in ipr_handle_log_data()
2504 ipr_log_cache_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2507 ipr_log_config_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2511 ipr_log_array_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2514 ipr_log_dual_ioa_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2517 ipr_log_enhanced_cache_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2520 ipr_log_enhanced_config_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2524 ipr_log_enhanced_array_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2527 ipr_log_enhanced_dual_ioa_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2530 ipr_log_fabric_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2533 ipr_log_sis64_device_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2536 ipr_log_sis64_config_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2540 ipr_log_sis64_array_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2543 ipr_log_sis64_fabric_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2548 ipr_log_generic_error(ioa_cfg, hostrcb); in ipr_handle_log_data()
2567 struct ipr_hostrcb *hostrcb = ipr_cmd->u.hostrcb; in ipr_process_error() local
2572 fd_ioasc = be32_to_cpu(hostrcb->hcam.u.error64.fd_ioasc); in ipr_process_error()
2574 fd_ioasc = be32_to_cpu(hostrcb->hcam.u.error.fd_ioasc); in ipr_process_error()
2576 list_del(&hostrcb->queue); in ipr_process_error()
2580 ipr_handle_log_data(ioa_cfg, hostrcb); in ipr_process_error()
2589 ipr_send_hcam(ioa_cfg, IPR_HCAM_CDB_OP_CODE_LOG_DATA, hostrcb); in ipr_process_error()
7013 struct ipr_hostrcb *hostrcb, *temp; in ipr_ioa_reset_done() local
7035 list_for_each_entry_safe(hostrcb, temp, &ioa_cfg->hostrcb_free_q, queue) { in ipr_ioa_reset_done()
7036 list_del(&hostrcb->queue); in ipr_ioa_reset_done()
7038 ipr_send_hcam(ioa_cfg, IPR_HCAM_CDB_OP_CODE_LOG_DATA, hostrcb); in ipr_ioa_reset_done()
7040 ipr_send_hcam(ioa_cfg, IPR_HCAM_CDB_OP_CODE_CONFIG_CHANGE, hostrcb); in ipr_ioa_reset_done()
8199 struct ipr_hostrcb *hostrcb; in ipr_get_unit_check_buffer() local
8230 hostrcb = list_entry(ioa_cfg->hostrcb_free_q.next, in ipr_get_unit_check_buffer()
8232 list_del(&hostrcb->queue); in ipr_get_unit_check_buffer()
8233 memset(&hostrcb->hcam, 0, sizeof(hostrcb->hcam)); in ipr_get_unit_check_buffer()
8237 (__be32 *)&hostrcb->hcam, in ipr_get_unit_check_buffer()
8238 min(length, (int)sizeof(hostrcb->hcam)) / sizeof(__be32)); in ipr_get_unit_check_buffer()
8241 ipr_handle_log_data(ioa_cfg, hostrcb); in ipr_get_unit_check_buffer()
8242 ioasc = be32_to_cpu(hostrcb->hcam.u.error.fd_ioasc); in ipr_get_unit_check_buffer()
8249 list_add_tail(&hostrcb->queue, &ioa_cfg->hostrcb_free_q); in ipr_get_unit_check_buffer()
9205 ioa_cfg->hostrcb[i], in ipr_free_mem()
9443 ioa_cfg->hostrcb[i] = dma_alloc_coherent(&pdev->dev, in ipr_alloc_mem()
9448 if (!ioa_cfg->hostrcb[i]) in ipr_alloc_mem()
9451 ioa_cfg->hostrcb[i]->hostrcb_dma = in ipr_alloc_mem()
9453 ioa_cfg->hostrcb[i]->ioa_cfg = ioa_cfg; in ipr_alloc_mem()
9454 list_add_tail(&ioa_cfg->hostrcb[i]->queue, &ioa_cfg->hostrcb_free_q); in ipr_alloc_mem()
9471 ioa_cfg->hostrcb[i], in ipr_alloc_mem()