From: Chad Dupuis <cdupuis@redhat.com> Date: Tue, 3 Aug 2010 13:50:47 -0400 Subject: [net] netxen: fix bios version calculation Message-id: <20100803134803.2239.89240.sendpatchset@localhost.localdomain> Patchwork-id: 27328 O-Subject: [RHEL 5.6 PATCH 26/44] netxen: fix bios version calculation Bugzilla: 562937 RH-Acked-by: David S. Miller <davem@redhat.com> RH-Acked-by: Neil Horman <nhorman@redhat.com> Bugzilla ======== 562937 Upstream Status =============== net-2.6 commit id bb2792e0383793d5135ba777e93f0a918371394b Description =========== >From 2c1175f89bbfbd8dd887035d4db6b83dbbdda501 Mon Sep 17 00:00:00 2001 From: Amit Kumar Salecha <amit.salecha@qlogic.com> Date: Fri, 26 Mar 2010 00:30:07 +0000 Subject: [PATCH] netxen: fix bios version calculation Bios sub version from unified fw image is calculated incorrect. Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net> diff --git a/drivers/net/netxen/netxen_nic_init.c b/drivers/net/netxen/netxen_nic_init.c index 4129649..4eda1a6 100644 --- a/drivers/net/netxen/netxen_nic_init.c +++ b/drivers/net/netxen/netxen_nic_init.c @@ -761,7 +761,7 @@ nx_get_bios_version(struct netxen_adapter *adapter) if (adapter->fw_type == NX_UNIFIED_ROMIMAGE) { bios_ver = cpu_to_le32(*((u32 *) (&fw->data[prd_off]) + NX_UNI_BIOS_VERSION_OFF)); - return (bios_ver << 24) + ((bios_ver >> 8) & 0xff00) + + return (bios_ver << 16) + ((bios_ver >> 8) & 0xff00) + (bios_ver >> 24); } else return cpu_to_le32(*(u32 *)&fw->data[NX_BIOS_VERSION_OFFSET]);