Commit Graph

171465 Commits

Author SHA1 Message Date
matt 52956f334c Fix a typo in the delay loop time delta calculation.
From Irme Desk <imre.deak@teleca.com>.
2008-07-03 06:12:02 +00:00
matt c62a0ac493 Add AT91 support. (XXX need to finish timecounter support). 2008-07-03 01:15:38 +00:00
he 3cb806e403 Add dependencies on the input files + Makefile for the auto-generated
files rumpdefs.h, rumpnode_if.h, and rumpvnode_if.c.  This is so that
an UPDATE build has a chance of succeeding.

Discussed with pooka@, and he wasn't totally against adding this...
2008-07-02 23:03:35 +00:00
he b6ffc4250b Don't rely on <sys/mutex.h> being implicitly included, because on
some ports (mvme68k for example) that's not happening.
2008-07-02 21:18:14 +00:00
rmind 7781a976a7 Avoid calling a syscall when argument to sbrk(2) is zero.
OK by <ad>.
2008-07-02 20:07:43 +00:00
rmind b7cdc71cd2 mq_open: fix confusion of FREAD/FWRITE and VREAD/VWRITE. 2008-07-02 20:06:09 +00:00
rmind 2a94bd63c1 Move scheduling functions from librt to libc.
Fixes PR/38657.
2008-07-02 20:05:16 +00:00
rmind 30dfdb2897 lwp_migrate: if LWP is still on the CPU (LP_RUNNING), it must be handled
like LSONPROC.  Should fix PR/38588.  OK by <ad>.
2008-07-02 19:53:12 +00:00
rmind 160268aca6 Remove proc_representative_lwp(), use a simple LIST_FIRST() instead.
OK by <ad>.
2008-07-02 19:49:58 +00:00
rmind 73f3b7bb31 Remove outdated comments, and historical CCPU_SHIFT. Make resched_cpu static,
const-ify ccpu.  Note: resched_cpu is not correct, should be revisited.

OK by <ad>.
2008-07-02 19:44:10 +00:00
rmind 61fc86b29b Remove locking of p_stmutex from sched_pstats(), protect l_pctcpu with p_lock,
and make l_cpticks lock-less.  Should fix PR/38296.

Reviewed (slightly different version) by <ad>.
2008-07-02 19:38:37 +00:00
drochner 14071b7c24 remove some obviously obsolete definitions 2008-07-02 19:18:52 +00:00
ad 16a991e560 uvm_pageidlezero: fix a broken test which made it give up too easily. 2008-07-02 17:47:53 +00:00
ad b94f79f0e8 Replce exec_map with a pool. Proposed on tech-kern@, reviewed by chs@. 2008-07-02 17:28:54 +00:00
ad df158b64b4 Add some comments. 2008-07-02 17:06:12 +00:00
matt 7408df1239 Change {ff,fd}_exclose and ff_allocated to bool. Change exclose arg to
fd_dup to bool.  Switch assignments from 1/0 to true/false.

This make alpha kernels compile.  Bump kern to 4.99.69 since structure
changed.
2008-07-02 16:45:19 +00:00
matt 41f74018fd Add KASSERTMSG(e, msg) for umass.c. XXX directly calls panic. 2008-07-02 15:25:08 +00:00
matt 1906aa3e59 Switch from KASSERT to CTASSERT for those asserts testing sizes of types. 2008-07-02 14:47:34 +00:00
vanhu d20c6ed916 From Timo Teras: fix some %d to %zu (size_t values) 2008-07-02 14:46:27 +00:00
vanhu 874968c865 fixed some %d to %zu (size_t values) 2008-07-02 14:46:26 +00:00
matt 67b10687dc Add CTASSERT (compile time assert) from FreeBSD.
Causes sources to fail to compile:
<file>:<line>: error: size of array '__ctassert<line>' is negative
2008-07-02 14:39:20 +00:00
reinoud 5eeb4f695a Update node sanity check system and redo allocation recording fixing
corruptions that could take place when overwriting sparse files.

Still one rare corruption possible where blocks are accidentally marked
free, but the cause is not yet found and looking at the pattern it won't
happen in every day use.
2008-07-02 13:25:33 +00:00
nakayama 773fffc601 UltraSPARCs don't have floating point queue, and reading %fq regsiter
will cause illegal instruction trap. So remove the code handling them.
2008-07-02 12:15:19 +00:00
ad 2c51a15095 Alter layout of fdfile_t slightly to make it fit into 64 bytes on alpha. 2008-07-02 10:30:09 +00:00
plunky c4df96ad44 change licence of my old code to two-clause BSD licence
remove my name from advertising list
2008-07-02 10:16:20 +00:00
dyoung d75414adf5 Let us add/remove features from ifconfig, such as support for
various address families (inet, inet6, iso, atalk) and protocols
(802.11, 802.3ad, CARP), simply by trimming the list of sources in
the Makefile.  This helps one customize ifconfig for an embedded
device or for install media, and it eliminates a lot of grotty
#ifdef'age.  Now, the ifconfig syntax and semantics are finalized
at run-time using the constructor routines in each address-family/protocol
module.

(In principle, ifconfig could load virtually all of its syntax from
shared objects.)

