All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] qla2xxx: fix RSCN handling on big-endian systems
@ 2007-02-19 18:18 malahal
  2007-02-21 23:11 ` Seokmann Ju
  2007-02-23 22:51 ` Seokmann Ju
  0 siblings, 2 replies; 7+ messages in thread
From: malahal @ 2007-02-19 18:18 UTC (permalink / raw)
  To: linux-scsi, linux-driver

qla2xxx driver fails to handle RSCN events affecting area or domain due
to an endian issue on big endian systems.  This fixes the port_id_t
structure on big endian systems.

Signed-off-by: Malahal Naineni <malahal@us.ibm.com>

diff -r c860739bb0f4 drivers/scsi/qla2xxx/qla_def.h
--- a/drivers/scsi/qla2xxx/qla_def.h	Fri Feb 16 14:19:34 2007 -0800
+++ b/drivers/scsi/qla2xxx/qla_def.h	Fri Feb 16 14:21:29 2007 -0800
@@ -1478,14 +1478,17 @@ typedef union {
 	uint32_t b24 : 24;
 
 	struct {
-		uint8_t d_id[3];
-		uint8_t rsvd_1;
-	} r;
-
-	struct {
+#ifdef __BIG_ENDIAN
+		uint8_t domain;
+		uint8_t area;
+		uint8_t al_pa;
+#elif __LITTLE_ENDIAN
 		uint8_t al_pa;
 		uint8_t area;
 		uint8_t domain;
+#else
+#error "__BIG_ENDIAN or __LITTLE_ENDIAN must be defined!"
+#endif
 		uint8_t rsvd_1;
 	} b;
 } port_id_t;

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2007-02-23 22:51 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-19 18:18 [PATCH] qla2xxx: fix RSCN handling on big-endian systems malahal
2007-02-21 23:11 ` Seokmann Ju
2007-02-22  2:53   ` malahal
2007-02-22 14:04     ` Seokmann Ju
2007-02-22 19:08       ` malahal
2007-02-22 19:43         ` Seokmann Ju
2007-02-23 22:51 ` Seokmann Ju

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.