Commit Graph

120790 Commits

Author SHA1 Message Date
Alexander Kabaev
3f34977614 Trim trailing whitespace. 2005-12-28 17:13:31 +00:00
Maxim Konovalov
6c3cd0e2f6 o Fix typos in the comments.
Submitted by:	Wojciech A. Koszek
2005-12-28 15:18:18 +00:00
Gleb Smirnoff
7ed2454cb3 Check for IFF_DRV_RUNNING in the interrupt loop.
Reported & tested by:	Martin P. Hansen <mph lima.dyndns.dk>
2005-12-28 13:21:05 +00:00
Gleb Smirnoff
747cdba40e In ng_netflow_disconnect() check whether we are working with "iface"
or with "out" hook, and clear the right pointer.

Reported by:	Vitaliy Ovsyannikov <V.Ovsyannikov kr.ru>
2005-12-28 12:56:59 +00:00
Robert Watson
4992df3ead Add 'juggle', a simple IPC micro-benchmark that uses various IPC types to
perform varying number of small IPC operations.  It runs using a single
process and one thread, a single process and two threads, and using
multiple processes.  Critical to its performance measure are the cost and
frequency of context switches, locking overhead, and threading
performance.  The benchmark generates .csv output appropriate for reading
into a spreadsheet to generate summary statistics and perform statistical
tests easily.
2005-12-28 12:42:12 +00:00
Søren Schmidt
796bd93e5e Further updates to the Marvell support code.
Should be reliable enough for actual use by now.
2005-12-28 11:55:43 +00:00
Gleb Smirnoff
086745614c When in rev. 1.47 cardbus_alloc_resources() function was moved from
cardbus_cis.c to this file, some code was not merged and thus resource
list entries were invalid. They didn't have a resources attached to
them.
  However, the problem was masked for some time later, because newer
resources list entries were added to the head of the list, and
resource_list_find() always returned the first matching resource list
entry. Usually the underlying driver allocated a valid resource and
added it to the head of the list, and invalid one wasn't used.
  In rev. 1.174 of subr_bus.c the sorting of resource list entries was
reversed demasking the problem in cardbus_alloc_resources().
  This commit fixes the problem returning back some code from
cardbus_cis.c, pre-1.49 revisions.

PR:			kern/87114
PR:			kern/90441
Hardware provided by:	Vasily Olekhov <olekhov yandex.ru>
Reviewed by:		imp
2005-12-28 10:15:01 +00:00
Xin LI
fc9fac4c78 Correct a typo 2005-12-28 10:03:48 +00:00
Gleb Smirnoff
6bbdde89f5 A style nit. 2005-12-28 09:37:04 +00:00
Christian Brueffer
232c858f19 Document new support for Marvell chipsets. 2005-12-28 09:35:29 +00:00
Gleb Smirnoff
dd157f8102 Tidy up em_resume():
- Don't call em_init_locked() twice.
  - Collapse two if() blocks into one.
