Print this page
Code review comments

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/io/mr_sas/mr_sas_tbolt.c
          +++ new/usr/src/uts/common/io/mr_sas/mr_sas_tbolt.c
↓ open down ↓ 543 lines elided ↑ open up ↑
 544  544                      instance->reply_desc_dma_obj);
 545  545                  instance->reply_desc_dma_obj.status = DMA_OBJ_FREED;
 546  546          }
 547  547  
 548  548          return (DDI_FAILURE);
 549  549  }
 550  550  
 551  551  /*
 552  552   * mrsas_alloc_cmd_pool_tbolt
 553  553   *
 554      - * TODO: merge tbolt-specific codee into mrsas_alloc_cmd_pool() to have single
      554 + * TODO: merge tbolt-specific code into mrsas_alloc_cmd_pool() to have single
 555  555   * routine
 556  556   */
 557  557  int
 558  558  mrsas_alloc_cmd_pool_tbolt(struct mrsas_instance *instance)
 559  559  {
 560  560          int             i;
 561  561          int             count;
 562  562          uint32_t        max_cmd;
 563  563          uint32_t        reserve_cmd;
 564  564          size_t          sz;
↓ open down ↓ 2227 lines elided ↑ open up ↑
2792 2792                                              "tbolt_process_outstanding_cmd:"
2793 2793                                              "mlist_del_init(&cmd->list).\n"));
2794 2794                                          mlist_del_init(&cmd->list);
2795 2795                                  }
2796 2796                          }
2797 2797  
2798 2798                          mutex_exit(&instance->cmd_pend_mtx);
2799 2799  
2800 2800                          tbolt_complete_cmd(instance, cmd);
2801 2801                  }
2802      -                /* set it back to all 0xfffffffff. */
2803      -                desc->Words = (uint64_t)~0;
     2802 +                /* set it back to all 1s. */
     2803 +                desc->Words = -1LL;
2804 2804  
2805 2805                  instance->reply_read_index++;
2806 2806  
2807 2807                  if (instance->reply_read_index >= (instance->reply_q_depth)) {
2808 2808                          con_log(CL_ANN1, (CE_NOTE, "wrap around"));
2809 2809                          instance->reply_read_index = 0;
2810 2810                  }
2811 2811  
2812 2812                  /* Get the next reply descriptor */
2813 2813                  if (!instance->reply_read_index)
↓ open down ↓ 980 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX