Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4b8ba5fa authored by James Smart's avatar James Smart Committed by Jens Axboe
Browse files

nvmet-fc: remove target cpu scheduling flag



Remove NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED. It's unnecessary.

Signed-off-by: default avatarJames Smart <james.smart@broadcom.com>
Reviewed-by: default avatarJohannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarJens Axboe <axboe@fb.com>
parent 2952a879
Loading
Loading
Loading
Loading
+1 −3
Original line number Original line Diff line number Diff line
@@ -517,9 +517,7 @@ nvmet_fc_queue_to_cpu(struct nvmet_fc_tgtport *tgtport, int qid)
{
{
	int cpu, idx, cnt;
	int cpu, idx, cnt;


	if (!(tgtport->ops->target_features &
	if (tgtport->ops->max_hw_queues == 1)
			NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED) ||
	    tgtport->ops->max_hw_queues == 1)
		return WORK_CPU_UNBOUND;
		return WORK_CPU_UNBOUND;


	/* Simple cpu selection based on qid modulo active cpu count */
	/* Simple cpu selection based on qid modulo active cpu count */
+0 −1
Original line number Original line Diff line number Diff line
@@ -698,7 +698,6 @@ static struct nvmet_fc_target_template tgttemplate = {
	.dma_boundary		= FCLOOP_DMABOUND_4G,
	.dma_boundary		= FCLOOP_DMABOUND_4G,
	/* optional features */
	/* optional features */
	.target_features	= NVMET_FCTGTFEAT_CMD_IN_ISR |
	.target_features	= NVMET_FCTGTFEAT_CMD_IN_ISR |
				  NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED |
				  NVMET_FCTGTFEAT_OPDONE_IN_ISR,
				  NVMET_FCTGTFEAT_OPDONE_IN_ISR,
	/* sizes of additional private data for data structures */
	/* sizes of additional private data for data structures */
	.target_priv_sz		= sizeof(struct fcloop_tport),
	.target_priv_sz		= sizeof(struct fcloop_tport),
+0 −1
Original line number Original line Diff line number Diff line
@@ -764,7 +764,6 @@ lpfc_nvmet_create_targetport(struct lpfc_hba *phba)
	lpfc_tgttemplate.max_sgl_segments = phba->cfg_nvme_seg_cnt + 1;
	lpfc_tgttemplate.max_sgl_segments = phba->cfg_nvme_seg_cnt + 1;
	lpfc_tgttemplate.max_hw_queues = phba->cfg_nvme_io_channel;
	lpfc_tgttemplate.max_hw_queues = phba->cfg_nvme_io_channel;
	lpfc_tgttemplate.target_features = NVMET_FCTGTFEAT_READDATA_RSP |
	lpfc_tgttemplate.target_features = NVMET_FCTGTFEAT_READDATA_RSP |
					   NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED |
					   NVMET_FCTGTFEAT_CMD_IN_ISR |
					   NVMET_FCTGTFEAT_CMD_IN_ISR |
					   NVMET_FCTGTFEAT_OPDONE_IN_ISR;
					   NVMET_FCTGTFEAT_OPDONE_IN_ISR;


+2 −10
Original line number Original line Diff line number Diff line
@@ -642,15 +642,7 @@ enum {
		 * sequence in one LLDD operation. Errors during Data
		 * sequence in one LLDD operation. Errors during Data
		 * sequence transmit must not allow RSP sequence to be sent.
		 * sequence transmit must not allow RSP sequence to be sent.
		 */
		 */
	NVMET_FCTGTFEAT_NEEDS_CMD_CPUSCHED = (1 << 1),
	NVMET_FCTGTFEAT_CMD_IN_ISR = (1 << 1),
		/* Bit 1: When 0, the LLDD will deliver FCP CMD
		 * on the CPU it should be affinitized to. Thus work will
		 * be scheduled on the cpu received on. When 1, the LLDD
		 * may not deliver the CMD on the CPU it should be worked
		 * on. The transport should pick a cpu to schedule the work
		 * on.
		 */
	NVMET_FCTGTFEAT_CMD_IN_ISR = (1 << 2),
		/* Bit 2: When 0, the LLDD is calling the cmd rcv handler
		/* Bit 2: When 0, the LLDD is calling the cmd rcv handler
		 * in a non-isr context, allowing the transport to finish
		 * in a non-isr context, allowing the transport to finish
		 * op completion in the calling context. When 1, the LLDD
		 * op completion in the calling context. When 1, the LLDD
@@ -658,7 +650,7 @@ enum {
		 * requiring the transport to transition to a workqueue
		 * requiring the transport to transition to a workqueue
		 * for op completion.
		 * for op completion.
		 */
		 */
	NVMET_FCTGTFEAT_OPDONE_IN_ISR = (1 << 3),
	NVMET_FCTGTFEAT_OPDONE_IN_ISR = (1 << 2),
		/* Bit 3: When 0, the LLDD is calling the op done handler
		/* Bit 3: When 0, the LLDD is calling the op done handler
		 * in a non-isr context, allowing the transport to finish
		 * in a non-isr context, allowing the transport to finish
		 * op completion in the calling context. When 1, the LLDD
		 * op completion in the calling context. When 1, the LLDD