Skip to content

Commit

Permalink
IB/ipath: Remove support for preproduction HTX InfiniPath cards
Browse files Browse the repository at this point in the history
Clean up some code by removing support for some older pre-production
HTX InfiniPath cards.

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
  • Loading branch information
Ralph Campbell authored and Roland Dreier committed Jul 10, 2007
1 parent 12f9a49 commit 9ca4865
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 48 deletions.
10 changes: 1 addition & 9 deletions drivers/infiniband/hw/ipath/ipath_driver.c
Original file line number Diff line number Diff line change
Expand Up @@ -1021,14 +1021,10 @@ void ipath_kreceive(struct ipath_devdata *dd)
goto bail;
}

/* There is already a thread processing this queue. */
if (test_and_set_bit(0, &dd->ipath_rcv_pending))
goto bail;

l = dd->ipath_port0head;
hdrqtail = (u32) le64_to_cpu(*dd->ipath_hdrqtailptr);
if (l == hdrqtail)
goto done;
goto bail;

reloop:
for (i = 0; l != hdrqtail; i++) {
Expand Down Expand Up @@ -1163,10 +1159,6 @@ void ipath_kreceive(struct ipath_devdata *dd)
ipath_stats.sps_avgpkts_call =
ipath_stats.sps_port0pkts / ++totcalls;

done:
clear_bit(0, &dd->ipath_rcv_pending);
smp_mb__after_clear_bit();

bail:;
}

Expand Down
39 changes: 11 additions & 28 deletions drivers/infiniband/hw/ipath/ipath_iba6110.c
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,12 @@ static int ipath_ht_boardname(struct ipath_devdata *dd, char *name,
if (n)
snprintf(name, namelen, "%s", n);

if (dd->ipath_boardrev != 6 && dd->ipath_boardrev != 7 &&
dd->ipath_boardrev != 11) {
ipath_dev_err(dd, "Unsupported InfiniPath board %s!\n", name);
ret = 1;
goto bail;
}
if (dd->ipath_majrev != 3 || (dd->ipath_minrev < 2 ||
dd->ipath_minrev > 4)) {
/*
Expand All @@ -694,36 +700,11 @@ static int ipath_ht_boardname(struct ipath_devdata *dd, char *name,
* copies
*/
dd->ipath_flags |= IPATH_32BITCOUNTERS;
dd->ipath_flags |= IPATH_GPIO_INTR;
if (dd->ipath_htspeed != 800)
ipath_dev_err(dd,
"Incorrectly configured for HT @ %uMHz\n",
dd->ipath_htspeed);
if (dd->ipath_boardrev == 7 || dd->ipath_boardrev == 11 ||
dd->ipath_boardrev == 6)
dd->ipath_flags |= IPATH_GPIO_INTR;
else
dd->ipath_flags |= IPATH_POLL_RX_INTR;
if (dd->ipath_boardrev == 8) { /* LS/X-1 */
u64 val;
val = ipath_read_kreg64(dd, dd->ipath_kregs->kr_extstatus);
if (val & INFINIPATH_EXTS_SERDESSEL) {
/*
* hardware disabled
*
* This means that the chip is hardware disabled,
* and will not be able to bring up the link,
* in any case. We special case this and abort
* early, to avoid later messages. We also set
* the DISABLED status bit
*/
ipath_dbg("Unit %u is hardware-disabled\n",
dd->ipath_unit);
*dd->ipath_statusp |= IPATH_STATUS_DISABLED;
/* this value is handled differently */
ret = 2;
goto bail;
}
}
ret = 0;

bail:
Expand Down Expand Up @@ -1574,8 +1555,10 @@ static int ipath_ht_early_init(struct ipath_devdata *dd)
* with 128, rather than 112.
*/
dd->ipath_flags |= IPATH_GPIO_INTR;
dd->ipath_flags &= ~IPATH_POLL_RX_INTR;
}
} else
ipath_dev_err(dd, "Unsupported InfiniPath serial "
"number %.16s!\n", dd->ipath_serial);

return 0;
}

Expand Down
4 changes: 0 additions & 4 deletions drivers/infiniband/hw/ipath/ipath_kernel.h
Original file line number Diff line number Diff line change
Expand Up @@ -391,9 +391,6 @@ struct ipath_devdata {
struct class_device *diag_class_dev;
/* timer used to prevent stats overflow, error throttling, etc. */
struct timer_list ipath_stats_timer;
/* check for stale messages in rcv queue */
/* only allow one intr at a time. */
unsigned long ipath_rcv_pending;
void *ipath_dummy_hdrq; /* used after port close */
dma_addr_t ipath_dummy_hdrq_phys;

Expand Down Expand Up @@ -740,7 +737,6 @@ int ipath_set_rx_pol_inv(struct ipath_devdata *dd, u8 new_pol_inv);
* are 64bit */
#define IPATH_32BITCOUNTERS 0x20000
/* can miss port0 rx interrupts */
#define IPATH_POLL_RX_INTR 0x40000
#define IPATH_DISABLED 0x80000 /* administratively disabled */
/* Use GPIO interrupts for new counters */
#define IPATH_GPIO_ERRINTRS 0x100000
Expand Down
7 changes: 0 additions & 7 deletions drivers/infiniband/hw/ipath/ipath_verbs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1375,13 +1375,6 @@ static void __verbs_timer(unsigned long arg)
{
struct ipath_devdata *dd = (struct ipath_devdata *) arg;

/*
* If port 0 receive packet interrupts are not available, or
* can be missed, poll the receive queue
*/
if (dd->ipath_flags & IPATH_POLL_RX_INTR)
ipath_kreceive(dd);

/* Handle verbs layer timeouts. */
ipath_ib_timer(dd->verbs_dev);

Expand Down

0 comments on commit 9ca4865

Please sign in to comment.