Commit Graph

57800 Commits

Author SHA1 Message Date
Andre Oppermann
80444f8803 The sysctls kern.ipc.[max_linkhdr|max_protohdr|max_hdr|max_datalen]
can't be changed from userland.  Make them read-only and provide
descriptions.

kern.ipc.max_datalen must never be less than one byte.  Enforce this
with a panic in net_init_domain().

Sponsored by:	TCP/IP Optimization Fundraise 2005
MFC after:	3 days
2006-02-18 17:16:18 +00:00
Andre Oppermann
8e8aab7aec Remove unneeded includes and provide more accurate description
to others.

Submitted by:	garys
PR:		kern/86437
2006-02-18 17:05:00 +00:00
Andre Oppermann
da3482e0f6 Add missing TH_PUSH to the TH_FLAGS enumeration.
Submitted by:	Andre Albsmeier <Andre.Albsmeier-at-siemens.com>
PR:		kern/85203
2006-02-18 16:50:08 +00:00
Robert Watson
d8ff22ea7f Add system call auditing support for sparc64.
Submitted by:	brueffer
Obtained from:	TrustedBSD Project
2006-02-18 16:36:56 +00:00
Pawel Jakub Dawidek
3d48264f02 Inform when label disappears.
MFC after:	3 days
2006-02-18 11:24:00 +00:00
Pawel Jakub Dawidek
bdf2e45a5c Allow to use g_slice_orphan() from outside.
MFC after:	3 days
2006-02-18 11:21:17 +00:00
Pawel Jakub Dawidek
c058f51257 - Do not depend on fact that file system covers entire provider.
It won't work for file systems created with -s option.
  Use better file system verfication.
- Add myself to the copyright.

MFC after:	3 days
2006-02-18 10:59:47 +00:00
Ariff Abdullah
050519958c - Fix severe crackling after long running and abusive module load / unload by
forcing DMA alignment to default buffer size.
- Make sure DMA pointer properly aligned to avoid being truncated by caller
  which causing severe underruns and random popping (especially in 32bit
  playback / recording).
- Add AC97 inverted external amplifier quirk for Maxselect x710s
  - http://maxselect.ru/

MFC after:	1 week
2006-02-18 10:24:48 +00:00
Ariff Abdullah
fba6b23875 Fix random popping while playing in 32bit by increasing default buffer size
from 4096 to 8192.

MFC after:	1 week
2006-02-18 10:23:37 +00:00
Pawel Jakub Dawidek
17fb8ae78f This function returns nothing. 2006-02-18 03:04:26 +00:00
Pawel Jakub Dawidek
33361bb5db If provider's sector size prevents reading SBLOCKSIZE bytes return
immediatelly.
2006-02-18 03:00:49 +00:00
Max Laier
ff8e7669d6 Use shell's version of if to check if the firmware really exists in the
current directory to allow user rules to create the firmware (e.g. from a
uuencoded blob).  make's version of if is evaluated too early to catch this.

Found-by:	gallatin
2006-02-18 01:38:44 +00:00
Sam Leffler
08d7a88599 use s/w bmiss facility
MFC after:	1 week
2006-02-18 01:04:08 +00:00
Sam Leffler
e3f629dff9 stop device so we don't panic on card eject
MFC after:	1 week
2006-02-18 01:03:09 +00:00
Warner Losh
2f415ac34d These files apply to all the atmel parts that freebsd is going to run on,
so name them more generically.  If we do support the MMU-less ARM7 parts,
then we'll need to, at that time, expand the files we have.
2006-02-17 22:33:13 +00:00
Warner Losh
77017e63bb This file was obsolete when committed. Catchup and delete it. 2006-02-17 22:23:36 +00:00
Tor Egge
625e6c0af4 Expand scope of marker to reduce the number of page queue scan restarts. 2006-02-17 21:02:39 +00:00
Doug Ambrisko
c094bde40d Re-work the bus attachment somewhat. Make the rids unique for
the SMI/TCO address space.  Switch the bus space I/O to the
one specific for either the SMI or TCO space.  Re-calibrate
the tick.  Add some more device id's, 82801FBR submitted by des.
This makes it work on the platforms I've tested with.

Go ahead by:	des
2006-02-17 18:46:18 +00:00
Tor Egge
db27dcc0f0 Check return value from nonblocking call to vn_start_write(). 2006-02-17 18:22:19 +00:00
Oleg Bulyzhin
1493e8838e 1) Ignore link events for MII/GMII cards if MI auto-polling disabled. This
should fix strange link state behaviour reported for bcm5721 & bcm5704c
2) Clear bge_link flag in bge_stop()
3) Force link state check after bge_ifmedia_upd(). Otherwise we can miss link
   event if PHY changes it's state fast enough.

