Commit Graph

74883 Commits

Author SHA1 Message Date
Alexander Motin
34cbb135e7 MFC r203347:
NetCell is a PCI hardware RAID without cable and mode setting.
2010-02-14 19:55:41 +00:00
Alexander Motin
dd96528dec MFC r203525:
Report SATA300 chips also as SATA.
2010-02-14 19:54:16 +00:00
Alexander Motin
d2846ca800 MFC r203445:
Report to CAM unit number of underlying ataX bus device, instead of this
atapicamX. It is more apropriate and useful together with "ata" name.
2010-02-14 19:53:09 +00:00
Alexander Motin
cf8a9069cd MFC r203499:
On probe error, if restart requested, skip any retries and recovery.
Just restart probe from the beginning immediately.
2010-02-14 19:51:39 +00:00
Alexander Motin
902a54900a MFC r203421:
Add Power Up In Stand-by feature support. Device with PUIS enabled
require explicit command to do initial spin-up. Mark that command
with CAM_HIGH_POWER flag, to allow CAM manage staggered spin-up.
2010-02-14 19:50:33 +00:00
Alexander Motin
ea35d583e8 MFC r203386:
Change the way in which fake async events generated. Do not use
taskqueue for lock decoupling, as it causes unwanted races.
2010-02-14 19:48:53 +00:00
Alexander Motin
31d3ea037e MFC r203385:
- Use separate buffer for identify data fetching. We can't use main buffer
here if device already running, as data need to be formatted before use.
- Remove some saved_ccb variables. They are unused now.
2010-02-14 19:46:54 +00:00
Alexander Motin
929100472e MFC r203376, r203384:
- Give ATA/SATA SIMs info about ATAPI packet size, supported by device.
- Make ATA XPT to reject longer SCSI CDBs then supported by device, or
any SCSI CDBs, if device doesn't support ATAPI.
2010-02-14 19:44:48 +00:00
Alexander Motin
50ae5fde8d MFC r203108:
Large set of CAM improvements:
- Unify bus reset/probe sequence. Whenever bus attached at boot or later,
CAM will automatically reset and scan it. It allows to remove duplicate
code from many drivers.
- Any bus, attached before CAM completed it's boot-time initialization,
will equally join to the process, delaying boot if needed.
- New kern.cam.boot_delay loader tunable should help controllers that
are still unable to register their buses in time (such as slow USB/
PCCard/ CardBus devices), by adding one more event to wait on boot.
- To allow synchronization between different CAM levels, concept of
requests priorities was extended. Priorities now split between several
"run levels". Device can be freezed at specified level, allowing higher
priority requests to pass. For example, no payload requests allowed,
until PMP driver enable port. ATA XPT negotiate transfer parameters,
periph driver configure caching and so on.
- Frozen requests are no more counted by request allocation scheduler.
It fixes deadlocks, when frozen low priority payload requests occupying
slots, required by higher levels to manage theit execution.
- Two last changes were holding proper ATA reinitialization and error
recovery implementation. Now it is done: SATA controllers and Port
Multipliers now implement automatic hot-plug and should correctly
recover from timeouts and bus resets.
- Improve SCSI error recovery for devices on buses without automatic sense
reporting, such as ATAPI or USB. For example, it allows CAM to wait, while
CD drive loads disk, instead of immediately return error status.
- Decapitalize diagnostic messages and make them more readable and sensible.
- Teach PMP driver to limit maximum speed on fan-out ports.
- Make boot wait for PMP scan completes, and make rescan more reliable.
- Fix pass driver, to return CCB to user level in case of error.
- Increase number of retries in cd driver, as device may return several UAs.
2010-02-14 19:38:27 +00:00
Alexander Motin
9290c85988 MFC r203030:
Add support for SATA part of Marvell 88SE912x controllers to ahci(4).
Limit early revisions from 6Gb/s to 3Gb/s by default, or they negotiate
only 1.5Gb/s, when 3Gb/s devices connected.

