freebsd-skq/sys
Attilio Rao 86d2e48c22 Per their definition, atomic instructions used in conjuction with
memory barriers should also ensure that the compiler doesn't reorder paths
where they are used.  GCC, however, does that aggressively, even in
presence of volatile operands.  The most reliable way GCC offers for avoid
instructions reordering is clobbering "memory" even if that is
theoretically an heavy-weight operation, flushing the content of all
the registers and forcing reload of them (We could rely, however, on
gcc DTRT by just understanding the purpose as this is a well-known
pattern for many modern operating-systems).

Not all our memory barriers, right now, clobber memory for GCC-like
compilers. The most notable cases are IA32 and amd64 where the memory
barrier are treacted the same as normal atomic instructions.
Fix this by offering the possibility to implement atomic instructions
with memory barriers separately from the normal version and implement
the GCC-like specific one using memory clobbering.
Thanks to Chris Lattner (@apple) for his discussion on llvm specifics.

Reported by:	jhb
Reviewed by:	jhb
Tested by:	rdivacky, Giovanni Trematerra
		<giovanni dot trematerra at gmail dot com>
2009-10-06 13:45:49 +00:00
..
amd64 Per their definition, atomic instructions used in conjuction with 2009-10-06 13:45:49 +00:00
arm - Drop unused pmap_use_l1 function and comment out currently unused 2009-10-05 10:08:58 +00:00
boot lindev(4) [1] is supposed to be a collection of linux-specific pseudo 2009-09-26 12:45:28 +00:00
bsm Add audit events for process descriptor system calls, which will appear in 2009-09-29 21:25:59 +00:00
cam Report SATA 3.x devices. 2009-09-27 20:50:54 +00:00
cddl Return EOPNOTSUPP instead of EINVAL when doing chflags(2) over an old 2009-10-01 18:58:26 +00:00
compat Make sure that the primary native brandinfo always gets added 2009-10-03 11:57:21 +00:00
conf cxgb(4) updates, including: 2009-10-05 20:21:41 +00:00
contrib Use __FBSDID to embed RCS ID. 2009-09-21 08:37:57 +00:00
crypto
ddb Put square backets ([]) around process names for system processes to patch 2009-10-01 19:12:14 +00:00
dev cxgb(4) updates, including: 2009-10-05 20:21:41 +00:00
fs Fix a bug that causes the fsx test case of mmap'ed page being out of sync 2009-10-04 10:38:04 +00:00
gdb
geom - Improve error message consistency and wording. 2009-10-05 08:44:31 +00:00
gnu Fix the build by using proper format. 2009-06-25 16:48:13 +00:00
i386 Per their definition, atomic instructions used in conjuction with 2009-10-06 13:45:49 +00:00
ia64 Make sure that the primary native brandinfo always gets added 2009-10-03 11:57:21 +00:00
isa Tweak the way that the ACPI and ISA bus drivers match hint devices to 2009-08-24 21:51:46 +00:00
kern Fix build on amd64, where sysctl arg1 is a pointer. 2009-10-05 22:23:12 +00:00
kgssapi When the KOBJMETHOD() macro was updated, it resulted in the 2009-06-14 17:33:46 +00:00
libkern done method is supposed to return int. 2009-06-22 22:09:18 +00:00
mips Make sure that the primary native brandinfo always gets added 2009-10-03 11:57:21 +00:00
modules cxgb(4) updates, including: 2009-10-05 20:21:41 +00:00
net Put #ifdef INET around parts of the FLOWTABLE code, to unbreak 2009-10-03 10:56:03 +00:00
net80211 Update 802.11s mesh support to draft 3.03. This includes a revised frame 2009-09-22 18:18:14 +00:00
netatalk Reverse misordered unlock and lock in at_control for netatalk phase I 2009-08-12 10:44:13 +00:00
netgraph Get those pesky RFCOMM RPM data bits right. This is likely a noop. 2009-09-10 23:30:13 +00:00
netinet In tcp_input(), we acquire a global write lock at first only if a 2009-10-05 22:24:13 +00:00
netinet6 Enable adding a link-local address even if ND6_IFF_IFDISABLED. 2009-10-02 07:00:20 +00:00
netipsec Changed an IPSEC_ASSERT to a simple test, as such invalid packets 2009-10-01 15:33:53 +00:00
netipx Use queue(9) instead of hand-crafted link lists for the global IPX 2009-06-24 20:57:50 +00:00
netnatm
netncp
netsmb Don't print out a message on loading a module. 'kldload -v' and 'kldstat 2009-09-10 18:33:08 +00:00
nfs Revert rev 192323 (nfs_common.c only): 2009-07-12 03:53:52 +00:00
nfsclient Reverting the previous change for now. Some users reports the patch 2009-09-15 22:09:42 +00:00
nfsserver Ensure that tv_sec is between INT32_MIN and INT32_MAX, so ZFS won't object. 2009-09-26 18:23:16 +00:00
nlm unifdef NFSCLIENT because the nlm depends on the nfsclient even if NFSCLIENT 2009-10-03 12:22:12 +00:00
opencrypto If crypto operation is finished with EAGAIN, don't repeat operation from 2009-09-04 09:48:18 +00:00
pc98 MFi386: revision 197653 2009-10-01 10:46:22 +00:00
pci intpm/sb700: force polling mode if configured interrupt is SMI 2009-09-19 08:56:28 +00:00
powerpc Make sure that the primary native brandinfo always gets added 2009-10-03 11:57:21 +00:00
rpc Set the prison in NFS anon and GSS SVC creds (as I indended to in r197581). 2009-09-28 18:55:29 +00:00
security Having thrown the cat out of the house, add a necessary include. 2009-09-08 13:24:36 +00:00
sparc64 Make sure that the primary native brandinfo always gets added 2009-10-03 11:57:21 +00:00
sun4v Add a new sysctl for reporting all of the supported page sizes. 2009-09-18 17:04:57 +00:00
sys Reserve numbers for XScale. 2009-10-02 11:14:12 +00:00
teken Add support for VT200-style mouse input. 2009-09-27 18:19:41 +00:00
tools - Increase dynamic range of filter coefficients from 28bit to 30bit. 2009-07-05 18:15:06 +00:00
ufs Don't build ufs_gjournal.c at all if UFS_GJOURNAL option is not given 2009-09-22 16:22:05 +00:00
vm Align and pad the page queue and free page queue locks so that the linker 2009-10-04 18:53:10 +00:00
xdr Add a check for a NULL mbuf ptr at the beginning of xdrmbuf_inline() 2009-08-12 16:27:51 +00:00
xen Temporarily revert the new-bus locking for 8.0 release. It will be 2009-08-20 19:17:53 +00:00
Makefile