/freebsd-current/sys/dev/ocs_fc/ |
H A D | ocs_pci.c | 39 #include "ocs.h" 68 static int32_t ocs_init_dma_tag(struct ocs_softc *ocs); 70 static int32_t ocs_setup_fcports(ocs_t *ocs); 116 ocs_map_g7_bars(device_t dev, struct ocs_softc *ocs) argument 130 ocs->reg[r].rid = PCIR_BAR(i); 131 ocs->reg[r].res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, 132 &ocs->reg[r].rid, RF_ACTIVE); 133 if (ocs->reg[r].res) { 134 ocs->reg[r].btag = rman_get_bustag(ocs 158 ocs_map_bars(device_t dev, struct ocs_softc *ocs) argument 180 ocs_setup_params(struct ocs_softc *ocs) argument 360 ocs_setup_fcports(ocs_t *ocs) argument 406 ocs_device_attach(ocs_t *ocs) argument 503 struct ocs_softc *ocs; local 618 ocs_device_detach(ocs_t *ocs) argument 671 struct ocs_softc *ocs; local 733 ocs_release_bus(struct ocs_softc *ocs) argument 773 ocs_intr_alloc(struct ocs_softc *ocs) argument 814 ocs_intr_setup(struct ocs_softc *ocs) argument 840 ocs_intr_teardown(struct ocs_softc *ocs) argument 867 struct ocs_softc *ocs = NULL; local 903 struct ocs_softc *ocs = intr->softc; local 918 ocs_init_dma_tag(struct ocs_softc *ocs) argument 987 ocs_t *ocs = os; local [all...] |
H A D | ocs_xport.c | 38 #include "ocs.h" 59 * @param ocs Pointer to device instance. 64 ocs_xport_alloc(ocs_t *ocs) argument 68 ocs_assert(ocs, NULL); 69 xport = ocs_malloc(ocs, sizeof(*xport), OCS_M_ZERO); 71 xport->ocs = ocs; 89 ocs_t *ocs = xport->ocs; local 102 ocs_log_debug(ocs, "wai 130 ocs_t *ocs = xport->ocs; local 187 ocs_t *ocs = xport->ocs; local 305 ocs_t *ocs = xport->ocs; local 384 ocs_topology_setup(ocs_t *ocs) argument 413 ocs_t *ocs = xport->ocs; local 633 ocs_t *ocs = xport->ocs; local 666 ocs_xport_domain_list_empty_cb(ocs_t *ocs, void *arg) argument 720 ocs_t *ocs = xport->ocs; local 754 ocs_t *ocs = NULL; local 837 ocs_t *ocs; local 948 ocs_t *ocs = NULL; local 1115 ocs_t *ocs; local [all...] |
H A D | ocs_gendump.h | 35 extern int ocs_gen_dump(ocs_t *ocs); 36 extern int ocs_fdb_dump(ocs_t *ocs); 37 extern int ocs_dump_to_host(ocs_t *ocs, void *buf, uint32_t buflen); 38 extern int ocs_function_speciic_dump(ocs_t *ocs, void *buf, uint32_t buflen);
|
H A D | ocs_gendump.c | 33 #include "ocs.h" 41 ocs_t *ocs; local 44 while ((ocs = ocs_get_instance(index++)) != NULL) { 48 ocs_get_bus_dev_func(ocs, &ocs_bus, &ocs_dev, &ocs_func); 53 if (ocs_hw_reset(&ocs->hw, OCS_HW_RESET_FUNCTION)) { 54 ocs_log_test(ocs, "failed to reset port\n"); 59 ocs_log_debug(ocs, "successfully reset port\n"); 60 while ((domain = ocs_list_get_head(&ocs->domain_list)) != NULL) { 61 ocs_log_debug(ocs, "free domain %p\n", domain); 65 if (ocs_hw_init(&ocs 76 ocs_gen_dump(ocs_t *ocs) argument 195 ocs_fdb_dump(ocs_t *ocs) argument 248 ocs_dump_to_host(ocs_t *ocs, void *buf, uint32_t buflen) argument 319 ocs_function_speciic_dump(ocs_t *ocs, void *buf, uint32_t buflen) argument [all...] |
H A D | ocs_drv_fc.h | 94 void (*domain_list_empty_cb)(ocs_t *ocs, void *arg); /*>> domain list empty callback */ 150 #define ocs_is_fc_initiator_enabled() (ocs->enable_ini) 151 #define ocs_is_fc_target_enabled() (ocs->enable_tgt) 154 ocs_device_lock_init(ocs_t *ocs) argument 156 ocs_rlock_init(ocs, &ocs->lock, "ocsdevicelock"); 159 ocs_device_lock_free(ocs_t *ocs) argument 161 ocs_rlock_free(&ocs->lock); 164 ocs_device_lock_try(ocs_t *ocs) argument 166 return ocs_rlock_try(&ocs 169 ocs_device_lock(ocs_t *ocs) argument 174 ocs_device_unlock(ocs_t *ocs) argument 183 ocs_io_alloc(ocs_t *ocs) argument 189 ocs_io_free(ocs_t *ocs, ocs_io_t *io) argument [all...] |
H A D | ocs_ioctl.c | 32 #include "ocs.h" 56 ocs_firmware_write(ocs_t *ocs, const uint8_t *buf, size_t buf_len, uint8_t *change_status); 73 struct ocs_softc *ocs = arg; local 76 mtx_lock(&ocs->dbg_lock); 78 mtx_unlock(&ocs->dbg_lock); 86 ocs_process_sli_config (ocs_t *ocs, ocs_ioctl_elxu_mbox_t *mcmd, ocs_dma_t *dma) argument 100 if (ocs_dma_alloc(ocs, dma, mcmd->out_bytes, 4096)) { 101 device_printf(ocs->dev, "%s: COMMON_READ_OBJECT - %lld allocation failed\n", 119 if (ocs_dma_alloc(ocs, dma, wrobj->desired_write_length, 4096)) { 120 device_printf(ocs 197 ocs_process_mbx_ioctl(ocs_t *ocs, ocs_ioctl_elxu_mbox_t *mcmd) argument 279 ocs_process_ecd_helper(ocs_t *ocs, ocs_ioctl_ecd_helper_t *req) argument 359 struct ocs_softc *ocs = cdev->si_drv1; local 672 ocs_firmware_write(ocs_t *ocs, const uint8_t *buf, size_t buf_len, uint8_t *change_status) argument 737 ocs_t *ocs = (ocs_t *)arg1; local 817 ocs_t *ocs = oidp->oid_arg1; local 856 ocs_t *ocs = oidp->oid_arg1; local 892 ocs_t *ocs = oidp->oid_arg1; local 903 ocs_t *ocs = oidp->oid_arg1; local 915 ocs_t *ocs = oidp->oid_arg1; local 945 ocs_t *ocs = oidp->oid_arg1; local 974 ocs_t *ocs = oidp->oid_arg1; local 993 ocs_t *ocs = (ocs_t *)arg1; local 1070 ocs_sysctl_init(ocs_t *ocs) argument 1201 struct ocs_softc *ocs = os; local 1232 struct ocs_softc *ocs = os; local [all...] |
H A D | ocs.h | 76 ocs_t *ocs; member in struct:ocs_fcport_s 92 #define FCPORT(ocs, chan) (&((ocs_fcport *)(ocs)->fcports)[(chan)]) 135 void (*domain_list_empty_cb)(ocs_t *ocs, void *arg); 220 ocs_device_lock_init(ocs_t *ocs) argument 222 ocs_rlock_init(ocs, &ocs->lock, "ocsdevicelock"); 226 ocs_device_lock_try(ocs_t *ocs) argument 228 return ocs_rlock_try(&ocs->lock); 232 ocs_device_lock(ocs_t *ocs) argument 238 ocs_device_unlock(ocs_t *ocs) argument 244 ocs_device_lock_free(ocs_t *ocs) argument 265 ocs_io_alloc(ocs_t *ocs) argument 271 ocs_io_free(ocs_t *ocs, ocs_io_t *io) argument [all...] |
H A D | ocs_mgmt.c | 41 #include "ocs.h" 50 static int ocs_mgmt_firmware_write(ocs_t *ocs, char *, void *buf, uint32_t buf_len, void*, uint32_t); 51 static int ocs_mgmt_firmware_reset(ocs_t *ocs, char *, void *buf, uint32_t buf_len, void*, uint32_t); 52 static int ocs_mgmt_function_reset(ocs_t *ocs, char *, void *buf, uint32_t buf_len, void*, uint32_t); 55 static int ocs_mgmt_force_assert(ocs_t *ocs, char *, void *buf, uint32_t buf_len, void*, uint32_t); 101 static void get_chip_type(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf); 102 static void get_tgt_rscn_delay(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf); 103 static void get_tgt_rscn_period(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf); 104 static void get_inject_drop_cmd(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf); 105 static void get_inject_free_drop_cmd(ocs_t *ocs, cha 221 ocs_mgmt_get_list(ocs_t *ocs, ocs_textbuf_t *textbuf) argument 293 ocs_mgmt_get(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 376 ocs_mgmt_set(ocs_t *ocs, char *name, char *value) argument 457 ocs_mgmt_exec(ocs_t *ocs, char *action, void *arg_in, uint32_t arg_in_length, void *arg_out, uint32_t arg_out_length) argument 523 ocs_mgmt_get_all(ocs_t *ocs, ocs_textbuf_t *textbuf) argument 560 ocs_mgmt_firmware_reset(ocs_t *ocs, char *name, void *buf, uint32_t buf_len, void *arg_out, uint32_t arg_out_length) argument 603 ocs_mgmt_function_reset(ocs_t *ocs, char *name, void *buf, uint32_t buf_len, void *arg_out, uint32_t arg_out_length) argument 614 ocs_mgmt_firmware_write(ocs_t *ocs, char *name, void *buf, uint32_t buf_len, void *arg_out, uint32_t arg_out_length) argument 731 ocs_t *ocs = os; local 751 ocs_mgmt_get_sfp(ocs_t *ocs, uint16_t page, void *buf, uint32_t buf_len) argument 794 ocs_mgmt_force_assert(ocs_t *ocs, char *name, void *buf, uint32_t buf_len, void *arg_out, uint32_t arg_out_length) argument 800 get_nodes_count(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 808 get_driver_version(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 814 get_desc(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 820 get_fw_rev(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 826 get_fw_rev2(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 832 get_ipl(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 838 get_hw_rev1(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 848 get_hw_rev2(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 858 get_hw_rev3(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 867 get_wwnn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 877 get_wwpn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 887 get_fcid(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 900 get_sn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 916 get_pn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 934 get_sli4_intf_reg(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 942 get_phy_port_num(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 954 get_asic_id(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 962 get_chip_type(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1058 get_pci_vendor(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1065 get_pci_device(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1072 get_pci_subsystem_vendor(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1079 get_pci_subsystem_device(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1086 get_tgt_rscn_delay(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1092 get_tgt_rscn_period(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1098 get_inject_drop_cmd(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1105 get_inject_free_drop_cmd(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1112 get_inject_drop_data(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1119 get_inject_drop_resp(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1126 get_cmd_err_inject(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1132 get_cmd_delay_value(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1138 get_businfo(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1144 get_sfp_a0(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1187 get_sfp_a2(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1230 get_debug_mq_dump(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1238 get_debug_cq_dump(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1246 get_debug_wq_dump(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1253 get_debug_eq_dump(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1260 get_logmask(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1268 get_loglevel(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1276 get_current_speed(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1286 get_configured_speed(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1300 get_current_topology(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1310 get_configured_topology(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1320 get_current_link_state(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1334 get_configured_link_state(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1427 get_linkcfg(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1448 get_req_wwnn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1465 get_req_wwpn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1482 get_nodedb_mask(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1498 set_req_wwnn(ocs_t *ocs, char *name, char *value) argument 1542 set_req_wwpn(ocs_t *ocs, char *name, char *value) argument 1585 set_nodedb_mask(ocs_t *ocs, char *name, char *value) argument 1601 set_linkcfg(ocs_t *ocs, char *name, char *value) argument 1653 set_debug_mq_dump(ocs_t *ocs, char *name, char *value) argument 1671 set_debug_cq_dump(ocs_t *ocs, char *name, char *value) argument 1689 set_debug_wq_dump(ocs_t *ocs, char *name, char *value) argument 1707 set_debug_eq_dump(ocs_t *ocs, char *name, char *value) argument 1725 set_logmask(ocs_t *ocs, char *name, char *value) argument 1734 set_loglevel(ocs_t *ocs, char *name, char *value) argument 1743 set_configured_speed(ocs_t *ocs, char *name, char *value) argument 1785 set_configured_topology(ocs_t *ocs, char *name, char *value) argument 1829 set_configured_link_state(ocs_t *ocs, char *name, char *value) argument 1876 get_port_protocol(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 1944 set_port_protocol(ocs_t *ocs, char *name, char *value) argument 2020 get_profile_list(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 2096 get_active_profile(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 2148 set_active_profile(ocs_t *ocs, char *name, char *value) argument 2213 get_nv_wwpn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 2251 get_nv_wwnn(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 2288 get_node_abort_cnt(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf) argument 2360 set_nv_wwn(ocs_t *ocs, char *name, char *wwn_p) argument 2461 set_tgt_rscn_delay(ocs_t *ocs, char *name, char *value) argument 2469 set_tgt_rscn_period(ocs_t *ocs, char *name, char *value) argument 2477 set_inject_drop_cmd(ocs_t *ocs, char *name, char *value) argument 2485 set_inject_free_drop_cmd(ocs_t *ocs, char *name, char *value) argument 2493 set_inject_drop_data(ocs_t *ocs, char *name, char *value) argument 2501 set_inject_drop_resp(ocs_t *ocs, char *name, char *value) argument 2509 set_cmd_err_inject(ocs_t *ocs, char *name, char *value) argument 2517 set_cmd_delay_value(ocs_t *ocs, char *name, char *value) argument [all...] |
H A D | ocs_domain.c | 41 #include "ocs.h" 48 if (OCS_LOG_ENABLE_DOMAIN_SM_TRACE(domain->ocs)) \ 49 ocs_log_info(domain->ocs, "[domain] %-20s %-20s\n", __func__, ocs_sm_event_name(evt)); \ 54 if (OCS_LOG_ENABLE_DOMAIN_SM_TRACE(domain ? domain->ocs : NULL)) \ 55 ocs_log_info(domain ? domain->ocs : NULL, fmt, ##__VA_ARGS__); \ 60 ocs_log_info(domain ? domain->ocs : NULL, fmt, ##__VA_ARGS__); \ 94 ocs_t *ocs = arg; local 114 domain = ocs_domain_find(ocs, fcf_wwn); 116 domain = ocs_domain_alloc(ocs, fcf_wwn); 118 ocs_log_err(ocs, "ocs_domain_allo 186 ocs_domain_find(ocs_t *ocs, uint64_t fcf_wwn) argument 215 ocs_domain_alloc(ocs_t *ocs, uint64_t fcf_wwn) argument 272 ocs_t *ocs; local 353 ocs_register_domain_list_empty_cb(ocs_t *ocs, void (*callback)(ocs_t *ocs, void *arg), void *arg) argument 377 ocs_domain_get_instance(ocs_t *ocs, uint32_t index) argument [all...] |
H A D | ocs_io.c | 41 #include "ocs.h" 64 ocs_t *ocs; /* Pointer to device object */ member in struct:ocs_io_pool_s 92 * @param ocs Driver instance's software context. 101 ocs_io_pool_create(ocs_t *ocs, uint32_t num_io, uint32_t num_sgl) argument 108 io_pool = ocs_malloc(ocs, sizeof(*io_pool), OCS_M_ZERO | OCS_M_NOWAIT); 110 ocs_log_err(ocs, "allocate of IO pool failed\n"); 114 io_pool->ocs = ocs; 118 ocs_lock_init(ocs, &io_pool->lock, "io_pool lock[%d]", ocs 192 ocs_t *ocs; local 241 ocs_t *ocs; local 284 ocs_t *ocs; local 315 ocs_io_find_tgt_io(ocs_t *ocs, ocs_node_t *node, uint16_t ox_id, uint16_t rx_id) argument 342 ocs_io_get_instance(ocs_t *ocs, uint32_t index) argument [all...] |
H A D | ocs_unsol.c | 41 #include "ocs.h" 46 #define frame_printf(ocs, hdr, fmt, ...) \ 50 ocs_log_debug(ocs, "[%06x.%s] %02x/%04x/%04x: " fmt, fc_be24toh((hdr)->d_id), s_id_text, \ 54 static int32_t ocs_unsol_process(ocs_t *ocs, ocs_hw_sequence_t *seq); 64 static int32_t ocs_purge_pending(ocs_t *ocs, ocs_list_t *pend_list, ocs_lock_t *list_lock); 80 ocs_t *ocs = thread_data->ocs; local 84 ocs_log_debug(ocs, "%s running\n", mythread->name); 102 ocs_log_debug(ocs, "%s exiting\n", mythread->name); 117 ocs_t *ocs local 131 ocs_port_owned_abort(ocs_t *ocs, ocs_hw_io_t *hio) argument 161 ocs_t *ocs = arg; local 198 ocs_unsol_process(ocs_t *ocs, ocs_hw_sequence_t *seq) argument 275 ocs_t *ocs = node->ocs; local 333 ocs_t *ocs = domain->ocs; local 392 ocs_purge_pending(ocs_t *ocs, ocs_list_t *pend_list, ocs_lock_t *list_lock) argument 447 ocs_t *ocs = domain->ocs; local 490 ocs_t *ocs = domain->ocs; local 515 ocs_t *ocs = domain->ocs; local 543 ocs_t *ocs = domain->ocs; local 575 ocs_t *ocs = domain->ocs; local 788 ocs_validate_fcp_cmd(ocs_t *ocs, ocs_hw_sequence_t *seq) argument 882 ocs_t *ocs = node->ocs; local 980 ocs_t *ocs = node->ocs; local 1071 ocs_t *ocs = node->ocs; local 1230 ocs_t *ocs = node->ocs; local [all...] |
H A D | ocs_utils.h | 92 ocs_t *ocs; member in struct:__anon4042 100 extern int32_t ocs_textbuf_alloc(ocs_t *ocs, ocs_textbuf_t *textbuf, uint32_t length); 102 extern int32_t ocs_textbuf_init(ocs_t *ocs, ocs_textbuf_t *textbuf, void *buffer, uint32_t length); 103 extern void ocs_textbuf_free(ocs_t *ocs, ocs_textbuf_t *textbuf); 141 #define OCS_LOG_ENABLE_SM_TRACE(ocs) (((ocs) != NULL) ? (((ocs)->logmask & (1U << 0)) != 0) : 0) 142 #define OCS_LOG_ENABLE_ELS_TRACE(ocs) (((ocs) != NULL) ? (((ocs) 214 ocs_t *ocs; member in struct:__anon4045 [all...] |
H A D | ocs_domain.h | 39 extern int32_t ocs_domain_init(ocs_t *ocs, ocs_domain_t *domain); 40 extern ocs_domain_t *ocs_domain_find(ocs_t *ocs, uint64_t fcf_wwn); 41 extern ocs_domain_t *ocs_domain_alloc(ocs_t *ocs, uint64_t fcf_wwn); 44 extern void ocs_register_domain_list_empty_cb(ocs_t *ocs, void (*callback)(ocs_t *ocs, void *arg), void *arg); 56 return ocs_device_lock_try(domain->ocs); 63 ocs_device_lock(domain->ocs); 70 ocs_device_unlock(domain->ocs);
|
H A D | ocs_cam.c | 44 #include "ocs.h" 86 static uint32_t ocs_abort_initiator_io(struct ocs_softc *ocs, union ccb *accb); 87 static void ocs_abort_inot(struct ocs_softc *ocs, union ccb *ccb); 88 static void ocs_abort_atio(struct ocs_softc *ocs, union ccb *ccb); 95 ocs_fcp_change_role(struct ocs_softc *ocs, ocs_fcport *fcp, uint32_t new_role); 99 static void ocs_delete_target(ocs_t *ocs, ocs_fcport *fcp, int tgt); 105 static inline ocs_io_t *ocs_scsi_find_io(struct ocs_softc *ocs, uint32_t tag) argument 108 return ocs_io_get_instance(ocs, tag); 117 if(io->ocs->io_in_use != 0) 118 atomic_subtract_acq_32(&io->ocs 122 ocs_attach_port(ocs_t *ocs, int chan) argument 167 ocs_detach_port(ocs_t *ocs, int32_t chan) argument 199 ocs_cam_attach(ocs_t *ocs) argument 241 ocs_cam_detach(ocs_t *ocs) argument 272 ocs_scsi_tgt_new_device(ocs_t *ocs) argument 293 ocs_scsi_tgt_del_device(ocs_t *ocs) argument 371 ocs_t *ocs = sport->ocs; local 423 ocs_t *ocs = node->ocs; local 495 ocs_t *ocs = node->ocs; local 551 ocs_t *ocs = io->ocs; local 684 ocs_t *ocs = tmfio->ocs; local 812 ocs_scsi_ini_new_device(ocs_t *ocs) argument 830 ocs_scsi_ini_del_device(ocs_t *ocs) argument 907 ocs_t *ocs = sport->ocs; local 935 ocs_t *ocs = sport->ocs; local 946 ocs_t *ocs = sport->ocs; local 1035 struct ocs_softc *ocs = node->ocs; local 1085 ocs_delete_target(ocs_t *ocs, ocs_fcport *fcp, int tgt) argument 1124 ocs_t *ocs = fcp->ocs; local 1180 struct ocs_softc *ocs = node->ocs; local 1317 ocs_t *ocs = io->ocs; local 1373 struct ocs_softc *ocs = csio->ccb_h.ccb_ocs_ptr; local 1443 struct ocs_softc *ocs = NULL; local 1490 struct ocs_softc *ocs = csio->ccb_h.ccb_ocs_ptr; local 1676 ocs_build_scsi_sgl(struct ocs_softc *ocs, union ccb *ccb, ocs_io_t *io, ocs_scsi_sgl_t *sgl, uint32_t sgl_max) argument 1719 ocs_target_io(struct ocs_softc *ocs, union ccb *ccb) argument 1856 ocs_initiator_io(struct ocs_softc *ocs, union ccb *ccb) argument 1982 ocs_fcp_change_role(struct ocs_softc *ocs, ocs_fcport *fcp, uint32_t new_role) argument 2053 struct ocs_softc *ocs = (struct ocs_softc *)cam_sim_softc(sim); local 2630 ocs_tgt_resource_abort(struct ocs_softc *ocs, ocs_tgt_resource_t *trsrc) argument 2656 ocs_abort_atio(struct ocs_softc *ocs, union ccb *ccb) argument 2717 ocs_abort_inot(struct ocs_softc *ocs, union ccb *ccb) argument 2747 ocs_abort_initiator_io(struct ocs_softc *ocs, union ccb *accb) argument [all...] |
H A D | ocs_sport.c | 37 #include "ocs.h" 81 ocs_t *ocs = arg; local 86 ocs_log_debug(ocs, "OCS_HW_PORT_ALLOC_OK\n"); 90 ocs_log_debug(ocs, "OCS_HW_PORT_ALLOC_FAIL\n"); 94 ocs_log_debug(ocs, "OCS_HW_PORT_ATTACH_OK\n"); 98 ocs_log_debug(ocs, "OCS_HW_PORT_ATTACH_FAIL\n"); 102 ocs_log_debug(ocs, "OCS_HW_PORT_FREE_OK\n"); 106 ocs_log_debug(ocs, "OCS_HW_PORT_FREE_FAIL\n"); 110 ocs_log_test(ocs, "unknown event %#x\n", event); 139 if (domain->ocs 920 ocs_t *ocs = domain->ocs; local 968 ocs_t *ocs = sport->ocs; local 1092 ocs_sport_vport_del(ocs_t *ocs, ocs_domain_t *domain, uint64_t wwpn, uint64_t wwnn) argument 1152 ocs_vport_del_all(ocs_t *ocs) argument 1476 ocs_t *ocs = sport->ocs; local 1513 ocs_vport_create_spec(ocs_t *ocs, uint64_t wwnn, uint64_t wwpn, uint32_t fc_id, uint32_t enable_ini, uint32_t enable_tgt, void *tgt_data, void *ini_data) argument 1739 ocs_t *ocs; local 1838 ocs_t *ocs; local [all...] |
H A D | ocs_scsi.c | 41 #include "ocs.h" 49 #define SCSI_ITT_SIZE(ocs) ((ocs->ocs_xport == OCS_XPORT_FC) ? 4 : 8) 51 #define SCSI_IOFMT_ARGS(io) io->instance_index, SCSI_ITT_SIZE(io->ocs), io->init_task_tag, SCSI_ITT_SIZE(io->ocs), io->tgt_task_tag, io->hw_tag 53 #define enable_tsend_auto_resp(ocs) ((ocs->ctrlmask & OCS_CTRLMASK_XPORT_DISABLE_AUTORSP_TSEND) == 0) 54 #define enable_treceive_auto_resp(ocs) ((ocs->ctrlmask & OCS_CTRLMASK_XPORT_DISABLE_AUTORSP_TRECEIVE) == 0) 56 #define scsi_io_printf(io, fmt, ...) ocs_log_info(io->ocs, "[ 170 ocs_t *ocs; local 249 ocs_t *ocs = io->ocs; local 320 ocs_t *ocs; local 503 ocs_t *ocs = io->ocs; local 602 ocs_scsi_dif_check_app_tag(ocs_t *ocs, ocs_hw_dif_info_t *dif_info, uint16_t exp_app_tag, ocs_dif_t *dif) argument 628 ocs_scsi_dif_check_ref_tag(ocs_t *ocs, ocs_hw_dif_info_t *dif_info, uint32_t exp_ref_tag, ocs_dif_t *dif) argument 687 ocs_t *ocs = hw->os; local 795 ocs_scsi_convert_dif_info(ocs_t *ocs, ocs_scsi_dif_info_t *scsi_dif_info, ocs_hw_dif_info_t *hw_dif_info) argument 989 ocs_scsi_check_pending(ocs_t *ocs) argument 1121 ocs_t *ocs = io->ocs; local 1200 ocs_t *ocs = io->ocs; local 1246 ocs_t *ocs = io->ocs; local 1462 ocs_t *ocs; local 1631 ocs_t *ocs; local 1751 ocs_t *ocs = NULL; local 1849 ocs_t *ocs; local 1921 ocs_t *ocs; local 1995 ocs_t *ocs; local 2123 ocs_t *ocs; local 2488 ocs_t *ocs; local 2669 ocs_t *ocs; local 2730 ocs_scsi_get_property(ocs_t *ocs, ocs_scsi_property_e prop) argument 2794 ocs_scsi_get_property_ptr(ocs_t *ocs, ocs_scsi_property_e prop) argument 2942 ocs_scsi_register_bounce(ocs_t *ocs, void(*fctn)(void(*fctn)(void *arg), void *arg, uint32_t s_id, uint32_t d_id, uint32_t ox_id)) argument [all...] |
H A D | ocs_ddump.c | 38 #include "ocs.h" 403 ocs_t *ocs = hw->os; local 410 ocs_assert(ocs); 412 ocs_ddump_section(textbuf, "hw", ocs->instance_index); 481 ocs_ddump_section(textbuf, "workaround", ocs->instance_index); 483 ocs_ddump_endsection(textbuf, "workaround", ocs->instance_index); 486 ocs_ddump_section(textbuf, "io_inuse", ocs->instance_index); 490 ocs_ddump_endsection(textbuf, "io_inuse", ocs->instance_index); 492 ocs_ddump_section(textbuf, "io_wait_free", ocs->instance_index); 496 ocs_ddump_endsection(textbuf, "io_wait_free", ocs 635 ocs_ddump(ocs_t *ocs, ocs_textbuf_t *textbuf, uint32_t flags, uint32_t qentries) argument 798 ocs_save_ddump(ocs_t *ocs, uint32_t flags, uint32_t qentries) argument 832 ocs_t *ocs; local 863 ocs_clear_saved_ddump(ocs_t *ocs) argument [all...] |
H A D | ocs_node.c | 43 #include "ocs.h" 48 #define SCSI_ITT_SIZE(ocs) ((ocs->ocs_xport == OCS_XPORT_FC) ? 4 : 8) 50 #define SCSI_IOFMT_ARGS(io) io->instance_index, SCSI_ITT_SIZE(io->ocs), io->init_task_tag, SCSI_ITT_SIZE(io->ocs), io->tgt_task_tag, io->hw_tag 52 #define scsi_io_printf(io, fmt, ...) ocs_log_debug(io->ocs, "[%s]" SCSI_IOFMT fmt, \ 89 ocs_log_debug(node->ocs, "[%s] initiate ELS abort %s\n", node->display_name, els->display_name); 105 * @param arg pointer to ocs 114 ocs_t *ocs = arg; local 137 ocs_log_test(ocs, "unhandle 233 ocs_node_create_pool(ocs_t *ocs, uint32_t node_count) argument 304 ocs_node_free_pool(ocs_t *ocs) argument 343 ocs_node_get_instance(ocs_t *ocs, uint32_t index) argument 375 ocs_t *ocs = sport->ocs; local 466 ocs_t *ocs; local 627 ocs_t *ocs = node->ocs; local 732 ocs_t *ocs = node->ocs; local 922 ocs_t *ocs; local 1224 ocs_t *ocs = NULL; local 1612 ocs_t *ocs = NULL; local 1662 ocs_t *ocs = NULL; local 2099 ocs_t *ocs = node->ocs; local 2169 ocs_t *ocs = node->ocs; local 2247 ocs_t *ocs = node->ocs; local 2323 ocs_t *ocs = node->ocs; local [all...] |
H A D | ocs_ddump.h | 43 extern int ocs_ddump(ocs_t *ocs, ocs_textbuf_t *textbuf, uint32_t flags, uint32_t qentries); 52 extern int32_t ocs_save_ddump(ocs_t *ocs, uint32_t flags, uint32_t qentries); 53 extern int32_t ocs_get_saved_ddump(ocs_t *ocs, ocs_textbuf_t *textbuf); 55 extern int32_t ocs_clear_saved_ddump(ocs_t *ocs);
|
H A D | ocs_mgmt.h | 104 extern void ocs_mgmt_get_list(ocs_t *ocs, ocs_textbuf_t *textbuf); 105 extern void ocs_mgmt_get_all(ocs_t *ocs, ocs_textbuf_t *textbuf); 106 extern int ocs_mgmt_get(ocs_t *ocs, char *name, ocs_textbuf_t *textbuf); 107 extern int ocs_mgmt_set(ocs_t *ocs, char *name, char *value); 108 extern int ocs_mgmt_exec(ocs_t *ocs, char *action, void *arg_in, uint32_t arg_in_length,
|
H A D | ocs_els.c | 41 #include "ocs.h" 51 if (OCS_LOG_ENABLE_ELS_TRACE(ocs)) \ 52 ocs_log_info(ocs, "[%s] %-20s\n", node->display_name, __func__); \ 56 ocs_log_debug(els->node->ocs, "[%s]" ELS_IOFMT " %-8s " fmt, els->node->display_name, ELS_IOFMT_ARGS(els), els->display_name, ##__VA_ARGS__); 165 ocs_t *ocs; local 169 ocs_assert(node->ocs, NULL); 170 ocs = node->ocs; 171 ocs_assert(ocs->xport, NULL); 172 xport = ocs 288 ocs_t *ocs; local 456 ocs_t *ocs; local 549 ocs_t *ocs; local 616 ocs_t *ocs = node->ocs; local 670 ocs_t *ocs; local 730 ocs_t *ocs; local 785 ocs_t *ocs = node->ocs; local 848 ocs_t *ocs = node->ocs; local 902 ocs_t *ocs; local 961 ocs_t *ocs; local 1024 ocs_t *ocs = node->ocs; local 1074 ocs_t *ocs = node->ocs; local 1123 ocs_t *ocs = node->ocs; local 1173 ocs_t *ocs = node->ocs; local 1232 ocs_t *ocs = node->ocs; local 1281 ocs_t *ocs = node->ocs; local 1343 ocs_t *ocs = node->ocs; local 1382 ocs_t *ocs = node->ocs; local 1447 ocs_t *ocs = node->ocs; local 1504 ocs_t *ocs = node->ocs; local 1556 ocs_t *ocs = node->ocs; local 1603 ocs_t *ocs = node->ocs; local 1654 ocs_t *ocs; local 1711 ocs_t *ocs = node->ocs; local 1763 ocs_t *ocs = node->ocs; local 1823 ocs_t *ocs = node->ocs; local 1901 ocs_t *ocs; local 1991 ocs_t *ocs; local 2041 ocs_t *ocs; local [all...] |
H A D | ocs_sport.h | 61 return ocs_device_lock_try(sport->ocs); 68 ocs_device_lock(sport->ocs); 75 ocs_device_unlock(sport->ocs); 93 extern int32_t ocs_sport_vport_del(ocs_t *ocs, ocs_domain_t *domain, uint64_t wwpn, uint64_t wwnn); 94 extern void ocs_vport_del_all(ocs_t *ocs); 95 extern int8_t ocs_vport_create_spec(ocs_t *ocs, uint64_t wwnn, uint64_t wwpn, uint32_t fc_id, uint32_t enable_ini, uint32_t enable_tgt, void *tgt_data, void *ini_data);
|
H A D | ocs_os.c | 37 #include "ocs.h" 92 * @param ocs Pointer to the driver's context 99 ocs_reg_read32(ocs_t *ocs, uint32_t rset, uint32_t off) argument 103 reg = &ocs->reg[rset]; 116 * @param ocs Pointer to the driver's context 123 ocs_reg_read16(ocs_t *ocs, uint32_t rset, uint32_t off) argument 127 reg = &ocs->reg[rset]; 140 * @param ocs Pointer to the driver's context 147 ocs_reg_read8(ocs_t *ocs, uint32_t rset, uint32_t off) argument 151 reg = &ocs 172 ocs_reg_write32(ocs_t *ocs, uint32_t rset, uint32_t off, uint32_t val) argument 197 ocs_reg_write16(ocs_t *ocs, uint32_t rset, uint32_t off, uint16_t val) argument 222 ocs_reg_write8(ocs_t *ocs, uint32_t rset, uint32_t off, uint8_t val) argument 319 struct ocs_softc *ocs = os; local 361 struct ocs_softc *ocs = os; local 566 _ocs_log(ocs_t *ocs, const char *func_name, int line, const char *fmt, ...) argument 884 ocs_get_bus_dev_func(ocs_t *ocs, uint8_t* bus, uint8_t* dev, uint8_t* func) argument [all...] |
H A D | ocs_node.h | 42 if (OCS_LOG_ENABLE_SM_TRACE(node->ocs)) \ 43 ocs_log_info(node->ocs, "[%s] %-20s\n", node->display_name, ocs_sm_event_name(evt)); \ 46 #define node_printf(node, fmt, ...) ocs_log_debug(node->ocs, "[%s] " fmt, node->display_name, ##__VA_ARGS__) 50 ocs_t *ocs = NULL; \ 53 ocs = node->ocs; \ 54 ocs_assert(ocs, NULL); \ 119 extern int32_t ocs_node_create_pool(ocs_t *ocs, uint32_t node_count); 120 extern void ocs_node_free_pool(ocs_t *ocs); 121 extern ocs_node_t *ocs_node_get_instance(ocs_t *ocs, uint32_ [all...] |
H A D | ocs_io.h | 42 if (OCS_LOG_ENABLE_IO_ERRORS(io->ocs)) \ 43 ocs_log_warn(io->ocs, fmt, ##__VA_ARGS__); \ 70 ocs_t *ocs; /**< pointer back to ocs */ member in struct:ocs_io_s 184 extern ocs_io_pool_t *ocs_io_pool_create(ocs_t *ocs, uint32_t num_io, uint32_t num_sgl); 190 extern ocs_io_t *ocs_io_find_tgt_io(ocs_t *ocs, ocs_node_t *node, uint16_t ox_id, uint16_t rx_id);
|