This reverts commit a7faf81d7858b504279713d6cb98053f0ff00082.
Signed-off-by: Yufen Yu yuyufen@huawei.com --- drivers/scsi/megaraid/megaraid_sas_base.c | 5 +---- drivers/scsi/megaraid/megaraid_sas_fusion.h | 17 +++-------------- 2 files changed, 4 insertions(+), 18 deletions(-)
diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c index cc45cdac1384..05927bcd306e 100644 --- a/drivers/scsi/megaraid/megaraid_sas_base.c +++ b/drivers/scsi/megaraid/megaraid_sas_base.c @@ -1892,10 +1892,6 @@ void megasas_set_dynamic_target_properties(struct scsi_device *sdev,
mr_device_priv_data->is_tm_capable = raid->capability.tmCapable; - - if (!raid->flags.isEPD) - sdev->no_write_same = 1; - } else if (instance->use_seqnum_jbod_fp) { pd_index = (sdev->channel * MEGASAS_MAX_DEV_PER_CHANNEL) + sdev->id; @@ -3429,6 +3425,7 @@ static struct scsi_host_template megasas_template = { .bios_param = megasas_bios_param, .change_queue_depth = scsi_change_queue_depth, .max_segment_size = 0xffffffff, + .no_write_same = 1, };
/** diff --git a/drivers/scsi/megaraid/megaraid_sas_fusion.h b/drivers/scsi/megaraid/megaraid_sas_fusion.h index d57ecc7f88d8..dd2e37e40d6b 100644 --- a/drivers/scsi/megaraid/megaraid_sas_fusion.h +++ b/drivers/scsi/megaraid/megaraid_sas_fusion.h @@ -865,20 +865,9 @@ struct MR_LD_RAID { u8 regTypeReqOnRead; __le16 seqNum;
-struct { -#ifndef MFI_BIG_ENDIAN - u32 ldSyncRequired:1; - u32 regTypeReqOnReadIsValid:1; - u32 isEPD:1; - u32 enableSLDOnAllRWIOs:1; - u32 reserved:28; -#else - u32 reserved:28; - u32 enableSLDOnAllRWIOs:1; - u32 isEPD:1; - u32 regTypeReqOnReadIsValid:1; - u32 ldSyncRequired:1; -#endif + struct { + u32 ldSyncRequired:1; + u32 reserved:31; } flags;
u8 LUN[8]; /* 0x24 8 byte LUN field used for SCSI IO's */