Add dummy driver for PATA part of these controllers, preventing generic
driver attach them. It causes system freeze when SATA controller used after
PATA was touched.
2010-02-14 19:28:45 +00:00
Alexander Motin
82368eed51 MFC r202699:
Make ata_getrev() an optional method by implementing ata_null_getrev().
This fixes a bogus '???' boot message on Cambria boards with a CompactFlash
card.
2010-02-14 19:23:05 +00:00
Alexander Motin
20bbf2de82 MFp4:
After last running command completed, give commands in timeout state
second time.
2010-02-14 12:24:12 +00:00
Alexander Motin
6228bcd1ee MFC r203524:
When hacking INQUIRY result, make sure that it is right INQUIRY and there
is enough of result to hack.
2010-02-14 12:04:25 +00:00
Alexander Motin
9a1be4e8d1 MFC r203489:
Return CAM_RELEASE_SIMQ flag only when it is needed, when SIM really
was frozen before and should be released.
2010-02-14 12:03:04 +00:00
Alexander Motin
66a894f383 MFC r203484:
Do not release device, when changing number of openings.
2010-02-14 12:00:23 +00:00
Alexander Motin
1ea9446171 MFC r202150, r202170:
Make OSS_GETVERSION ioctl really work. It has 'M' group, not 'P',
as different nearby ones, and was grabbed by MIXER_xxx() handler.

While there, replace '(cmd & MIXER_xxx(0)) == MIXER_xxx(0)' expressions
with more correct '(cmd & ~0xff) == MIXER_xxx(0)'. Use of bit operations
to compare numeric fields doesn't looks sane.
2010-02-14 11:53:51 +00:00
Gavin Atkinson
3390bcf4cf Merge r200530 from head:
Don't panic on failure to attach if we fail before or during the
  if_alloc() of ifp.

  This fixes the panic reported in the PRs, but not the attach failure.

PR:		kern/139079, kern/143874
Tested by:	Steven Noonan <steven uplinklabs.net>
Reviewed by:	thompsa
2010-02-14 09:34:27 +00:00
Rick Macklem
16a11310f0 MFC: r203303
Patch the experimental NFS client so that there is a timeout
for negative name cache entries in a manner analogous to
r202767 for the regular NFS client. Also, make the code in
nfs_lookup() compatible with that of the regular client
and replace the sysctl variable that enabled negative name
caching with the mount point option.
2010-02-14 00:43:42 +00:00
Matt Jacob
9090fd5bfa Pick up some changes the the MFC missed. 2010-02-12 00:47:23 +00:00
Rick Macklem
0668507346 MFC: r203119
Patch the experimental NFS client in a manner analogous to
r203072 for the regular NFS client. Also, delete two fields
of struct nfsmount that are not used by the FreeBSD port of
the client.
2010-02-11 21:25:48 +00:00
Matt Jacob
7733cf8fff MFC a number of changes from head for ISP (203478,203463,203444,202418,201758,
201408,201325,200089,198822,197373,197372,197214,196162). Since one of those
changes was a semicolon cleanup from somebody else, this touches a lot more.
2010-02-11 18:34:06 +00:00
Rick Macklem
88cf3d348f MFC: r203072
Fix a race that can occur when nfs nfsiod threads are being created.
Without this patch it was possible for a different thread that calls
nfs_asyncio() to snitch a newly created nfsiod thread that was
intended for another caller of nfs_asyncio(), because the nfs_iod_mtx
mutex was unlocked while the new nfsiod thread was created. This patch
labels the newly created nfsiod, so that it is not taken by another
caller of nfs_asyncio(). This is believed to fix the problem reported
on the freebsd-stable email list under the subject:
FreeBSD NFS client/Linux NFS server issue.

Tested by:	to DOT my DOT trociny AT gmail DOT com
Reviewed by:	jhb
2010-02-10 16:16:50 +00:00
Andriy Gapon
d5f8ba9274 MFC r203062: acpi_hpet: correctly get number of timers in a timer block 2010-02-10 09:46:31 +00:00
Marko Zec
7526c9dfc7 MFC r203483:
Instead of spamming the console on each curvnet recursion event, print
  out each such call graph only once, along with a stack backtrace.  This
  should make kernels built with VNET_DEBUG reasonably usable again in
  busy / production environments.

  Introduce a new DDB command "show vnetrcrs" which dumps the whole log
  of distinctive curvnet recursion events.  This might be useful when
  recursion reports get burried / lost too deep in the message buffer.
  In the later case stack backtraces are not available.

  Reviewed by:  bz