2005-12-28 08:58:28 +00:00
Ade Lovett
d9aef362c0 Someone buy me a beer. Now. 2005-12-28 08:41:57 +00:00
Scott Long
557e53c6f7 Cache the tx producer index instead of reading it every time ti_start is
called.
2005-12-28 08:36:32 +00:00
Simon L. B. Nielsen
c783d10bb8 ti(4) also works on sparc64 now. 2005-12-28 08:35:30 +00:00
Scott Long
3c41ebd1f8 Fix a serious regression from the busdma conversion. Check to make sure
that we don't overrun the tx descriptor ring before actually trying to
overrun it.
2005-12-28 08:14:35 +00:00
Tom Rhodes
0e36e11d57 Cast tv_sec to intmax_t and print with %jd in some ifdef'ed code. 2005-12-28 07:08:54 +00:00
Warner Losh
df2f828a8f Add some sanity checking to the pccard insertion case. Whine if the
bridge tries to tell us about a new card when we have one already in
the socket.
2005-12-28 05:30:09 +00:00
Pyun YongHyeon
1bd8f78656 Uncomment ti(4) as it's now working. 2005-12-28 02:59:16 +00:00
Pyun YongHyeon
d54c905707 Bring big-endian architecture support for ti(4).
. remove unnecessay header files after Scott's bus_dma(9) commit.
 . remove global variable tis which was introduced at the time of
   zero_copy(9) changes. The variable tis was not used at all. The
   same applyes to ti_links in softc so axe it.
 . deregister variables.
 . axe ti_vhandle and switch to use explicit register access for
   accessing NIC local memory. Creates three variants of ti_mem to
   read/write NIC local memory(ti_mem_read, ti_mem_write) and clearing
   NIC local memory(ti_mem_zero). This greatly enhances code
   readability and have ti(4) drop using shared memory scheme for
   Tigon 1. As Tigon 1 switched to use explicit register access for Tx,
   axe ti_tx_ring_nic/ti_cmd_ring in softc.(Tigon 2 used to host ring
   scheme which means there is no need to access NIC local memory via
   register access for Tx and NIC would DMA the modified Tx rings into
   its local memory.) [1]
 . introduce new macro TI_EVENT_*/TI_CMD_* to handle NIC envent/command.
   Instead of using bit fields assginment for accessing the event, use
   shift operations to set/get it. [1]
 . add additional check for valid DMA tags in ti_free_dmamaps().
 . add missing bus_dmamap_sync/bus_dmamap_unload in ti_free_*_ring_*.
 . fix locking nits(MTX_RECURSE mutex) and make ti(4) MPSAFE.
 . change data type of ti_rdata_phys to bus_addr_t and don't blindly
   cast to uint32_t.
 . rearrange detach path and make ti(4) survive during device detach.
 . for Tigon 1, use explicit register access for checking Tx descriptors
   in ti_encap()/ti_txeof(). [1]
 . properly call bus_dmamap_sync(9) for updating statistics.
 . remove extra semicolon in ti_encap()
 . rewrite loading MAC address to work on strict-alignment architectures.
 . move TI_RD_OFF macro to if_tireg.h
 . axe ETHER_ALIGN as it's already defined in <net/ethernet.h>.
 . make macros immuine from expansion by adding parenthesis and do-while.
 . remove alpha specific hack as vtophys(9) is no longer used in ti(4)
   after Scott's bus_dma(9) fix.

Reviewed by:	scottl
Obtained from:	OpenBSD [1]
2005-12-28 02:57:19 +00:00
Pawel Jakub Dawidek
619f284195 In realloc(9), determine size of the original block based on
UMA_SLAB_MALLOC flag.
In some circumstances (I observed it when I was doing a lot of reallocs)
UMA_SLAB_MALLOC can be set even if us_keg != NULL.

If this is the case we have wonderful, silent data corruption, because less
data is copied to the newly allocated region than should be.

I'm not sure when this bug was introduced, it could be there undetected
for years now, as we don't have a lot of realloc(9) consumers and it was
hard to reproduce it...
...but what I know for sure, is that I don't want to know who introduce
the bug:) It took me two/three days to track it down (of course most of
the time I was looking for the bug in my own code).
2005-12-28 01:53:13 +00:00
Florent Thoumie
333051eeb3 Add a hid blacklist quirk.
PR:		usb/80383
Submitted by:	Lonnie Mendez <lmendez19@austin.rr.com>
Tested by:	Adam Kropelin <akropel1@rochester.rr.com>, thierry, fenner
Approved by:	pjd
MFC after:	1 week
2005-12-27 23:35:38 +00:00
Pawel Jakub Dawidek
70665fda32 Fix watch address truncation. The address was truncated when it was passed to
amd64_set_watch() as 'unsigned int' and 'unsigned int' is 32bit long on amd64.

Even with that fix hardware watchpoint don't work for me on amd64, ie. when
I set the watchpoint and write a byte there, nothing happens.
2005-12-27 23:23:47 +00:00
Doug Barton
cc41555849 Fix another braino, don't remove the X related socket directories
right after creating them.

Twiddle whitespace while I'm here.
2005-12-27 23:22:18 +00:00
Doug Barton
eeb92ff283 Make sure that the prestart routine is run with *start, instead of
just 'start'.

Reminded by:	keramida
2005-12-27 23:08:58 +00:00
Garrett Wollman
e50b756cb3 Merge tzdata2005r from vendor branch. Only significant change is to
update those Canadian provinces which have announced that they will
follow the new US DST rules.
2005-12-27 19:55:21 +00:00
Garrett Wollman
fb21dcd6dd This commit was generated by cvs2svn to compensate for changes in r153758,
which included commits to RCS files with non-trunk default branches.
2005-12-27 19:52:05 +00:00
Garrett Wollman
c965fe6f24 No sooner did I make noises about seeing the last timezone update of
2005 when another one comes out.  This one, even ADO hopes will be the
last of the year.

