| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
| |
The register layout is little different from memory-mapped stats
in the previous generation chips. In fact, it is bad because
registers in this range are cleared after reading them.
Reviewed by: scottl
MFC after: 3 days
Notes:
svn path=/head/; revision=173675
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
support machines having multiple independently numbered PCI domains
and don't support reenumeration without ambiguity amongst the
devices as seen by the OS and represented by PCI location strings.
This includes introducing a function pci_find_dbsf(9) which works
like pci_find_bsf(9) but additionally takes a domain number argument
and limiting pci_find_bsf(9) to only search devices in domain 0 (the
only domain in single-domain systems). Bge(4) and ofw_pcibus(4) are
changed to use pci_find_dbsf(9) instead of pci_find_bsf(9) in order
to no longer report false positives when searching for siblings and
dupe devices in the same domain respectively.
Along with this change the sole host-PCI bridge driver converted to
actually make use of PCI domain support is uninorth(4), the others
continue to use domain 0 only for now and need to be converted as
appropriate later on.
Note that this means that the format of the location strings as used
by pciconf(8) has been changed and that consumers of <sys/pciio.h>
potentially need to be recompiled.
Suggested by: jhb
Reviewed by: grehan, jhb, marcel
Approved by: re (kensmith), jhb (PCI maintainer hat)
Notes:
svn path=/head/; revision=172394
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sysctl_handle_int is not sizeof the int type you want to export.
The type must always be an int or an unsigned int.
Remove the instances where a sizeof(variable) is passed to stop
people accidently cut and pasting these examples.
In a few places this was sysctl_handle_int was being used on 64 bit
types, which would truncate the value to be exported. In these
cases use sysctl_handle_quad to export them and change the format
to Q so that sysctl(1) can still print them.
Notes:
svn path=/head/; revision=170289
|
| |
|
|
| |
Notes:
svn path=/head/; revision=170176
|
| |
|
|
| |
Notes:
svn path=/head/; revision=169882
|
| |
|
|
|
|
|
| |
auto-detect the condition.
Notes:
svn path=/head/; revision=169881
|
| |
|
|
|
|
|
|
|
| |
provided by davidch via glebius.
PR: kern/96806
Notes:
svn path=/head/; revision=169880
|
| |
|
|
| |
Notes:
svn path=/head/; revision=169878
|
| |
|
|
|
|
|
| |
Submitted by: mjacob
Notes:
svn path=/head/; revision=169876
|
| |
|
|
| |
Notes:
svn path=/head/; revision=169875
|
| |
|
|
|
|
|
| |
MFC after: 3 days
Notes:
svn path=/head/; revision=169191
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Blade 2500, Fire V210 and probably some other sparc64 machines.
These chips are typically not fitted with an EEPROM which means
that we have to obtain the MAC address via OFW and that some chip
tests will just always fail.
These changes are based on the respective code found in OpenBSD
with some additional info obtained from OpenSolaris and some style
suggestions by jkim@. They also have the desired side-effect of
respecting the 'local-mac-address?' system configuration variable
for the affected BGEs.
- In bge_attach() factor out calling bge_release_resources() before
going to the fail label into the fail label as well as replace a
magic 6 with ETHER_ADDR_LEN.
Reviewed by: yongari (before style changes), jkim
Notes:
svn path=/head/; revision=169152
|
| |
|
|
|
|
|
| |
MFC after: 3 days
Notes:
svn path=/head/; revision=168277
|
| |
|
|
|
|
|
|
|
|
| |
Also, apparently quad support is broken in the sysctl infrastructure, so don't
pretend that it works.
Submitted by: ru, bde
Notes:
svn path=/head/; revision=167496
|
| |
|
|
| |
Notes:
svn path=/head/; revision=167480
|
| |
|
|
|
|
|
| |
Obtained from: OpenBSD
Notes:
svn path=/head/; revision=167351
|
| |
|
|
| |
Notes:
svn path=/head/; revision=167312
|
| |
|
|
|
|
|
|
|
|
|
|
| |
- Remove some excessive parentheses around shift operators.
- Use macro instead of magic number where it is applicable.
- Change lower-case hexdecimals to upper cases to match wpaul's style.
- Revert some unnecessary line wraps and changes from the previous commit.
Pointed out by: bde
Notes:
svn path=/head/; revision=167311
|
| |
|
|
| |
Notes:
svn path=/head/; revision=167280
|
| |
|
|
|
|
|
| |
MFC after: 3 days
Notes:
svn path=/head/; revision=167279
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
bus_setup_intr()
o add an int return code to all fast handlers
o retire INTR_FAST/IH_FAST
For more info: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=465712+0+current/freebsd-current
Reviewed by: many
Approved by: re@
Notes:
svn path=/head/; revision=166901
|
| |
|
|
|
|
|
|
|
|
| |
chipsets. It was causing 'firmware handshake timed out' errors for some
chips.
Discussed with: scottl
Notes:
svn path=/head/; revision=166718
|
| |
|
|
| |
Notes:
svn path=/head/; revision=166717
|
| |
|
|
| |
Notes:
svn path=/head/; revision=166677
|
| |
|
|
|
|
|
| |
Pointed out by: many
Notes:
svn path=/head/; revision=166676
|
| |
|
|
|
|
|
| |
Obtained from: OpenBSD
Notes:
svn path=/head/; revision=166673
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Move some PHY bug detections from brgphy.c to if_bge.c.
- Do not penalize working PHYs.
- Re-arrange bge_flags roughly by their categories.
- Fix minor style(9) nits.
PR: kern/107257
Obtained from: OpenBSD
Tested by: Mike Hibler <mike at flux dot utah dot edu>
Notes:
svn path=/head/; revision=166031
|
| |
|
|
|
|
|
| |
It had the sense of the bit reversed.
Notes:
svn path=/head/; revision=165932
|
| |
|
|
|
|
|
|
|
|
| |
bge_intr(). Some of them are used in bge_poll(). Simplify by only
initializing these for polling mode and not toggling them when switching
modes. This also fixes missing synchronization with the coalescing
engine in the toggling.
Notes:
svn path=/head/; revision=165557
|
| |
|
|
|
|
|
| |
properly.
Notes:
svn path=/head/; revision=165459
|
| |
|
|
|
|
|
| |
MFC after: 1 week
Notes:
svn path=/head/; revision=165458
|
| |
|
|
|
|
|
|
|
|
| |
been handled instead of when at least one descriptor was just handled.
For bge, it is normal to get a txeof when only a small fraction of the
queued tx descriptors have been handled, so the bug broke the watchdog
in a usual case.
Notes:
svn path=/head/; revision=165383
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- moved the synchronizing bus read to after the bus write for the first
interrupt ack so that it actually synchronizes everything necessary.
We were acking not only the status update that triggered the interrupt
together with any status updates that occurred before we got around
to the bus write for the ack, but also any status updates that occur
after we do the bus write but before the write reaches the device.
The corresponding race for the second interrupt ack resulted in
sometimes returning from the interrupt handler with acked but
unserviced interrupt events. Such events then remain unserviced
until further events cause another interrupt or the watchdog times
out.
The race was often lost on my 5705, apparently since my 5705 has broken
event coalescing which causes a status update for almost every packet,
so another status update is quite likely to occur while the interrupt
handler is running. Watchdog timeouts weren't very noticeable,
apparently because bge_txeof() has one of the usual bugs resetting the
watchdog.
- don't disable device interrupts while bge_intr() is running. Doing this
just had the side effects of:
- entering a device mode in which different coalescing parameters apply.
Different coalescing parameters can be used to either inhibit or
enhance the chance of getting another status update while in the
interrupt handler. This feature is useless with the current
organization of the interrupt handler but might be useful with a
taskqueue handler.
- giving a race for ack+reenable/return. This cannot be handled
by simply rearranging the order of bus accesses like the race for
ack+keepenable/entry. It is necessary to sync the ack and then
check for new events.
- taking longer, especially with the extra code to avoid the race on
ack+reenable/return.
Reviewed by: ru, gleb, scottl
Notes:
svn path=/head/; revision=165376
|
| |
|
|
|
|
|
| |
Remaining changes are cosmetic.
Notes:
svn path=/head/; revision=165363
|
| |
|
|
|
|
|
|
|
|
| |
- Synchronize bge_tick() with callout_reset/callout_stop() calls.
- Avoid using bge_tick() inside bge_link_upd(), use mii_pollstat() instead.
MFC after: 2 month
Notes:
svn path=/head/; revision=165344
|
| |
|
|
|
|
|
|
|
|
|
| |
- Do not repeatedly read vendor/device IDs while probing.
- Remove redundant bzero(3) for softc. device_get_softc(9) does it for free[1].
Reviewed by: glebius
Suggested by: glebius[1]
Notes:
svn path=/head/; revision=165333
|
| |
|
|
|
|
|
|
|
| |
are problems with it on several revisions of this chip. I'll
re-enable it after I've sorted out which chip revisions work and which
don't.
Notes:
svn path=/head/; revision=165236
|
| |
|
|
|
|
|
| |
running an i386 kernel, and it worked fine.
Notes:
svn path=/head/; revision=165233
|
| |
|
|
|
|
|
| |
Submitted by: Bruce Evans
Notes:
svn path=/head/; revision=165189
|
| |
|
|
|
|
|
| |
cases to the debug_info function.
Notes:
svn path=/head/; revision=165188
|
| |
|
|
|
|
|
|
|
|
|
|
| |
have been added erroneously, and it causes problems on some chips. A larger
change is needed to do this write at a more appropriate place, but that
change requires reworking the ASF logic. That will be worked on in the
future.
Submitted by: Bruce Evans
Notes:
svn path=/head/; revision=165187
|
| |
|
|
|
|
|
| |
It reduces chance of errors from multiple counter wraps at the same time.
Notes:
svn path=/head/; revision=165181
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Use the appropriate register writing method when reseting the chip
- Program the descriptor DMA engine correctly.
- More reliably detect certain chips and their features.
Also add some low-level debugging tools to help future work on this driver.
Submitted by: David Christenson (proof of concept changes)
Sponsored by: www.UIA.net
Notes:
svn path=/head/; revision=165114
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Correct RX packet drop counter for BCM5705+. This register is read/clear
and it wraps very quickly under heavy packet drops because only the lower
ten bits are valid according to the documentation. However, it seems few
more bits are actually valid and the rest bits are always zeros[1].
Therefore, we don't mask them off here. To get accurate packet drop count,
we need to check the register from bge_rxeof(). It is commented out for now,
not to penalize normal operation. Actual performance impact should be
measured later.
- Correct integer casting from u_long to uint32_t. Casting is not really
needed for all supported platforms but we better do this correctly[2].
Tested by: bde[1]
Suggested by: bde[2]
Notes:
svn path=/head/; revision=165101
|
| |
|
|
|
|
|
|
| |
may be able to support jumbo frames for BCM5714 and BCM5780.
- Rename BGE_IS_5705_OR_BEYOND() to BGE_IS_5705_PLUS() for consistency.
Notes:
svn path=/head/; revision=164888
|
| |
|
|
| |
Notes:
svn path=/head/; revision=164886
|
| |
|
|
|
|
|
| |
Submitted by: oleg
Notes:
svn path=/head/; revision=164879
|
| |
|
|
| |
Notes:
svn path=/head/; revision=164781
|
| |
|
|
|
|
|
|
|
|
|
| |
discarded RX packets to input error for BCM5705 or newer chipset as the others.
Unfortunately we cannot do the same for output errors because ifOutDiscards
equivalent register does not exist. While I am here, replace misleading and
wrong BGE_RX_STATS/BGE_TX_STATS with BGE_MAC_STATS. They were reversed but
worked accidently.
Notes:
svn path=/head/; revision=164780
|
| |
|
|
|
|
|
|
| |
that piggybacks on bge_tick() callout.
- Lock bge_tick() using callout_init_mtx().
Notes:
svn path=/head/; revision=164769
|