Skip to contentSkip to conversation

qla4: fix shift precedence (sparse warning)

PATCH New Randy Dunlap 1 participant 1 message Feb 24, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 qla4: fix shift precedence (sparse warning)

From: Randy Dunlap <[email protected]>

Fix qla4xxx sparse warning:

drivers/scsi/qla4xxx/ql4_mbx.c:470:66: warning: right shift by bigger than source value

Cc Karen Higgins <[email protected]>
Cc David C Somayajulu <[email protected]>
---
 drivers/scsi/qla4xxx/ql4_mbx.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/qla4xxx/ql4_mbx.c +1 -1
@@ -467,7 +467,7 @@ int qla4xxx_get_fwddb_entry(struct scsi_
 	if (conn_err_detail)
 		*conn_err_detail = mbox_sts[5];
 	if (tcp_source_port_num)
-		*tcp_source_port_num = (uint16_t) mbox_sts[6] >> 16;
+		*tcp_source_port_num = (uint16_t) (mbox_sts[6] >> 16);
 	if (connection_id)
 		*connection_id = (uint16_t) mbox_sts[6] & 0x00FF;
 	status = QLA_SUCCESS;