2010-02-10 08:50:06 +00:00
Ed Maste
207a2ae06c MFC r198593:
Rename aac_fast_intr to aac_filter to reflect its current use.  Eliminate
  the fallback of using the filter as an interrupt handler, as it is no
  longer needed.

  Discussed with:       scottl, jhb
2010-02-09 22:05:30 +00:00
Qing Li
613e96b8c6 MFC r203401
Some of the existing ppp and vpn related scripts create and set
the IP addresses of the tunnel end points to the same value. In
these cases the loopback route is not installed for the local
end.
2010-02-09 19:27:54 +00:00
Attilio Rao
95e1c1fa00 MC r202889, r202940:
- Fix a race in sched_switch() of sched_4bsd.
  Block the td_lock when acquiring explicitly sched_lock in order to prevent
  races with other td_lock contenders.
- Merge the ULE's internal function thread_block_switch() into the global
  thread_lock_block() and make the former semantic as the default for
  thread_lock_block().
- Split out an invariant in order to have better checks.
2010-02-08 14:08:52 +00:00
David Xu
d430c009c7 MFC r203414:
After busied the lock, re-read state word before checking waiters flag,
otherwise, the waiters bit may not be set and a wakeup is lost.
2010-02-08 03:11:55 +00:00
Marius Strobl
73769927ae MFC: r202900
Merge r203608 from amd64/i386:

In syscall(), reread syscall number and arguments after ptracestop(),
if debugger modified anything in the process environment.
2010-02-07 11:59:55 +00:00
Konstantin Belousov
c329abd0d3 MFC r202882:
For i386, amd64 and ia32 on amd64 MD syscall(), reread syscall number
and arguments after ptracestop(), if debugger modified anything in the
process environment.
2010-02-07 11:37:38 +00:00
Konstantin Belousov
02d65815cb MFC r202529:
vunref() the vnode in vm object deallocation code for OBJT_VNODE
appropriate number of times to prevent possible vnode reference leak.
2010-02-07 10:51:17 +00:00
Konstantin Belousov
e9560b4089 MFC r202528:
Add vunref(9).
2010-02-07 10:44:44 +00:00
Julian Elischer
2ae7ec29fd MFC of 197952 and 198075
Virtualize the pfil hooks so that different jails may chose different
    packet filters. ALso allows ipfw to be enabled on on ejail and disabled
    on another. In 8.0 it's a global setting.
and
    Unbreak the VIMAGE build with IPSEC, broken with r197952 by
    virtualizing the pfil hooks.
    For consistency add the V_ to virtualize the pfil hooks in here as well.
2010-02-07 09:00:22 +00:00
Marius Strobl
901c651d7b MFC: r203185
Implement handling of the third argument of cpu_switch().

PR:		143215
2010-02-06 17:33:39 +00:00
Andriy Gapon
bb07fbe3c1 MFC r203160: add static qualifier to definition of a static function 2010-02-06 12:17:20 +00:00
Andriy Gapon
e21bbd1743 MFC r197104,197105,197106,197107,197688,198237,199337,199338,200553,200554,
202771,202773: bring acpica version to 20100121

MFC details:
r197104 | jkim | 2009-09-12 01:48:53 +0300 (Sat, 12 Sep 2009) | 4 lines
MFV:    r196804
Import ACPICA 20090903

r197105 | jkim | 2009-09-12 01:49:34 +0300 (Sat, 12 Sep 2009) | 2 lines
Catch up with ACPICA 20090903.

r197106 | jkim | 2009-09-12 01:50:15 +0300 (Sat, 12 Sep 2009) | 2 lines
Catch up with ACPICA 20090903.

r197107 | jkim | 2009-09-12 01:56:08 +0300 (Sat, 12 Sep 2009) | 2 lines
Canonify include paths for newly added files.

