Commit Graph

163891 Commits

Author SHA1 Message Date
ad
c69c0e0f91 Make the 64-bit operations available when possible. 2007-11-29 01:04:57 +00:00
ad
92d7e73c2a Add alias for atomic_cas_64() if available. 2007-11-29 01:04:20 +00:00
ad
695c2bc225 Only build the 64-bit versions if __HAVE_ATOMIC64_OPS. 2007-11-29 01:02:40 +00:00
ad
f5474801b3 __HAVE_ATOMIC64_OPS if 64-bit 2007-11-29 00:58:03 +00:00
ad
32c745d42e __HAVE_ATOMIC64_OPS 2007-11-29 00:56:53 +00:00
ad
962de970f5 __HAVE_ATOMIC64_OPS for SUN4U. 2007-11-29 00:56:13 +00:00
ad
c291a9d4fa RW_GIVE() needs to do a mb_memory() now. 2007-11-29 00:17:54 +00:00
ad
7b3b1e0427 Atomic ops for MIPS. Use the CAS functions already provided by the kernel,
and use the generic C code to provide the rest. Unfortunatley the C code
assembles up pretty badly on MIPS but at least it will work.
2007-11-29 00:16:23 +00:00
ad
872af53778 - Change _lock_cas and friends to do "compare and swap" instead of "compare
and set".
- Rename them to _atomic_cas_uint, _atomic_cas_ulong etc and provide strong
  aliases for the other names CAS goes by.
2007-11-29 00:14:27 +00:00
degroote
9a2478a81d Fix compilation in case of COMPAT_FREEBSD_NET80211.
Any reason that we use by default the old api ioctl instead of the 'new' api ioctl ?
(Time is a good reason :)).
2007-11-28 23:23:11 +00:00
he
ddc4103ec7 Allow this to build both for sparc64 and for the GENERIC_SUN4U sparc kernel. 2007-11-28 22:54:46 +00:00
degroote
db9d3119cf In wpi_init, check for the status of radio switch and print a useful message
in this case.
2007-11-28 22:51:49 +00:00
wiz
297acee710 less-416 out. 2007-11-28 22:04:47 +00:00
christos
f6cecc05cf Sync phk malloc.c with the latest one from FreeBSD. This gives us the
same api as jemalloc by:

    - adding posix_memalign()
    - moving calloc in the same file
    - renaming malloc_options -> _malloc_options
2007-11-28 21:55:14 +00:00
ad
2f827ecd6a ppc64 atomic ops. 2007-11-28 21:47:00 +00:00
plunky
87914664c7 [experimentally] report failing commands
this does happen sometimes and I would like to see if it happens
more often than I know of.
2007-11-28 21:46:52 +00:00
ad
57ab3d5998 Grab tty_lock in more places. Noted and tested by degroote@. 2007-11-28 21:44:11 +00:00
ad
bc7bf35c36 Atomic ops for powerpc. Please review. 2007-11-28 21:39:48 +00:00
ad
a906840a60 There is no mvme88k! 2007-11-28 20:50:10 +00:00
jnemeth
f3ce6c9275 don't include sys/intr.h twice, why aren't the includes sorted? 2007-11-28 20:41:35 +00:00
plunky
736a9db087 Clean up the way that bluetooth drivers attach to the bluetooth stack,
to remove the frobbing that drivers must do in the hci_unit structure.

