ihost 694 drivers/scsi/be2iscsi/be_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 696 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_state = test_bit(BEISCSI_HBA_LINK_UP, &phba->state) ? ihost 708 drivers/scsi/be2iscsi/be_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 712 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_10MBPS; ihost 715 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_100MBPS; ihost 718 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_1GBPS; ihost 721 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_10GBPS; ihost 724 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_25GBPS; ihost 727 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_40GBPS; ihost 730 drivers/scsi/be2iscsi/be_iscsi.c ihost->port_speed = ISCSI_PORT_SPEED_UNKNOWN; ihost 181 drivers/scsi/isci/host.c static bool sci_controller_completion_queue_has_entries(struct isci_host *ihost) ihost 183 drivers/scsi/isci/host.c u32 get_value = ihost->completion_queue_get; ihost 187 drivers/scsi/isci/host.c COMPLETION_QUEUE_CYCLE_BIT(ihost->completion_queue[get_index])) ihost 193 drivers/scsi/isci/host.c static bool sci_controller_isr(struct isci_host *ihost) ihost 195 drivers/scsi/isci/host.c if (sci_controller_completion_queue_has_entries(ihost)) ihost 202 drivers/scsi/isci/host.c writel(SMU_ISR_COMPLETION, &ihost->smu_registers->interrupt_status); ihost 210 drivers/scsi/isci/host.c spin_lock(&ihost->scic_lock); ihost 211 drivers/scsi/isci/host.c if (test_bit(IHOST_IRQ_ENABLED, &ihost->flags)) { ihost 212 drivers/scsi/isci/host.c writel(0xFF000000, &ihost->smu_registers->interrupt_mask); ihost 213 drivers/scsi/isci/host.c writel(0, &ihost->smu_registers->interrupt_mask); ihost 215 drivers/scsi/isci/host.c spin_unlock(&ihost->scic_lock); ihost 222 drivers/scsi/isci/host.c struct isci_host *ihost = data; ihost 224 drivers/scsi/isci/host.c if (sci_controller_isr(ihost)) ihost 225 drivers/scsi/isci/host.c tasklet_schedule(&ihost->completion_tasklet); ihost 230 drivers/scsi/isci/host.c static bool sci_controller_error_isr(struct isci_host *ihost) ihost 235 drivers/scsi/isci/host.c readl(&ihost->smu_registers->interrupt_status); ihost 251 drivers/scsi/isci/host.c writel(0xff, &ihost->smu_registers->interrupt_mask); ihost 252 drivers/scsi/isci/host.c writel(0, &ihost->smu_registers->interrupt_mask); ihost 257 drivers/scsi/isci/host.c static void sci_controller_task_completion(struct isci_host *ihost, u32 ent) ihost 260 drivers/scsi/isci/host.c struct isci_request *ireq = ihost->reqs[index]; ihost 265 drivers/scsi/isci/host.c ISCI_TAG_SEQ(ireq->io_tag) == ihost->io_request_sequence[index]) ihost 272 drivers/scsi/isci/host.c static void sci_controller_sdma_completion(struct isci_host *ihost, u32 ent) ihost 283 drivers/scsi/isci/host.c ireq = ihost->reqs[index]; ihost 284 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s: %x for io request %p\n", ihost 293 drivers/scsi/isci/host.c idev = ihost->device_table[index]; ihost 294 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s: %x for device %p\n", ihost 301 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s: unknown completion type %x\n", ihost 307 drivers/scsi/isci/host.c static void sci_controller_unsolicited_frame(struct isci_host *ihost, u32 ent) ihost 320 drivers/scsi/isci/host.c frame_header = ihost->uf_control.buffers.array[frame_index].header; ihost 321 drivers/scsi/isci/host.c ihost->uf_control.buffers.array[frame_index].state = UNSOLICITED_FRAME_IN_USE; ihost 328 drivers/scsi/isci/host.c sci_controller_release_frame(ihost, frame_index); ihost 334 drivers/scsi/isci/host.c iphy = &ihost->phys[index]; ihost 346 drivers/scsi/isci/host.c iphy = &ihost->phys[index]; ihost 349 drivers/scsi/isci/host.c if (index < ihost->remote_node_entries) ihost 350 drivers/scsi/isci/host.c idev = ihost->device_table[index]; ihost 357 drivers/scsi/isci/host.c sci_controller_release_frame(ihost, frame_index); ihost 368 drivers/scsi/isci/host.c static void sci_controller_event_completion(struct isci_host *ihost, u32 ent) ihost 380 drivers/scsi/isci/host.c dev_err(&ihost->pdev->dev, ihost 384 drivers/scsi/isci/host.c ihost, ihost 394 drivers/scsi/isci/host.c dev_err(&ihost->pdev->dev, ihost 398 drivers/scsi/isci/host.c ihost, ihost 403 drivers/scsi/isci/host.c ireq = ihost->reqs[index]; ihost 411 drivers/scsi/isci/host.c ireq = ihost->reqs[index]; ihost 415 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 420 drivers/scsi/isci/host.c ihost, ihost 426 drivers/scsi/isci/host.c idev = ihost->device_table[index]; ihost 430 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 435 drivers/scsi/isci/host.c ihost, ihost 452 drivers/scsi/isci/host.c iphy = &ihost->phys[index]; ihost 459 drivers/scsi/isci/host.c if (index < ihost->remote_node_entries) { ihost 460 drivers/scsi/isci/host.c idev = ihost->device_table[index]; ihost 465 drivers/scsi/isci/host.c dev_err(&ihost->pdev->dev, ihost 470 drivers/scsi/isci/host.c ihost, ihost 477 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 485 drivers/scsi/isci/host.c static void sci_controller_process_completions(struct isci_host *ihost) ihost 494 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 497 drivers/scsi/isci/host.c ihost->completion_queue_get); ihost 500 drivers/scsi/isci/host.c get_index = NORMALIZE_GET_POINTER(ihost->completion_queue_get); ihost 501 drivers/scsi/isci/host.c get_cycle = SMU_CQGR_CYCLE_BIT & ihost->completion_queue_get; ihost 503 drivers/scsi/isci/host.c event_get = NORMALIZE_EVENT_POINTER(ihost->completion_queue_get); ihost 504 drivers/scsi/isci/host.c event_cycle = SMU_CQGR_EVENT_CYCLE_BIT & ihost->completion_queue_get; ihost 508 drivers/scsi/isci/host.c == COMPLETION_QUEUE_CYCLE_BIT(ihost->completion_queue[get_index]) ihost 512 drivers/scsi/isci/host.c ent = ihost->completion_queue[get_index]; ihost 519 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 526 drivers/scsi/isci/host.c sci_controller_task_completion(ihost, ent); ihost 530 drivers/scsi/isci/host.c sci_controller_sdma_completion(ihost, ent); ihost 534 drivers/scsi/isci/host.c sci_controller_unsolicited_frame(ihost, ent); ihost 538 drivers/scsi/isci/host.c sci_controller_event_completion(ihost, ent); ihost 546 drivers/scsi/isci/host.c sci_controller_event_completion(ihost, ent); ihost 550 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 561 drivers/scsi/isci/host.c ihost->completion_queue_get = ihost 569 drivers/scsi/isci/host.c writel(ihost->completion_queue_get, ihost 570 drivers/scsi/isci/host.c &ihost->smu_registers->completion_queue_get); ihost 574 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 577 drivers/scsi/isci/host.c ihost->completion_queue_get); ihost 581 drivers/scsi/isci/host.c static void sci_controller_error_handler(struct isci_host *ihost) ihost 586 drivers/scsi/isci/host.c readl(&ihost->smu_registers->interrupt_status); ihost 589 drivers/scsi/isci/host.c sci_controller_completion_queue_has_entries(ihost)) { ihost 591 drivers/scsi/isci/host.c sci_controller_process_completions(ihost); ihost 592 drivers/scsi/isci/host.c writel(SMU_ISR_QUEUE_SUSPEND, &ihost->smu_registers->interrupt_status); ihost 594 drivers/scsi/isci/host.c dev_err(&ihost->pdev->dev, "%s: status: %#x\n", __func__, ihost 597 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_FAILED); ihost 605 drivers/scsi/isci/host.c writel(0, &ihost->smu_registers->interrupt_mask); ihost 611 drivers/scsi/isci/host.c struct isci_host *ihost = data; ihost 613 drivers/scsi/isci/host.c if (sci_controller_isr(ihost)) { ihost 614 drivers/scsi/isci/host.c writel(SMU_ISR_COMPLETION, &ihost->smu_registers->interrupt_status); ihost 615 drivers/scsi/isci/host.c tasklet_schedule(&ihost->completion_tasklet); ihost 617 drivers/scsi/isci/host.c } else if (sci_controller_error_isr(ihost)) { ihost 618 drivers/scsi/isci/host.c spin_lock(&ihost->scic_lock); ihost 619 drivers/scsi/isci/host.c sci_controller_error_handler(ihost); ihost 620 drivers/scsi/isci/host.c spin_unlock(&ihost->scic_lock); ihost 629 drivers/scsi/isci/host.c struct isci_host *ihost = data; ihost 631 drivers/scsi/isci/host.c if (sci_controller_error_isr(ihost)) ihost 632 drivers/scsi/isci/host.c sci_controller_error_handler(ihost); ihost 645 drivers/scsi/isci/host.c static void isci_host_start_complete(struct isci_host *ihost, enum sci_status completion_status) ihost 648 drivers/scsi/isci/host.c dev_info(&ihost->pdev->dev, ihost 650 drivers/scsi/isci/host.c clear_bit(IHOST_START_PENDING, &ihost->flags); ihost 651 drivers/scsi/isci/host.c wake_up(&ihost->eventq); ihost 657 drivers/scsi/isci/host.c struct isci_host *ihost = ha->lldd_ha; ihost 659 drivers/scsi/isci/host.c if (test_bit(IHOST_START_PENDING, &ihost->flags)) ihost 679 drivers/scsi/isci/host.c static u32 sci_controller_get_suggested_start_timeout(struct isci_host *ihost) ihost 682 drivers/scsi/isci/host.c if (!ihost) ihost 704 drivers/scsi/isci/host.c static void sci_controller_enable_interrupts(struct isci_host *ihost) ihost 706 drivers/scsi/isci/host.c set_bit(IHOST_IRQ_ENABLED, &ihost->flags); ihost 707 drivers/scsi/isci/host.c writel(0, &ihost->smu_registers->interrupt_mask); ihost 710 drivers/scsi/isci/host.c void sci_controller_disable_interrupts(struct isci_host *ihost) ihost 712 drivers/scsi/isci/host.c clear_bit(IHOST_IRQ_ENABLED, &ihost->flags); ihost 713 drivers/scsi/isci/host.c writel(0xffffffff, &ihost->smu_registers->interrupt_mask); ihost 714 drivers/scsi/isci/host.c readl(&ihost->smu_registers->interrupt_mask); /* flush */ ihost 717 drivers/scsi/isci/host.c static void sci_controller_enable_port_task_scheduler(struct isci_host *ihost) ihost 722 drivers/scsi/isci/host.c readl(&ihost->scu_registers->peg0.ptsg.control); ihost 727 drivers/scsi/isci/host.c &ihost->scu_registers->peg0.ptsg.control); ihost 730 drivers/scsi/isci/host.c static void sci_controller_assign_task_entries(struct isci_host *ihost) ihost 740 drivers/scsi/isci/host.c readl(&ihost->smu_registers->task_context_assignment[0]); ihost 743 drivers/scsi/isci/host.c (SMU_TCA_GEN_VAL(ENDING, ihost->task_context_entries - 1)) | ihost 747 drivers/scsi/isci/host.c &ihost->smu_registers->task_context_assignment[0]); ihost 751 drivers/scsi/isci/host.c static void sci_controller_initialize_completion_queue(struct isci_host *ihost) ihost 758 drivers/scsi/isci/host.c ihost->completion_queue_get = 0; ihost 765 drivers/scsi/isci/host.c &ihost->smu_registers->completion_queue_control); ihost 777 drivers/scsi/isci/host.c &ihost->smu_registers->completion_queue_get); ihost 786 drivers/scsi/isci/host.c &ihost->smu_registers->completion_queue_put); ihost 794 drivers/scsi/isci/host.c ihost->completion_queue[index] = 0x80000000; ihost 798 drivers/scsi/isci/host.c static void sci_controller_initialize_unsolicited_frame_queue(struct isci_host *ihost) ihost 809 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.unsolicited_frame_queue_control); ihost 818 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.unsolicited_frame_get_pointer); ihost 822 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.unsolicited_frame_put_pointer); ihost 825 drivers/scsi/isci/host.c void sci_controller_transition_to_ready(struct isci_host *ihost, enum sci_status status) ihost 827 drivers/scsi/isci/host.c if (ihost->sm.current_state_id == SCIC_STARTING) { ihost 832 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_READY); ihost 834 drivers/scsi/isci/host.c isci_host_start_complete(ihost, status); ihost 861 drivers/scsi/isci/host.c bool is_controller_start_complete(struct isci_host *ihost) ihost 866 drivers/scsi/isci/host.c struct isci_phy *iphy = &ihost->phys[i]; ihost 873 drivers/scsi/isci/host.c if (is_port_config_apc(ihost)) ihost 887 drivers/scsi/isci/host.c (ihost->port_agent.phy_ready_mask != ihost->port_agent.phy_configured_mask)) ihost 902 drivers/scsi/isci/host.c static enum sci_status sci_controller_start_next_phy(struct isci_host *ihost) ihost 904 drivers/scsi/isci/host.c struct sci_oem_params *oem = &ihost->oem_parameters; ihost 910 drivers/scsi/isci/host.c if (ihost->phy_startup_timer_pending) ihost 913 drivers/scsi/isci/host.c if (ihost->next_phy_to_start >= SCI_MAX_PHYS) { ihost 914 drivers/scsi/isci/host.c if (is_controller_start_complete(ihost)) { ihost 915 drivers/scsi/isci/host.c sci_controller_transition_to_ready(ihost, SCI_SUCCESS); ihost 916 drivers/scsi/isci/host.c sci_del_timer(&ihost->phy_timer); ihost 917 drivers/scsi/isci/host.c ihost->phy_startup_timer_pending = false; ihost 920 drivers/scsi/isci/host.c iphy = &ihost->phys[ihost->next_phy_to_start]; ihost 924 drivers/scsi/isci/host.c ihost->next_phy_to_start++; ihost 935 drivers/scsi/isci/host.c return sci_controller_start_next_phy(ihost); ihost 942 drivers/scsi/isci/host.c sci_mod_timer(&ihost->phy_timer, ihost 944 drivers/scsi/isci/host.c ihost->phy_startup_timer_pending = true; ihost 946 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 951 drivers/scsi/isci/host.c ihost->phys[ihost->next_phy_to_start].phy_index, ihost 955 drivers/scsi/isci/host.c ihost->next_phy_to_start++; ihost 964 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(tmr, typeof(*ihost), phy_timer); ihost 968 drivers/scsi/isci/host.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 973 drivers/scsi/isci/host.c ihost->phy_startup_timer_pending = false; ihost 976 drivers/scsi/isci/host.c status = sci_controller_start_next_phy(ihost); ihost 980 drivers/scsi/isci/host.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 983 drivers/scsi/isci/host.c static u16 isci_tci_active(struct isci_host *ihost) ihost 985 drivers/scsi/isci/host.c return CIRC_CNT(ihost->tci_head, ihost->tci_tail, SCI_MAX_IO_REQUESTS); ihost 988 drivers/scsi/isci/host.c static enum sci_status sci_controller_start(struct isci_host *ihost, ihost 994 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_INITIALIZED) { ihost 995 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 996 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 1001 drivers/scsi/isci/host.c BUILD_BUG_ON(SCI_MAX_IO_REQUESTS > 1 << sizeof(ihost->tci_pool[0]) * 8); ihost 1002 drivers/scsi/isci/host.c ihost->tci_head = 0; ihost 1003 drivers/scsi/isci/host.c ihost->tci_tail = 0; ihost 1004 drivers/scsi/isci/host.c for (index = 0; index < ihost->task_context_entries; index++) ihost 1005 drivers/scsi/isci/host.c isci_tci_free(ihost, index); ihost 1008 drivers/scsi/isci/host.c sci_remote_node_table_initialize(&ihost->available_remote_nodes, ihost 1009 drivers/scsi/isci/host.c ihost->remote_node_entries); ihost 1015 drivers/scsi/isci/host.c sci_controller_disable_interrupts(ihost); ihost 1018 drivers/scsi/isci/host.c sci_controller_enable_port_task_scheduler(ihost); ihost 1021 drivers/scsi/isci/host.c sci_controller_assign_task_entries(ihost); ihost 1024 drivers/scsi/isci/host.c sci_controller_initialize_completion_queue(ihost); ihost 1027 drivers/scsi/isci/host.c sci_controller_initialize_unsolicited_frame_queue(ihost); ihost 1030 drivers/scsi/isci/host.c for (index = 0; index < ihost->logical_port_entries; index++) { ihost 1031 drivers/scsi/isci/host.c struct isci_port *iport = &ihost->ports[index]; ihost 1038 drivers/scsi/isci/host.c sci_controller_start_next_phy(ihost); ihost 1040 drivers/scsi/isci/host.c sci_mod_timer(&ihost->timer, timeout); ihost 1042 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_STARTING); ihost 1049 drivers/scsi/isci/host.c struct isci_host *ihost = SHOST_TO_SAS_HA(shost)->lldd_ha; ihost 1050 drivers/scsi/isci/host.c unsigned long tmo = sci_controller_get_suggested_start_timeout(ihost); ihost 1052 drivers/scsi/isci/host.c set_bit(IHOST_START_PENDING, &ihost->flags); ihost 1054 drivers/scsi/isci/host.c spin_lock_irq(&ihost->scic_lock); ihost 1055 drivers/scsi/isci/host.c sci_controller_start(ihost, tmo); ihost 1056 drivers/scsi/isci/host.c sci_controller_enable_interrupts(ihost); ihost 1057 drivers/scsi/isci/host.c spin_unlock_irq(&ihost->scic_lock); ihost 1060 drivers/scsi/isci/host.c static void isci_host_stop_complete(struct isci_host *ihost) ihost 1062 drivers/scsi/isci/host.c sci_controller_disable_interrupts(ihost); ihost 1063 drivers/scsi/isci/host.c clear_bit(IHOST_STOP_PENDING, &ihost->flags); ihost 1064 drivers/scsi/isci/host.c wake_up(&ihost->eventq); ihost 1067 drivers/scsi/isci/host.c static void sci_controller_completion_handler(struct isci_host *ihost) ihost 1070 drivers/scsi/isci/host.c if (sci_controller_completion_queue_has_entries(ihost)) ihost 1071 drivers/scsi/isci/host.c sci_controller_process_completions(ihost); ihost 1074 drivers/scsi/isci/host.c writel(SMU_ISR_COMPLETION, &ihost->smu_registers->interrupt_status); ihost 1076 drivers/scsi/isci/host.c writel(0xFF000000, &ihost->smu_registers->interrupt_mask); ihost 1077 drivers/scsi/isci/host.c writel(0, &ihost->smu_registers->interrupt_mask); ihost 1080 drivers/scsi/isci/host.c void ireq_done(struct isci_host *ihost, struct isci_request *ireq, struct sas_task *task) ihost 1086 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 1092 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 1103 drivers/scsi/isci/host.c wake_up_all(&ihost->eventq); ihost 1106 drivers/scsi/isci/host.c isci_free_tag(ihost, ireq->io_tag); ihost 1118 drivers/scsi/isci/host.c struct isci_host *ihost = (struct isci_host *)data; ihost 1121 drivers/scsi/isci/host.c spin_lock_irq(&ihost->scic_lock); ihost 1122 drivers/scsi/isci/host.c sci_controller_completion_handler(ihost); ihost 1123 drivers/scsi/isci/host.c spin_unlock_irq(&ihost->scic_lock); ihost 1129 drivers/scsi/isci/host.c active = isci_tci_active(ihost) - SCI_MAX_PORTS; ihost 1137 drivers/scsi/isci/host.c &ihost->smu_registers->interrupt_coalesce_control); ihost 1158 drivers/scsi/isci/host.c static enum sci_status sci_controller_stop(struct isci_host *ihost, u32 timeout) ihost 1160 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_READY) { ihost 1161 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 1162 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 1166 drivers/scsi/isci/host.c sci_mod_timer(&ihost->timer, timeout); ihost 1167 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_STOPPING); ihost 1183 drivers/scsi/isci/host.c static enum sci_status sci_controller_reset(struct isci_host *ihost) ihost 1185 drivers/scsi/isci/host.c switch (ihost->sm.current_state_id) { ihost 1194 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_RESETTING); ihost 1197 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 1198 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 1203 drivers/scsi/isci/host.c static enum sci_status sci_controller_stop_phys(struct isci_host *ihost) ihost 1212 drivers/scsi/isci/host.c phy_status = sci_phy_stop(&ihost->phys[index]); ihost 1218 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 1222 drivers/scsi/isci/host.c ihost->phys[index].phy_index, phy_status); ihost 1241 drivers/scsi/isci/host.c void isci_host_deinit(struct isci_host *ihost) ihost 1246 drivers/scsi/isci/host.c for (i = 0; i < isci_gpio_count(ihost); i++) ihost 1247 drivers/scsi/isci/host.c writel(SGPIO_HW_CONTROL, &ihost->scu_registers->peg0.sgpio.output_data_select[i]); ihost 1249 drivers/scsi/isci/host.c set_bit(IHOST_STOP_PENDING, &ihost->flags); ihost 1251 drivers/scsi/isci/host.c spin_lock_irq(&ihost->scic_lock); ihost 1252 drivers/scsi/isci/host.c sci_controller_stop(ihost, SCIC_CONTROLLER_STOP_TIMEOUT); ihost 1253 drivers/scsi/isci/host.c spin_unlock_irq(&ihost->scic_lock); ihost 1255 drivers/scsi/isci/host.c wait_for_stop(ihost); ihost 1262 drivers/scsi/isci/host.c sci_controller_stop_phys(ihost); ihost 1267 drivers/scsi/isci/host.c writel(0, &ihost->scu_registers->peg0.sgpio.interface_control); ihost 1269 drivers/scsi/isci/host.c spin_lock_irq(&ihost->scic_lock); ihost 1270 drivers/scsi/isci/host.c sci_controller_reset(ihost); ihost 1271 drivers/scsi/isci/host.c spin_unlock_irq(&ihost->scic_lock); ihost 1274 drivers/scsi/isci/host.c for (i = 0; i < ihost->logical_port_entries; i++) { ihost 1275 drivers/scsi/isci/host.c struct isci_port *iport = &ihost->ports[i]; ihost 1281 drivers/scsi/isci/host.c struct isci_phy *iphy = &ihost->phys[i]; ihost 1285 drivers/scsi/isci/host.c del_timer_sync(&ihost->port_agent.timer.timer); ihost 1287 drivers/scsi/isci/host.c del_timer_sync(&ihost->power_control.timer.timer); ihost 1289 drivers/scsi/isci/host.c del_timer_sync(&ihost->timer.timer); ihost 1291 drivers/scsi/isci/host.c del_timer_sync(&ihost->phy_timer.timer); ihost 1312 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1314 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_RESET); ihost 1319 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1321 drivers/scsi/isci/host.c sci_del_timer(&ihost->timer); ihost 1349 drivers/scsi/isci/host.c sci_controller_set_interrupt_coalescence(struct isci_host *ihost, ihost 1434 drivers/scsi/isci/host.c &ihost->smu_registers->interrupt_coalesce_control); ihost 1437 drivers/scsi/isci/host.c ihost->interrupt_coalesce_number = (u16)coalesce_number; ihost 1438 drivers/scsi/isci/host.c ihost->interrupt_coalesce_timeout = coalesce_timeout / 100; ihost 1446 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1450 drivers/scsi/isci/host.c val = readl(&ihost->smu_registers->clock_gating_control); ihost 1455 drivers/scsi/isci/host.c writel(val, &ihost->smu_registers->clock_gating_control); ihost 1458 drivers/scsi/isci/host.c sci_controller_set_interrupt_coalescence(ihost, 0, 0); ihost 1463 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1466 drivers/scsi/isci/host.c sci_controller_set_interrupt_coalescence(ihost, 0, 0); ihost 1469 drivers/scsi/isci/host.c static enum sci_status sci_controller_stop_ports(struct isci_host *ihost) ihost 1475 drivers/scsi/isci/host.c for (index = 0; index < ihost->logical_port_entries; index++) { ihost 1476 drivers/scsi/isci/host.c struct isci_port *iport = &ihost->ports[index]; ihost 1484 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 1496 drivers/scsi/isci/host.c static enum sci_status sci_controller_stop_devices(struct isci_host *ihost) ihost 1504 drivers/scsi/isci/host.c for (index = 0; index < ihost->remote_node_entries; index++) { ihost 1505 drivers/scsi/isci/host.c if (ihost->device_table[index] != NULL) { ihost 1507 drivers/scsi/isci/host.c device_status = sci_remote_device_stop(ihost->device_table[index], 0); ihost 1511 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 1516 drivers/scsi/isci/host.c ihost->device_table[index], device_status); ihost 1526 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1528 drivers/scsi/isci/host.c sci_controller_stop_devices(ihost); ihost 1529 drivers/scsi/isci/host.c sci_controller_stop_ports(ihost); ihost 1531 drivers/scsi/isci/host.c if (!sci_controller_has_remote_devices_stopping(ihost)) ihost 1532 drivers/scsi/isci/host.c isci_host_stop_complete(ihost); ihost 1537 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1539 drivers/scsi/isci/host.c sci_del_timer(&ihost->timer); ihost 1542 drivers/scsi/isci/host.c static void sci_controller_reset_hardware(struct isci_host *ihost) ihost 1545 drivers/scsi/isci/host.c sci_controller_disable_interrupts(ihost); ihost 1548 drivers/scsi/isci/host.c writel(0xFFFFFFFF, &ihost->smu_registers->soft_reset_control); ihost 1554 drivers/scsi/isci/host.c writel(0x00000000, &ihost->smu_registers->completion_queue_get); ihost 1557 drivers/scsi/isci/host.c writel(0, &ihost->scu_registers->sdma.unsolicited_frame_get_pointer); ihost 1560 drivers/scsi/isci/host.c writel(~SMU_INTERRUPT_STATUS_RESERVED_MASK, &ihost->smu_registers->interrupt_status); ihost 1565 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(sm, typeof(*ihost), sm); ihost 1567 drivers/scsi/isci/host.c sci_controller_reset_hardware(ihost); ihost 1568 drivers/scsi/isci/host.c sci_change_state(&ihost->sm, SCIC_RESET); ihost 1598 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(tmr, typeof(*ihost), timer); ihost 1599 drivers/scsi/isci/host.c struct sci_base_state_machine *sm = &ihost->sm; ihost 1602 drivers/scsi/isci/host.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1608 drivers/scsi/isci/host.c sci_controller_transition_to_ready(ihost, SCI_FAILURE_TIMEOUT); ihost 1611 drivers/scsi/isci/host.c isci_host_stop_complete(ihost); ihost 1613 drivers/scsi/isci/host.c dev_err(&ihost->pdev->dev, ihost 1619 drivers/scsi/isci/host.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1622 drivers/scsi/isci/host.c static enum sci_status sci_controller_construct(struct isci_host *ihost, ihost 1628 drivers/scsi/isci/host.c sci_init_sm(&ihost->sm, sci_controller_state_table, SCIC_INITIAL); ihost 1630 drivers/scsi/isci/host.c ihost->scu_registers = scu_base; ihost 1631 drivers/scsi/isci/host.c ihost->smu_registers = smu_base; ihost 1633 drivers/scsi/isci/host.c sci_port_configuration_agent_construct(&ihost->port_agent); ihost 1637 drivers/scsi/isci/host.c sci_port_construct(&ihost->ports[i], i, ihost); ihost 1638 drivers/scsi/isci/host.c sci_port_construct(&ihost->ports[i], SCIC_SDS_DUMMY_PORT, ihost); ihost 1643 drivers/scsi/isci/host.c sci_phy_construct(&ihost->phys[i], ihost 1644 drivers/scsi/isci/host.c &ihost->ports[SCI_MAX_PORTS], i); ihost 1647 drivers/scsi/isci/host.c ihost->invalid_phy_mask = 0; ihost 1649 drivers/scsi/isci/host.c sci_init_timer(&ihost->timer, controller_timeout); ihost 1651 drivers/scsi/isci/host.c return sci_controller_reset(ihost); ihost 1730 drivers/scsi/isci/host.c static u8 max_spin_up(struct isci_host *ihost) ihost 1732 drivers/scsi/isci/host.c if (ihost->user_parameters.max_concurr_spinup) ihost 1733 drivers/scsi/isci/host.c return min_t(u8, ihost->user_parameters.max_concurr_spinup, ihost 1736 drivers/scsi/isci/host.c return min_t(u8, ihost->oem_parameters.controller.max_concurr_spin_up, ihost 1743 drivers/scsi/isci/host.c struct isci_host *ihost = container_of(tmr, typeof(*ihost), power_control.timer); ihost 1748 drivers/scsi/isci/host.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1753 drivers/scsi/isci/host.c ihost->power_control.phys_granted_power = 0; ihost 1755 drivers/scsi/isci/host.c if (ihost->power_control.phys_waiting == 0) { ihost 1756 drivers/scsi/isci/host.c ihost->power_control.timer_started = false; ihost 1762 drivers/scsi/isci/host.c if (ihost->power_control.phys_waiting == 0) ihost 1765 drivers/scsi/isci/host.c iphy = ihost->power_control.requesters[i]; ihost 1769 drivers/scsi/isci/host.c if (ihost->power_control.phys_granted_power >= max_spin_up(ihost)) ihost 1772 drivers/scsi/isci/host.c ihost->power_control.requesters[i] = NULL; ihost 1773 drivers/scsi/isci/host.c ihost->power_control.phys_waiting--; ihost 1774 drivers/scsi/isci/host.c ihost->power_control.phys_granted_power++; ihost 1781 drivers/scsi/isci/host.c struct isci_phy *requester = ihost->power_control.requesters[j]; ihost 1794 drivers/scsi/isci/host.c ihost->power_control.requesters[j] = NULL; ihost 1795 drivers/scsi/isci/host.c ihost->power_control.phys_waiting--; ihost 1808 drivers/scsi/isci/host.c ihost->power_control.timer_started = true; ihost 1811 drivers/scsi/isci/host.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1814 drivers/scsi/isci/host.c void sci_controller_power_control_queue_insert(struct isci_host *ihost, ihost 1819 drivers/scsi/isci/host.c if (ihost->power_control.phys_granted_power < max_spin_up(ihost)) { ihost 1820 drivers/scsi/isci/host.c ihost->power_control.phys_granted_power++; ihost 1827 drivers/scsi/isci/host.c if (ihost->power_control.timer_started) ihost 1828 drivers/scsi/isci/host.c sci_del_timer(&ihost->power_control.timer); ihost 1830 drivers/scsi/isci/host.c sci_mod_timer(&ihost->power_control.timer, ihost 1832 drivers/scsi/isci/host.c ihost->power_control.timer_started = true; ihost 1844 drivers/scsi/isci/host.c current_phy = &ihost->phys[i]; ihost 1860 drivers/scsi/isci/host.c ihost->power_control.requesters[iphy->phy_index] = iphy; ihost 1861 drivers/scsi/isci/host.c ihost->power_control.phys_waiting++; ihost 1866 drivers/scsi/isci/host.c void sci_controller_power_control_queue_remove(struct isci_host *ihost, ihost 1871 drivers/scsi/isci/host.c if (ihost->power_control.requesters[iphy->phy_index]) ihost 1872 drivers/scsi/isci/host.c ihost->power_control.phys_waiting--; ihost 1874 drivers/scsi/isci/host.c ihost->power_control.requesters[iphy->phy_index] = NULL; ihost 1895 drivers/scsi/isci/host.c static unsigned char *to_cable_select(struct isci_host *ihost) ihost 1899 drivers/scsi/isci/host.c + ihost->id; ihost 1901 drivers/scsi/isci/host.c return &ihost->oem_parameters.controller.cable_selection_mask; ihost 1904 drivers/scsi/isci/host.c enum cable_selections decode_cable_selection(struct isci_host *ihost, int phy) ihost 1906 drivers/scsi/isci/host.c return decode_selection_byte(phy, *to_cable_select(ihost)); ihost 1923 drivers/scsi/isci/host.c static void sci_controller_afe_initialization(struct isci_host *ihost) ihost 1925 drivers/scsi/isci/host.c struct scu_afe_registers __iomem *afe = &ihost->scu_registers->afe; ihost 1926 drivers/scsi/isci/host.c const struct sci_oem_params *oem = &ihost->oem_parameters; ihost 1927 drivers/scsi/isci/host.c struct pci_dev *pdev = ihost->pdev; ihost 1930 drivers/scsi/isci/host.c unsigned char cable_selection_mask = *to_cable_select(ihost); ihost 2124 drivers/scsi/isci/host.c static void sci_controller_initialize_power_control(struct isci_host *ihost) ihost 2126 drivers/scsi/isci/host.c sci_init_timer(&ihost->power_control.timer, power_control_timeout); ihost 2128 drivers/scsi/isci/host.c memset(ihost->power_control.requesters, 0, ihost 2129 drivers/scsi/isci/host.c sizeof(ihost->power_control.requesters)); ihost 2131 drivers/scsi/isci/host.c ihost->power_control.phys_waiting = 0; ihost 2132 drivers/scsi/isci/host.c ihost->power_control.phys_granted_power = 0; ihost 2135 drivers/scsi/isci/host.c static enum sci_status sci_controller_initialize(struct isci_host *ihost) ihost 2137 drivers/scsi/isci/host.c struct sci_base_state_machine *sm = &ihost->sm; ihost 2141 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_RESET) { ihost 2142 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 2143 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 2149 drivers/scsi/isci/host.c sci_init_timer(&ihost->phy_timer, phy_startup_timeout); ihost 2151 drivers/scsi/isci/host.c ihost->next_phy_to_start = 0; ihost 2152 drivers/scsi/isci/host.c ihost->phy_startup_timer_pending = false; ihost 2154 drivers/scsi/isci/host.c sci_controller_initialize_power_control(ihost); ihost 2161 drivers/scsi/isci/host.c sci_controller_afe_initialization(ihost); ihost 2165 drivers/scsi/isci/host.c writel(0, &ihost->smu_registers->soft_reset_control); ihost 2175 drivers/scsi/isci/host.c status = readl(&ihost->smu_registers->control_status); ihost 2186 drivers/scsi/isci/host.c val = readl(&ihost->smu_registers->device_context_capacity); ihost 2189 drivers/scsi/isci/host.c ihost->logical_port_entries = min(smu_max_ports(val), SCI_MAX_PORTS); ihost 2190 drivers/scsi/isci/host.c ihost->task_context_entries = min(smu_max_task_contexts(val), SCI_MAX_IO_REQUESTS); ihost 2191 drivers/scsi/isci/host.c ihost->remote_node_entries = min(smu_max_rncs(val), SCI_MAX_REMOTE_DEVICES); ihost 2197 drivers/scsi/isci/host.c for (i = 0; i < ihost->logical_port_entries; i++) { ihost 2199 drivers/scsi/isci/host.c *ptsg = &ihost->scu_registers->peg0.ptsg; ihost 2205 drivers/scsi/isci/host.c val = readl(&ihost->scu_registers->sdma.pdma_configuration); ihost 2207 drivers/scsi/isci/host.c writel(val, &ihost->scu_registers->sdma.pdma_configuration); ihost 2209 drivers/scsi/isci/host.c val = readl(&ihost->scu_registers->sdma.cdma_configuration); ihost 2211 drivers/scsi/isci/host.c writel(val, &ihost->scu_registers->sdma.cdma_configuration); ihost 2218 drivers/scsi/isci/host.c result = sci_phy_initialize(&ihost->phys[i], ihost 2219 drivers/scsi/isci/host.c &ihost->scu_registers->peg0.pe[i].tl, ihost 2220 drivers/scsi/isci/host.c &ihost->scu_registers->peg0.pe[i].ll); ihost 2225 drivers/scsi/isci/host.c for (i = 0; i < ihost->logical_port_entries; i++) { ihost 2226 drivers/scsi/isci/host.c struct isci_port *iport = &ihost->ports[i]; ihost 2228 drivers/scsi/isci/host.c iport->port_task_scheduler_registers = &ihost->scu_registers->peg0.ptsg.port[i]; ihost 2229 drivers/scsi/isci/host.c iport->port_pe_configuration_register = &ihost->scu_registers->peg0.ptsg.protocol_engine[0]; ihost 2230 drivers/scsi/isci/host.c iport->viit_registers = &ihost->scu_registers->peg0.viit[i]; ihost 2233 drivers/scsi/isci/host.c result = sci_port_configuration_agent_initialize(ihost, &ihost->port_agent); ihost 2246 drivers/scsi/isci/host.c static int sci_controller_dma_alloc(struct isci_host *ihost) ihost 2248 drivers/scsi/isci/host.c struct device *dev = &ihost->pdev->dev; ihost 2253 drivers/scsi/isci/host.c if (ihost->completion_queue) ihost 2257 drivers/scsi/isci/host.c ihost->completion_queue = dmam_alloc_coherent(dev, size, &ihost->cq_dma, ihost 2259 drivers/scsi/isci/host.c if (!ihost->completion_queue) ihost 2262 drivers/scsi/isci/host.c size = ihost->remote_node_entries * sizeof(union scu_remote_node_context); ihost 2263 drivers/scsi/isci/host.c ihost->remote_node_context_table = dmam_alloc_coherent(dev, size, &ihost->rnc_dma, ihost 2266 drivers/scsi/isci/host.c if (!ihost->remote_node_context_table) ihost 2269 drivers/scsi/isci/host.c size = ihost->task_context_entries * sizeof(struct scu_task_context), ihost 2270 drivers/scsi/isci/host.c ihost->task_context_table = dmam_alloc_coherent(dev, size, &ihost->tc_dma, ihost 2272 drivers/scsi/isci/host.c if (!ihost->task_context_table) ihost 2276 drivers/scsi/isci/host.c ihost->ufi_buf = dmam_alloc_coherent(dev, size, &ihost->ufi_dma, GFP_KERNEL); ihost 2277 drivers/scsi/isci/host.c if (!ihost->ufi_buf) ihost 2288 drivers/scsi/isci/host.c ireq->tc = &ihost->task_context_table[i]; ihost 2289 drivers/scsi/isci/host.c ireq->owning_controller = ihost; ihost 2291 drivers/scsi/isci/host.c ireq->isci_host = ihost; ihost 2292 drivers/scsi/isci/host.c ihost->reqs[i] = ireq; ihost 2298 drivers/scsi/isci/host.c static int sci_controller_mem_init(struct isci_host *ihost) ihost 2300 drivers/scsi/isci/host.c int err = sci_controller_dma_alloc(ihost); ihost 2305 drivers/scsi/isci/host.c writel(lower_32_bits(ihost->cq_dma), &ihost->smu_registers->completion_queue_lower); ihost 2306 drivers/scsi/isci/host.c writel(upper_32_bits(ihost->cq_dma), &ihost->smu_registers->completion_queue_upper); ihost 2308 drivers/scsi/isci/host.c writel(lower_32_bits(ihost->rnc_dma), &ihost->smu_registers->remote_node_context_lower); ihost 2309 drivers/scsi/isci/host.c writel(upper_32_bits(ihost->rnc_dma), &ihost->smu_registers->remote_node_context_upper); ihost 2311 drivers/scsi/isci/host.c writel(lower_32_bits(ihost->tc_dma), &ihost->smu_registers->host_task_table_lower); ihost 2312 drivers/scsi/isci/host.c writel(upper_32_bits(ihost->tc_dma), &ihost->smu_registers->host_task_table_upper); ihost 2314 drivers/scsi/isci/host.c sci_unsolicited_frame_control_construct(ihost); ihost 2320 drivers/scsi/isci/host.c writel(lower_32_bits(ihost->uf_control.headers.physical_address), ihost 2321 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.uf_header_base_address_lower); ihost 2322 drivers/scsi/isci/host.c writel(upper_32_bits(ihost->uf_control.headers.physical_address), ihost 2323 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.uf_header_base_address_upper); ihost 2325 drivers/scsi/isci/host.c writel(lower_32_bits(ihost->uf_control.address_table.physical_address), ihost 2326 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.uf_address_table_lower); ihost 2327 drivers/scsi/isci/host.c writel(upper_32_bits(ihost->uf_control.address_table.physical_address), ihost 2328 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.uf_address_table_upper); ihost 2341 drivers/scsi/isci/host.c int isci_host_init(struct isci_host *ihost) ihost 2346 drivers/scsi/isci/host.c spin_lock_irq(&ihost->scic_lock); ihost 2347 drivers/scsi/isci/host.c status = sci_controller_construct(ihost, scu_base(ihost), smu_base(ihost)); ihost 2348 drivers/scsi/isci/host.c spin_unlock_irq(&ihost->scic_lock); ihost 2350 drivers/scsi/isci/host.c dev_err(&ihost->pdev->dev, ihost 2357 drivers/scsi/isci/host.c spin_lock_irq(&ihost->scic_lock); ihost 2358 drivers/scsi/isci/host.c status = sci_controller_initialize(ihost); ihost 2359 drivers/scsi/isci/host.c spin_unlock_irq(&ihost->scic_lock); ihost 2361 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 2368 drivers/scsi/isci/host.c err = sci_controller_mem_init(ihost); ihost 2373 drivers/scsi/isci/host.c writel(1, &ihost->scu_registers->peg0.sgpio.interface_control); ihost 2374 drivers/scsi/isci/host.c for (i = 0; i < isci_gpio_count(ihost); i++) ihost 2375 drivers/scsi/isci/host.c writel(SGPIO_HW_CONTROL, &ihost->scu_registers->peg0.sgpio.output_data_select[i]); ihost 2376 drivers/scsi/isci/host.c writel(0, &ihost->scu_registers->peg0.sgpio.vendor_specific_code); ihost 2381 drivers/scsi/isci/host.c void sci_controller_link_up(struct isci_host *ihost, struct isci_port *iport, ihost 2384 drivers/scsi/isci/host.c switch (ihost->sm.current_state_id) { ihost 2386 drivers/scsi/isci/host.c sci_del_timer(&ihost->phy_timer); ihost 2387 drivers/scsi/isci/host.c ihost->phy_startup_timer_pending = false; ihost 2388 drivers/scsi/isci/host.c ihost->port_agent.link_up_handler(ihost, &ihost->port_agent, ihost 2390 drivers/scsi/isci/host.c sci_controller_start_next_phy(ihost); ihost 2393 drivers/scsi/isci/host.c ihost->port_agent.link_up_handler(ihost, &ihost->port_agent, ihost 2397 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 2400 drivers/scsi/isci/host.c ihost->sm.current_state_id); ihost 2404 drivers/scsi/isci/host.c void sci_controller_link_down(struct isci_host *ihost, struct isci_port *iport, ihost 2407 drivers/scsi/isci/host.c switch (ihost->sm.current_state_id) { ihost 2410 drivers/scsi/isci/host.c ihost->port_agent.link_down_handler(ihost, &ihost->port_agent, ihost 2414 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 2419 drivers/scsi/isci/host.c ihost->sm.current_state_id); ihost 2423 drivers/scsi/isci/host.c bool sci_controller_has_remote_devices_stopping(struct isci_host *ihost) ihost 2427 drivers/scsi/isci/host.c for (index = 0; index < ihost->remote_node_entries; index++) { ihost 2428 drivers/scsi/isci/host.c if ((ihost->device_table[index] != NULL) && ihost 2429 drivers/scsi/isci/host.c (ihost->device_table[index]->sm.current_state_id == SCI_DEV_STOPPING)) ihost 2436 drivers/scsi/isci/host.c void sci_controller_remote_device_stopped(struct isci_host *ihost, ihost 2439 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_STOPPING) { ihost 2440 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, ihost 2443 drivers/scsi/isci/host.c ihost, idev, ihost 2444 drivers/scsi/isci/host.c ihost->sm.current_state_id); ihost 2448 drivers/scsi/isci/host.c if (!sci_controller_has_remote_devices_stopping(ihost)) ihost 2449 drivers/scsi/isci/host.c isci_host_stop_complete(ihost); ihost 2452 drivers/scsi/isci/host.c void sci_controller_post_request(struct isci_host *ihost, u32 request) ihost 2454 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, "%s[%d]: %#x\n", ihost 2455 drivers/scsi/isci/host.c __func__, ihost->id, request); ihost 2457 drivers/scsi/isci/host.c writel(request, &ihost->smu_registers->post_context_port); ihost 2460 drivers/scsi/isci/host.c struct isci_request *sci_request_by_tag(struct isci_host *ihost, u16 io_tag) ihost 2467 drivers/scsi/isci/host.c if (task_index < ihost->task_context_entries) { ihost 2468 drivers/scsi/isci/host.c struct isci_request *ireq = ihost->reqs[task_index]; ihost 2473 drivers/scsi/isci/host.c if (task_sequence == ihost->io_request_sequence[task_index]) ihost 2495 drivers/scsi/isci/host.c enum sci_status sci_controller_allocate_remote_node_context(struct isci_host *ihost, ihost 2503 drivers/scsi/isci/host.c &ihost->available_remote_nodes, remote_node_count ihost 2507 drivers/scsi/isci/host.c ihost->device_table[node_index] = idev; ihost 2517 drivers/scsi/isci/host.c void sci_controller_free_remote_node_context(struct isci_host *ihost, ihost 2523 drivers/scsi/isci/host.c if (ihost->device_table[node_id] == idev) { ihost 2524 drivers/scsi/isci/host.c ihost->device_table[node_id] = NULL; ihost 2527 drivers/scsi/isci/host.c &ihost->available_remote_nodes, remote_node_count, node_id ihost 2544 drivers/scsi/isci/host.c void sci_controller_release_frame(struct isci_host *ihost, u32 frame_index) ihost 2546 drivers/scsi/isci/host.c if (sci_unsolicited_frame_control_release_frame(&ihost->uf_control, frame_index)) ihost 2547 drivers/scsi/isci/host.c writel(ihost->uf_control.get, ihost 2548 drivers/scsi/isci/host.c &ihost->scu_registers->sdma.unsolicited_frame_get_pointer); ihost 2551 drivers/scsi/isci/host.c void isci_tci_free(struct isci_host *ihost, u16 tci) ihost 2553 drivers/scsi/isci/host.c u16 tail = ihost->tci_tail & (SCI_MAX_IO_REQUESTS-1); ihost 2555 drivers/scsi/isci/host.c ihost->tci_pool[tail] = tci; ihost 2556 drivers/scsi/isci/host.c ihost->tci_tail = tail + 1; ihost 2559 drivers/scsi/isci/host.c static u16 isci_tci_alloc(struct isci_host *ihost) ihost 2561 drivers/scsi/isci/host.c u16 head = ihost->tci_head & (SCI_MAX_IO_REQUESTS-1); ihost 2562 drivers/scsi/isci/host.c u16 tci = ihost->tci_pool[head]; ihost 2564 drivers/scsi/isci/host.c ihost->tci_head = head + 1; ihost 2568 drivers/scsi/isci/host.c static u16 isci_tci_space(struct isci_host *ihost) ihost 2570 drivers/scsi/isci/host.c return CIRC_SPACE(ihost->tci_head, ihost->tci_tail, SCI_MAX_IO_REQUESTS); ihost 2573 drivers/scsi/isci/host.c u16 isci_alloc_tag(struct isci_host *ihost) ihost 2575 drivers/scsi/isci/host.c if (isci_tci_space(ihost)) { ihost 2576 drivers/scsi/isci/host.c u16 tci = isci_tci_alloc(ihost); ihost 2577 drivers/scsi/isci/host.c u8 seq = ihost->io_request_sequence[tci]; ihost 2585 drivers/scsi/isci/host.c enum sci_status isci_free_tag(struct isci_host *ihost, u16 io_tag) ihost 2591 drivers/scsi/isci/host.c if (isci_tci_active(ihost) == 0) ihost 2594 drivers/scsi/isci/host.c if (seq == ihost->io_request_sequence[tci]) { ihost 2595 drivers/scsi/isci/host.c ihost->io_request_sequence[tci] = (seq+1) & (SCI_MAX_SEQ-1); ihost 2597 drivers/scsi/isci/host.c isci_tci_free(ihost, tci); ihost 2604 drivers/scsi/isci/host.c enum sci_status sci_controller_start_io(struct isci_host *ihost, ihost 2610 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_READY) { ihost 2611 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 2612 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 2616 drivers/scsi/isci/host.c status = sci_remote_device_start_io(ihost, idev, ireq); ihost 2621 drivers/scsi/isci/host.c sci_controller_post_request(ihost, ireq->post_context); ihost 2625 drivers/scsi/isci/host.c enum sci_status sci_controller_terminate_request(struct isci_host *ihost, ihost 2635 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_READY) { ihost 2636 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 2637 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 2642 drivers/scsi/isci/host.c dev_dbg(&ihost->pdev->dev, "%s: status=%d; ireq=%p; flags=%lx\n", ihost 2652 drivers/scsi/isci/host.c ihost, ireq->post_context | ihost 2669 drivers/scsi/isci/host.c enum sci_status sci_controller_complete_io(struct isci_host *ihost, ihost 2676 drivers/scsi/isci/host.c switch (ihost->sm.current_state_id) { ihost 2681 drivers/scsi/isci/host.c status = sci_remote_device_complete_io(ihost, idev, ireq); ihost 2689 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 2690 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 2698 drivers/scsi/isci/host.c struct isci_host *ihost = ireq->owning_controller; ihost 2700 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_READY) { ihost 2701 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, "%s invalid state: %d\n", ihost 2702 drivers/scsi/isci/host.c __func__, ihost->sm.current_state_id); ihost 2707 drivers/scsi/isci/host.c sci_controller_post_request(ihost, ireq->post_context); ihost 2720 drivers/scsi/isci/host.c enum sci_status sci_controller_start_task(struct isci_host *ihost, ihost 2726 drivers/scsi/isci/host.c if (ihost->sm.current_state_id != SCIC_READY) { ihost 2727 drivers/scsi/isci/host.c dev_warn(&ihost->pdev->dev, ihost 2734 drivers/scsi/isci/host.c status = sci_remote_device_start_task(ihost, idev, ireq); ihost 2747 drivers/scsi/isci/host.c sci_controller_post_request(ihost, ireq->post_context); ihost 2756 drivers/scsi/isci/host.c static int sci_write_gpio_tx_gp(struct isci_host *ihost, u8 reg_index, u8 reg_count, u8 *write_data) ihost 2764 drivers/scsi/isci/host.c for (d = 0; d < isci_gpio_count(ihost); d++) { ihost 2783 drivers/scsi/isci/host.c writel(val, &ihost->scu_registers->peg0.sgpio.output_data_select[d]); ihost 2795 drivers/scsi/isci/host.c struct isci_host *ihost = sas_ha->lldd_ha; ihost 2800 drivers/scsi/isci/host.c written = sci_write_gpio_tx_gp(ihost, reg_index, reg_count, write_data); ihost 112 drivers/scsi/isci/host.h bool is_port_config_apc(struct isci_host *ihost); ihost 113 drivers/scsi/isci/host.h bool is_controller_start_complete(struct isci_host *ihost); ihost 307 drivers/scsi/isci/host.h static inline struct Scsi_Host *to_shost(struct isci_host *ihost) ihost 309 drivers/scsi/isci/host.h return ihost->sas_ha.core.shost; ihost 312 drivers/scsi/isci/host.h #define for_each_isci_host(id, ihost, pdev) \ ihost 314 drivers/scsi/isci/host.h (ihost = to_pci_info(pdev)->hosts[id]); id++) ihost 316 drivers/scsi/isci/host.h static inline void wait_for_start(struct isci_host *ihost) ihost 318 drivers/scsi/isci/host.h wait_event(ihost->eventq, !test_bit(IHOST_START_PENDING, &ihost->flags)); ihost 321 drivers/scsi/isci/host.h static inline void wait_for_stop(struct isci_host *ihost) ihost 323 drivers/scsi/isci/host.h wait_event(ihost->eventq, !test_bit(IHOST_STOP_PENDING, &ihost->flags)); ihost 326 drivers/scsi/isci/host.h static inline void wait_for_device_start(struct isci_host *ihost, struct isci_remote_device *idev) ihost 328 drivers/scsi/isci/host.h wait_event(ihost->eventq, !test_bit(IDEV_START_PENDING, &idev->flags)); ihost 331 drivers/scsi/isci/host.h static inline void wait_for_device_stop(struct isci_host *ihost, struct isci_remote_device *idev) ihost 333 drivers/scsi/isci/host.h wait_event(ihost->eventq, !test_bit(IDEV_STOP_PENDING, &idev->flags)); ihost 429 drivers/scsi/isci/host.h enum cable_selections decode_cable_selection(struct isci_host *ihost, int phy); ihost 430 drivers/scsi/isci/host.h void validate_cable_selections(struct isci_host *ihost); ihost 440 drivers/scsi/isci/host.h static inline int isci_gpio_count(struct isci_host *ihost) ihost 442 drivers/scsi/isci/host.h return ARRAY_SIZE(ihost->scu_registers->peg0.sgpio.output_data_select); ihost 445 drivers/scsi/isci/host.h void sci_controller_post_request(struct isci_host *ihost, ihost 447 drivers/scsi/isci/host.h void sci_controller_release_frame(struct isci_host *ihost, ihost 452 drivers/scsi/isci/host.h enum sci_status sci_controller_allocate_remote_node_context(struct isci_host *ihost, ihost 456 drivers/scsi/isci/host.h struct isci_host *ihost, ihost 460 drivers/scsi/isci/host.h struct isci_request *sci_request_by_tag(struct isci_host *ihost, u16 io_tag); ihost 461 drivers/scsi/isci/host.h void sci_controller_power_control_queue_insert(struct isci_host *ihost, ihost 463 drivers/scsi/isci/host.h void sci_controller_power_control_queue_remove(struct isci_host *ihost, ihost 465 drivers/scsi/isci/host.h void sci_controller_link_up(struct isci_host *ihost, struct isci_port *iport, ihost 467 drivers/scsi/isci/host.h void sci_controller_link_down(struct isci_host *ihost, struct isci_port *iport, ihost 469 drivers/scsi/isci/host.h void sci_controller_remote_device_stopped(struct isci_host *ihost, ihost 475 drivers/scsi/isci/host.h u16 isci_alloc_tag(struct isci_host *ihost); ihost 476 drivers/scsi/isci/host.h enum sci_status isci_free_tag(struct isci_host *ihost, u16 io_tag); ihost 477 drivers/scsi/isci/host.h void isci_tci_free(struct isci_host *ihost, u16 tci); ihost 478 drivers/scsi/isci/host.h void ireq_done(struct isci_host *ihost, struct isci_request *ireq, struct sas_task *task); ihost 483 drivers/scsi/isci/host.h void sci_controller_disable_interrupts(struct isci_host *ihost); ihost 484 drivers/scsi/isci/host.h bool sci_controller_has_remote_devices_stopping(struct isci_host *ihost); ihost 485 drivers/scsi/isci/host.h void sci_controller_transition_to_ready(struct isci_host *ihost, enum sci_status status); ihost 488 drivers/scsi/isci/host.h struct isci_host *ihost, ihost 493 drivers/scsi/isci/host.h struct isci_host *ihost, ihost 498 drivers/scsi/isci/host.h struct isci_host *ihost, ihost 503 drivers/scsi/isci/host.h struct isci_host *ihost, ihost 511 drivers/scsi/isci/host.h struct isci_host *ihost, ihost 138 drivers/scsi/isci/init.c struct isci_host *ihost = container_of(sas_ha, typeof(*ihost), sas_ha); ihost 140 drivers/scsi/isci/init.c return snprintf(buf, PAGE_SIZE, "%d\n", ihost->id); ihost 331 drivers/scsi/isci/init.c struct isci_host *ihost; ihost 348 drivers/scsi/isci/init.c ihost = pci_info->hosts[id]; ihost 356 drivers/scsi/isci/init.c isr, 0, DRV_NAME"-msix", ihost); ihost 363 drivers/scsi/isci/init.c ihost = pci_info->hosts[id]; ihost 365 drivers/scsi/isci/init.c ihost); ihost 373 drivers/scsi/isci/init.c for_each_isci_host(i, ihost, pdev) { ihost 376 drivers/scsi/isci/init.c ihost); ihost 406 drivers/scsi/isci/init.c static enum sci_status sci_user_parameters_set(struct isci_host *ihost, ihost 437 drivers/scsi/isci/init.c memcpy(&ihost->user_parameters, sci_parms, sizeof(*sci_parms)); ihost 442 drivers/scsi/isci/init.c static void sci_oem_defaults(struct isci_host *ihost) ihost 445 drivers/scsi/isci/init.c struct sci_user_parameters *user = &ihost->user_parameters; ihost 446 drivers/scsi/isci/init.c struct sci_oem_params *oem = &ihost->oem_parameters; ihost 480 drivers/scsi/isci/init.c oem->phys[i].sas_address.low = 0x1 + ihost->id; ihost 496 drivers/scsi/isci/init.c struct isci_host *ihost; ihost 500 drivers/scsi/isci/init.c ihost = devm_kzalloc(&pdev->dev, sizeof(*ihost), GFP_KERNEL); ihost 501 drivers/scsi/isci/init.c if (!ihost) ihost 504 drivers/scsi/isci/init.c ihost->pdev = pdev; ihost 505 drivers/scsi/isci/init.c ihost->id = id; ihost 506 drivers/scsi/isci/init.c spin_lock_init(&ihost->scic_lock); ihost 507 drivers/scsi/isci/init.c init_waitqueue_head(&ihost->eventq); ihost 508 drivers/scsi/isci/init.c ihost->sas_ha.dev = &ihost->pdev->dev; ihost 509 drivers/scsi/isci/init.c ihost->sas_ha.lldd_ha = ihost; ihost 510 drivers/scsi/isci/init.c tasklet_init(&ihost->completion_tasklet, ihost 511 drivers/scsi/isci/init.c isci_host_completion_routine, (unsigned long)ihost); ihost 515 drivers/scsi/isci/init.c sci_oem_defaults(ihost); ihost 517 drivers/scsi/isci/init.c if (sci_user_parameters_set(ihost, &sci_user_params)) { ihost 529 drivers/scsi/isci/init.c ihost->oem_parameters = orom->ctrl[id]; ihost 534 drivers/scsi/isci/init.c if (sci_oem_parameters_validate(&ihost->oem_parameters, oem_version)) { ihost 540 drivers/scsi/isci/init.c struct isci_port *iport = &ihost->ports[i]; ihost 543 drivers/scsi/isci/init.c iport->isci_host = ihost; ihost 547 drivers/scsi/isci/init.c isci_phy_init(&ihost->phys[i], ihost, i); ihost 550 drivers/scsi/isci/init.c struct isci_remote_device *idev = &ihost->devices[i]; ihost 561 drivers/scsi/isci/init.c (is_cable_select_overridden() ? "* " : ""), ihost->id, ihost 562 drivers/scsi/isci/init.c lookup_cable_names(decode_cable_selection(ihost, 3)), ihost 563 drivers/scsi/isci/init.c lookup_cable_names(decode_cable_selection(ihost, 2)), ihost 564 drivers/scsi/isci/init.c lookup_cable_names(decode_cable_selection(ihost, 1)), ihost 565 drivers/scsi/isci/init.c lookup_cable_names(decode_cable_selection(ihost, 0))); ihost 567 drivers/scsi/isci/init.c err = isci_host_init(ihost); ihost 571 drivers/scsi/isci/init.c SHOST_TO_SAS_HA(shost) = &ihost->sas_ha; ihost 572 drivers/scsi/isci/init.c ihost->sas_ha.core.shost = shost; ihost 590 drivers/scsi/isci/init.c err = isci_register_sas_ha(ihost); ihost 594 drivers/scsi/isci/init.c return ihost; ihost 692 drivers/scsi/isci/init.c struct isci_host *ihost; ihost 695 drivers/scsi/isci/init.c for_each_isci_host(i, ihost, pdev) { ihost 696 drivers/scsi/isci/init.c wait_for_start(ihost); ihost 697 drivers/scsi/isci/init.c isci_unregister(ihost); ihost 698 drivers/scsi/isci/init.c isci_host_deinit(ihost); ihost 706 drivers/scsi/isci/init.c struct isci_host *ihost; ihost 709 drivers/scsi/isci/init.c for_each_isci_host(i, ihost, pdev) { ihost 710 drivers/scsi/isci/init.c sas_suspend_ha(&ihost->sas_ha); ihost 711 drivers/scsi/isci/init.c isci_host_deinit(ihost); ihost 724 drivers/scsi/isci/init.c struct isci_host *ihost; ihost 739 drivers/scsi/isci/init.c for_each_isci_host(i, ihost, pdev) { ihost 740 drivers/scsi/isci/init.c sas_prep_resume_ha(&ihost->sas_ha); ihost 742 drivers/scsi/isci/init.c isci_host_init(ihost); ihost 743 drivers/scsi/isci/init.c isci_host_start(ihost->sas_ha.core.shost); ihost 744 drivers/scsi/isci/init.c wait_for_start(ihost); ihost 746 drivers/scsi/isci/init.c sas_resume_ha(&ihost->sas_ha); ihost 83 drivers/scsi/isci/phy.c struct isci_host *ihost = container_of(table, typeof(*ihost), phys[0]); ihost 85 drivers/scsi/isci/phy.c return ihost; ihost 119 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 131 drivers/scsi/isci/phy.c phy_user = &ihost->user_parameters.phys[phy_idx]; ihost 132 drivers/scsi/isci/phy.c phy_oem = &ihost->oem_parameters.phys[phy_idx]; ihost 170 drivers/scsi/isci/phy.c if (ihost->oem_parameters.controller.do_enable_ssc) { ihost 171 drivers/scsi/isci/phy.c struct scu_afe_registers __iomem *afe = &ihost->scu_registers->afe; ihost 173 drivers/scsi/isci/phy.c struct isci_pci_info *pci_info = to_pci_info(ihost->pdev); ihost 187 drivers/scsi/isci/phy.c sata_spread = ihost->oem_parameters.controller.ssc_sata_tx_spread_level; ihost 188 drivers/scsi/isci/phy.c sas_spread = ihost->oem_parameters.controller.ssc_sas_tx_spread_level; ihost 195 drivers/scsi/isci/phy.c sas_type = ihost->oem_parameters.controller.ssc_sas_tx_type; ihost 261 drivers/scsi/isci/phy.c if (is_c0(ihost->pdev) || is_c1(ihost->pdev)) { ihost 268 drivers/scsi/isci/phy.c (u8)ihost->user_parameters.no_outbound_task_timeout); ihost 296 drivers/scsi/isci/phy.c if (is_a2(ihost->pdev)) { ihost 322 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 325 drivers/scsi/isci/phy.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 338 drivers/scsi/isci/phy.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 974 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 983 drivers/scsi/isci/phy.c result = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1017 drivers/scsi/isci/phy.c sci_controller_release_frame(ihost, frame_index); ihost 1024 drivers/scsi/isci/phy.c result = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1033 drivers/scsi/isci/phy.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1054 drivers/scsi/isci/phy.c sci_controller_release_frame(ihost, frame_index); ihost 1077 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 1079 drivers/scsi/isci/phy.c sci_controller_power_control_queue_insert(ihost, iphy); ihost 1085 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 1087 drivers/scsi/isci/phy.c sci_controller_power_control_queue_remove(ihost, iphy); ihost 1093 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 1095 drivers/scsi/isci/phy.c sci_controller_power_control_queue_insert(ihost, iphy); ihost 1101 drivers/scsi/isci/phy.c struct isci_host *ihost = iphy->owning_port->owning_controller; ihost 1103 drivers/scsi/isci/phy.c sci_controller_power_control_queue_remove(ihost, iphy); ihost 1259 drivers/scsi/isci/phy.c struct isci_host *ihost = iport->owning_controller; ihost 1270 drivers/scsi/isci/phy.c sci_controller_link_down(ihost, phy_get_non_dummy_port(iphy), iphy); ihost 1277 drivers/scsi/isci/phy.c struct isci_host *ihost = iport->owning_controller; ihost 1287 drivers/scsi/isci/phy.c sci_controller_link_down(ihost, phy_get_non_dummy_port(iphy), iphy); ihost 1296 drivers/scsi/isci/phy.c struct isci_host *ihost = iport->owning_controller; ihost 1298 drivers/scsi/isci/phy.c sci_controller_link_up(ihost, phy_get_non_dummy_port(iphy), iphy); ihost 1392 drivers/scsi/isci/phy.c void isci_phy_init(struct isci_phy *iphy, struct isci_host *ihost, int index) ihost 1394 drivers/scsi/isci/phy.c struct sci_oem_params *oem = &ihost->oem_parameters; ihost 1408 drivers/scsi/isci/phy.c iphy->sas_phy.ha = &ihost->sas_ha; ihost 1438 drivers/scsi/isci/phy.c struct isci_host *ihost = sas_phy->ha->lldd_ha; ihost 1441 drivers/scsi/isci/phy.c dev_dbg(&ihost->pdev->dev, ihost 1447 drivers/scsi/isci/phy.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1450 drivers/scsi/isci/phy.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1454 drivers/scsi/isci/phy.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1458 drivers/scsi/isci/phy.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1465 drivers/scsi/isci/phy.c ret = isci_port_perform_hard_reset(ihost, port->lldd_port, iphy); ihost 1481 drivers/scsi/isci/phy.c dev_dbg(&ihost->pdev->dev, ihost 457 drivers/scsi/isci/phy.h void isci_phy_init(struct isci_phy *iphy, struct isci_host *ihost, int index); ihost 77 drivers/scsi/isci/port.c struct isci_host *ihost; ihost 83 drivers/scsi/isci/port.c ihost = container_of(table, typeof(*ihost), ports[0]); ihost 85 drivers/scsi/isci/port.c return &ihost->pdev->dev; ihost 159 drivers/scsi/isci/port.c static void isci_port_bc_change_received(struct isci_host *ihost, ihost 163 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, ihost 167 drivers/scsi/isci/port.c ihost->sas_ha.notify_port_event(&iphy->sas_phy, PORTE_BROADCAST_RCVD); ihost 318 drivers/scsi/isci/port.c struct isci_host *ihost = isci_port->owning_controller; ihost 320 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, ihost 332 drivers/scsi/isci/port.c struct isci_phy *iphy = &ihost->phys[phy_idx]; ihost 338 drivers/scsi/isci/port.c isci_port_link_down(ihost, iphy, isci_port); ihost 347 drivers/scsi/isci/port.c wake_up(&ihost->eventq); ihost 364 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 365 drivers/scsi/isci/port.c struct sci_user_parameters *user = &ihost->user_parameters; ihost 488 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 491 drivers/scsi/isci/port.c sci_phy_set_port(iphy, &ihost->ports[SCI_MAX_PORTS]); ihost 572 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 575 drivers/scsi/isci/port.c task_context = &ihost->task_context_table[ISCI_TAG_TCI(tag)]; ihost 592 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 595 drivers/scsi/isci/port.c isci_free_tag(ihost, iport->reserved_tag); ihost 598 drivers/scsi/isci/port.c sci_remote_node_table_release_remote_node_index(&ihost->available_remote_nodes, ihost 625 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 632 drivers/scsi/isci/port.c sci_controller_clear_invalid_phy(ihost, iphy); ihost 635 drivers/scsi/isci/port.c isci_port_link_up(ihost, iport, iphy); ihost 641 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 659 drivers/scsi/isci/port.c isci_port_link_down(ihost, iphy, iport); ihost 664 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 671 drivers/scsi/isci/port.c if ((ihost->invalid_phy_mask & (1 << iphy->phy_index)) == 0) { ihost 672 drivers/scsi/isci/port.c ihost->invalid_phy_mask |= 1 << iphy->phy_index; ihost 673 drivers/scsi/isci/port.c dev_warn(&ihost->pdev->dev, "Invalid link up!\n"); ihost 762 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 763 drivers/scsi/isci/port.c struct isci_port *dst_port = &(ihost->ports[iphy->phy_index]); ihost 776 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 780 drivers/scsi/isci/port.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 814 drivers/scsi/isci/port.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 885 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 890 drivers/scsi/isci/port.c tc = &ihost->task_context_table[ISCI_TAG_TCI(tag)]; ihost 897 drivers/scsi/isci/port.c sci_controller_post_request(ihost, command); ihost 909 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 914 drivers/scsi/isci/port.c tc = &ihost->task_context_table[ISCI_TAG_TCI(tag)]; ihost 921 drivers/scsi/isci/port.c sci_controller_post_request(ihost, command); ihost 966 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 968 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, "%s: port%d ready\n", ihost 992 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 998 drivers/scsi/isci/port.c rnc = &ihost->remote_node_context_table[rni]; ihost 1006 drivers/scsi/isci/port.c readl(&ihost->smu_registers->interrupt_status); /* flush */ ihost 1012 drivers/scsi/isci/port.c sci_controller_post_request(ihost, command); ihost 1026 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 1035 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, "%s: port%d !ready\n", ihost 1045 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 1048 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, "%s: port%d !ready\n", ihost 1058 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 1081 drivers/scsi/isci/port.c &ihost->available_remote_nodes, 1); ihost 1093 drivers/scsi/isci/port.c tag = isci_alloc_tag(ihost); ihost 1460 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 1466 drivers/scsi/isci/port.c rnc = &ihost->remote_node_context_table[rni]; ihost 1472 drivers/scsi/isci/port.c sci_controller_post_request(ihost, command); ihost 1477 drivers/scsi/isci/port.c readl(&ihost->smu_registers->interrupt_status); /* flush */ ihost 1483 drivers/scsi/isci/port.c sci_controller_post_request(ihost, command); ihost 1510 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 1517 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, "%s: port%d !ready\n", ihost 1607 drivers/scsi/isci/port.c struct isci_host *ihost) ihost 1618 drivers/scsi/isci/port.c iport->owning_controller = ihost; ihost 1637 drivers/scsi/isci/port.c struct isci_host *ihost = iport->owning_controller; ihost 1640 drivers/scsi/isci/port.c isci_port_bc_change_received(ihost, iport, iphy); ihost 1643 drivers/scsi/isci/port.c static void wait_port_reset(struct isci_host *ihost, struct isci_port *iport) ihost 1645 drivers/scsi/isci/port.c wait_event(ihost->eventq, !test_bit(IPORT_RESET_PENDING, &iport->state)); ihost 1648 drivers/scsi/isci/port.c int isci_port_perform_hard_reset(struct isci_host *ihost, struct isci_port *iport, ihost 1655 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, "%s: iport = %p\n", ihost 1658 drivers/scsi/isci/port.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1664 drivers/scsi/isci/port.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1667 drivers/scsi/isci/port.c wait_port_reset(ihost, iport); ihost 1669 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, ihost 1676 drivers/scsi/isci/port.c dev_err(&ihost->pdev->dev, ihost 1682 drivers/scsi/isci/port.c wake_up(&ihost->eventq); ihost 1685 drivers/scsi/isci/port.c dev_err(&ihost->pdev->dev, ihost 1697 drivers/scsi/isci/port.c struct isci_host *ihost = dev_to_ihost(dev); ihost 1702 drivers/scsi/isci/port.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1704 drivers/scsi/isci/port.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1721 drivers/scsi/isci/port.c struct isci_host *ihost = phy->ha->lldd_ha; ihost 1732 drivers/scsi/isci/port.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1737 drivers/scsi/isci/port.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1740 drivers/scsi/isci/port.c dev_dbg(&ihost->pdev->dev, "%s: port: %ld\n", ihost 1741 drivers/scsi/isci/port.c __func__, (long) (iport - &ihost->ports[0])); ihost 1746 drivers/scsi/isci/port.c struct isci_host *ihost = phy->ha->lldd_ha; ihost 1756 drivers/scsi/isci/port.c wait_for_start(ihost); ihost 1758 drivers/scsi/isci/port.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1760 drivers/scsi/isci/port.c iport = &ihost->ports[i]; ihost 1764 drivers/scsi/isci/port.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 205 drivers/scsi/isci/port.h struct isci_host *ihost); ihost 280 drivers/scsi/isci/port.h int isci_port_perform_hard_reset(struct isci_host *ihost, struct isci_port *iport, ihost 116 drivers/scsi/isci/port_config.c struct isci_host *ihost, ihost 133 drivers/scsi/isci/port_config.c for (i = 0; i < ihost->logical_port_entries; i++) { ihost 134 drivers/scsi/isci/port_config.c struct isci_port *iport = &ihost->ports[i]; ihost 160 drivers/scsi/isci/port_config.c struct isci_host *ihost, ihost 197 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[0], &first_address); ihost 198 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[3], &second_address); ihost 210 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[0], &first_address); ihost 211 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[2], &second_address); ihost 224 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[1], &first_address); ihost 225 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[3], &second_address); ihost 242 drivers/scsi/isci/port_config.c sci_mpc_agent_validate_phy_configuration(struct isci_host *ihost, ihost 257 drivers/scsi/isci/port_config.c phy_mask = ihost->oem_parameters.ports[port_index].phy_mask; ihost 272 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[phy_index], ihost 297 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[phy_index], ihost 310 drivers/scsi/isci/port_config.c sci_port_add_phy(&ihost->ports[port_index], ihost 311 drivers/scsi/isci/port_config.c &ihost->phys[phy_index]); ihost 318 drivers/scsi/isci/port_config.c return sci_port_configuration_agent_validate_ports(ihost, port_agent); ihost 326 drivers/scsi/isci/port_config.c struct isci_host *ihost; ihost 331 drivers/scsi/isci/port_config.c ihost = container_of(port_agent, typeof(*ihost), port_agent); ihost 333 drivers/scsi/isci/port_config.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 344 drivers/scsi/isci/port_config.c struct isci_phy *iphy = &ihost->phys[index]; ihost 347 drivers/scsi/isci/port_config.c port_agent->link_up_handler(ihost, port_agent, ihost 354 drivers/scsi/isci/port_config.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 357 drivers/scsi/isci/port_config.c static void sci_mpc_agent_link_up(struct isci_host *ihost, ihost 393 drivers/scsi/isci/port_config.c struct isci_host *ihost, ihost 432 drivers/scsi/isci/port_config.c sci_apc_agent_validate_phy_configuration(struct isci_host *ihost, ihost 446 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[phy_index], ihost 450 drivers/scsi/isci/port_config.c sci_phy_get_sas_address(&ihost->phys[phy_index], ihost 465 drivers/scsi/isci/port_config.c return sci_port_configuration_agent_validate_ports(ihost, port_agent); ihost 481 drivers/scsi/isci/port_config.c static void sci_apc_agent_configure_ports(struct isci_host *ihost, ihost 491 drivers/scsi/isci/port_config.c iport = sci_port_configuration_agent_find_port(ihost, iphy); ihost 509 drivers/scsi/isci/port_config.c iport = &ihost->ports[port_index]; ihost 603 drivers/scsi/isci/port_config.c static void sci_apc_agent_link_up(struct isci_host *ihost, ihost 636 drivers/scsi/isci/port_config.c struct isci_host *ihost, ihost 661 drivers/scsi/isci/port_config.c struct isci_host *ihost; ihost 666 drivers/scsi/isci/port_config.c ihost = container_of(port_agent, typeof(*ihost), port_agent); ihost 668 drivers/scsi/isci/port_config.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 684 drivers/scsi/isci/port_config.c sci_apc_agent_configure_ports(ihost, port_agent, ihost 685 drivers/scsi/isci/port_config.c &ihost->phys[index], false); ihost 688 drivers/scsi/isci/port_config.c if (is_controller_start_complete(ihost)) ihost 689 drivers/scsi/isci/port_config.c sci_controller_transition_to_ready(ihost, SCI_SUCCESS); ihost 692 drivers/scsi/isci/port_config.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 726 drivers/scsi/isci/port_config.c bool is_port_config_apc(struct isci_host *ihost) ihost 728 drivers/scsi/isci/port_config.c return ihost->port_agent.link_up_handler == sci_apc_agent_link_up; ihost 732 drivers/scsi/isci/port_config.c struct isci_host *ihost, ihost 738 drivers/scsi/isci/port_config.c mode = ihost->oem_parameters.controller.mode_type; ihost 742 drivers/scsi/isci/port_config.c ihost, port_agent); ihost 750 drivers/scsi/isci/port_config.c ihost, port_agent); ihost 90 drivers/scsi/isci/remote_device.c static void isci_remote_device_ready(struct isci_host *ihost, struct isci_remote_device *idev) ihost 92 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 98 drivers/scsi/isci/remote_device.c wake_up(&ihost->eventq); ihost 102 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 112 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 118 drivers/scsi/isci/remote_device.c return sci_controller_terminate_request(ihost, idev, ireq); ihost 125 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 130 drivers/scsi/isci/remote_device.c struct isci_request *ireq = ihost->reqs[i]; ihost 133 drivers/scsi/isci/remote_device.c s = sci_remote_device_terminate_req(ihost, idev, chk, ireq); ihost 154 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 162 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 165 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 171 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 178 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 181 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 187 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 195 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 198 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, "%s: failed isci_get_device(idev=%p)\n", ihost 200 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 209 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 220 drivers/scsi/isci/remote_device.c sci_remote_device_terminate_req(ihost, idev, 0, ireq); ihost 221 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 222 drivers/scsi/isci/remote_device.c if (!wait_event_timeout(ihost->eventq, ihost 223 drivers/scsi/isci/remote_device.c isci_check_reqterm(ihost, idev, ireq, ihost 227 drivers/scsi/isci/remote_device.c dev_warn(&ihost->pdev->dev, "%s host%d timeout single\n", ihost 228 drivers/scsi/isci/remote_device.c __func__, ihost->id); ihost 229 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 246 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 249 drivers/scsi/isci/remote_device.c isci_free_tag(ihost, ireq->io_tag); ihost 250 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 254 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 255 drivers/scsi/isci/remote_device.c if (!wait_event_timeout(ihost->eventq, ihost 256 drivers/scsi/isci/remote_device.c isci_check_devempty(ihost, idev, ihost 260 drivers/scsi/isci/remote_device.c dev_warn(&ihost->pdev->dev, "%s host%d timeout all\n", ihost 261 drivers/scsi/isci/remote_device.c __func__, ihost->id); ihost 262 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 280 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, "%s: idev=%p, wait done\n", ihost 296 drivers/scsi/isci/remote_device.c static void isci_remote_device_not_ready(struct isci_host *ihost, ihost 300 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 444 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 458 drivers/scsi/isci/remote_device.c sci_controller_release_frame(ihost, frame_index); ihost 471 drivers/scsi/isci/remote_device.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 480 drivers/scsi/isci/remote_device.c ireq = sci_request_by_tag(ihost, be16_to_cpu(hdr.tag)); ihost 488 drivers/scsi/isci/remote_device.c sci_controller_release_frame(ihost, frame_index); ihost 495 drivers/scsi/isci/remote_device.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 518 drivers/scsi/isci/remote_device.c sci_controller_release_frame(ihost, frame_index); ihost 653 drivers/scsi/isci/remote_device.c enum sci_status sci_remote_device_start_io(struct isci_host *ihost, ihost 789 drivers/scsi/isci/remote_device.c enum sci_status sci_remote_device_complete_io(struct isci_host *ihost, ihost 871 drivers/scsi/isci/remote_device.c enum sci_status sci_remote_device_start_task(struct isci_host *ihost, ihost 984 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 990 drivers/scsi/isci/remote_device.c isci_remote_device_ready(ihost, idev); ihost 1018 drivers/scsi/isci/remote_device.c struct isci_host *ihost; ihost 1026 drivers/scsi/isci/remote_device.c ihost = idev->owning_port->owning_controller; ihost 1027 drivers/scsi/isci/remote_device.c sci_controller_free_remote_node_context(ihost, idev, ihost 1041 drivers/scsi/isci/remote_device.c static void isci_remote_device_deconstruct(struct isci_host *ihost, struct isci_remote_device *idev) ihost 1043 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1060 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1068 drivers/scsi/isci/remote_device.c isci_remote_device_deconstruct(ihost, idev); ihost 1070 drivers/scsi/isci/remote_device.c sci_controller_remote_device_stopped(ihost, idev); ihost 1076 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1078 drivers/scsi/isci/remote_device.c isci_remote_device_not_ready(ihost, idev, ihost 1085 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1093 drivers/scsi/isci/remote_device.c isci_remote_device_ready(ihost, idev); ihost 1102 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1104 drivers/scsi/isci/remote_device.c isci_remote_device_not_ready(ihost, idev, ihost 1112 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1114 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1123 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1125 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1151 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1155 drivers/scsi/isci/remote_device.c isci_remote_device_not_ready(ihost, idev, ihost 1162 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1165 drivers/scsi/isci/remote_device.c isci_remote_device_not_ready(ihost, idev, ihost 1172 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1174 drivers/scsi/isci/remote_device.c isci_remote_device_ready(ihost, idev); ihost 1180 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1184 drivers/scsi/isci/remote_device.c isci_remote_device_not_ready(ihost, idev, ihost 1356 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 1368 drivers/scsi/isci/remote_device.c wake_up(&ihost->eventq); ihost 1372 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 1378 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1382 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1388 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 1391 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, "%s: starting resume wait: %p\n", ihost 1395 drivers/scsi/isci/remote_device.c if (!wait_event_timeout(ihost->eventq, ihost 1396 drivers/scsi/isci/remote_device.c isci_remote_device_test_resume_done(ihost, idev), ihost 1399 drivers/scsi/isci/remote_device.c dev_warn(&ihost->pdev->dev, "%s: #### Timeout waiting for " ihost 1404 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, "%s: resume wait done: %p\n", ihost 1409 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 1416 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1429 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1431 drivers/scsi/isci/remote_device.c isci_remote_device_wait_for_resume_from_abort(ihost, idev); ihost 1477 drivers/scsi/isci/remote_device.c struct isci_host *ihost = iport->isci_host; ihost 1487 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, "%s: construct failed: %d\n", ihost 1497 drivers/scsi/isci/remote_device.c dev_warn(&ihost->pdev->dev, "remote device start failed: %d\n", ihost 1512 drivers/scsi/isci/remote_device.c isci_remote_device_alloc(struct isci_host *ihost, struct isci_port *iport) ihost 1518 drivers/scsi/isci/remote_device.c idev = &ihost->devices[i]; ihost 1524 drivers/scsi/isci/remote_device.c dev_warn(&ihost->pdev->dev, "%s: failed\n", __func__); ihost 1536 drivers/scsi/isci/remote_device.c struct isci_host *ihost = idev->isci_port->isci_host; ihost 1546 drivers/scsi/isci/remote_device.c wake_up(&ihost->eventq); ihost 1557 drivers/scsi/isci/remote_device.c enum sci_status isci_remote_device_stop(struct isci_host *ihost, struct isci_remote_device *idev) ihost 1562 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1565 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1571 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1577 drivers/scsi/isci/remote_device.c wait_for_device_stop(ihost, idev); ihost 1579 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1593 drivers/scsi/isci/remote_device.c struct isci_host *ihost = dev_to_ihost(dev); ihost 1596 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1600 drivers/scsi/isci/remote_device.c isci_remote_device_stop(ihost, idev); ihost 1659 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 1667 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1670 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 1673 drivers/scsi/isci/remote_device.c status = isci_remote_device_terminate_requests(ihost, idev, ireq); ihost 1675 drivers/scsi/isci/remote_device.c dev_dbg(&ihost->pdev->dev, ihost 1697 drivers/scsi/isci/remote_device.c struct isci_host *ihost, ihost 1703 drivers/scsi/isci/remote_device.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 1705 drivers/scsi/isci/remote_device.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 139 drivers/scsi/isci/remote_device.h enum sci_status isci_remote_device_stop(struct isci_host *ihost, ihost 141 drivers/scsi/isci/remote_device.h void isci_remote_device_nuke_requests(struct isci_host *ihost, ihost 322 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 327 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 332 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 351 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 360 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 364 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 368 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 372 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 377 drivers/scsi/isci/remote_device.h struct isci_host *ihost, ihost 105 drivers/scsi/isci/remote_node_context.c static union scu_remote_node_context *sci_rnc_by_id(struct isci_host *ihost, u16 id) ihost 107 drivers/scsi/isci/remote_node_context.c if (id < ihost->remote_node_entries && ihost 108 drivers/scsi/isci/remote_node_context.c ihost->device_table[id]) ihost 109 drivers/scsi/isci/remote_node_context.c return &ihost->remote_node_context_table[id]; ihost 120 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost; ihost 123 drivers/scsi/isci/remote_node_context.c ihost = idev->owning_port->owning_controller; ihost 124 drivers/scsi/isci/remote_node_context.c rnc = sci_rnc_by_id(ihost, rni); ihost 148 drivers/scsi/isci/remote_node_context.c ihost->user_parameters.stp_max_occupancy_timeout; ihost 150 drivers/scsi/isci/remote_node_context.c ihost->user_parameters.stp_inactivity_timeout; ihost 153 drivers/scsi/isci/remote_node_context.c ihost->user_parameters.ssp_max_occupancy_timeout; ihost 155 drivers/scsi/isci/remote_node_context.c ihost->user_parameters.ssp_inactivity_timeout; ihost 196 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost = idev_to_ihost(rnc_to_dev(sci_rnc)); ihost 202 drivers/scsi/isci/remote_node_context.c wake_up(&ihost->eventq); ihost 244 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 246 drivers/scsi/isci/remote_node_context.c rnc_buffer = sci_rnc_by_id(ihost, sci_rnc->remote_node_index); ihost 265 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 267 drivers/scsi/isci/remote_node_context.c rnc_buffer = sci_rnc_by_id(ihost, sci_rnc->remote_node_index); ihost 279 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 289 drivers/scsi/isci/remote_node_context.c wake_up(&ihost->eventq); ihost 363 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 375 drivers/scsi/isci/remote_node_context.c wake_up(&ihost->eventq); ihost 642 drivers/scsi/isci/remote_node_context.c struct isci_host *ihost = idev->owning_port->owning_controller; ihost 644 drivers/scsi/isci/remote_node_context.c wake_up_all(&ihost->eventq); /* Let observers look. */ ihost 87 drivers/scsi/isci/request.c static dma_addr_t to_sgl_element_pair_dma(struct isci_host *ihost, ihost 94 drivers/scsi/isci/request.c (void *) &ihost->task_context_table[0]; ihost 95 drivers/scsi/isci/request.c return ihost->tc_dma + offset; ihost 98 drivers/scsi/isci/request.c (void *) &ihost->task_context_table[0]; ihost 99 drivers/scsi/isci/request.c return ihost->tc_dma + offset; ihost 115 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->isci_host; ihost 137 drivers/scsi/isci/request.c dma_addr = to_sgl_element_pair_dma(ihost, ihost 153 drivers/scsi/isci/request.c dma_addr = dma_map_single(&ihost->pdev->dev, ihost 788 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 791 drivers/scsi/isci/request.c if (readl(&ihost->smu_registers->address_modifier) == 0) { ihost 792 drivers/scsi/isci/request.c void __iomem *scu_reg_base = ihost->scu_registers; ihost 812 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 816 drivers/scsi/isci/request.c dev_warn(&ihost->pdev->dev, ihost 921 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 930 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, ihost 942 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 947 drivers/scsi/isci/request.c dev_warn(&ihost->pdev->dev, "%s: (%x) in wrong state %s\n", ihost 961 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 1558 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 1563 drivers/scsi/isci/request.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1569 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1578 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1586 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 1591 drivers/scsi/isci/request.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1605 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1614 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1709 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 1721 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1732 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1750 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 1760 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1768 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1777 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1787 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1805 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 1819 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1844 drivers/scsi/isci/request.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1849 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 1862 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1876 drivers/scsi/isci/request.c dev_warn(&ihost->pdev->dev, ihost 1889 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1899 drivers/scsi/isci/request.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 1904 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 1914 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1961 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 1971 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 1990 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 1999 drivers/scsi/isci/request.c status = sci_unsolicited_frame_control_get_header(&ihost->uf_control, ihost 2004 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 2015 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 2029 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 2037 drivers/scsi/isci/request.c sci_unsolicited_frame_control_get_buffer(&ihost->uf_control, ihost 2045 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 2067 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 2087 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 2091 drivers/scsi/isci/request.c dev_warn(&ihost->pdev->dev, ihost 2098 drivers/scsi/isci/request.c sci_controller_release_frame(ihost, frame_index); ihost 2397 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 2451 drivers/scsi/isci/request.c dev_warn(&ihost->pdev->dev, "%s: %x in wrong state %s\n", ihost 2735 drivers/scsi/isci/request.c static void isci_request_io_request_complete(struct isci_host *ihost, ihost 2746 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 2757 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 2768 drivers/scsi/isci/request.c &ihost->pdev->dev); ihost 2772 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 2778 drivers/scsi/isci/request.c dev_err(&ihost->pdev->dev, ihost 2813 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 2818 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, "%s: SCI_IO_SUCCESS\n", ihost 2824 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 2883 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 2912 drivers/scsi/isci/request.c dma_unmap_single(&ihost->pdev->dev, ihost 2916 drivers/scsi/isci/request.c dma_unmap_sg(&ihost->pdev->dev, task->scatter, ihost 2924 drivers/scsi/isci/request.c dma_unmap_sg(&ihost->pdev->dev, sg, 1, DMA_TO_DEVICE); ihost 2951 drivers/scsi/isci/request.c sci_controller_complete_io(ihost, request->target_device, request); ihost 2959 drivers/scsi/isci/request.c ireq_done(ihost, request, task); ihost 3003 drivers/scsi/isci/request.c struct isci_host *ihost = ireq->owning_controller; ihost 3007 drivers/scsi/isci/request.c isci_request_io_request_complete(ihost, ireq, ihost 3010 drivers/scsi/isci/request.c isci_task_request_complete(ihost, ireq, ireq->sci_status); ihost 3071 drivers/scsi/isci/request.c sci_general_request_construct(struct isci_host *ihost, ihost 3087 drivers/scsi/isci/request.c sci_io_request_construct(struct isci_host *ihost, ihost 3095 drivers/scsi/isci/request.c sci_general_request_construct(ihost, idev, ireq); ihost 3114 drivers/scsi/isci/request.c enum sci_status sci_task_request_construct(struct isci_host *ihost, ihost 3122 drivers/scsi/isci/request.c sci_general_request_construct(ihost, idev, ireq); ihost 3340 drivers/scsi/isci/request.c static enum sci_status isci_io_request_build(struct isci_host *ihost, ihost 3347 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 3364 drivers/scsi/isci/request.c &ihost->pdev->dev, ihost 3374 drivers/scsi/isci/request.c status = sci_io_request_construct(ihost, idev, request); ihost 3377 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 3396 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 3404 drivers/scsi/isci/request.c static struct isci_request *isci_request_from_tag(struct isci_host *ihost, u16 tag) ihost 3408 drivers/scsi/isci/request.c ireq = ihost->reqs[ISCI_TAG_TCI(tag)]; ihost 3417 drivers/scsi/isci/request.c static struct isci_request *isci_io_request_from_tag(struct isci_host *ihost, ihost 3423 drivers/scsi/isci/request.c ireq = isci_request_from_tag(ihost, tag); ihost 3431 drivers/scsi/isci/request.c struct isci_request *isci_tmf_request_from_tag(struct isci_host *ihost, ihost 3437 drivers/scsi/isci/request.c ireq = isci_request_from_tag(ihost, tag); ihost 3444 drivers/scsi/isci/request.c int isci_request_execute(struct isci_host *ihost, struct isci_remote_device *idev, ihost 3453 drivers/scsi/isci/request.c ireq = isci_io_request_from_tag(ihost, task, tag); ihost 3455 drivers/scsi/isci/request.c status = isci_io_request_build(ihost, ireq, idev); ihost 3457 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 3464 drivers/scsi/isci/request.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 3476 drivers/scsi/isci/request.c status = sci_controller_start_task(ihost, ihost 3484 drivers/scsi/isci/request.c status = sci_controller_start_io(ihost, idev, ihost 3490 drivers/scsi/isci/request.c dev_dbg(&ihost->pdev->dev, ihost 3493 drivers/scsi/isci/request.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 3506 drivers/scsi/isci/request.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 290 drivers/scsi/isci/request.h struct isci_request *isci_tmf_request_from_tag(struct isci_host *ihost, ihost 293 drivers/scsi/isci/request.h int isci_request_execute(struct isci_host *ihost, struct isci_remote_device *idev, ihost 296 drivers/scsi/isci/request.h sci_task_request_construct(struct isci_host *ihost, ihost 76 drivers/scsi/isci/task.c static void isci_task_refuse(struct isci_host *ihost, struct sas_task *task, ihost 84 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, "%s: task = %p, response=%d, status=%d\n", ihost 126 drivers/scsi/isci/task.c struct isci_host *ihost = dev_to_ihost(task->dev); ihost 133 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 136 drivers/scsi/isci/task.c tag = isci_alloc_tag(ihost); ihost 137 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 139 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 145 drivers/scsi/isci/task.c isci_task_refuse(ihost, task, SAS_TASK_UNDELIVERED, ihost 151 drivers/scsi/isci/task.c isci_task_refuse(ihost, task, SAS_TASK_COMPLETE, ihost 161 drivers/scsi/isci/task.c isci_task_refuse(ihost, task, ihost 169 drivers/scsi/isci/task.c status = isci_request_execute(ihost, idev, task, tag); ihost 181 drivers/scsi/isci/task.c isci_task_refuse(ihost, task, ihost 193 drivers/scsi/isci/task.c isci_task_refuse(ihost, task, ihost 202 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 206 drivers/scsi/isci/task.c isci_tci_free(ihost, ISCI_TAG_TCI(tag)); ihost 207 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 214 drivers/scsi/isci/task.c static struct isci_request *isci_task_request_build(struct isci_host *ihost, ihost 222 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 228 drivers/scsi/isci/task.c ireq = isci_tmf_request_from_tag(ihost, isci_tmf, tag); ihost 233 drivers/scsi/isci/task.c status = sci_task_request_construct(ihost, idev, tag, ihost 237 drivers/scsi/isci/task.c dev_warn(&ihost->pdev->dev, ihost 256 drivers/scsi/isci/task.c static int isci_task_execute_tmf(struct isci_host *ihost, ihost 268 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 269 drivers/scsi/isci/task.c tag = isci_alloc_tag(ihost); ihost 270 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 281 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 287 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 295 drivers/scsi/isci/task.c ireq = isci_task_request_build(ihost, idev, tag, tmf); ihost 299 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 302 drivers/scsi/isci/task.c status = sci_controller_start_task(ihost, idev, ireq); ihost 305 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 310 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 313 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 316 drivers/scsi/isci/task.c isci_remote_device_resume_from_abort(ihost, idev); ihost 326 drivers/scsi/isci/task.c isci_remote_device_suspend_terminate(ihost, idev, ireq); ihost 329 drivers/scsi/isci/task.c isci_print_tmf(ihost, tmf); ihost 334 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 342 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 350 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 351 drivers/scsi/isci/task.c isci_tci_free(ihost, ISCI_TAG_TCI(tag)); ihost 352 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 414 drivers/scsi/isci/task.c struct isci_host *ihost = dev_to_ihost(dev); ihost 419 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 421 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 423 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 425 drivers/scsi/isci/task.c __func__, dev, ihost, idev); ihost 429 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, "%s: No dev\n", __func__); ihost 436 drivers/scsi/isci/task.c if (isci_remote_device_suspend_terminate(ihost, idev, NULL) ihost 448 drivers/scsi/isci/task.c ret = isci_task_send_lu_reset_sas(ihost, idev, lun); ihost 480 drivers/scsi/isci/task.c struct isci_host *ihost = dev_to_ihost(task->dev); ihost 494 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 508 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 510 drivers/scsi/isci/task.c dev_warn(&ihost->pdev->dev, ihost 541 drivers/scsi/isci/task.c dev_warn(&ihost->pdev->dev, ihost 547 drivers/scsi/isci/task.c if (isci_remote_device_suspend_terminate(ihost, idev, old_request) ihost 549 drivers/scsi/isci/task.c dev_warn(&ihost->pdev->dev, ihost 556 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 563 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 566 drivers/scsi/isci/task.c isci_remote_device_resume_from_abort(ihost, idev); ihost 568 drivers/scsi/isci/task.c dev_warn(&ihost->pdev->dev, ihost 595 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 599 drivers/scsi/isci/task.c ret = isci_task_execute_tmf(ihost, idev, &tmf, ihost 603 drivers/scsi/isci/task.c dev_warn(&ihost->pdev->dev, ihost 696 drivers/scsi/isci/task.c isci_task_request_complete(struct isci_host *ihost, ihost 703 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, ihost 724 drivers/scsi/isci/task.c sci_controller_complete_io(ihost, ireq->target_device, ireq); ihost 731 drivers/scsi/isci/task.c wake_up_all(&ihost->eventq); ihost 734 drivers/scsi/isci/task.c isci_free_tag(ihost, ireq->io_tag); ihost 741 drivers/scsi/isci/task.c static int isci_reset_device(struct isci_host *ihost, ihost 749 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, "%s: idev %p\n", __func__, idev); ihost 752 drivers/scsi/isci/task.c if (isci_remote_device_suspend_terminate(ihost, idev, NULL) ihost 765 drivers/scsi/isci/task.c struct isci_phy *iphy = &ihost->phys[phy->number]; ihost 767 drivers/scsi/isci/task.c reset_stat = isci_port_perform_hard_reset(ihost, iport, ihost 773 drivers/scsi/isci/task.c isci_remote_device_resume_from_abort(ihost, idev); ihost 775 drivers/scsi/isci/task.c dev_dbg(&ihost->pdev->dev, "%s: idev %p complete, reset_stat=%d.\n", ihost 784 drivers/scsi/isci/task.c struct isci_host *ihost = dev_to_ihost(dev); ihost 789 drivers/scsi/isci/task.c spin_lock_irqsave(&ihost->scic_lock, flags); ihost 791 drivers/scsi/isci/task.c spin_unlock_irqrestore(&ihost->scic_lock, flags); ihost 801 drivers/scsi/isci/task.c ret = isci_reset_device(ihost, dev, idev); ihost 99 drivers/scsi/isci/task.h static inline void isci_print_tmf(struct isci_host *ihost, struct isci_tmf *tmf) ihost 102 drivers/scsi/isci/task.h dev_dbg(&ihost->pdev->dev, ihost 111 drivers/scsi/isci/task.h dev_dbg(&ihost->pdev->dev, ihost 60 drivers/scsi/isci/unsolicited_frame_control.c void sci_unsolicited_frame_control_construct(struct isci_host *ihost) ihost 62 drivers/scsi/isci/unsolicited_frame_control.c struct sci_unsolicited_frame_control *uf_control = &ihost->uf_control; ihost 64 drivers/scsi/isci/unsolicited_frame_control.c dma_addr_t dma = ihost->ufi_dma; ihost 65 drivers/scsi/isci/unsolicited_frame_control.c void *virt = ihost->ufi_buf; ihost 266 drivers/scsi/isci/unsolicited_frame_control.h void sci_unsolicited_frame_control_construct(struct isci_host *ihost); ihost 89 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 91 drivers/scsi/libiscsi.c if (ihost->workq) ihost 92 drivers/scsi/libiscsi.c queue_work(ihost->workq, &conn->xmitwork); ihost 661 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(session->host); ihost 741 drivers/scsi/libiscsi.c if (!ihost->workq) { ihost 1638 drivers/scsi/libiscsi.c struct iscsi_host *ihost; ihost 1647 drivers/scsi/libiscsi.c ihost = shost_priv(host); ihost 1725 drivers/scsi/libiscsi.c if (!ihost->workq) { ihost 1904 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 1907 drivers/scsi/libiscsi.c if (ihost->workq) ihost 1908 drivers/scsi/libiscsi.c flush_workqueue(ihost->workq); ihost 2620 drivers/scsi/libiscsi.c struct iscsi_host *ihost; ihost 2625 drivers/scsi/libiscsi.c ihost = shost_priv(shost); ihost 2628 drivers/scsi/libiscsi.c snprintf(ihost->workq_name, sizeof(ihost->workq_name), ihost 2630 drivers/scsi/libiscsi.c ihost->workq = create_singlethread_workqueue(ihost->workq_name); ihost 2631 drivers/scsi/libiscsi.c if (!ihost->workq) ihost 2635 drivers/scsi/libiscsi.c spin_lock_init(&ihost->lock); ihost 2636 drivers/scsi/libiscsi.c ihost->state = ISCSI_HOST_SETUP; ihost 2637 drivers/scsi/libiscsi.c ihost->num_sessions = 0; ihost 2638 drivers/scsi/libiscsi.c init_waitqueue_head(&ihost->session_removal_wq); ihost 2661 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 2664 drivers/scsi/libiscsi.c spin_lock_irqsave(&ihost->lock, flags); ihost 2665 drivers/scsi/libiscsi.c ihost->state = ISCSI_HOST_REMOVED; ihost 2666 drivers/scsi/libiscsi.c spin_unlock_irqrestore(&ihost->lock, flags); ihost 2669 drivers/scsi/libiscsi.c wait_event_interruptible(ihost->session_removal_wq, ihost 2670 drivers/scsi/libiscsi.c ihost->num_sessions == 0); ihost 2675 drivers/scsi/libiscsi.c if (ihost->workq) ihost 2676 drivers/scsi/libiscsi.c destroy_workqueue(ihost->workq); ihost 2682 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 2684 drivers/scsi/libiscsi.c kfree(ihost->netdev); ihost 2685 drivers/scsi/libiscsi.c kfree(ihost->hwaddress); ihost 2686 drivers/scsi/libiscsi.c kfree(ihost->initiatorname); ihost 2693 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 2704 drivers/scsi/libiscsi.c spin_lock_irqsave(&ihost->lock, flags); ihost 2705 drivers/scsi/libiscsi.c ihost->num_sessions--; ihost 2706 drivers/scsi/libiscsi.c if (ihost->num_sessions == 0) ihost 2707 drivers/scsi/libiscsi.c wake_up(&ihost->session_removal_wq); ihost 2708 drivers/scsi/libiscsi.c spin_unlock_irqrestore(&ihost->lock, flags); ihost 2734 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 2740 drivers/scsi/libiscsi.c spin_lock_irqsave(&ihost->lock, flags); ihost 2741 drivers/scsi/libiscsi.c if (ihost->state == ISCSI_HOST_REMOVED) { ihost 2742 drivers/scsi/libiscsi.c spin_unlock_irqrestore(&ihost->lock, flags); ihost 2745 drivers/scsi/libiscsi.c ihost->num_sessions++; ihost 2746 drivers/scsi/libiscsi.c spin_unlock_irqrestore(&ihost->lock, flags); ihost 3599 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 3604 drivers/scsi/libiscsi.c len = sprintf(buf, "%s\n", ihost->netdev); ihost 3607 drivers/scsi/libiscsi.c len = sprintf(buf, "%s\n", ihost->hwaddress); ihost 3610 drivers/scsi/libiscsi.c len = sprintf(buf, "%s\n", ihost->initiatorname); ihost 3623 drivers/scsi/libiscsi.c struct iscsi_host *ihost = shost_priv(shost); ihost 3627 drivers/scsi/libiscsi.c return iscsi_switch_str_param(&ihost->netdev, buf); ihost 3629 drivers/scsi/libiscsi.c return iscsi_switch_str_param(&ihost->hwaddress, buf); ihost 3631 drivers/scsi/libiscsi.c return iscsi_switch_str_param(&ihost->initiatorname, buf); ihost 1866 drivers/scsi/qla4xxx/ql4_os.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1885 drivers/scsi/qla4xxx/ql4_os.c ihost->port_speed = speed; ihost 1891 drivers/scsi/qla4xxx/ql4_os.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1897 drivers/scsi/qla4xxx/ql4_os.c ihost->port_state = state; ihost 1541 drivers/scsi/scsi_transport_iscsi.c iscsi_bsg_host_add(struct Scsi_Host *shost, struct iscsi_cls_host *ihost) ihost 1560 drivers/scsi/scsi_transport_iscsi.c ihost->bsg_q = q; ihost 1568 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1570 drivers/scsi/scsi_transport_iscsi.c memset(ihost, 0, sizeof(*ihost)); ihost 1571 drivers/scsi/scsi_transport_iscsi.c atomic_set(&ihost->nr_scans, 0); ihost 1572 drivers/scsi/scsi_transport_iscsi.c mutex_init(&ihost->mutex); ihost 1574 drivers/scsi/scsi_transport_iscsi.c iscsi_bsg_host_add(shost, ihost); ihost 1584 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1586 drivers/scsi/scsi_transport_iscsi.c bsg_remove_queue(ihost->bsg_q); ihost 1770 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1775 drivers/scsi/scsi_transport_iscsi.c return !atomic_read(&ihost->nr_scans); ihost 1791 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost; ihost 1803 drivers/scsi/scsi_transport_iscsi.c ihost = shost->shost_data; ihost 1805 drivers/scsi/scsi_transport_iscsi.c mutex_lock(&ihost->mutex); ihost 1824 drivers/scsi/scsi_transport_iscsi.c mutex_unlock(&ihost->mutex); ihost 1848 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1857 drivers/scsi/scsi_transport_iscsi.c atomic_dec(&ihost->nr_scans); ihost 1929 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 1950 drivers/scsi/scsi_transport_iscsi.c atomic_inc(&ihost->nr_scans); ihost 2003 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 2010 drivers/scsi/scsi_transport_iscsi.c mutex_lock(&ihost->mutex); ihost 2014 drivers/scsi/scsi_transport_iscsi.c mutex_unlock(&ihost->mutex); ihost 2021 drivers/scsi/scsi_transport_iscsi.c mutex_unlock(&ihost->mutex); ihost 4335 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 4336 drivers/scsi/scsi_transport_iscsi.c uint32_t port_speed = ihost->port_speed; ihost 4361 drivers/scsi/scsi_transport_iscsi.c struct iscsi_cls_host *ihost = shost->shost_data; ihost 4362 drivers/scsi/scsi_transport_iscsi.c uint32_t port_state = ihost->port_state;