r197688 | jkim | 2009-10-01 23:56:15 +0300 (Thu, 01 Oct 2009) | 4 lines
Compile ACPI debugger and disassembler for kernel modules
unconditionally.
These files will generate almost empty object files without
ACPI_DEBUG/DDB
options.  As a result, size of acpi.ko will increase slightly.

r198237 | jkim | 2009-10-19 19:12:58 +0300 (Mon, 19 Oct 2009) | 2 lines
Merge ACPICA 20091013.

r199337 | jkim | 2009-11-16 23:47:12 +0200 (Mon, 16 Nov 2009) | 2 lines
Merge ACPICA 20091112.

r199338 | jkim | 2009-11-16 23:53:56 +0200 (Mon, 16 Nov 2009) | 2 lines
Add a forgotten module Makefile change from the previous commit.

r200553 | jkim | 2009-12-15 00:24:04 +0200 (Tue, 15 Dec 2009) | 2 lines
Merge ACPICA 20091214.

r200554 | jkim | 2009-12-15 00:28:32 +0200 (Tue, 15 Dec 2009) | 3 lines
Remove _FDE quirk handling as these quirks are automatically repaired
by ACPICA layer since ACPICA 20091214.

r202771 | jkim | 2010-01-21 23:14:28 +0200 (Thu, 21 Jan 2010) | 2 lines
Merge ACPICA 20100121.

r202773 | jkim | 2010-01-21 23:31:39 +0200 (Thu, 21 Jan 2010) | 2 lines
Fix a new header inclusion.

Discussed with:		jkim, jhb
No objections from:	acpi@
2010-02-06 12:03:25 +00:00
Alexander Motin
f8451095fa MFC r203043, r203058:
Do not place fake interrupt register on chip.
Now we have better place for it.
2010-02-05 12:17:14 +00:00
Alexander Motin
3ca74a280b MFC r203034:
Restore SATA speed reporting, broken by ATA_CAM changes.
2010-02-05 12:09:43 +00:00
Alexander Motin
dc65878eb6 MFC r203033:
Clear ch->devices, if hard-reset failed.
This makes hot-plug work better.
2010-02-05 12:07:53 +00:00
Alexander Motin
981b11104a MFC r201566, r201567:
Move wakeup() out of mutex to reduce contention.
2010-02-05 11:56:12 +00:00
Alexander Motin
9185a70204 MFC r201545:
Slightly optimize XOR calculation.
2010-02-05 11:53:41 +00:00
Alexander Motin
9ab219c83f MFC r201264:
Call wakeup() only for the first request on the queue.
2010-02-05 11:52:28 +00:00
Gavin Atkinson
75cf52103d Merge r202161 from head:
Spell "Hz" correctly wherever it is user-visible.

PR:		bin/142566
Submitted by:	N.J. Mann   njm njm.me.uk
2010-02-05 08:52:51 +00:00
Alexander Motin
9eb48f44f2 MFC r202789, r202796:
- Improve tracer, to handle more cases of input-to-output monitoring
loopback.
- Use "igain" mixer control for input-to-output monitoring loopback.
- Allow AD1981HD codecs to use playback mixer. Now driver should be able to
really use it.
- Fix bug in shared muters operation.
2010-02-05 08:36:33 +00:00
Alexander Motin
24f890094e MFC r202736:
Print playback channels paths in order of their sequence numbers, not nids.
2010-02-05 08:32:07 +00:00
Rick Macklem
e3feb3a780 MFC: r202774
Fix a typo in a comment introduced by r202767.
2010-02-04 17:31:34 +00:00
Rick Macklem
89ae8d8476 MFC: r202767
Add a timeout for the negative name cache entries in the NFS client.
This avoids a bogus negative name cache entry from persisting forever
when another client creates an entry with the same name within the
same NFS server time of day clock tick. The mount option negnametimeo
can be used to override the default timeout interval on a
per-mount-point basis. Setting negnametimeo to 0 disables negative
name caching for the mount point.
I also fixed one obvious typo where args.timeo should be
args.maxgrouplist.