Tested by:	phk (bcm5704c)
Approved by:	glebius (mentor)
MFC after:	1 week
2006-02-17 14:33:35 +00:00
Andre Oppermann
ec63cb90a3 Replace the 4k fixed sized jumbo mbuf clusters with PAGE_SIZE sized
jumbo mbuf clusters.  To make the variable size clear they are named
MJUMPAGESIZE.

Having jumbo clusters with the native PAGE_SIZE is more useful than
a fixed 4k size according the device driver writers using this API.

The 9k and 16k jumbo mbuf clusters remain unchanged.

Requested by:	glebius, gallatin
Sponsored by:	TCP/IP Optimization Fundraise 2005
MFC after:	3 days
2006-02-17 14:14:15 +00:00
Søren Schmidt
608e65bb2a Add r/w support for JMicron ATA RAID metadata.
Acknowledgement should definitly go to JMicron Technology for providing full
docs on the metadata format as the only vendor so far, big thanks from here.
2006-02-17 13:02:10 +00:00
Ruslan Ermilov
525312f7c0 Fix standalone module build.
Reported by:	Boris Samorodov
2006-02-17 10:52:59 +00:00
Gleb Smirnoff
ffbea430b8 Remove unused now field. 2006-02-17 09:42:49 +00:00
David E. O'Brien
40244cc2ca When linking make sure it succeeds. 2006-02-17 04:59:23 +00:00
Eric Anholt
14b4fdc4d6 Add support for the Intel E7205 chipset.
PR:		kern/91315
Submitted by:	Joerg Pulz <Joerg.Pulz@frm2.tum.de>
2006-02-17 01:40:46 +00:00
Tor Egge
6bd7e81d83 Rounding addr upwards to next 4M or 2M boundary in pmap_growkernel() could
cause addr to become 0, resulting in an early return without populating
the last PDE.

Reviewed by:	alc
2006-02-16 22:10:57 +00:00
Andre Oppermann
eaf80179e2 Have TCP Inflight disable itself if the RTT is below a certain
threshold.  Inflight doesn't make sense on a LAN as it has
trouble figuring out the maximal bandwidth because of the coarse
tick granularity.

The sysctl net.inet.tcp.inflight.rttthresh specifies the threshold
in milliseconds below which inflight will disengage.  It defaults
to 10ms.

Tested by:	Joao Barros <joao.barros-at-gmail.com>,
		Rich Murphey <rich-at-whiteoaklabs.com>
Sponsored by:	TCP/IP Optimization Fundraise 2005
2006-02-16 19:38:07 +00:00
Søren Schmidt
e3989d3ebf Add support for the JMicron JMB363 dual SATA + single PATA controller.
Documentation and HW kindly provided by JMicron.
2006-02-16 17:09:24 +00:00
Andre Oppermann
cf744713e8 In in_pcbconnect_setup() reduce code duplication and use ip_rtaddr()
to find the outgoing interface for this connection.

Sponsored by:	TCP/IP Optimization Fundraise 2005
MFC after:	2 weeks
2006-02-16 15:45:28 +00:00
Andre Oppermann
a4684d742d Make sysctl_msec_to_ticks(SYSCTL_HANDLER_ARGS) generally available instead
of being private to tcp_timer.c.

Sponsored by:	TCP/IP Optimization Fundraise 2005
MFC after:	3 days
2006-02-16 15:40:36 +00:00
David Xu
94f0972bec Fix a long standing race between sleep queue and thread
suspension code. When a thread A is going to sleep, it calls
sleepq_catch_signals() to detect any pending signals or thread
suspension request, if nothing happens, it returns without
holding process lock or scheduler lock, this opens a race
window which allows thread B to come in and do process
suspension work, however since A is still at running state,
thread B can do nothing to A, thread A continues, and puts
itself into actually sleeping state, but B has never seen it,
and it sits there forever until B is woken up by other threads
sometimes later(this can be very long delay or never
happen). Fix this bug by forcing sleepq_catch_signals to
return with scheduler lock held.
Fix sleepq_abort() by passing it an interrupted code, previously,
it worked as wakeup_one(), and the interruption can not be
identified correctly by sleep queue code when the sleeping
thread is resumed.
Let thread_suspend_check() returns EINTR or ERESTART, so sleep
queue no longer has to use SIGSTOP as a hack to build a return
value.

Reviewed by:	jhb
MFC after:	1 week
2006-02-15 23:52:01 +00:00
Stephan Uphoff
224409590d When the VM needs to allocated physical memory pages (for non interrupt use)
and it has not plenty of free pages it tries to free pages in the cache queue.
Unfortunately freeing a cached page requires the locking of the object that
owns the page. However in the context of allocating pages we may not be able
to lock the object and thus can only TRY to lock the object. If the locking try
fails the cache page can not be freed and is activated to move it out of the way
so that we may try to free other cache pages.

