History

nvmet-fc: remove target cpu scheduling flag

Remove NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED. It's unnecessary.

James Smart committed 9 years ago

Commit 4b8ba5f1 parent 2952a874 files · +3 −15Browse files

Unified · Split

4 files
  1. drivers/nvme/target/fc.c +1 −3
  2. drivers/nvme/target/fcloop.c +0 −1
  3. drivers/scsi/lpfc/lpfc_nvmet.c +0 −1
  4. include/linux/nvme-fc-driver.h +2 −10
drivers/nvme/target/fc.c+1−3
@@ -517,9 +517,7 @@ nvmet_fc_queue_to_cpu(struct nvmet_fc_tgtport *tgtport, int qid) · 516 unmodified lines
517{517{
518 int cpu, idx, cnt;518 int cpu, idx, cnt;
519 519
520 if (!(tgtport->ops->target_features &520 if (tgtport->ops->max_hw_queues == 1)
521 NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED) ||
522 tgtport->ops->max_hw_queues == 1)
523 return WORK_CPU_UNBOUND;521 return WORK_CPU_UNBOUND;
524 522
525 /* Simple cpu selection based on qid modulo active cpu count */523 /* Simple cpu selection based on qid modulo active cpu count */
drivers/nvme/target/fcloop.c+0−1
@@ -698,7 +698,6 @@ static struct nvmet_fc_target_template tgttemplate = { · 697 unmodified lines
698 .dma_boundary = FCLOOP_DMABOUND_4G,698 .dma_boundary = FCLOOP_DMABOUND_4G,
699 /* optional features */699 /* optional features */
700 .target_features = NVMET_FCTGTFEAT_CMD_IN_ISR |700 .target_features = NVMET_FCTGTFEAT_CMD_IN_ISR |
701 NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED |
702 NVMET_FCTGTFEAT_OPDONE_IN_ISR,701 NVMET_FCTGTFEAT_OPDONE_IN_ISR,
703 /* sizes of additional private data for data structures */702 /* sizes of additional private data for data structures */
704 .target_priv_sz = sizeof(struct fcloop_tport),703 .target_priv_sz = sizeof(struct fcloop_tport),
drivers/scsi/lpfc/lpfc_nvmet.c+0−1
@@ -764,7 +764,6 @@ lpfc_nvmet_create_targetport(struct lpfc_hba *phba) · 763 unmodified lines
764 lpfc_tgttemplate.max_sgl_segments = phba->cfg_nvme_seg_cnt + 1;764 lpfc_tgttemplate.max_sgl_segments = phba->cfg_nvme_seg_cnt + 1;
765 lpfc_tgttemplate.max_hw_queues = phba->cfg_nvme_io_channel;765 lpfc_tgttemplate.max_hw_queues = phba->cfg_nvme_io_channel;
766 lpfc_tgttemplate.target_features = NVMET_FCTGTFEAT_READDATA_RSP |766 lpfc_tgttemplate.target_features = NVMET_FCTGTFEAT_READDATA_RSP |
767 NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED |
768 NVMET_FCTGTFEAT_CMD_IN_ISR |767 NVMET_FCTGTFEAT_CMD_IN_ISR |
769 NVMET_FCTGTFEAT_OPDONE_IN_ISR;768 NVMET_FCTGTFEAT_OPDONE_IN_ISR;
770 769
include/linux/nvme-fc-driver.h+2−10
@@ -642,15 +642,7 @@ enum { · 641 unmodified lines
642 * sequence in one LLDD operation. Errors during Data642 * sequence in one LLDD operation. Errors during Data
643 * sequence transmit must not allow RSP sequence to be sent.643 * sequence transmit must not allow RSP sequence to be sent.
644 */644 */
645 NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED = (1 << 1),645 NVMET_FCTGTFEAT_CMD_IN_ISR = (1 << 1),
646 /* Bit 1: When 0, the LLDD will deliver FCP CMD
647 * on the CPU it should be affinitized to. Thus work will
648 * be scheduled on the cpu received on. When 1, the LLDD
649 * may not deliver the CMD on the CPU it should be worked
650 * on. The transport should pick a cpu to schedule the work
651 * on.
652 */
653 NVMET_FCTGTFEAT_CMD_IN_ISR = (1 << 2),
654 /* Bit 2: When 0, the LLDD is calling the cmd rcv handler646 /* Bit 2: When 0, the LLDD is calling the cmd rcv handler
655 * in a non-isr context, allowing the transport to finish647 * in a non-isr context, allowing the transport to finish
656 * op completion in the calling context. When 1, the LLDD648 * op completion in the calling context. When 1, the LLDD
@@ -658,7 +650,7 @@ enum { · 1 unmodified line
658 * requiring the transport to transition to a workqueue650 * requiring the transport to transition to a workqueue
659 * for op completion.651 * for op completion.
660 */652 */
661 NVMET_FCTGTFEAT_OPDONE_IN_ISR = (1 << 3),653 NVMET_FCTGTFEAT_OPDONE_IN_ISR = (1 << 2),
662 /* Bit 3: When 0, the LLDD is calling the op done handler654 /* Bit 3: When 0, the LLDD is calling the op done handler
663 * in a non-isr context, allowing the transport to finish655 * in a non-isr context, allowing the transport to finish
664 * op completion in the calling context. When 1, the LLDD656 * op completion in the calling context. When 1, the LLDD