Submitted by:	jhb (earlier version)
Reviewed by:	jhb
2010-02-04 16:57:01 +00:00
Pyun YongHyeon
0fb14c6f0d MFC r203082:
Add initial support for RTL8103E PCIe fastethernet.

  PR:	kern/142974
2010-02-01 23:57:42 +00:00
John Baldwin
d362c2a208 MFC 203070:
Initialize the ifnet before calling mii_phy_probe() as some phy drivers
(e.g. e1000phy(4)) expect if_dname to be valid when they are probed.
2010-02-01 22:01:48 +00:00
Konstantin Belousov
546b397a1f MFC r203175:
The MAP_ENTRY_NEEDS_COPY flag belongs to protoeflags, cow variable
uses different namespace.
2010-02-01 10:45:23 +00:00
Xin LI
72c12306f9 Reduce diff against OpenSolaris - move Giant acquire/release to
zfs_znode.c.  As a side effect this also eliminates two potential
Giant leaks.

Approved by:  pjd
2010-02-01 09:29:32 +00:00
Gavin Atkinson
b8370f7d42 Merge r202931 from head:
Add support for four more nfsmb controllers, shipping on at least the
  ASUS Atom ION boards.

PR:		kern/142571
Submitted by:	oliver
Approved by:	ed (mentor, implicit)
2010-01-31 19:41:58 +00:00
Konstantin Belousov
613bd3f32b Bump __FreeBSD_version for sigpause(3) addition. 2010-01-31 18:41:00 +00:00
Konstantin Belousov
f2d58a1d9b MFC r199827:
Implement sighold, sigignore, sigpause, sigrelse, sigset functions.

MFC r200881 (by cognet):
Don't name parameters.
2010-01-31 18:38:03 +00:00
Konstantin Belousov
661f092a6d MFC r202881:
Staticise sigqueue manipulation functions used only in kern_sig.c.
2010-01-31 18:25:57 +00:00
Marius Strobl
36a153df8b MFC: r202903
On LP64 struct ifid is 64-bit aligned while struct fid is 32-bit aligned
so on architectures with strict alignment requirements we can't just simply
cast the latter to the former but need to copy it bytewise instead.

PR:		143010
2010-01-31 17:43:22 +00:00
Marius Strobl
6c8d1299a2 MFC: r203094
- Zero the MSI/MSI-X queue argument, otherwise mtx_init(9) can panic
  indicating an already initialized lock.
- Check for an empty MSI/MSI-X queue entry before asserting that we have
  received a MSI/MSI-X message in order to not panic in case of stray MSI/
  MSI-X queue interrupts which may happen in case of using an interrupt
  handler rather than a filter.
2010-01-31 17:17:24 +00:00
Shteryana Shopova
3ddba6330c MFC r202935:
While flushing the multicast filter of an interface, do not zero the relevant
ifmultiaddr structures' reference to the parent interface, unless the parent
interface is really detaching. While here, program only link layer multicast
filters to a wlan's hardware parent interface.

PR:		kern/142391, kern/142392
Reviewed by:	sam, rpaulo, bms
2010-01-31 11:30:28 +00:00
Edward Tomasz Napierala
7782c5efe8 MFC r196949:
Enable NFSv4 ACL support in ZFS.

MFC r197435:

In VOP_SETACL(9) and VOP_GETACL(9), specifying wrong ACL type should result
in EINVAL, not EOPNOTSUPP.
2010-01-31 02:11:14 +00:00
Antoine Brodin
c261b5023b MFC r202448 to stable/8:
Do not build netgraph kernel modules if WITHOUT_NETGRAPH is set in src.conf
  Submitted by:	bf
2010-01-30 15:28:14 +00:00
Antoine Brodin
e2b36efde5 MFC r201145 to stable/8:
(S)LIST_HEAD_INITIALIZER takes a (S)LIST_HEAD as an argument.
  Fix some wrong usages.
  Note: this does not affect generated binaries as this argument is not used.

  PR:		137213
  Submitted by:	Eygene Ryabinkin (initial version)
