Print this page
10055 recursive mutex enter in ahci

Split
Expand all
Collapse all
          --- old/usr/src/uts/common/io/sata/adapters/ahci/ahci.c
          +++ new/usr/src/uts/common/io/sata/adapters/ahci/ahci.c
↓ open down ↓ 1195 lines elided ↑ open up ↑
1196 1196                   * will not generate interrupts or modify or access memory.
1197 1197                   */
1198 1198                  mutex_enter(&ahci_ctlp->ahcictl_mutex);
1199 1199                  if (ahci_ctlp->ahcictl_flags & AHCI_SUSPEND) {
1200 1200                          mutex_exit(&ahci_ctlp->ahcictl_mutex);
1201 1201                          return (DDI_SUCCESS);
1202 1202                  }
1203 1203  
1204 1204                  ahci_ctlp->ahcictl_flags |= AHCI_SUSPEND;
1205 1205  
1206      -                ahci_em_suspend(ahci_ctlp);
1207      -
1208 1206                  /* stop the watchdog handler */
1209 1207                  if (ahci_ctlp->ahcictl_timeout_id) {
1210 1208                          (void) untimeout(ahci_ctlp->ahcictl_timeout_id);
1211 1209                          ahci_ctlp->ahcictl_timeout_id = 0;
1212 1210                  }
1213 1211  
1214 1212                  mutex_exit(&ahci_ctlp->ahcictl_mutex);
1215 1213  
     1214 +                ahci_em_suspend(ahci_ctlp);
     1215 +
1216 1216                  /*
1217 1217                   * drain the taskq
1218 1218                   */
1219 1219                  ahci_drain_ports_taskq(ahci_ctlp);
1220 1220  
1221 1221                  /*
1222 1222                   * Disable the interrupts and stop all the ports.
1223 1223                   */
1224 1224                  ahci_uninitialize_controller(ahci_ctlp);
1225 1225  
↓ open down ↓ 9656 lines elided ↑ open up ↑