Skip to contentSkip to conversation

scsi: myrs: only build on little-endian platforms

PATCH Applied Arnd Bergmann 3 participants 3 messages Nov 2, 2018 – Nov 6, 2018 SCSI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scsi: myrs: only build on little-endian platforms

Reading throught the new driver, I noticed that this cannot work on big-endian CPUs, and the old DAC960 had exactly the same behavior.

To document this for the future, add a Kconfig dependency that prevents it from being included in big-endian kernels. Since the hardware is really old and we never had a working driver on it for big-endian platforms, it's unlikely to make a difference to users.

---
 drivers/scsi/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/scsi/Kconfig +1 -0
index f07444d30b21..640cd1b31a18 100644
@@ -578,6 +578,7 @@ config SCSI_MYRB
 config SCSI_MYRS
 	tristate "Mylex DAC960/DAC1100 PCI RAID Controller (SCSI Interface)"
 	depends on PCI
+	depends on !CPU_BIG_ENDIAN || COMPILE_TEST
 	select RAID_ATTRS
 	help
 	  This driver adds support for the Mylex DAC960, AcceleRAID, and
Signature · 1 line
2.18.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 19 lines · Arnd Bergmann

Reading throught the new driver, I noticed that this cannot work on big-endian CPUs, and the old DAC960 had exactly the same behavior.

To document this for the future, add a Kconfig dependency that prevents it from being included in big-endian kernels. Since the hardware is really old and we never had a working driver on it for big-endian platforms, it's unlikely to make a difference to users.

---
  drivers/scsi/Kconfig | 1 +
  1 file changed, 1 insertion(+)
drivers/scsi/Kconfig +0 -0
index f07444d30b21..640cd1b31a18 100644

drivers/scsi/Kconfig config SCSI_MYRB · line 584

Quoted 7 lines
drivers/scsi/Kconfig +1 -0
@@ -578,6 +578,7 @@ config SCSI_MYRB
  config SCSI_MYRS
  	tristate "Mylex DAC960/DAC1100 PCI RAID Controller (SCSI Interface)"
  	depends on PCI
+	depends on !CPU_BIG_ENDIAN || COMPILE_TEST
  	select RAID_ATTRS
  	help
  	  This driver adds support for the Mylex DAC960, AcceleRAID, and

Cheers,

Hannes

Signature · 5 lines
Dr. Hannes Reinecke		   Teamlead Storage & Networking
[email protected]			               +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton
HRB 21284 (AG Nürnberg)
#2 lore raw
In reply to Arnd Bergmann

Arnd,

Quoted 7 lines

Reading throught the new driver, I noticed that this cannot work on big-endian CPUs, and the old DAC960 had exactly the same behavior.

To document this for the future, add a Kconfig dependency that prevents it from being included in big-endian kernels. Since the hardware is really old and we never had a working driver on it for big-endian platforms, it's unlikely to make a difference to users.

Applied to 4.20/scsi-fixes. Thank you!

Signature · 1 line
Martin K. Petersen	Oracle Linux Engineering