2010-01-30 12:11:21 +00:00
Alan Cox
6d41eae028 MFC r202894
Handle a race between pmap_kextract() and pmap_promote_pde().
2010-01-30 06:23:28 +00:00
Konstantin Belousov
c9dc5d496d MFC r202692:
Remove the signal from sigqueue before notifying the debugger for traced
process, fixing the race between resuming from stopped state and other
thread noting the old signal on the queue and acting.
2010-01-29 20:02:28 +00:00
Rui Paulo
b85fb2f79c MFC r202986:
o add more notification strings in iwn_intr_str()
  o sync with OpenBSD code

  Submitted by:	Bernhard Schmidt <bschmidt at techwires.net>
  MFC after:	3 days
2010-01-29 18:19:43 +00:00
Rui Paulo
623592e0c0 MFC r202967:
Call ieee80211_radiotap_rx, not ieee80211_radiotap_tx on sta_input()

   PR:		143163
   Submitted by:Alexander Egorenkov <egorenar at gmail.com>
2010-01-29 18:18:18 +00:00
George V. Neville-Neil
fbbbfe0ba5 MFC r196797:
Add ARP statistics to the kernel and netstat.
2010-01-28 16:48:44 +00:00
Joerg Wunsch
1f9b7387d8 Merge of r202870,202898:
Overhaul of the pcii driver:

. Properly allocate all IO space resources.  These cards scatter their
  IO addresses over a range of 0x1600 bytes, and they require an
  additional address for "special interrupt handling".

. Implement the "special interrupt handling" per the GPIB-PCIIA
  Technical Reference Manual; this was apparently not declared for the
  clone card this driver has been originally implemented for, but it
  turned out to be needed for both, an original NI brand PCII/PCIIA
  card as well as the Axiom AX5488 clone.

. Add some diagnostic messages for various resource allocation etc.
  failures during probe.

. Add some comments about the structure of the IO address space that
  is used by these cards.
2010-01-27 10:32:02 +00:00
Bjoern A. Zeeb
ce77b9149a MFC r202915:
Correct a typo.

  Submitted by: kensmith
2010-01-27 09:45:07 +00:00
Marko Zec
b83b25d7b1 MFC r201895:
Reduce recursions on curvnet and thus spamming the console with warning
  messages for kernels built with options VIMAGE and VNET_DEBUG enabled.

  Reviewed by:  bz
2010-01-25 14:17:13 +00:00
Attilio Rao
93a45f0f56 MFC r201879:
Introduce the new kernel thread called "deadlock resolver".
It is used in order to seek within the threads state and heuristically
understand if there is any deadlock happening.

In order to implement it, the sq_type in sleepqueues is mandatory and not
only compiled along with INVARIANTS option. Additively, a new sleepqueue
function, sleepq_type() is added, returning the type of the sleepqueue
linked to a wchan.
Three new sysctls are added in order to configure the thread:
debug.deadlkres.slptime_threshold
debug.deadlkres.blktime_threshold
debug.deadlkres.sleepfreq

rappresenting the thresholds for sleep and block time that will lead to
a deadlock matching (when exceeded), while the sleepfreq rappresents the
number of seconds between 2 consecutive thread runnings.
In order to enable the deadlock resolver thread recompile your kernel
with the option DEADLKRES.

Sponsored by:	Sandvine Incorporated
2010-01-25 12:05:51 +00:00
Attilio Rao
aa16019d66 MFC r201790:
- Set td_slptick to 0 when moving threads out of sleepqueues.
- Move td_slptick from u_int to int in order to follow 'ticks' signedness
  and wrap up accordingly.

Sponsored by:	Sandvine Incorporated
2010-01-25 11:56:53 +00:00
Michael Tuexen
b93b253dc6 MFC 202449:
Get rid of support of an old version of the SCTP-AUTH draft.
Get rid of unused MD5 code.
2010-01-24 22:17:08 +00:00
Gavin Atkinson
7ac856b829 Merge r202000 from head:
Don't panic on attach if we can't allocate ifp