Obtained from: Arthur Olson, ftp://elsie.nci.nih.gov/pub/tzdata2005r.tar.gz
2005-12-27 19:52:05 +00:00
Warner Losh
0e6e3c1384 Ensure that we're aligned at leas tto the size of the resource being requested.
When cbb_debug is on, print the windows that we're mapping.
2005-12-27 19:18:11 +00:00
Warner Losh
0780312f3d nits 2005-12-27 18:55:21 +00:00
Søren Schmidt
7af3abd894 Change the probes in ATA to return a negative value on success.
This allows other driver to take over if needed during probe, and allows
me to distribute new drivers as modules.
2005-12-27 18:22:11 +00:00
Søren Schmidt
091bb42ceb Update the last commit to also take 48Bit access functions. 2005-12-27 17:13:11 +00:00
Søren Schmidt
4b55f0c7c7 Add initial support for the Marvell 88SX[56]0[48][01] series of SATA chips.
Hardware donated by: Matthew Jacob
Hardware donated by: Y!
2005-12-27 17:09:52 +00:00
Søren Schmidt
8ec96d7b8d Fix rebuilds of arrays that got stuck.
Misc minor fixes.

Bughunting and initial fixes by Pav@ and Anton.
2005-12-27 16:49:33 +00:00
Joseph Koshy
fe5ca00ac4 Document the EOPNOTSUPP returned by hwpmc(4) if a sampling mode PMC
is requested on a CPU without an APIC.

Requested by:	anholt (a while ago)
2005-12-27 15:35:06 +00:00
Stefan Farfeleder
c14284a637 Try to unbreak the tinderbox: Cast a time_t argument to long before printing
it with %ld.
2005-12-27 12:33:18 +00:00
David Xu
9f8eb3cb52 Use variable i instead of variable cpus as an index to get correct kseq. 2005-12-27 12:02:03 +00:00
Pawel Jakub Dawidek
7b53693f42 Document CTR6() macro. 2005-12-27 11:12:51 +00:00
Gleb Smirnoff
3c6160327d Add \n to log() message.
Submitted by:	Stanislaw Halik <weirdo tehran.lain.pl>
2005-12-27 00:17:11 +00:00
Maxim Sobolev
d49b21093c Fix breakage introduced in the previous commit. 2005-12-26 22:32:52 +00:00
Olivier Houchard
81e5864f2e Fix typo in comment. 2005-12-26 22:09:09 +00:00
Maxim Sobolev
900b28f9f6 Remove kern.elf32.can_exec_dyn sysctl. Instead extend Brandinfo structure
with flags bitfield and set BI_CAN_EXEC_DYN flag for all brands that usually
allow executing elf dynamic binaries (aka shared libraries). When it is
requested to execute ET_DYN elf image check if this flag is on after we
know the elf brand allowing execution if so.

PR:		kern/87615
Submitted by:	Marcin Koziej <creep@desk.pl>
2005-12-26 21:23:57 +00:00
Sam Leffler
4e0a8f0dc7 document deftxkey 2005-12-26 18:15:09 +00:00
Joseph Koshy
ba8ae2de36 - Plug a memory leak: free up per-cpu sample buffers at module unload time.
- Correct a few style nits.
2005-12-26 16:10:00 +00:00
Jens Schweikhardt
bb3020ee66 Correct some typos. 2005-12-26 16:09:58 +00:00
Yoshihiro Takahashi
3b52aaddac MFi386: revision 1.621 2005-12-26 12:46:36 +00:00
Gleb Smirnoff
0b6169c0fa Add simple suspend and resume methods. We call em_stop() on suspend and
em_init() on resume. With this change the network is ready right after
resume, without half minute lag.

Tested by:	Jacques Garrigue
2005-12-26 10:39:21 +00:00
Joseph Koshy
06490ba975 Wrap comment lines to be under 80 characters wide.
MFC after:	3 days
2005-12-26 09:27:24 +00:00
David Xu
1bfa910843 Move global variable private_tss into per-cpu area.
Reviewed by: jhb
2005-12-26 00:07:19 +00:00
Max Laier
6ae8d74a9e Only decrement the max-src-conn counter for tcp connections that reached
"established" state.

Similar to OpenBSD's rev. 1.499 by joel but not breaking ABI.

Obtained from:	OpenBSD (with changes)
Reported by:	Bruno Afonso
MFC after:	3 days
X-MFC:		together with local_flags
2005-12-25 23:52:00 +00:00
Wilko Bulte
e2f9880300 We will not be responsible for damage to equipment, your ego, county wide
power outages, spontaneously generated mini (or larger) black holes,
planetary disruptions, or personal injury or worse that may result from the
use of this material.
                -- taken from Samuel M. Goldwasser's
                   Sam's Strobe FAQ Notes on the Troubleshooting
                   and Repair of Electronic Flash Units and Strobe Lights
2005-12-25 23:29:59 +00:00