- driver provides a static const interface descriptor
- hci_unit is allocated by hci_attach() rather than part of softc
- statistics are compiled by driver and provided on request
- driver provides output methods and is responsible for output queue
- stack provides input methods and is responsible for input queue
- mutex is used to arbitrate device queue access
2007-11-28 20:16:11 +00:00
rmind
c75dc3277a Unify the license: All rights reserved.
No functional change.
2007-11-28 19:30:55 +00:00
ad
b8f8bca01a Use the softint API. 2007-11-28 18:55:30 +00:00
pooka
e49789dd46 more l removal 2007-11-28 18:50:10 +00:00
ad
16b547ec7f Please can we nuke this code? 2007-11-28 18:45:03 +00:00
ad
4517da3861 x86_mb_nop is now unused. 2007-11-28 18:19:20 +00:00
ad
1a82318781 Use the softint API. 2007-11-28 18:03:56 +00:00
ad
44fc0a18e5 A lock prefix on xchg is meaningless. 2007-11-28 18:02:29 +00:00
ad
77724e6afd Hook in the atomic ops on alpha. 2007-11-28 17:40:02 +00:00
ad
fb900ec918 Pull in alpha atomic ops from the thorpej-atomic branch. 2007-11-28 17:39:06 +00:00
ad
f1d10eab90 Pull in sparc64 atomic ops from the thorpej-atomic branch. 2007-11-28 17:29:31 +00:00
ad
77ca26a240 Memory barriers for sparc64. XXX Can the 'membar' go in retl delay slot? 2007-11-28 17:29:13 +00:00
ad
0df165c04d Use xchgb, bswapl and not rotate/shift. 2007-11-28 17:03:35 +00:00
pooka
bce4ea0296 one more lock to destroy 2007-11-28 17:01:59 +00:00
ad
13c86772e9 Memory barrier in respect of the CAS isn't necessary. 2007-11-28 16:59:09 +00:00
pooka
efe797dc32 * version the registration interface
* destroy all created locks
2007-11-28 16:59:02 +00:00
ad
79085586b9 Support files from the thorpej-atomic branch. 2007-11-28 16:54:57 +00:00
agc
23c77f8d12 Do runtime detection of machine's endianness, rather than relying on a cpp
macro which was never changed. This is the QAD fix, longer term we will
move to use native md5 routines if available.

Should go some way to fixing authentication problems when using an
initiator and target of different endianness.
2007-11-28 16:46:38 +00:00
ad
a0b58b4601 Remove remaining CPUCLASS_386 tests. 2007-11-28 16:44:46 +00:00
ad
157ae0ddef Use the new atomic ops. 2007-11-28 16:40:40 +00:00
ad
6def667f04 Use the new atomic ops. 2007-11-28 16:28:43 +00:00
ad
0cddf536c0 Hook in the atomic ops from libkern. 2007-11-28 15:26:00 +00:00
ad
db42e14f44 Hook the atomic ops in. Right now they are only built into libkern, and
only if available.
2007-11-28 15:25:44 +00:00
ad
b47fc5f5e0 Fix up a few minor problems. 2007-11-28 15:24:38 +00:00
yamt
82d61b9ade - merge {i386,xen}/i386/trap.c.
- add a comment about a hack for xen2.
2007-11-28 14:02:30 +00:00
jnemeth
fd5cef8508 Sync with src/sys/sparc/dev/fd.c change to use softint(9) API.
XXX Please keep these two in sync as this one is a drop-in replacement
for the sparc version and the idea is to have both sparc and sparc64
use the same file one day.
2007-11-28 12:44:13 +00:00
simonb
f717d58276 Use lswi/syswi instead of lwz/stw when doing loads/stores since we don't
know the alignment of data being copied.  403 cores have alignment
restrictions on lwz/stw that 405 cores don't have.  lswi/syswi benchmark
at the same speed as lwz/stw on a 405 Walnut.

Fixes problems reported by Juergen Hannken-Illjes on the Explora.
2007-11-28 12:22:28 +00:00
he
756f91194a Follow up the removal of the lwp argument to VOP_ functions.
In some cases, use curlwp instead of the now missing argument.
2007-11-28 10:34:37 +00:00
jnemeth
f8660caf4c fix not protecting variable length buffer warning 2007-11-28 08:20:29 +00:00
dyoung
b6995d1653 Bug fix: make pf_route() set M_CSUM_IPV4 before calling ip_fragment().
If you use a route-to rule such as 'pass out quick on ath0 route-to
gre2 all', and the MTU on gre2 is smaller than the MTU on ath0,
then pf_route() will fragment your packet by calling ip_fragment().
Because pf_route() did not set M_CSUM_IPv4, ip_fragment() would
not compute the checksum on the fragments, and PF would send IP
fragments with bad checksums out of gre2.
2007-11-28 04:23:33 +00:00