Approved by:	ed (mentor, implicit)
2010-01-24 22:01:04 +00:00
Konstantin Belousov
2af4053ea7 Bump __FreeBSD_version for scandir(3) and alphasort(3) interface changes. 2010-01-24 12:37:30 +00:00
Bjoern A. Zeeb
be6797dde8 MFC r202469:
Garbage collect references to the no longer implemented tcp_fasttimo().
2010-01-24 12:22:38 +00:00
Max Khon
3dd81e0306 MFC: Send link state change control messages to "orphans" hook as well. 2010-01-24 08:59:33 +00:00
Bjoern A. Zeeb
3bcceea40e MFC r202468:
Add ip4.saddrsel/ip4.nosaddrsel (and equivalent for ip6) to control
  whether to use source address selection (default) or the primary
  jail address for unbound outgoing connections.

  This is intended to be used by people upgrading from single-IP
  jails to multi-IP jails but not having to change firewall rules,
  application ACLs, ... but to force their connections (unless
  otherwise changed) to the primry jail IP they had been used for
  years, as well as for people prefering to implement similar policies.

  Note that for IPv6, if configured incorrectly, this might lead to
  scope violations, which single-IPv6 jails could as well, as by the
  design of jails. [1]

  Reviewed by:		jamie, hrs (ipv6 part)
  Pointed out by:	hrs [1]
2010-01-23 16:40:35 +00:00
Robert Noland
c79d8f1fb5 MFC r200764
Fix a handful of issues with via agp support.

  * Read the pci capability register to identify AGP 3 support
  * Add missing smaller aperture sizes for AGP3 chips.
  * Fix the aperture size calculation on AGP2 chips.
    All sizes between 32M and 256M reported as 256M.
  * Add \n to error string.
2010-01-23 16:29:04 +00:00
Navdeep Parhar
c78cb5e4f1 MFC r202863
Don't forget to release the adapter lock for a no-op.
2010-01-23 08:37:04 +00:00
Marcel Moolenaar
5a183eb8e4 MFC rev 202552:
Add command-line option -dev to set the default value of the currdev
variable.
2010-01-23 06:29:34 +00:00
Xin LI
11ad45c9ce MFC r202268:
o Add PCI ID for BCM 5756.
 o Don't enable BGE_FLAG_BER_BUG on both 5722 and 5756, and based
   on their PCI IDs rather than their chip IDs.

Reported by:    several PC-BSD users via kmoore
Reviewed by:    yongari, imp, jhb, davidch
Sponsored by:   iXsystems, Inc.
2010-01-23 01:25:09 +00:00
Xin LI
bd277cec42 MFC r200930:
Adapt OpenBSD pf's "sloopy" TCP state machine which is useful for Direct
Server Return mode, where not all packets would be visible to the load
balancer or gateway.

This commit should be reverted when we merge future pf versions.  The
benefit it would provide is that this version does not break any existing
public interface and thus won't be a problem if we want to MFC it to
earlier FreeBSD releases.

