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

Commit 3189b067 authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Nicholas Bellinger
Browse files

target: pack struct se_task more tightly



Rearrange the fields in se_task to avoid holes.  Also increase the
flags field to 16 bits as we have the space for it, and this makes
adding new flags safer.

Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarNicholas Bellinger <nab@linux-iscsi.org>
parent 04629b7b
Loading
Loading
Loading
Loading
+15 −15
Original line number Diff line number Diff line
@@ -402,24 +402,24 @@ struct se_queue_obj {
} ____cacheline_aligned;

struct se_task {
	unsigned char	task_sense;
	unsigned long long	task_lba;
	u32			task_sectors;
	u32			task_size;
	struct se_cmd		*task_se_cmd;
	struct scatterlist	*task_sg;
	u32		task_sg_nents;
	struct scatterlist	*task_sg_bidi;
	u32			task_sg_nents;
	u16			task_flags;
	u8			task_sense;
	u8			task_scsi_status;
	u8		task_flags;
	int			task_error_status;
	unsigned long long	task_lba;
	u32		task_sectors;
	u32		task_size;
	enum dma_data_direction	task_data_direction;
	struct se_cmd *task_se_cmd;
	struct completion	task_stop_comp;
	atomic_t		task_state_active;
	struct timer_list	task_timer;
	struct list_head	t_list;
	struct list_head	t_execute_list;
	struct list_head	t_state_list;
	struct completion	task_stop_comp;
} ____cacheline_aligned;

struct se_cmd {