From dc570ce83f5359352bb1850eb6d20810f6b3fa9b Mon Sep 17 00:00:00 2001 From: Ariel Elior Date: Mon, 23 Jan 2012 07:31:55 +0000 Subject: [PATCH] --- yaml --- r: 286703 b: refs/heads/master c: 65087cfee50595185f6bbf3d78272eeb34186d2b h: refs/heads/master i: 286701: 68e3a63320bd221ce03bf424146eb80553813228 286699: 98b21f6ec77dfb4f3c04f797dccc1c63b5388177 286695: aa77eb0818e37a7e201c59c5080159c731b19558 286687: c80059e3e5840959d014b16018c809155e1a3ae7 v: v3 --- [refs] | 2 +- trunk/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/[refs] b/[refs] index aa07b3844d2e..f3f20e7b77df 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 1fdf155158886514c82e5401ab7b1264beb375bf +refs/heads/master: 65087cfee50595185f6bbf3d78272eeb34186d2b diff --git a/trunk/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c b/trunk/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c index ffeaaa95ed96..f4c2fe52ab1c 100644 --- a/trunk/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c +++ b/trunk/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c @@ -10536,6 +10536,9 @@ static int __devinit bnx2x_init_dev(struct pci_dev *pdev, { struct bnx2x *bp; int rc; + bool chip_is_e1x = (board_type == BCM57710 || + board_type == BCM57711 || + board_type == BCM57711E); SET_NETDEV_DEV(dev, &pdev->dev); bp = netdev_priv(dev); @@ -10624,7 +10627,7 @@ static int __devinit bnx2x_init_dev(struct pci_dev *pdev, REG_WR(bp, PXP2_REG_PGL_ADDR_90_F0, 0); REG_WR(bp, PXP2_REG_PGL_ADDR_94_F0, 0); - if (CHIP_IS_E1x(bp)) { + if (chip_is_e1x) { REG_WR(bp, PXP2_REG_PGL_ADDR_88_F1, 0); REG_WR(bp, PXP2_REG_PGL_ADDR_8C_F1, 0); REG_WR(bp, PXP2_REG_PGL_ADDR_90_F1, 0); @@ -10635,9 +10638,7 @@ static int __devinit bnx2x_init_dev(struct pci_dev *pdev, * Enable internal target-read (in case we are probed after PF FLR). * Must be done prior to any BAR read access. Only for 57712 and up */ - if (board_type != BCM57710 && - board_type != BCM57711 && - board_type != BCM57711E) + if (!chip_is_e1x) REG_WR(bp, PGLUE_B_REG_INTERNAL_PFID_ENABLE_TARGET_READ, 1); /* Reset the load counter */