Discussed with:	mlaier
Obtained from:	OpenBSD
Sponsored by:	iXsystems, Inc.
2010-01-23 00:32:19 +00:00
Brooks Davis
2ca586a5ac MFC r201261:
Add missing `void' keywords.
2010-01-22 20:24:55 +00:00
Brooks Davis
52c240aaf4 MFC r201350:
The devices that supported EVFILT_NETDEV kqueue filters were removed in
  r195175.  Remove all definitions, documentation, and usage.

The change of function signature for vlan_link_state() was not merged to
maintain the ABI.
2010-01-22 19:51:34 +00:00
Christian Brueffer
7468bbeaea MFC: r201848
Free allocated sbufs before returning ENOMEM.
2010-01-22 17:03:49 +00:00
Alexander Motin
320cdf733e MFC r202127, r202156:
Add multichannel (4.0, 5.1 and 7.1) playback support.

Stereo stream is no more duplicated to all ports. If you loose sound, check
you are using right connectors. Front speakers connector is usually green,
center/LFE - orange, rear - black, side - gray.
2010-01-22 11:37:19 +00:00
Alexander Motin
858bc163b7 MFC r202267:
Hide from default sndstat some information not used on daily basis,
to make it readable by average user with average screen size.
2010-01-22 11:31:49 +00:00
Alexander Motin
c6ce452791 MFC r202166:
Make default recording source choosing more intelligent.
Change default recording level from 0 to 75.
It should increase chances for things to work just out of the box.
2010-01-22 11:30:32 +00:00
Alexander Motin
d871d872fa MFC r197420:
Lock bus scan.
2010-01-22 11:16:46 +00:00
Andriy Gapon
83279a93f5 MFC r202567: acpi_ec: remove redundant acpi_disabled check 2010-01-22 09:41:09 +00:00
Andriy Gapon
773425fade MFC r202558: acpi_ec: clean up 'private' ivar when freeing memory 2010-01-22 09:34:57 +00:00
Marcel Moolenaar
a354a30d5e MFC rev. 202271-202273:
o  Add wrappers for the RT Variable Services.
o  Add ioctl requests to /dev/io on ia64 for reading and writing
   EFI variables.
2010-01-22 03:59:05 +00:00
Marcel Moolenaar
4b5ab11113 MFC rev. 202097:
Use io(4) for I/O port access on ia64, rather than through sysarch(2).
2010-01-22 03:50:43 +00:00
John Baldwin
49cc13441b MFC 198411:
- Fix several off-by-one errors when using MAXCOMLEN.  The p_comm[] and
  td_name[] arrays are actually MAXCOMLEN + 1 in size and a few places that
  created shadow copies of these arrays were just using MAXCOMLEN.
- Prefer using sizeof() of an array type to explicit constants for the
  array length in a few places.
- Ensure that all of p_comm[] and td_name[] is always zero'd during
  execve() to guard against any possible information leaks.  Previously
  trailing garbage in p_comm[] could be leaked to userland in ktrace
  record headers via td_name[].
2010-01-21 19:11:18 +00:00
John Baldwin
7b10638c5b MFC 198134,198149,198170,198171,198391,200948:
Add a facility for associating optional descriptions with active interrupt
handlers.  This is primarily intended as a way to allow devices that use
multiple interrupts (e.g. MSI) to meaningfully distinguish the various
interrupt handlers.
- Add a new BUS_DESCRIBE_INTR() method to the bus interface to associate
  a description with an active interrupt handler setup by BUS_SETUP_INTR.
  It has a default method (bus_generic_describe_intr()) which simply passes
  the request up to the parent device.
- Add a bus_describe_intr() wrapper around BUS_DESCRIBE_INTR() that supports
  printf(9) style formatting using var args.
- Reserve MAXCOMLEN bytes in the intr_handler structure to hold the name of
  an interrupt handler and copy the name passed to intr_event_add_handler()
  into that buffer instead of just saving the pointer to the name.
- Add a new intr_event_describe_handler() which appends a description string
  to an interrupt handler's name.
- Implement support for interrupt descriptions on amd64, i386, and sparc64 by
  having the nexus(4) driver supply a custom bus_describe_intr method that
  invokes a new intr_describe() MD routine which in turn looks up the
  associated interrupt event and invokes intr_event_describe_handler().
2010-01-21 17:54:29 +00:00
Marius Strobl
828c6b73ab MFC: r202587
Add epic(4) also here.
2010-01-21 17:37:25 +00:00
Christian Brueffer
4e31204f25 MFC: r202290
Build iwi(4) and iwifw(4) modules on amd64 as well.
2010-01-21 16:31:45 +00:00
John Baldwin
4b2625a76f MFC 202286:
Update the ident for the XENHVM kernel config to match the filename.
2010-01-21 15:10:20 +00:00
Navdeep Parhar
cbbe4a754c MFC r201416:
Avoid NULL dereference in arpresolve.

Requested by: kib@
2010-01-21 10:12:21 +00:00
Navdeep Parhar
e0d8d4df28 MFC r201907,202671,202678
r201907:
Extra parantheses to keep certain compilers happy.

r202671:
Fix for a cxgb(4) panic.  cxgb_ioctl can be called by the IP and IPv6
layers with non-sleepable locks held.  Don't (potentially) sleep in
those situations.

r202678:
Complain if freelist queue sizes are significantly less than desired.
2010-01-21 03:06:52 +00:00