diff options
| author | Alan Duboff <Alan.Duboff@Sun.COM> | 2008-10-21 00:16:15 -0700 |
|---|---|---|
| committer | Alan Duboff <Alan.Duboff@Sun.COM> | 2008-10-21 00:16:15 -0700 |
| commit | 915ebf8da9f4ef3e7b2e34dd367f64d358a628d9 (patch) | |
| tree | ce1429f7104a532f7e1693a88d743b12b6c3a892 /usr/src | |
| parent | e5a7a30b42c34918b40930de0e02883a37ef0c3d (diff) | |
| download | illumos-joyent-915ebf8da9f4ef3e7b2e34dd367f64d358a628d9.tar.gz | |
6729383 sfe driver gets reset timeout panic on sparc
Diffstat (limited to 'usr/src')
| -rw-r--r-- | usr/src/uts/common/io/sfe/sfe.c | 20 | ||||
| -rw-r--r-- | usr/src/uts/common/io/sfe/sfe_mii.h | 1 | ||||
| -rw-r--r-- | usr/src/uts/common/io/sfe/sfe_util.c | 2 | ||||
| -rw-r--r-- | usr/src/uts/common/io/sfe/sfe_util.h | 10 | ||||
| -rw-r--r-- | usr/src/uts/common/io/sfe/sfereg.h | 2 |
5 files changed, 16 insertions, 19 deletions
diff --git a/usr/src/uts/common/io/sfe/sfe.c b/usr/src/uts/common/io/sfe/sfe.c index d364bb372b..8e4f2d0119 100644 --- a/usr/src/uts/common/io/sfe/sfe.c +++ b/usr/src/uts/common/io/sfe/sfe.c @@ -55,7 +55,7 @@ #include "sfe_util.h" #include "sfereg.h" -char ident[] = "sis900/dp83815 driver"; +char ident[] = "sis900/dp83815 driver v" "2.6.1t29os"; /* Debugging support */ #ifdef DEBUG_LEVEL @@ -537,7 +537,7 @@ sfe_reset_chip_sis900(struct gem_dev *dp) OUTL(dp, IMR, 0); lp->isr_pended |= INL(dp, ISR) & lp->our_intr_bits; - OUTL(dp, RFCR, 0); + OUTLINL(dp, RFCR, 0); OUTL(dp, CR, CR_RST | CR_TXR | CR_RXR); drv_usecwait(10); @@ -822,8 +822,8 @@ sfe_set_rx_filter_sis900(struct gem_dev *dp) DPRINTF(4, (CE_CONT, CONS "%s: %s: called", dp->name, __func__)); if ((dp->rxmode & RXMODE_ENABLE) == 0) { - /* disalbe rx filter */ - OUTL(dp, RFCR, 0); + /* disable rx filter */ + OUTLINL(dp, RFCR, 0); return (GEM_SUCCESS); } @@ -862,9 +862,9 @@ sfe_set_rx_filter_sis900(struct gem_dev *dp) /* Disable Rx filter and load mac address */ for (i = 0; i < ETHERADDRL/2; i++) { /* For sis900, index is in word */ - OUTL(dp, RFCR, + OUTLINL(dp, RFCR, (RFADDR_MAC_SIS900+i) << RFCR_RFADDR_SHIFT_SIS900); - OUTL(dp, RFDR, (mac[i*2+1] << 8) | mac[i*2]); + OUTLINL(dp, RFDR, (mac[i*2+1] << 8) | mac[i*2]); } bcopy(mac, lp->mac_addr, ETHERADDRL); @@ -873,13 +873,13 @@ sfe_set_rx_filter_sis900(struct gem_dev *dp) /* Load Multicast hash table */ for (i = 0; i < hash_size; i++) { /* For sis900, index is in word */ - OUTL(dp, RFCR, + OUTLINL(dp, RFCR, (RFADDR_MULTICAST_SIS900 + i) << RFCR_RFADDR_SHIFT_SIS900); - OUTL(dp, RFDR, hash_tbl[i]); + OUTLINL(dp, RFDR, hash_tbl[i]); } /* Load rx filter mode and enable rx filter */ - OUTL(dp, RFCR, RFCR_RFEN | mode); + OUTLINL(dp, RFCR, RFCR_RFEN | mode); return (GEM_SUCCESS); } @@ -2295,7 +2295,7 @@ sfedetach(dev_info_t *dip, ddi_detach_cmd_t cmd) */ /* ======================================================== */ DDI_DEFINE_STREAM_OPS(sfe_ops, nulldev, nulldev, sfeattach, sfedetach, - nodev, NULL, D_MP, NULL, ddi_quiesce_not_supported); + nodev, NULL, D_MP, NULL, ddi_quiesce_not_supported); static struct modldrv modldrv = { &mod_driverops, /* Type of module. This one is a driver */ diff --git a/usr/src/uts/common/io/sfe/sfe_mii.h b/usr/src/uts/common/io/sfe/sfe_mii.h index b31a2ace6d..d9dfa90d70 100644 --- a/usr/src/uts/common/io/sfe/sfe_mii.h +++ b/usr/src/uts/common/io/sfe/sfe_mii.h @@ -30,7 +30,6 @@ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * DAMAGE. */ -#pragma ident "%Z%%M% %I% %E% SMI" /* sfe device driver */ /* * sfe_mii.h : MII registers diff --git a/usr/src/uts/common/io/sfe/sfe_util.c b/usr/src/uts/common/io/sfe/sfe_util.c index 0afb5eab39..0d8f736d15 100644 --- a/usr/src/uts/common/io/sfe/sfe_util.c +++ b/usr/src/uts/common/io/sfe/sfe_util.c @@ -31,8 +31,6 @@ * DAMAGE. */ -#pragma ident "%Z%%M% %I% %E% SMI" /* sfe device driver */ - /* * System Header files. */ diff --git a/usr/src/uts/common/io/sfe/sfe_util.h b/usr/src/uts/common/io/sfe/sfe_util.h index 0ed3bbf9cd..576a3d5d08 100644 --- a/usr/src/uts/common/io/sfe/sfe_util.h +++ b/usr/src/uts/common/io/sfe/sfe_util.h @@ -31,8 +31,6 @@ * DAMAGE. */ -#pragma ident "%Z%%M% %I% %E% SMI" /* sfe device driver */ - #ifndef _SFE_UTIL_H_ #define _SFE_UTIL_H_ #include <sys/mac.h> @@ -66,9 +64,13 @@ typedef int32_t seqnum_t; #define OUTW(dp, p, v) \ ddi_put16((dp)->regs_handle, \ (void *)((caddr_t)((dp)->base_addr) + (p)), v) -#define OUTL(dp, p, v) \ +#define OUTL(dp, p, v) \ ddi_put32((dp)->regs_handle, \ - (void *)((caddr_t)((dp)->base_addr) + (p)), v) + (void *)((caddr_t)((dp)->base_addr) + (p)), v) +#define OUTLINL(dp, p, v) \ + ddi_put32((dp)->regs_handle, \ + (void *)((caddr_t)((dp)->base_addr) + (p)), v); \ + (void) INL((dp), (p)) #define INB(dp, p) \ ddi_get8((dp)->regs_handle, \ (void *)(((caddr_t)(dp)->base_addr) + (p))) diff --git a/usr/src/uts/common/io/sfe/sfereg.h b/usr/src/uts/common/io/sfe/sfereg.h index 31e9e359d7..b6134625f1 100644 --- a/usr/src/uts/common/io/sfe/sfereg.h +++ b/usr/src/uts/common/io/sfe/sfereg.h @@ -31,8 +31,6 @@ * DAMAGE. */ -#pragma ident "%Z%%M% %I% %E% SMI" /* sfe device driver */ - #ifndef _SFEREG_H_ #define _SFEREG_H_ /* |