If all pages in the cache belong to objects that are currently locked the
cache queue can be emptied without freeing a single page. This scenario caused
two problems:

    1)  vm_page_alloc always failed allocation when it tried freeing pages from
        the cache queue and failed to do so. However if there are more than
        cnt.v_interrupt_free_min pages on the free list it should return pages
        when requested with priority VM_ALLOC_SYSTEM. Failure to do so can cause
        resource exhaustion deadlocks.

    2)  Threads than need to allocate pages spend a lot of time cleaning up the
        page queue without really getting anything done while the pagedaemon
         needs to work overtime to refill the cache.

This change fixes the first problem. (1)

Reviewed by:	tegge@
2006-02-15 22:29:53 +00:00
Sam Leffler
1d89d44f74 drop softc lock around copyin/copyout
MFC after:	2 weeks
2006-02-15 18:36:52 +00:00
Sam Leffler
d2f6ed153d fix build w/o AR_DEBUG
MFC after:	2 weeks
2006-02-15 18:35:09 +00:00
Sam Leffler
7a4c5ed92c improve tx/rx buf printing routines
MFC after:	2 weeks
2006-02-15 18:31:04 +00:00
Sam Leffler
9760f8aeb9 add missing bit from 1.130 2006-02-15 18:24:22 +00:00
Sam Leffler
16c8acaab5 o handle fatal errors directly instead of via the task queue
o temporarily dump some h/w state for diagnosis; this will be
  removed once some issues are resolved

MFC after:	2 weeks
2006-02-15 18:23:03 +00:00
Sam Leffler
e2815d6951 use ath_hal_gettxintrtxqs so we only process h/w tx
queues that have an interrupt pending

MFC after:	2 weeks
2006-02-15 18:17:53 +00:00
Sam Leffler
c66c48cba2 fixup comments 2006-02-15 18:15:49 +00:00
Sam Leffler
1539af1ef5 close race between ath_tx_start and ath_tx_processq
Reviewed by:	apatti
MFC after:	1 week
2006-02-15 18:12:24 +00:00
Marius Strobl
f8c28bb5ac For E250 and E450 enable the watchdog part of the MK48Txx as it just
works there.

MFC after:	3 days
2006-02-15 16:56:38 +00:00
David Malone
0cbae93607 It seems bit 5 of cpu_feature2 is the VMX (Virtual Machine Extensions)
bit. While I'm here, delete a comment that was cut and past from the
cpu_features code that doesn't belong here.
2006-02-15 14:48:59 +00:00
Gleb Smirnoff
37790e7f74 Fix fallout from last commit - we need to program the MAC address in em_init(). 2006-02-15 14:27:38 +00:00
Gleb Smirnoff
95c01e57d9 em_hardware_init() in em_init() is not needed, and leads to annoying
link flap.

Submitted by:	ru, Mike Tancsa
2006-02-15 13:45:02 +00:00
Gleb Smirnoff
1d66a76549 Set ifp->if_baudrate according to current speed. 2006-02-15 11:38:33 +00:00
Gleb Smirnoff
c47c580e83 - Rename em_print_link_status() to em_update_link_status().
- In em_attach() remove em_check_for_link(). Not needed here, since
  already done in em_hardware_init().
- In em_attach() replace the printing block with call to
  em_update_link_status().
- Remove modification of sc->link_state from em_hardware_init() and
  from em_media_status(). This makes em_update_link_status() a
  single point of change. Call em_update_link_status() where needed.
2006-02-15 10:51:11 +00:00
Gleb Smirnoff
eb0ec08982 - Second style(9) megacleanup.
- Rename "adapter" to "sc"/"softc", to be like other drivers.

  (-13 Kb less source code)
2006-02-15 08:39:50 +00:00
Gleb Smirnoff
a7c959fe18 Fix build. 2006-02-15 08:25:40 +00:00
Matt Jacob
1dae40eb49 a) clean up some declaration stuff (i.e., make more modern with respect
to getting rid u_int for uint and so on).

b) Turn back on 64 bit DAC support. Cheeze it a bit in that we have two
DMA callback functions- one when we have bus_addr_t > 4 bits in width and
the other which should be normal. Even Cheezier in that we turn off setting
up DMA maps to be BUS_SPACE_MAXADDR if we're in ISP_TARGET_MODE. More work
on this in a week or so.

c) Tested under amd64 and 1MB DFLTPHYS, sparc64, i386 (PAE, but insufficient
memory to really test > 4GB). LINT check under amd64.

MFC after:	1 month
2006-02-15 00:31:48 +00:00