Extract a lot of common code into subroutines, in order to shrink
the ifconfig binary a bit.  Make all of the address families share
code for address addition/replacement/removal, and delete "legacy"
code for manipulating addresses.  That may have broken atalk and
iso, despite my best efforts.

Extract an include file, Makefile.inc, containing the make-fu that
both ifconfig and x_ifconfig share.

Sprinkle static.  Change some int's to bool's.  Constify.

Add RCS Ids to carp.c and env.c.  Move media code to a new file,
media.c.  Delete several unneeded header files.

Set, reset, and display the IEEE 802.11 attribute, 'dot11RTSThreshold'.

Bug fix: do not require both a interface address and a destination
address for point-to-point interfaces, but accept a interface
address by itself.
2008-07-02 07:44:13 +00:00
cube 13a6f63066 Protect private mbuf external data storage allocater with a mutex, as it
was done in nfe(4), sk(4) and msk(4).  And maybe some others.
Confirmed to fix the usual issue of data corruption by Jared McNeill.
2008-07-02 03:42:55 +00:00
macallan 9403c29e8e actually initialize sc_dmacmd and get rid of getnodebypci() - use
pcidev_to_ofdev() instead
noticed by Marco Trillo, tested on my iBook G4
2008-07-02 03:20:19 +00:00
dyoung 9b4187042c Comment out some device IDs that do not actually belong to mach64
devices.  This stops machfb0 from trying and failing to attach as
console on my G4 PowerBook.  Now, genfb0 will attach as console,
instead.

Apparently, Michael Lorenz made a similar change on the netbsd-4
branch, but it was never committed to -current.
2008-07-01 23:25:06 +00:00
dyoung dcfcd6affa Cosmetic: use device_t, cfdata_t, __arraycount(), device_private(). 2008-07-01 23:19:48 +00:00
mlelstv be6f2a4b87 Ignore freed rtcache entries. 2008-07-01 20:18:45 +00:00
bouyer 802c7519a2 Raise ci_idepth (and switch to interrupt stack on i386) becore calling
xenevt_event().
2008-07-01 18:49:20 +00:00
bouyer 42f814d7d2 spllower(): return immediatly if ci->ci_ilevel <= nlevel, as the asm
versions do.
2008-07-01 18:44:50 +00:00
pooka d4aaae9291 Code is in subr_hash, not kern_hash.
from Michal Spacek
2008-07-01 15:37:04 +00:00
mrg 1a29454088 hack around PR#38480:
- rename MTRR_I686_NVAR to MTRR_I686_NVAR_MAX, still set to 8
- store mtrr VCNT value into i686_mtrr_vcnt.  if it is less than 8,
  zero out the relevant parts of mtrr_raw[].msraddr
- replace all usage of MTRR_I686_NVAR with either i686_mtrr_vcnt or
  with MTRR_I686_NVAR_MAX as appropriate
- in i686_mtrr_reload() and mtrr_init_first() don't use mtrr_raw[]
  addresses of 0

still needs a bunch of reworking to handle VCNT > 8 case.
2008-07-01 15:27:34 +00:00
tsutsui 4a193f31ac Split device_t/softc with misc cosmetic changes. 2008-07-01 15:15:34 +00:00
tsutsui 5886a7c394 - avoid extra offset calculation in region/multi ops
- fix swapped dist/src in copy_region ops
2008-07-01 15:14:32 +00:00
pooka 371212ff48 Add missing calls for attribute management (e.g. chown, stat).
[Incidentally, stat() won't work on non-NetBSD because of struct stat
binary layout difference and needs to be fixed some day]

from Arnaud Ysmal
2008-07-01 13:09:44 +00:00
pooka e940fdb5d3 regen 2008-07-01 13:03:56 +00:00
pooka 1805817468 Adjust rump syscalls: remove a few pointless ones and add a few
missing ones.
2008-07-01 13:03:08 +00:00
jmcneill 206d3d3809 VT8233+ uses a different register base for capturing, tested by sborrill 2008-07-01 12:43:03 +00:00
pooka d2e855d5a6 Fixes to build rump utilities as host binaries on Linux by removing
sys namespace pollution which has crept in.

Submitted in private mail by takemura, domain ca2.so-net.ne.jp
2008-07-01 12:33:32 +00:00
matt 94bc3febe6 Changes to make lint STFU. 2008-06-30 20:54:19 +00:00
matt 0500366437 Don't build rb.c anymore since it's in libc now. 2008-06-30 20:14:42 +00:00
matt 5a4f0c6b2b Change tree op members/typedefs to rbto_compare_* from rb_compare_* 2008-06-30 20:14:09 +00:00
matt 48717a981d Move rb.c from sys/lib/libkern to common so it can be in both libc and libkern. 2008-06-30 19:03:59 +00:00
reinoud af39897a83 Fix serious allocation recording bug if overwriting piece that was
allocated before. Fixes regression test on random overwriting data.

Also fix endian issues and add extra documentation to variables.
2008-06-30 16:43:13 +00:00
matt 90f0e9be76 Hello 4.99.68 (struct rb_node changed size) 2008-06-30 16:43:12 +00:00
matt da597625e8 Add some significant improvements to the red-black tree implementation.
Shrink size of rb_node by 25% (merge parent/father pointer and flags).
2008-06-30 16:36:18 +00:00
nakayama 3644fd9574 Fix commented sparc derived code. 2008-06-30 14:16:13 +00:00