Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 229280
b: refs/heads/master
c: f2d255a
h: refs/heads/master
v: v3
  • Loading branch information
Mike Marciniszyn authored and Roland Dreier committed Jan 11, 2011
1 parent 38c68a7 commit fe4b71c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: dd04e43d46ad7a4e625a9ff3b270dc0db9abe81d
refs/heads/master: f2d255a0787119f7f4dc0e6093a0bd2700a49402
26 changes: 23 additions & 3 deletions trunk/drivers/infiniband/hw/qib/qib_iba7322.c
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,7 @@ struct qib_chippport_specific {
u8 ibmalfusesnap;
struct qib_qsfp_data qsfp_data;
char epmsgbuf[192]; /* for port error interrupt msg buffer */
u8 bounced;
};

static struct {
Expand Down Expand Up @@ -1742,6 +1743,8 @@ static void handle_serdes_issues(struct qib_pportdata *ppd, u64 ibcst)
}
}

static int qib_7322_set_ib_cfg(struct qib_pportdata *, int, u32);

/*
* This is per-pport error handling.
* will likely get it's own MSIx interrupt (one for each port,
Expand Down Expand Up @@ -1878,7 +1881,23 @@ static noinline void handle_7322_p_errors(struct qib_pportdata *ppd)
IB_PHYSPORTSTATE_DISABLED)
qib_set_ib_7322_lstate(ppd, 0,
QLOGIC_IB_IBCC_LINKINITCMD_DISABLE);
else
else {
u32 lstate;
/*
* We need the current logical link state before
* lflags are set in handle_e_ibstatuschanged.
*/
lstate = qib_7322_iblink_state(ibcs);

if (IS_QMH(dd) && !ppd->cpspec->bounced &&
ltstate == IB_PHYSPORTSTATE_LINKUP &&
(lstate >= IB_PORT_INIT &&
lstate <= IB_PORT_ACTIVE)) {
ppd->cpspec->bounced = 1;
qib_7322_set_ib_cfg(ppd, QIB_IB_CFG_LSTATE,
IB_LINKCMD_DOWN | IB_LINKINITCMD_POLL);
}

/*
* Since going into a recovery state causes the link
* state to go down and since recovery is transitory,
Expand All @@ -1892,6 +1911,7 @@ static noinline void handle_7322_p_errors(struct qib_pportdata *ppd)
ltstate != IB_PHYSPORTSTATE_RECOVERY_WAITRMT &&
ltstate != IB_PHYSPORTSTATE_RECOVERY_IDLE)
qib_handle_e_ibstatuschanged(ppd, ibcs);
}
}
if (*msg && iserr)
qib_dev_porterr(dd, ppd->port, "%s error\n", msg);
Expand Down Expand Up @@ -7282,8 +7302,8 @@ static void ibsd_wr_allchans(struct qib_pportdata *ppd, int addr, unsigned data,
static void serdes_7322_los_enable(struct qib_pportdata *ppd, int enable)
{
u64 data = qib_read_kreg_port(ppd, krp_serdesctrl);
printk(KERN_INFO QIB_DRV_NAME " Turning LOS %s for port %d\n",
(enable ? "on" : "off"), ppd->port);
printk(KERN_INFO QIB_DRV_NAME " IB%u:%u Turning LOS %s\n",
ppd->dd->unit, ppd->port, (enable ? "on" : "off"));
if (enable)
data |= SYM_MASK(IBSerdesCtrl_0, RXLOSEN);
else
Expand Down

0 comments on commit fe4b71c

Please sign in to comment.