The NetBSD Project

CVS log for src/sys/kern/kern_time.c

[BACK] Up to [cvs.NetBSD.org] / src / sys / kern

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.218 / (download) - annotate - [select for diffs], Wed Oct 26 23:23:52 2022 UTC (3 months, 1 week ago) by riastradh
Branch: MAIN
CVS Tags: netbsd-10-base, netbsd-10, HEAD
Changes since 1.217: +3 -3 lines
Diff to previous 1.217 (colored)

sys: Put externs for time_adjtime and time_adjusted in .h files.

time_adjtime: sys/timex.h (defined in ntp code)
time_adjusted: sys/timevar.h (defined in non-ntp code)

(Not really sure this is a valuable distinction to maintain; there's
non-ntp code that uses time_adjtime too.)

Revision 1.217 / (download) - annotate - [select for diffs], Fri Jul 1 21:22:44 2022 UTC (7 months ago) by riastradh
Branch: MAIN
CVS Tags: bouyer-sunxi-drm-base, bouyer-sunxi-drm
Changes since 1.216: +36 -36 lines
Diff to previous 1.216 (colored)

kern: KNF in kern_time.c: Omit needless return parentheses.

Also nix trailing whitespace while here.

No functional change intended.

Revision 1.216 / (download) - annotate - [select for diffs], Mon Jun 27 00:34:24 2022 UTC (7 months, 1 week ago) by riastradh
Branch: MAIN
Changes since 1.215: +12 -4 lines
Diff to previous 1.215 (colored)

setitimer(2): Avoid arithmetic overflow in periodic bookkeeping.

Reported-by: syzbot+93cef6090844ec304cde@syzkaller.appspotmail.com

Revision 1.215 / (download) - annotate - [select for diffs], Sun Jun 26 22:31:58 2022 UTC (7 months, 1 week ago) by riastradh
Branch: MAIN
Changes since 1.214: +14 -3 lines
Diff to previous 1.214 (colored)

setitimer(2): Guard against overflow in arithmetic.

Reported-by: syzbot+6036bc8b6d2b963e3ba6@syzkaller.appspotmail.com

Revision 1.214 / (download) - annotate - [select for diffs], Sun May 15 16:20:10 2022 UTC (8 months, 3 weeks ago) by riastradh
Branch: MAIN
Changes since 1.213: +6 -4 lines
Diff to previous 1.213 (colored)

adjtime(2): Handle negative tv_sec and tv_usec.

Previously I clamped these to avoid dangerous arithmetic overflow.
But I assumed sensible values should be nonnegative.

For tv_sec, this assumption was just wrong -- the adjustment may be
negative.

For tv_usec, this assumption is...not wrong, but also not right.
tv_usec is not _supposed_ to be negative (by POSIX, the type need
only represent values in [-1, 1000000]; semantically the member is
supposed to be a nonnegative number of microseconds below 1000000),
but ntp abuses it to hold negative values, for reasons unclear -- the
same effect could be had by subtracting one from tv_sec, and adding
1000000 to the negative tv_usec.  However, let's not break existing
ntp userlands...

Revision 1.213 / (download) - annotate - [select for diffs], Sun Mar 13 12:21:28 2022 UTC (10 months, 3 weeks ago) by riastradh
Branch: MAIN
Changes since 1.212: +10 -4 lines
Diff to previous 1.212 (colored)

kern: Handle clock winding back in nanosleep1 without overflow.

Reported-by: syzbot+3bdd260582424a611946@syzkaller.appspotmail.com

Revision 1.212 / (download) - annotate - [select for diffs], Sat Mar 12 16:46:57 2022 UTC (10 months, 3 weeks ago) by riastradh
Branch: MAIN
Changes since 1.211: +13 -4 lines
Diff to previous 1.211 (colored)

kern: Clamp time_adjtime to avoid overflow.

Reported-by: syzbot+7edce1a31dfd2a5eaa18@syzkaller.appspotmail.com

Revision 1.206.2.2 / (download) - annotate - [select for diffs], Sat Apr 3 22:29:00 2021 UTC (22 months ago) by thorpej
Branch: thorpej-futex
Changes since 1.206.2.1: +4 -5 lines
Diff to previous 1.206.2.1 (colored) next main 1.207 (colored)

Sync with HEAD.

Revision 1.210.2.1 / (download) - annotate - [select for diffs], Sat Apr 3 21:45:00 2021 UTC (22 months ago) by thorpej
Branch: thorpej-cfargs
Changes since 1.210: +4 -5 lines
Diff to previous 1.210 (colored) next main 1.211 (colored)

Sync with HEAD.

Revision 1.211 / (download) - annotate - [select for diffs], Sat Apr 3 12:57:21 2021 UTC (22 months ago) by simonb
Branch: MAIN
CVS Tags: thorpej-i2c-spi-conf2-base, thorpej-i2c-spi-conf2, thorpej-i2c-spi-conf-base, thorpej-i2c-spi-conf, thorpej-futex2-base, thorpej-futex2, thorpej-futex-base, thorpej-cfargs2-base, thorpej-cfargs2, thorpej-cfargs-base, cjep_sun2x-base1, cjep_sun2x-base, cjep_sun2x, cjep_staticlib_x-base1, cjep_staticlib_x-base, cjep_staticlib_x
Changes since 1.210: +4 -5 lines
Diff to previous 1.210 (colored)

Centralise the setitimer() timer type validation in dosetitimer() as is
done with dogetitimer().

Revision 1.206.2.1 / (download) - annotate - [select for diffs], Mon Dec 14 14:38:14 2020 UTC (2 years, 1 month ago) by thorpej
Branch: thorpej-futex
Changes since 1.206: +824 -613 lines
Diff to previous 1.206 (colored)

Sync w/ HEAD.

Revision 1.210 / (download) - annotate - [select for diffs], Tue Dec 8 04:09:38 2020 UTC (2 years, 1 month ago) by thorpej
Branch: MAIN
Branch point for: thorpej-cfargs
Changes since 1.209: +50 -48 lines
Diff to previous 1.209 (colored)

A couple of tweaks to the previous re-factor:

- Some of what was defined as "generic itimer" behavior turned out to be
  ptimer-specific.  As such, everything related to the "fired timer queue"
  is now specific to ptimers, and the queue and softint handle fields of
  itimer_ops are not needed.

- Split itimer_fini() into 2 parts: itimer_poision() marks the timer as
  dead and attempts to cancel it.  itimer_fini() is then just responsible
  for freeing itimer resources and releasing the lock.  They are split
  into two parts, as ptimers require an addition processing step between
  those two operations, but other kinds of itimers do not necessarily require
  that.

- Export a few more itimer-related symbols that other itimer types will
  need.

Riding previous kernel version bump since there are no external uses of
this code since the version bump that accompanied the original change.

Revision 1.209 / (download) - annotate - [select for diffs], Mon Dec 7 03:01:15 2020 UTC (2 years, 1 month ago) by christos
Branch: MAIN
Changes since 1.208: +4 -2 lines
Diff to previous 1.208 (colored)

fix the build; gcc does not always see that it can't happen.

Revision 1.208 / (download) - annotate - [select for diffs], Sun Dec 6 13:45:58 2020 UTC (2 years, 2 months ago) by thorpej
Branch: MAIN
Changes since 1.207: +6 -6 lines
Diff to previous 1.207 (colored)

Fix an uninitialized pointer deref introduced in rev 1.207.

Reported-by: syzbot+6d69101d5f2fd954c4e2@syzkaller.appspotmail.com

Revision 1.207 / (download) - annotate - [select for diffs], Sat Dec 5 18:17:01 2020 UTC (2 years, 2 months ago) by thorpej
Branch: MAIN
Changes since 1.206: +821 -614 lines
Diff to previous 1.206 (colored)

Refactor interval timers to make it possible to support types other than
the BSD/POSIX per-process timers:

- "struct ptimer" is split into "struct itimer" (common interval timer
  data) and "struct ptimer" (per-process timer data, which contains a
  "struct itimer").

- Introduce a new "struct itimer_ops" that supplies information about
  the specific kind of interval timer, including it's processing
  queue, the softint handle used to schedule processing, the function
  to call when the timer fires (which adds it to the queue), and an
  optional function to call when the CLOCK_REALTIME clock is changed by
  a call to clock_settime() or settimeofday().

- Rename some fuctions to clearly identify what they're operating on
  (ptimer vs itimer).

- Use kmem(9) to allocate ptimer-related structures, rather than having
  dedicated pools for them.

Welcome to NetBSD 9.99.77.

Revision 1.197.4.4 / (download) - annotate - [select for diffs], Sun Nov 1 17:26:01 2020 UTC (2 years, 3 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-3-RELEASE, netbsd-9-2-RELEASE
Changes since 1.197.4.3: +9 -2 lines
Diff to previous 1.197.4.3 (colored) to branchpoint 1.197 (colored) next main 1.198 (colored)

Pull up following revision(s) (requested by nia in ticket #1124):

	sys/kern/kern_time.c: revision 1.206

kern_time: prevent the system clock from being set too low or high
currently doing this will drive KUBSAN haywire and possibly cause
system lock-ups, so more testing should probably be performed before
we let the clock be set too many thousands of years into the future.

ditto for negative values, which were being passed by chrony for
some reason while my internet connection was being unreliable.
this also triggered some interesting KUBSAN reports.

Revision 1.206 / (download) - annotate - [select for diffs], Tue Oct 27 00:07:18 2020 UTC (2 years, 3 months ago) by nia
Branch: MAIN
Branch point for: thorpej-futex
Changes since 1.205: +9 -2 lines
Diff to previous 1.205 (colored)

kern_time: prevent the system clock from being set too low or high

currently doing this will drive KUBSAN haywire and possibly cause
system lock-ups, so more testing should probably be performed before
we let the clock be set too many thousands of years into the future.

ditto for negative values, which were being passed by chrony for
some reason while my internet connection was being unreliable.
this also triggered some interesting KUBSAN reports.

Revision 1.189.8.6 / (download) - annotate - [select for diffs], Mon May 25 17:48:16 2020 UTC (2 years, 8 months ago) by martin
Branch: netbsd-8
Changes since 1.189.8.5: +7 -3 lines
Diff to previous 1.189.8.5 (colored) to branchpoint 1.189 (colored) next main 1.190 (colored)

Pull up following revision(s) (requested by christos in ticket #1549):

	sys/netinet/igmp.c: revision 1.70
	sys/kern/kern_time.c: revision 1.204

igmp_sendpkt() expects ip_output() to set 'imo.imo_multicast_ttl' into
'ip->ip_ttl'; but ip_output() won't if the target is not a multicast
address, meaning that the uninitialized 'ip->ip_ttl' byte gets sent to
the network. This leaks one byte of kernel heap.

Fix this by filling 'ip->ip_ttl' with a TTL of one.
Found by KMSAN.

 -

Fix uninitialized memory access. Found by KMSAN.

Revision 1.205 / (download) - annotate - [select for diffs], Sat May 23 23:42:43 2020 UTC (2 years, 8 months ago) by ad
Branch: MAIN
Changes since 1.204: +4 -4 lines
Diff to previous 1.204 (colored)

Move proc_lock into the data segment.  It was dynamically allocated because
at the time we had mutex_obj_alloc() but not __cacheline_aligned.

Revision 1.197.4.3 / (download) - annotate - [select for diffs], Mon May 18 19:05:32 2020 UTC (2 years, 8 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-1-RELEASE
Changes since 1.197.4.2: +7 -3 lines
Diff to previous 1.197.4.2 (colored) to branchpoint 1.197 (colored)

Pull up following revision(s) (requested by maxv in ticket #916):

	sys/kern/kern_time.c: revision 1.204

Fix uninitialized memory access. Found by KMSAN.

Revision 1.204 / (download) - annotate - [select for diffs], Thu May 14 18:18:24 2020 UTC (2 years, 8 months ago) by maxv
Branch: MAIN
Changes since 1.203: +7 -3 lines
Diff to previous 1.203 (colored)

Fix uninitialized memory access. Found by KMSAN.

Reported-by: syzbot+9f2a173d29d66c88f9ac@syzkaller.appspotmail.com

Revision 1.189.16.3 / (download) - annotate - [select for diffs], Mon Apr 13 08:05:04 2020 UTC (2 years, 9 months ago) by martin
Branch: phil-wifi
Changes since 1.189.16.2: +75 -8 lines
Diff to previous 1.189.16.2 (colored) to branchpoint 1.189 (colored) next main 1.190 (colored)

Mostly merge changes from HEAD upto 20200411

Revision 1.189.16.2 / (download) - annotate - [select for diffs], Wed Apr 8 14:08:51 2020 UTC (2 years, 9 months ago) by martin
Branch: phil-wifi
Changes since 1.189.16.1: +2 -9 lines
Diff to previous 1.189.16.1 (colored) to branchpoint 1.189 (colored)

Merge changes from current as of 20200406

Revision 1.203 / (download) - annotate - [select for diffs], Thu Jan 2 15:42:27 2020 UTC (3 years, 1 month ago) by thorpej
Branch: MAIN
CVS Tags: phil-wifi-20200421, phil-wifi-20200411, phil-wifi-20200406, is-mlppp-base, is-mlppp, bouyer-xenpvh-base2, bouyer-xenpvh-base1, bouyer-xenpvh-base, bouyer-xenpvh, ad-namecache-base3, ad-namecache-base2, ad-namecache-base1, ad-namecache-base, ad-namecache
Changes since 1.202: +2 -4 lines
Diff to previous 1.202 (colored)

- Eliminate the global "boottime" variable, which was being accessed
  without any synchronization against changes by e.g. clock_settime().
- Replace with new getbinboottime() / getnanoboottime() / getmicroboottime()
  functions (naming mirrors that of other time access functions in kern_tc.c).
  It returns the (maybe-converted) value of timebasebin, which also tracks
  our estimate of when the system was booted (i.e. the legacy "boottime" was
  redundant).

XXX There needs to be a lockless synchronization mechanism for reading
timebasebin, but this is a problem in kern_tc.c that pre-existed these
"boottime" changes.  At least now the problem is centralized in one location.

Revision 1.202 / (download) - annotate - [select for diffs], Wed Jan 1 17:28:17 2020 UTC (3 years, 1 month ago) by thorpej
Branch: MAIN
Changes since 1.201: +2 -7 lines
Diff to previous 1.201 (colored)

Remove superfluous splclock()/splx() pair around tc_setclock().

Revision 1.201 / (download) - annotate - [select for diffs], Sat Oct 5 12:57:40 2019 UTC (3 years, 4 months ago) by kamil
Branch: MAIN
CVS Tags: phil-wifi-20191119
Changes since 1.200: +5 -2 lines
Diff to previous 1.200 (colored)

Check for valid timespec in clock_settime1()

An alternative approach would be to check the valie in settime1(), but
it would result in multiple checks for valid tv_nsec, as there are
settime1() users that need to check the ranges earlier.

Reported-by: syzbot+96e5ce2c2c704d96c2f0@syzkaller.appspotmail.com

Revision 1.200 / (download) - annotate - [select for diffs], Fri Sep 20 14:12:57 2019 UTC (3 years, 4 months ago) by kamil
Branch: MAIN
Changes since 1.199: +5 -2 lines
Diff to previous 1.199 (colored)

Validate usec ranges in settimeofday1()

Revision 1.197.4.2 / (download) - annotate - [select for diffs], Wed Sep 11 16:36:13 2019 UTC (3 years, 4 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-0-RELEASE, netbsd-9-0-RC2, netbsd-9-0-RC1
Changes since 1.197.4.1: +3 -3 lines
Diff to previous 1.197.4.1 (colored) to branchpoint 1.197 (colored)

Additionally pull up the following revision for ticket #192, to fix the build:

	src/sys/kern/kern_time.c	1.199

mark a variable __diagused to fix this problem affecting many builds:

kern/kern_time.c:1413:6: error: variable 'error' set but not used
[-Werror=unused-but-set-variable]

Revision 1.197.4.1 / (download) - annotate - [select for diffs], Tue Sep 10 16:16:46 2019 UTC (3 years, 4 months ago) by martin
Branch: netbsd-9
Changes since 1.197: +71 -10 lines
Diff to previous 1.197 (colored)

Pull up following revision(s) (requested by maxv in ticket #192):

	sys/sys/timevar.h: revision 1.39
	sys/kern/kern_time.c: revision 1.198

Fix race in timer destruction.

Anything we confirmed about the world before callout_halt may cease
to be true afterward, so make sure to start over in that case.

Add some comments explaining what's going on.

Revision 1.199 / (download) - annotate - [select for diffs], Wed Aug 7 07:22:12 2019 UTC (3 years, 6 months ago) by mrg
Branch: MAIN
Changes since 1.198: +3 -3 lines
Diff to previous 1.198 (colored)

mark a variable __diagused to fix this problem affecting many builds:

kern/kern_time.c:1413:6: error: variable 'error' set but not used [-Werror=unused-but-set-variable]

Revision 1.198 / (download) - annotate - [select for diffs], Tue Aug 6 15:47:55 2019 UTC (3 years, 6 months ago) by riastradh
Branch: MAIN
Changes since 1.197: +71 -10 lines
Diff to previous 1.197 (colored)

Fix race in timer destruction.

Anything we confirmed about the world before callout_halt may cease
to be true afterward, so make sure to start over in that case.

Add some comments explaining what's going on.

Reported-by: syzbot+d58da99969f58c1a024a@syzkaller.appspotmail.com

Revision 1.189.16.1 / (download) - annotate - [select for diffs], Mon Jun 10 22:09:03 2019 UTC (3 years, 7 months ago) by christos
Branch: phil-wifi
Changes since 1.189: +10 -7 lines
Diff to previous 1.189 (colored)

Sync with HEAD

Revision 1.197 / (download) - annotate - [select for diffs], Sun Mar 10 14:45:53 2019 UTC (3 years, 10 months ago) by kre
Branch: MAIN
CVS Tags: phil-wifi-20190609, netbsd-9-base, isaki-audio2-base, isaki-audio2
Branch point for: netbsd-9
Changes since 1.196: +4 -4 lines
Diff to previous 1.196 (colored)

Fix the code that deals with very long sleeps (> 248 days) which
go beyond the maximum that the callout mechanism can handle.
[See the comments in tvtohz() in subr_sleep.c for the details.]

When that happens the timeout is clamped to MAX_INT (ticks), and the
code in nanosleep1() looped (or tried to) repeating the sleep (aka
kpause()) until the requested end time for the sleep was reached.

Unfortunately, the code assumed that kpause() would return 0 when
it returned after the timeout expired.   But it doesn't, it returns
EWOULDBLOCK instead (why is incomprehensible to me, but I assume
there is a reason.)   [That comes from sleepq_block() which returns
EWOULDBLOCK when callout_halt() indicates that the callout had fired,
which is exactly what has happened when the time has elapsed.]

There was already code to deal with that EWOULDBLOCK and return 0
instead of an error in that case - but it was placed after the
error code was tested against 0 for the purposes of the loop.

Simply move the EWOULDBLOCK->0 mapping earlier, so the code which
is expecting "error == 0" to mean "nothing went wrong" actually
gets to see that happen, and the loop can actually loop.

(Someday the loop should probably be rewritten as a loop, instead of
as a bunch of code followed by a "goto again"!)

Revision 1.179.12.6 / (download) - annotate - [select for diffs], Sun Feb 24 10:55:24 2019 UTC (3 years, 11 months ago) by martin
Branch: netbsd-7-0
Changes since 1.179.12.5: +3 -3 lines
Diff to previous 1.179.12.5 (colored) to branchpoint 1.179 (colored) next main 1.180 (colored)

Pull up following revision(s) (requested by mlelstv in ticket #1196):

	sys/kern/kern_time.c: revision 1.196

The callout is used by any nonvirtual timer including CLOCK_MONOTONIC
and needs to be initialized.

Detected by [syzkaller].

Revision 1.179.8.1.4.5 / (download) - annotate - [select for diffs], Sun Feb 24 10:54:36 2019 UTC (3 years, 11 months ago) by martin
Branch: netbsd-7-1
Changes since 1.179.8.1.4.4: +3 -3 lines
Diff to previous 1.179.8.1.4.4 (colored) to branchpoint 1.179.8.1 (colored) next main 1.179.8.2 (colored)

Pull up following revision(s) (requested by mlelstv in ticket #1196):

	sys/kern/kern_time.c: revision 1.196

The callout is used by any nonvirtual timer including CLOCK_MONOTONIC
and needs to be initialized.

Detected by [syzkaller].

Revision 1.179.8.6 / (download) - annotate - [select for diffs], Sun Feb 24 10:53:32 2019 UTC (3 years, 11 months ago) by martin
Branch: netbsd-7
Changes since 1.179.8.5: +3 -3 lines
Diff to previous 1.179.8.5 (colored) to branchpoint 1.179 (colored) next main 1.180 (colored)

Pull up following revision(s) (requested by mlelstv in ticket #1196):

	sys/kern/kern_time.c: revision 1.196

The callout is used by any nonvirtual timer including CLOCK_MONOTONIC
and needs to be initialized.

Detected by [syzkaller].

Revision 1.189.8.5 / (download) - annotate - [select for diffs], Sun Feb 24 10:49:53 2019 UTC (3 years, 11 months ago) by martin
Branch: netbsd-8
CVS Tags: netbsd-8-2-RELEASE, netbsd-8-1-RELEASE, netbsd-8-1-RC1
Changes since 1.189.8.4: +3 -3 lines
Diff to previous 1.189.8.4 (colored) to branchpoint 1.189 (colored)

Pull up following revision(s) (requested by mlelstv in ticket #1196):

	sys/kern/kern_time.c: revision 1.196

The callout is used by any nonvirtual timer including CLOCK_MONOTONIC
and needs to be initialized.

Detected by [syzkaller].

Revision 1.196 / (download) - annotate - [select for diffs], Sun Feb 24 07:23:11 2019 UTC (3 years, 11 months ago) by mlelstv
Branch: MAIN
Changes since 1.195: +3 -3 lines
Diff to previous 1.195 (colored)

The callout is used by any nonvirtual timer including CLOCK_MONOTONIC
and needs to be initialized.

Detected by [syzkaller].

Revision 1.195 / (download) - annotate - [select for diffs], Sun Feb 10 17:13:33 2019 UTC (3 years, 11 months ago) by christos
Branch: MAIN
Changes since 1.194: +4 -6 lines
Diff to previous 1.194 (colored)

Introduce PR_ZERO to avoid open-coding memset()s everywhere. OK riastradh@.

Revision 1.189.8.4 / (download) - annotate - [select for diffs], Fri Feb 1 11:21:30 2019 UTC (4 years ago) by martin
Branch: netbsd-8
Changes since 1.189.8.3: +4 -2 lines
Diff to previous 1.189.8.3 (colored) to branchpoint 1.189 (colored)

Pull up following revision(s) (requested by maxv in ticket #1180):

	sys/kern/kern_time.c: revision 1.190
	sys/kern/kern_time.c: revision 1.194

Fix stack info leak. There are 4 bytes of padding in struct timeval. Looks
like there are other leaks related to timeval in this file.

[  133.414352] kleak: Possible leak in copyout: [len=16, leaked=4]
[  133.414352] #0 0xffffffff80224d0a in kleak_note <netbsd>
[  133.424360] #1 0xffffffff80224d8a in kleak_copyout <netbsd>
[  133.434361] #2 0xffffffff80b5fd79 in sys___gettimeofday50 <netbsd>
[  133.434361] #3 0xffffffff8025a89c in sy_call <netbsd>
[  133.444351] #4 0xffffffff8025aace in sy_invoke <netbsd>
[  133.454365] #5 0xffffffff8025ab54 in syscall <netbsd>

 -

Fix kernel info leaks.

Revision 1.179.12.5 / (download) - annotate - [select for diffs], Fri Feb 1 11:12:03 2019 UTC (4 years ago) by martin
Branch: netbsd-7-0
Changes since 1.179.12.4: +4 -2 lines
Diff to previous 1.179.12.4 (colored) to branchpoint 1.179 (colored)

Pull up following revision(s) (requested by maxv in ticket #1678):

	sys/kern/kern_time.c: revision 1.190
	sys/kern/kern_time.c: revision 1.194

Fix stack info leak. There are 4 bytes of padding in struct timeval. Looks
like there are other leaks related to timeval in this file.

[  133.414352] kleak: Possible leak in copyout: [len=16, leaked=4]
[  133.414352] #0 0xffffffff80224d0a in kleak_note <netbsd>
[  133.424360] #1 0xffffffff80224d8a in kleak_copyout <netbsd>
[  133.434361] #2 0xffffffff80b5fd79 in sys___gettimeofday50 <netbsd>
[  133.434361] #3 0xffffffff8025a89c in sy_call <netbsd>
[  133.444351] #4 0xffffffff8025aace in sy_invoke <netbsd>
[  133.454365] #5 0xffffffff8025ab54 in syscall <netbsd>

 -

Fix kernel info leaks.

Revision 1.179.8.1.4.4 / (download) - annotate - [select for diffs], Fri Feb 1 11:08:56 2019 UTC (4 years ago) by martin
Branch: netbsd-7-1
Changes since 1.179.8.1.4.3: +4 -2 lines
Diff to previous 1.179.8.1.4.3 (colored) to branchpoint 1.179.8.1 (colored)

Pull up following revision(s) (requested by maxv in ticket #1678):

	sys/kern/kern_time.c: revision 1.190
	sys/kern/kern_time.c: revision 1.194

Fix stack info leak. There are 4 bytes of padding in struct timeval. Looks
like there are other leaks related to timeval in this file.

[  133.414352] kleak: Possible leak in copyout: [len=16, leaked=4]
[  133.414352] #0 0xffffffff80224d0a in kleak_note <netbsd>
[  133.424360] #1 0xffffffff80224d8a in kleak_copyout <netbsd>
[  133.434361] #2 0xffffffff80b5fd79 in sys___gettimeofday50 <netbsd>
[  133.434361] #3 0xffffffff8025a89c in sy_call <netbsd>
[  133.444351] #4 0xffffffff8025aace in sy_invoke <netbsd>
[  133.454365] #5 0xffffffff8025ab54 in syscall <netbsd>

 -

Fix kernel info leaks.

Revision 1.179.8.5 / (download) - annotate - [select for diffs], Fri Feb 1 11:06:20 2019 UTC (4 years ago) by martin
Branch: netbsd-7
Changes since 1.179.8.4: +4 -2 lines
Diff to previous 1.179.8.4 (colored) to branchpoint 1.179 (colored)

Pull up following revision(s) (requested by maxv in ticket #1678):

	sys/kern/kern_time.c: revision 1.190
	sys/kern/kern_time.c: revision 1.194

Fix stack info leak. There are 4 bytes of padding in struct timeval. Looks
like there are other leaks related to timeval in this file.

[  133.414352] kleak: Possible leak in copyout: [len=16, leaked=4]
[  133.414352] #0 0xffffffff80224d0a in kleak_note <netbsd>
[  133.424360] #1 0xffffffff80224d8a in kleak_copyout <netbsd>
[  133.434361] #2 0xffffffff80b5fd79 in sys___gettimeofday50 <netbsd>
[  133.434361] #3 0xffffffff8025a89c in sy_call <netbsd>
[  133.444351] #4 0xffffffff8025aace in sy_invoke <netbsd>
[  133.454365] #5 0xffffffff8025ab54 in syscall <netbsd>

 -

Fix kernel info leaks.

Revision 1.194 / (download) - annotate - [select for diffs], Thu Jan 31 20:09:05 2019 UTC (4 years ago) by maxv
Branch: MAIN
Changes since 1.193: +3 -2 lines
Diff to previous 1.193 (colored)

Fix kernel info leaks.

Revision 1.189.8.3 / (download) - annotate - [select for diffs], Thu Dec 27 12:19:45 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-8
Changes since 1.189.8.2: +3 -2 lines
Diff to previous 1.189.8.2 (colored) to branchpoint 1.189 (colored)

Pull up following revision(s) (requested by maxv in ticket #1147):

	sys/kern/kern_time.c: revision 1.191

Fix kernel info leak. There are 2x4 bytes of padding in struct itimerval.

[  738.451860] kleak: Possible leak in copyout: [len=32, leaked=8]
[  738.481840] #0 0xffffffff80b7c42a in kleak_note <netbsd>
[  738.491821] #1 0xffffffff80b7c4aa in kleak_copyout <netbsd>
[  738.501806] #2 0xffffffff80b6154e in sys___getitimer50 <netbsd>
[  738.511778] #3 0xffffffff80b61e39 in sys___setitimer50 <netbsd>
[  738.521781] #4 0xffffffff8025ab3c in sy_call <netbsd>
[  738.521781] #5 0xffffffff8025ad6e in sy_invoke <netbsd>
[  738.531808] #6 0xffffffff8025adf4 in syscall <netbsd>

Revision 1.179.12.4 / (download) - annotate - [select for diffs], Thu Dec 27 12:01:50 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-7-0
Changes since 1.179.12.3: +3 -2 lines
Diff to previous 1.179.12.3 (colored) to branchpoint 1.179 (colored)

Pull up following revision(s) (requested by maxv in ticket #1667):

	sys/kern/kern_time.c: revision 1.191

Fix kernel info leak. There are 2x4 bytes of padding in struct itimerval.

[  738.451860] kleak: Possible leak in copyout: [len=32, leaked=8]
[  738.481840] #0 0xffffffff80b7c42a in kleak_note <netbsd>
[  738.491821] #1 0xffffffff80b7c4aa in kleak_copyout <netbsd>
[  738.501806] #2 0xffffffff80b6154e in sys___getitimer50 <netbsd>
[  738.511778] #3 0xffffffff80b61e39 in sys___setitimer50 <netbsd>
[  738.521781] #4 0xffffffff8025ab3c in sy_call <netbsd>
[  738.521781] #5 0xffffffff8025ad6e in sy_invoke <netbsd>
[  738.531808] #6 0xffffffff8025adf4 in syscall <netbsd>

Revision 1.179.8.1.4.3 / (download) - annotate - [select for diffs], Thu Dec 27 12:01:06 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-7-1
Changes since 1.179.8.1.4.2: +3 -2 lines
Diff to previous 1.179.8.1.4.2 (colored) to branchpoint 1.179.8.1 (colored)

Pull up following revision(s) (requested by maxv in ticket #1667):

	sys/kern/kern_time.c: revision 1.191

Fix kernel info leak. There are 2x4 bytes of padding in struct itimerval.

[  738.451860] kleak: Possible leak in copyout: [len=32, leaked=8]
[  738.481840] #0 0xffffffff80b7c42a in kleak_note <netbsd>
[  738.491821] #1 0xffffffff80b7c4aa in kleak_copyout <netbsd>
[  738.501806] #2 0xffffffff80b6154e in sys___getitimer50 <netbsd>
[  738.511778] #3 0xffffffff80b61e39 in sys___setitimer50 <netbsd>
[  738.521781] #4 0xffffffff8025ab3c in sy_call <netbsd>
[  738.521781] #5 0xffffffff8025ad6e in sy_invoke <netbsd>
[  738.531808] #6 0xffffffff8025adf4 in syscall <netbsd>

Revision 1.179.8.4 / (download) - annotate - [select for diffs], Thu Dec 27 12:00:10 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-7
Changes since 1.179.8.3: +3 -2 lines
Diff to previous 1.179.8.3 (colored) to branchpoint 1.179 (colored)

Pull up following revision(s) (requested by maxv in ticket #1667):

	sys/kern/kern_time.c: revision 1.191

Fix kernel info leak. There are 2x4 bytes of padding in struct itimerval.

[  738.451860] kleak: Possible leak in copyout: [len=32, leaked=8]
[  738.481840] #0 0xffffffff80b7c42a in kleak_note <netbsd>
[  738.491821] #1 0xffffffff80b7c4aa in kleak_copyout <netbsd>
[  738.501806] #2 0xffffffff80b6154e in sys___getitimer50 <netbsd>
[  738.511778] #3 0xffffffff80b61e39 in sys___setitimer50 <netbsd>
[  738.521781] #4 0xffffffff8025ab3c in sy_call <netbsd>
[  738.521781] #5 0xffffffff8025ad6e in sy_invoke <netbsd>
[  738.531808] #6 0xffffffff8025adf4 in syscall <netbsd>

Revision 1.189.14.2 / (download) - annotate - [select for diffs], Wed Dec 26 14:02:04 2018 UTC (4 years, 1 month ago) by pgoyette
Branch: pgoyette-compat
CVS Tags: pgoyette-compat-merge-20190127
Changes since 1.189.14.1: +4 -2 lines
Diff to previous 1.189.14.1 (colored) to branchpoint 1.189 (colored) next main 1.190 (colored)

Sync with HEAD, resolve a few conflicts

Revision 1.179.12.3 / (download) - annotate - [select for diffs], Fri Dec 14 12:07:54 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-7-0
Changes since 1.179.12.2: +3 -2 lines
Diff to previous 1.179.12.2 (colored) to branchpoint 1.179 (colored)

Additionally pull up following revision(s) (requested by maxv in ticket #1660):

	sys/compat/linux/common/linux_misc_notalpha.c: revision 1.110
	sys/kern/kern_time.c: revision 1.193

Improve my kern_time.c::rev1.192, systematically clear the buffers we get
from 'ptimer_pool' to prevent more leaks.

Revision 1.179.8.1.4.2 / (download) - annotate - [select for diffs], Fri Dec 14 12:06:43 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-7-1
Changes since 1.179.8.1.4.1: +3 -2 lines
Diff to previous 1.179.8.1.4.1 (colored) to branchpoint 1.179.8.1 (colored)

Additionally pull up following revision(s) (requested by maxv in ticket #1660):

	sys/compat/linux/common/linux_misc_notalpha.c: revision 1.110
	sys/kern/kern_time.c: revision 1.193

Improve my kern_time.c::rev1.192, systematically clear the buffers we get
from 'ptimer_pool' to prevent more leaks.

Revision 1.179.8.3 / (download) - annotate - [select for diffs], Fri Dec 14 12:04:26 2018 UTC (4 years, 1 month ago) by martin
Branch: netbsd-7
Changes since 1.179.8.2: +3 -2 lines
Diff to previous 1.179.8.2 (colored) to branchpoint 1.179 (colored)

Additionally pull up following revision(s) (requested by maxv in ticket #1660):

	sys/compat/linux/common/linux_misc_notalpha.c: revision 1.110
	sys/kern/kern_time.c: revision 1.193

Improve my kern_time.c::rev1.192, systematically clear the buffers we get
from 'ptimer_pool' to prevent more leaks.

Revision 1.189.8.2 / (download) - annotate - [select for diffs], Fri Nov 30 10:28:46 2018 UTC (4 years, 2 months ago) by martin
Branch: netbsd-8
Changes since 1.189.8.1: +3 -2 lines
Diff to previous 1.189.8.1 (colored) to branchpoint 1.189 (colored)

Additionally pull up following revision(s) (requested by maxv in ticket #1110):

	sys/compat/linux/common/linux_misc_notalpha.c: revision 1.110
	sys/kern/kern_time.c: revision 1.193

Improve my kern_time.c::rev1.192, systematically clear the buffers we get
from 'ptimer_pool' to prevent more leaks.

Revision 1.193 / (download) - annotate - [select for diffs], Thu Nov 29 17:40:12 2018 UTC (4 years, 2 months ago) by maxv
Branch: MAIN
CVS Tags: pgoyette-compat-20190127, pgoyette-compat-20190118, pgoyette-compat-1226
Changes since 1.192: +3 -2 lines
Diff to previous 1.192 (colored)

Improve my kern_time.c::rev1.192, systematically clear the buffers we get
from 'ptimer_pool' to prevent more leaks.

Revision 1.179.12.2 / (download) - annotate - [select for diffs], Thu Nov 29 09:00:14 2018 UTC (4 years, 2 months ago) by martin
Branch: netbsd-7-0
Changes since 1.179.12.1: +3 -2 lines
Diff to previous 1.179.12.1 (colored) to branchpoint 1.179 (colored)

Pull up following revision(s) (requested by maxv in ticket #1660):

	sys/kern/kern_time.c: revision 1.192

Fix kernel info leak.

        + Possible info leak: [len=32, leaked=16]
        | #0 0xffffffff80baf3a7 in kleak_copyout
        | #1 0xffffffff80b940f8 in sys___timer_settime50
        | #2 0xffffffff80259c42 in syscall

Revision 1.179.8.1.4.1 / (download) - annotate - [select for diffs], Thu Nov 29 08:59:26 2018 UTC (4 years, 2 months ago) by martin
Branch: netbsd-7-1
Changes since 1.179.8.1: +3 -2 lines
Diff to previous 1.179.8.1 (colored)

Pull up following revision(s) (requested by maxv in ticket #1660):

	sys/kern/kern_time.c: revision 1.192

Fix kernel info leak.

        + Possible info leak: [len=32, leaked=16]
        | #0 0xffffffff80baf3a7 in kleak_copyout
        | #1 0xffffffff80b940f8 in sys___timer_settime50
        | #2 0xffffffff80259c42 in syscall

Revision 1.179.8.2 / (download) - annotate - [select for diffs], Thu Nov 29 08:56:45 2018 UTC (4 years, 2 months ago) by martin
Branch: netbsd-7
Changes since 1.179.8.1: +3 -2 lines
Diff to previous 1.179.8.1 (colored) to branchpoint 1.179 (colored)

Pull up following revision(s) (requested by maxv in ticket #1660):

	sys/kern/kern_time.c: revision 1.192

Fix kernel info leak.

        + Possible info leak: [len=32, leaked=16]
        | #0 0xffffffff80baf3a7 in kleak_copyout
        | #1 0xffffffff80b940f8 in sys___timer_settime50
        | #2 0xffffffff80259c42 in syscall

Revision 1.189.8.1 / (download) - annotate - [select for diffs], Thu Nov 29 08:48:38 2018 UTC (4 years, 2 months ago) by martin
Branch: netbsd-8
Changes since 1.189: +3 -2 lines
Diff to previous 1.189 (colored)

Pull up following revision(s) (requested by maxv in ticket #1110):

	sys/kern/kern_time.c: revision 1.192

Fix kernel info leak.

        + Possible info leak: [len=32, leaked=16]
        | #0 0xffffffff80baf3a7 in kleak_copyout
        | #1 0xffffffff80b940f8 in sys___timer_settime50
        | #2 0xffffffff80259c42 in syscall

Revision 1.192 / (download) - annotate - [select for diffs], Wed Nov 28 15:10:40 2018 UTC (4 years, 2 months ago) by maxv
Branch: MAIN
Changes since 1.191: +3 -2 lines
Diff to previous 1.191 (colored)

Fix kernel info leak.

	+ Possible info leak: [len=32, leaked=16]
	| #0 0xffffffff80baf3a7 in kleak_copyout
	| #1 0xffffffff80b940f8 in sys___timer_settime50
	| #2 0xffffffff80259c42 in syscall

Revision 1.189.14.1 / (download) - annotate - [select for diffs], Mon Nov 26 01:52:50 2018 UTC (4 years, 2 months ago) by pgoyette
Branch: pgoyette-compat
Changes since 1.189: +4 -2 lines
Diff to previous 1.189 (colored)

Sync with HEAD, resolve a couple of conflicts

Revision 1.191 / (download) - annotate - [select for diffs], Tue Nov 13 07:16:33 2018 UTC (4 years, 2 months ago) by maxv
Branch: MAIN
CVS Tags: pgoyette-compat-1126
Changes since 1.190: +3 -2 lines
Diff to previous 1.190 (colored)

Fix kernel info leak. There are 2x4 bytes of padding in struct itimerval.

[  738.451860] kleak: Possible leak in copyout: [len=32, leaked=8]
[  738.481840] #0 0xffffffff80b7c42a in kleak_note <netbsd>
[  738.491821] #1 0xffffffff80b7c4aa in kleak_copyout <netbsd>
[  738.501806] #2 0xffffffff80b6154e in sys___getitimer50 <netbsd>
[  738.511778] #3 0xffffffff80b61e39 in sys___setitimer50 <netbsd>
[  738.521781] #4 0xffffffff8025ab3c in sy_call <netbsd>
[  738.521781] #5 0xffffffff8025ad6e in sy_invoke <netbsd>
[  738.531808] #6 0xffffffff8025adf4 in syscall <netbsd>

Revision 1.190 / (download) - annotate - [select for diffs], Sun Nov 11 11:17:49 2018 UTC (4 years, 2 months ago) by maxv
Branch: MAIN
Changes since 1.189: +3 -2 lines
Diff to previous 1.189 (colored)

Fix stack info leak. There are 4 bytes of padding in struct timeval. Looks
like there are other leaks related to timeval in this file.

[  133.414352] kleak: Possible leak in copyout: [len=16, leaked=4]
[  133.414352] #0 0xffffffff80224d0a in kleak_note <netbsd>
[  133.424360] #1 0xffffffff80224d8a in kleak_copyout <netbsd>
[  133.434361] #2 0xffffffff80b5fd79 in sys___gettimeofday50 <netbsd>
[  133.434361] #3 0xffffffff8025a89c in sy_call <netbsd>
[  133.444351] #4 0xffffffff8025aace in sy_invoke <netbsd>
[  133.454365] #5 0xffffffff8025ab54 in syscall <netbsd>

Revision 1.174.2.3 / (download) - annotate - [select for diffs], Sun Dec 3 11:38:45 2017 UTC (5 years, 2 months ago) by jdolecek
Branch: tls-maxphys
Changes since 1.174.2.2: +57 -14 lines
Diff to previous 1.174.2.2 (colored) to branchpoint 1.174 (colored) next main 1.175 (colored)

update from HEAD

Revision 1.188.2.1 / (download) - annotate - [select for diffs], Sat Jan 7 08:56:49 2017 UTC (6 years, 1 month ago) by pgoyette
Branch: pgoyette-localcount
Changes since 1.188: +4 -3 lines
Diff to previous 1.188 (colored) next main 1.189 (colored)

Sync with HEAD.  (Note that most of these changes are simply $NetBSD$
tag issues.)

Revision 1.179.10.6 / (download) - annotate - [select for diffs], Mon Dec 5 10:55:26 2016 UTC (6 years, 2 months ago) by skrll
Branch: nick-nhusb
Changes since 1.179.10.5: +8 -7 lines
Diff to previous 1.179.10.5 (colored) to branchpoint 1.179 (colored) next main 1.180 (colored)

Sync with HEAD

Revision 1.189 / (download) - annotate - [select for diffs], Fri Nov 11 15:29:36 2016 UTC (6 years, 2 months ago) by njoly
Branch: MAIN
CVS Tags: tls-maxphys-base-20171202, prg-localcount2-base3, prg-localcount2-base2, prg-localcount2-base1, prg-localcount2-base, prg-localcount2, phil-wifi-base, pgoyette-localcount-20170426, pgoyette-localcount-20170320, pgoyette-localcount-20170107, pgoyette-compat-base, pgoyette-compat-1020, pgoyette-compat-0930, pgoyette-compat-0906, pgoyette-compat-0728, pgoyette-compat-0625, pgoyette-compat-0521, pgoyette-compat-0502, pgoyette-compat-0422, pgoyette-compat-0415, pgoyette-compat-0407, pgoyette-compat-0330, pgoyette-compat-0322, pgoyette-compat-0315, perseant-stdc-iso10646-base, perseant-stdc-iso10646, nick-nhusb-base-20170825, nick-nhusb-base-20170204, nick-nhusb-base-20161204, netbsd-8-base, netbsd-8-0-RELEASE, netbsd-8-0-RC2, netbsd-8-0-RC1, matt-nb8-mediatek-base, matt-nb8-mediatek, jdolecek-ncq-base, jdolecek-ncq, bouyer-socketcan-base1, bouyer-socketcan-base, bouyer-socketcan
Branch point for: phil-wifi, pgoyette-compat, netbsd-8
Changes since 1.188: +4 -3 lines
Diff to previous 1.188 (colored)

Adjust clock_nanosleep(2) to not copyout remaining time struct if
TIMER_ABSTIME flag is set.

Ok Christos.

Revision 1.179.10.5 / (download) - annotate - [select for diffs], Sat Jul 9 20:25:20 2016 UTC (6 years, 6 months ago) by skrll
Branch: nick-nhusb
Changes since 1.179.10.4: +7 -4 lines
Diff to previous 1.179.10.4 (colored) to branchpoint 1.179 (colored)

Sync with HEAD

Revision 1.188 / (download) - annotate - [select for diffs], Thu Jul 7 06:55:43 2016 UTC (6 years, 7 months ago) by msaitoh
Branch: MAIN
CVS Tags: pgoyette-localcount-base, pgoyette-localcount-20161104, pgoyette-localcount-20160806, pgoyette-localcount-20160726, nick-nhusb-base-20161004, nick-nhusb-base-20160907, localcount-20160914
Branch point for: pgoyette-localcount
Changes since 1.187: +4 -4 lines
Diff to previous 1.187 (colored)

KNF. Remove extra spaces. No functional change.

Revision 1.187 / (download) - annotate - [select for diffs], Fri Jun 10 23:29:20 2016 UTC (6 years, 7 months ago) by christos
Branch: MAIN
Changes since 1.186: +5 -2 lines
Diff to previous 1.186 (colored)

GSoC 2016: Charles Cui: Add timer related macros
    _POSIX_CPUTIME
    _POSIX_THREAD_CPUTIME
    _POSIX_DELAYTIMER_MAX

Revision 1.179.10.4 / (download) - annotate - [select for diffs], Sun May 29 08:44:37 2016 UTC (6 years, 8 months ago) by skrll
Branch: nick-nhusb
Changes since 1.179.10.3: +33 -2 lines
Diff to previous 1.179.10.3 (colored) to branchpoint 1.179 (colored)

Sync with HEAD

Revision 1.186 / (download) - annotate - [select for diffs], Sat Apr 23 23:08:26 2016 UTC (6 years, 9 months ago) by christos
Branch: MAIN
CVS Tags: nick-nhusb-base-20160529
Changes since 1.185: +33 -2 lines
Diff to previous 1.185 (colored)

Add clock_getcpuclockid2(2) as well as CLOCK_{PROCESS,THREAD}_CPUTIME_ID.

Revision 1.179.10.3 / (download) - annotate - [select for diffs], Sat Mar 19 11:30:31 2016 UTC (6 years, 10 months ago) by skrll
Branch: nick-nhusb
Changes since 1.179.10.2: +14 -9 lines
Diff to previous 1.179.10.2 (colored) to branchpoint 1.179 (colored)

Sync with HEAD

Revision 1.185 / (download) - annotate - [select for diffs], Tue Mar 8 05:02:55 2016 UTC (6 years, 11 months ago) by christos
Branch: MAIN
CVS Tags: nick-nhusb-base-20160422, nick-nhusb-base-20160319
Changes since 1.184: +2 -3 lines
Diff to previous 1.184 (colored)

- GC pts_fired, and fix the comment about MAX_TIMERS
- Bump MAX_TIMERS to 36 so that we have 32 POSIX user timers which is the
  minimum required.

Revision 1.179.8.1 / (download) - annotate - [select for diffs], Thu Mar 3 15:42:26 2016 UTC (6 years, 11 months ago) by martin
Branch: netbsd-7
CVS Tags: netbsd-7-nhusb-base-20170116, netbsd-7-nhusb-base, netbsd-7-nhusb, netbsd-7-2-RELEASE, netbsd-7-1-RELEASE, netbsd-7-1-RC2, netbsd-7-1-RC1, netbsd-7-1-2-RELEASE, netbsd-7-1-1-RELEASE
Branch point for: netbsd-7-1
Changes since 1.179: +10 -4 lines
Diff to previous 1.179 (colored)

Pull up following revision(s) (requested by uwe in ticket #1128):
	sys/kern/kern_time.c: revision 1.184
Don't leak garabage from the kernel stack on sleep(0) and equivalents.
Hat tip to perl's ext/POSIX/t/wrappers.t

Revision 1.179.12.1 / (download) - annotate - [select for diffs], Thu Mar 3 15:41:35 2016 UTC (6 years, 11 months ago) by martin
Branch: netbsd-7-0
CVS Tags: netbsd-7-0-2-RELEASE, netbsd-7-0-1-RELEASE
Changes since 1.179: +10 -4 lines
Diff to previous 1.179 (colored)

Pull up following revision(s) (requested by uwe in ticket #1128):
	sys/kern/kern_time.c: revision 1.184
Don't leak garabage from the kernel stack on sleep(0) and equivalents.
Hat tip to perl's ext/POSIX/t/wrappers.t

Revision 1.184 / (download) - annotate - [select for diffs], Thu Mar 3 01:39:17 2016 UTC (6 years, 11 months ago) by uwe
Branch: MAIN
Changes since 1.183: +10 -4 lines
Diff to previous 1.183 (colored)

Don't leak garabage from the kernel stack on sleep(0) and equivalents.
Hat tip to perl's ext/POSIX/t/wrappers.t

Revision 1.183 / (download) - annotate - [select for diffs], Fri Feb 26 17:08:58 2016 UTC (6 years, 11 months ago) by christos
Branch: MAIN
Changes since 1.182: +6 -6 lines
Diff to previous 1.182 (colored)

Make comments and code match reality; there are 4 reserved timers.

Revision 1.179.10.2 / (download) - annotate - [select for diffs], Sun Dec 27 12:10:05 2015 UTC (7 years, 1 month ago) by skrll
Branch: nick-nhusb
Changes since 1.179.10.1: +9 -6 lines
Diff to previous 1.179.10.1 (colored) to branchpoint 1.179 (colored)

Sync with HEAD (as of 26th Dec)

Revision 1.182 / (download) - annotate - [select for diffs], Tue Oct 6 15:03:34 2015 UTC (7 years, 4 months ago) by christos
Branch: MAIN
CVS Tags: nick-nhusb-base-20151226
Changes since 1.181: +2 -3 lines
Diff to previous 1.181 (colored)

CID/1325753: remove extra return.

Revision 1.181 / (download) - annotate - [select for diffs], Fri Oct 2 19:47:08 2015 UTC (7 years, 4 months ago) by christos
Branch: MAIN
Changes since 1.180: +9 -5 lines
Diff to previous 1.180 (colored)

PR/50295: clock_nanotime() should not set errno, but return the error.

Revision 1.179.10.1 / (download) - annotate - [select for diffs], Tue Sep 22 12:06:07 2015 UTC (7 years, 4 months ago) by skrll
Branch: nick-nhusb
Changes since 1.179: +4 -4 lines
Diff to previous 1.179 (colored)

Sync with HEAD

Revision 1.180 / (download) - annotate - [select for diffs], Fri Jul 24 13:02:52 2015 UTC (7 years, 6 months ago) by maxv
Branch: MAIN
CVS Tags: nick-nhusb-base-20150921
Changes since 1.179: +4 -4 lines
Diff to previous 1.179 (colored)

Unused inits (harmless).

Found by Brainy.

Revision 1.170.2.3 / (download) - annotate - [select for diffs], Thu May 22 11:41:03 2014 UTC (8 years, 8 months ago) by yamt
Branch: yamt-pagecache
Changes since 1.170.2.2: +10 -31 lines
Diff to previous 1.170.2.2 (colored) to branchpoint 1.170 (colored) next main 1.171 (colored)

sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs.  ("Protocol error: too many arguments")

Revision 1.174.2.2 / (download) - annotate - [select for diffs], Sun Jun 23 06:18:58 2013 UTC (9 years, 7 months ago) by tls
Branch: tls-maxphys
Changes since 1.174.2.1: +10 -31 lines
Diff to previous 1.174.2.1 (colored) to branchpoint 1.174 (colored)

resync from head

Revision 1.179 / (download) - annotate - [select for diffs], Wed May 22 16:00:52 2013 UTC (9 years, 8 months ago) by christos
Branch: MAIN
CVS Tags: yamt-pagecache-base9, tls-maxphys-base, tls-earlyentropy-base, tls-earlyentropy, rmind-smpnet-nbase, rmind-smpnet-base, rmind-smpnet, riastradh-xf86-video-intel-2-7-1-pre-2-21-15, riastradh-drm2-base3, riastradh-drm2-base2, riastradh-drm2-base1, riastradh-drm2-base, riastradh-drm2, nick-nhusb-base-20150606, nick-nhusb-base-20150406, nick-nhusb-base, netbsd-7-base, netbsd-7-0-RELEASE, netbsd-7-0-RC3, netbsd-7-0-RC2, netbsd-7-0-RC1
Branch point for: nick-nhusb, netbsd-7-0, netbsd-7
Changes since 1.178: +8 -4 lines
Diff to previous 1.178 (colored)

Make ts2timo(9) always return the absolute start time if the start argument
is present, and handle the TIMER_ABSTIME case in nanosleep1(9).

Revision 1.178 / (download) - annotate - [select for diffs], Sun Mar 31 16:45:06 2013 UTC (9 years, 10 months ago) by christos
Branch: MAIN
CVS Tags: khorben-n900
Changes since 1.177: +4 -6 lines
Diff to previous 1.177 (colored)

always return immediately on error, and if we passed negative seconds,
return with 0.

Revision 1.177 / (download) - annotate - [select for diffs], Fri Mar 29 10:34:12 2013 UTC (9 years, 10 months ago) by martin
Branch: MAIN
Changes since 1.176: +2 -20 lines
Diff to previous 1.176 (colored)

Move clock_gettime1() to subr_time.c (which is included in rump kernels)

Revision 1.176 / (download) - annotate - [select for diffs], Fri Mar 29 01:08:17 2013 UTC (9 years, 10 months ago) by christos
Branch: MAIN
Changes since 1.175: +6 -11 lines
Diff to previous 1.175 (colored)

Centralize the computation of struct timespec to the int timo.
Make lwp_park take the regular arguments for specifying what kind
of timeout we supply like clock_nanosleep(), namely clockid_t and flags.

Revision 1.174.2.1 / (download) - annotate - [select for diffs], Tue Nov 20 03:02:43 2012 UTC (10 years, 2 months ago) by tls
Branch: tls-maxphys
Changes since 1.174: +41 -7 lines
Diff to previous 1.174 (colored)

Resync to 2012-11-19 00:00:00 UTC

Revision 1.170.2.2 / (download) - annotate - [select for diffs], Tue Oct 30 17:22:32 2012 UTC (10 years, 3 months ago) by yamt
Branch: yamt-pagecache
CVS Tags: yamt-pagecache-tag8
Changes since 1.170.2.1: +41 -7 lines
Diff to previous 1.170.2.1 (colored) to branchpoint 1.170 (colored)

sync with head

Revision 1.175 / (download) - annotate - [select for diffs], Tue Oct 2 01:44:28 2012 UTC (10 years, 4 months ago) by christos
Branch: MAIN
CVS Tags: yamt-pagecache-base8, yamt-pagecache-base7, yamt-pagecache-base6, agc-symver-base, agc-symver
Changes since 1.174: +41 -7 lines
Diff to previous 1.174 (colored)

kernel portion of clock_nanosleep()

Revision 1.170.2.1 / (download) - annotate - [select for diffs], Tue Apr 17 00:08:27 2012 UTC (10 years, 9 months ago) by yamt
Branch: yamt-pagecache
Changes since 1.170: +17 -119 lines
Diff to previous 1.170 (colored)

sync with head

Revision 1.170.6.3 / (download) - annotate - [select for diffs], Thu Apr 5 21:33:39 2012 UTC (10 years, 10 months ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.170.6.2: +1 -1 lines
Diff to previous 1.170.6.2 (colored) to branchpoint 1.170 (colored) next main 1.171 (colored)

sync to latest -current.

Revision 1.174 / (download) - annotate - [select for diffs], Thu Mar 22 17:46:07 2012 UTC (10 years, 10 months ago) by dholland
Branch: MAIN
CVS Tags: yamt-pagecache-base5, yamt-pagecache-base4, jmcneill-usbmp-base9, jmcneill-usbmp-base8, jmcneill-usbmp-base10
Branch point for: tls-maxphys
Changes since 1.173: +3 -3 lines
Diff to previous 1.173 (colored)

Misplaced parenthesis; fixes PR 44927

Revision 1.170.6.2 / (download) - annotate - [select for diffs], Fri Feb 24 09:11:47 2012 UTC (10 years, 11 months ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.170.6.1: +5 -115 lines
Diff to previous 1.170.6.1 (colored) to branchpoint 1.170 (colored)

sync to -current.

Revision 1.173 / (download) - annotate - [select for diffs], Mon Feb 20 01:12:42 2012 UTC (10 years, 11 months ago) by rmind
Branch: MAIN
CVS Tags: jmcneill-usbmp-base7, jmcneill-usbmp-base6, jmcneill-usbmp-base5, jmcneill-usbmp-base4, jmcneill-usbmp-base3
Changes since 1.172: +3 -3 lines
Diff to previous 1.172 (colored)

itimerfire: fix a regression, check if timer is already queued.

Revision 1.172 / (download) - annotate - [select for diffs], Sun Feb 19 21:06:55 2012 UTC (10 years, 11 months ago) by rmind
Branch: MAIN
Changes since 1.171: +5 -115 lines
Diff to previous 1.171 (colored)

Remove COMPAT_SA / KERN_SA.  Welcome to 6.99.3!
Approved by core@.

Revision 1.170.6.1 / (download) - annotate - [select for diffs], Sat Feb 18 07:35:31 2012 UTC (10 years, 11 months ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.170: +13 -5 lines
Diff to previous 1.170 (colored)

merge to -current.

Revision 1.171 / (download) - annotate - [select for diffs], Sun Dec 18 22:30:25 2011 UTC (11 years, 1 month ago) by christos
Branch: MAIN
CVS Tags: netbsd-6-base, netbsd-6-1-RELEASE, netbsd-6-1-RC4, netbsd-6-1-RC3, netbsd-6-1-RC2, netbsd-6-1-RC1, netbsd-6-1-5-RELEASE, netbsd-6-1-4-RELEASE, netbsd-6-1-3-RELEASE, netbsd-6-1-2-RELEASE, netbsd-6-1-1-RELEASE, netbsd-6-1, netbsd-6-0-RELEASE, netbsd-6-0-RC2, netbsd-6-0-RC1, netbsd-6-0-6-RELEASE, netbsd-6-0-5-RELEASE, netbsd-6-0-4-RELEASE, netbsd-6-0-3-RELEASE, netbsd-6-0-2-RELEASE, netbsd-6-0-1-RELEASE, netbsd-6-0, netbsd-6, matt-nb6-plus-nbase, matt-nb6-plus-base, matt-nb6-plus, jmcneill-usbmp-base2
Changes since 1.170: +13 -5 lines
Diff to previous 1.170 (colored)

Fix monotonic interval timers.

Revision 1.170 / (download) - annotate - [select for diffs], Thu Oct 27 16:12:52 2011 UTC (11 years, 3 months ago) by christos
Branch: MAIN
CVS Tags: yamt-pagecache-base3, yamt-pagecache-base2, yamt-pagecache-base, jmcneill-usbmp-pre-base2, jmcneill-usbmp-base, jmcneill-audiomp3-base, jmcneill-audiomp3
Branch point for: yamt-pagecache, jmcneill-usbmp
Changes since 1.169: +26 -14 lines
Diff to previous 1.169 (colored)

There is no reason not to support CLOCK_MONOTONIC in {g,s}etitimer() since
the underlying implementation already supports it, so add it.

Revision 1.169 / (download) - annotate - [select for diffs], Wed Jul 27 14:35:34 2011 UTC (11 years, 6 months ago) by uebayasi
Branch: MAIN
Changes since 1.168: +2 -4 lines
Diff to previous 1.168 (colored)

These don't need uvm/uvm_extern.h.

Revision 1.166.2.1 / (download) - annotate - [select for diffs], Mon Jun 6 09:09:32 2011 UTC (11 years, 8 months ago) by jruoho
Branch: jruoho-x86intr
Changes since 1.166: +41 -22 lines
Diff to previous 1.166 (colored) next main 1.167 (colored)

Sync with HEAD.

Revision 1.163.4.3 / (download) - annotate - [select for diffs], Thu Apr 21 01:42:08 2011 UTC (11 years, 9 months ago) by rmind
Branch: rmind-uvmplock
Changes since 1.163.4.2: +39 -20 lines
Diff to previous 1.163.4.2 (colored) to branchpoint 1.163 (colored) next main 1.164 (colored)

sync with head

Revision 1.168 / (download) - annotate - [select for diffs], Fri Apr 8 10:35:37 2011 UTC (11 years, 10 months ago) by yamt
Branch: MAIN
CVS Tags: rmind-uvmplock-nbase, rmind-uvmplock-base, cherry-xenmp-base, cherry-xenmp
Changes since 1.167: +40 -21 lines
Diff to previous 1.167 (colored)

implement timer_create of CLOCK_MONOTONIC

Revision 1.167 / (download) - annotate - [select for diffs], Tue Apr 5 00:27:35 2011 UTC (11 years, 10 months ago) by yamt
Branch: MAIN
Changes since 1.166: +3 -3 lines
Diff to previous 1.166 (colored)

fix assertion failure in timer_intr.  CLOCK_REALTIME timers can be on
timer_queue.

Revision 1.163.4.2 / (download) - annotate - [select for diffs], Sat Mar 5 20:55:17 2011 UTC (11 years, 11 months ago) by rmind
Branch: rmind-uvmplock
Changes since 1.163.4.1: +7 -7 lines
Diff to previous 1.163.4.1 (colored) to branchpoint 1.163 (colored)

sync with head

Revision 1.166 / (download) - annotate - [select for diffs], Fri Dec 17 22:08:18 2010 UTC (12 years, 1 month ago) by yamt
Branch: MAIN
CVS Tags: matt-mips64-premerge-20101231, jruoho-x86intr-base, bouyer-quota2-nbase, bouyer-quota2-base, bouyer-quota2
Branch point for: jruoho-x86intr
Changes since 1.165: +7 -7 lines
Diff to previous 1.165 (colored)

realtimerexpire: rename a confusing variable.  no functional change.
(now_ms -> now_ns as it hold a nano second value)

Revision 1.145.2.5 / (download) - annotate - [select for diffs], Wed Aug 11 22:54:41 2010 UTC (12 years, 5 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.145.2.4: +36 -18 lines
Diff to previous 1.145.2.4 (colored) to branchpoint 1.145 (colored) next main 1.146 (colored)

sync with head.

Revision 1.163.4.1 / (download) - annotate - [select for diffs], Sun May 30 05:17:57 2010 UTC (12 years, 8 months ago) by rmind
Branch: rmind-uvmplock
Changes since 1.163: +36 -18 lines
Diff to previous 1.163 (colored)

sync with head

Revision 1.163.2.1 / (download) - annotate - [select for diffs], Fri Apr 30 14:44:11 2010 UTC (12 years, 9 months ago) by uebayasi
Branch: uebayasi-xip
Changes since 1.163: +36 -18 lines
Diff to previous 1.163 (colored) next main 1.164 (colored)

Sync with HEAD.

Revision 1.155.4.2.4.1 / (download) - annotate - [select for diffs], Wed Apr 21 00:28:17 2010 UTC (12 years, 9 months ago) by matt
Branch: matt-nb5-mips64
CVS Tags: matt-nb5-mips64-premerge-20101231, matt-nb5-mips64-k15
Changes since 1.155.4.2: +6 -3 lines
Diff to previous 1.155.4.2 (colored) next main 1.155.4.3 (colored)

sync to netbsd-5

Revision 1.165 / (download) - annotate - [select for diffs], Thu Apr 8 11:51:13 2010 UTC (12 years, 10 months ago) by njoly
Branch: MAIN
CVS Tags: yamt-nfs-mp-base11, yamt-nfs-mp-base10, uebayasi-xip-base4, uebayasi-xip-base3, uebayasi-xip-base2, uebayasi-xip-base1
Changes since 1.164: +18 -8 lines
Diff to previous 1.164 (colored)

Add a new clock_gettime1() function that holds most of the
clock_gettime syscall code (except for the copyout). Adjust all
corresponding syscalls to make use of it.

Revision 1.164 / (download) - annotate - [select for diffs], Sat Apr 3 17:20:05 2010 UTC (12 years, 10 months ago) by njoly
Branch: MAIN
Changes since 1.163: +20 -12 lines
Diff to previous 1.163 (colored)

Move most clock_getres syscall code, except for coypout call, to a new
clock_getres1() function which can be used by emulations. Adjust all
clock_getres syscalls to now make of use it.

Revision 1.145.2.4 / (download) - annotate - [select for diffs], Thu Mar 11 15:04:18 2010 UTC (12 years, 10 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.145.2.3: +32 -3 lines
Diff to previous 1.145.2.3 (colored) to branchpoint 1.145 (colored)

sync with head

Revision 1.155.4.2.2.1 / (download) - annotate - [select for diffs], Thu Dec 10 23:12:18 2009 UTC (13 years, 1 month ago) by snj
Branch: netbsd-5-0
CVS Tags: netbsd-5-0-2-RELEASE
Changes since 1.155.4.2: +6 -3 lines
Diff to previous 1.155.4.2 (colored) next main 1.155.4.3 (colored)

Pull up following revision(s) (requested by drochner in ticket #1189):
	sys/kern/kern_time.c: revision 1.163
If a struct sigevent with SIGEV_SIGNAL is passed to timer_create(2),
check the signal number to be in the allowed range. An invalid
signal number could crash the kernel by overflowing the sigset_t
array.
More checks would be good, and SIGEV_THREAD shouldn't be dropped
silently, but this fixes at least the local DOS vulnerability.

Revision 1.155.4.3 / (download) - annotate - [select for diffs], Thu Dec 10 23:10:38 2009 UTC (13 years, 1 month ago) by snj
Branch: netbsd-5
CVS Tags: netbsd-5-2-RELEASE, netbsd-5-2-RC1, netbsd-5-2-3-RELEASE, netbsd-5-2-2-RELEASE, netbsd-5-2-1-RELEASE, netbsd-5-2, netbsd-5-1-RELEASE, netbsd-5-1-RC4, netbsd-5-1-RC3, netbsd-5-1-RC2, netbsd-5-1-RC1, netbsd-5-1-5-RELEASE, netbsd-5-1-4-RELEASE, netbsd-5-1-3-RELEASE, netbsd-5-1-2-RELEASE, netbsd-5-1-1-RELEASE, netbsd-5-1, matt-nb5-pq3-base, matt-nb5-pq3
Changes since 1.155.4.2: +6 -3 lines
Diff to previous 1.155.4.2 (colored) to branchpoint 1.155 (colored) next main 1.156 (colored)

Pull up following revision(s) (requested by drochner in ticket #1189):
	sys/kern/kern_time.c: revision 1.163
If a struct sigevent with SIGEV_SIGNAL is passed to timer_create(2),
check the signal number to be in the allowed range. An invalid
signal number could crash the kernel by overflowing the sigset_t
array.
More checks would be good, and SIGEV_THREAD shouldn't be dropped
silently, but this fixes at least the local DOS vulnerability.

Revision 1.163 / (download) - annotate - [select for diffs], Thu Dec 10 12:39:12 2009 UTC (13 years, 1 month ago) by drochner
Branch: MAIN
CVS Tags: yamt-nfs-mp-base9, uebayasi-xip-base, matt-premerge-20091211
Branch point for: uebayasi-xip, rmind-uvmplock
Changes since 1.162: +6 -3 lines
Diff to previous 1.162 (colored)

If a struct sigevent with SIGEV_SIGNAL is passed to timer_create(2),
check the signal number to be in the allowed range. An invalid
signal number could crash the kernel by overflowing the sigset_t
array.
More checks would be good, and SIGEV_THREAD shouldn't be dropped
silently, but this fixes at least the local DOS vulnerability.

Revision 1.162 / (download) - annotate - [select for diffs], Sat Oct 3 20:48:42 2009 UTC (13 years, 4 months ago) by elad
Branch: MAIN
CVS Tags: jym-xensuspend-nbase
Changes since 1.161: +28 -2 lines
Diff to previous 1.161 (colored)

Introduce time_wraps() to check if setting the time will wrap it (or
close to it). Useful for secmodels.

Replace open-coded form with it in secmodel code (securelevel, keylock).

Note: I need to find a way to make secmodel_keylock.c ~<100 lines.

Revision 1.145.2.3 / (download) - annotate - [select for diffs], Wed Sep 16 13:38:01 2009 UTC (13 years, 4 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.145.2.2: +7 -7 lines
Diff to previous 1.145.2.2 (colored) to branchpoint 1.145 (colored)

sync with head

Revision 1.161 / (download) - annotate - [select for diffs], Sun Sep 13 18:45:11 2009 UTC (13 years, 4 months ago) by pooka
Branch: MAIN
CVS Tags: yamt-nfs-mp-base8
Changes since 1.160: +7 -7 lines
Diff to previous 1.160 (colored)

Wipe out the last vestiges of POOL_INIT with one swift stroke.  In
most cases, use a proper constructor.  For proplib, give a local
equivalent of POOL_INIT for the kernel object implementation.  This
way the code structure can be preserved, and a local link set is
not hazardous anyway (unless proplib is split to several modules,
but that'll be the day).

tested by booting a kernel in qemu and compile-testing i386/ALL

Revision 1.159.2.1 / (download) - annotate - [select for diffs], Wed May 13 17:21:57 2009 UTC (13 years, 8 months ago) by jym
Branch: jym-xensuspend
Changes since 1.159: +8 -6 lines
Diff to previous 1.159 (colored) next main 1.160 (colored)

Sync with HEAD.

Commit is split, to avoid a "too many arguments" protocol error.

Revision 1.145.2.2 / (download) - annotate - [select for diffs], Mon May 4 08:13:47 2009 UTC (13 years, 9 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.145.2.1: +322 -275 lines
Diff to previous 1.145.2.1 (colored) to branchpoint 1.145 (colored)

sync with head.

Revision 1.155.2.3 / (download) - annotate - [select for diffs], Tue Apr 28 07:37:00 2009 UTC (13 years, 9 months ago) by skrll
Branch: nick-hppapmap
Changes since 1.155.2.2: +8 -6 lines
Diff to previous 1.155.2.2 (colored) to branchpoint 1.155 (colored) next main 1.156 (colored)

Sync with HEAD.

Revision 1.160 / (download) - annotate - [select for diffs], Sun Mar 29 19:21:19 2009 UTC (13 years, 10 months ago) by christos
Branch: MAIN
CVS Tags: yamt-nfs-mp-base7, yamt-nfs-mp-base6, yamt-nfs-mp-base5, yamt-nfs-mp-base4, yamt-nfs-mp-base3, nick-hppapmap-base4, nick-hppapmap-base3, nick-hppapmap-base, jymxensuspend-base, jym-xensuspend-base
Changes since 1.159: +8 -6 lines
Diff to previous 1.159 (colored)

Move the internal poll/select related API's to use timespec instead
of timeval (rides the uvm bump).

Revision 1.155.2.2 / (download) - annotate - [select for diffs], Tue Mar 3 18:32:56 2009 UTC (13 years, 11 months ago) by skrll
Branch: nick-hppapmap
Changes since 1.155.2.1: +6 -23 lines
Diff to previous 1.155.2.1 (colored) to branchpoint 1.155 (colored)

Sync with HEAD.

Revision 1.155.4.2 / (download) - annotate - [select for diffs], Sun Feb 8 20:38:49 2009 UTC (13 years, 11 months ago) by snj
Branch: netbsd-5
CVS Tags: netbsd-5-0-RELEASE, netbsd-5-0-RC4, netbsd-5-0-RC3, netbsd-5-0-RC2, netbsd-5-0-1-RELEASE, matt-nb5-mips64-u2-k2-k4-k7-k8-k9, matt-nb5-mips64-u1-k1-k5, matt-nb5-mips64-premerge-20091211, matt-nb4-mips64-k7-u2a-k9b
Branch point for: netbsd-5-0, matt-nb5-mips64
Changes since 1.155.4.1: +2 -17 lines
Diff to previous 1.155.4.1 (colored) to branchpoint 1.155 (colored)

Pull up following revision(s) (requested by rmind in ticket #429):
	sys/kern/kern_time.c: revision 1.159 via patch
settime1: fix a bug i introduced when i made l_stime use monotonic time.
from Matthias Drochner on tech-kern@.  PR/40511 from Martin Husemann.

Revision 1.155.4.1 / (download) - annotate - [select for diffs], Mon Feb 2 22:10:39 2009 UTC (14 years ago) by snj
Branch: netbsd-5
Changes since 1.155: +6 -8 lines
Diff to previous 1.155 (colored)

Pull up following revision(s) (requested by ad in ticket #401):
	sys/kern/kern_time.c: revision 1.158
timer_intr: hold proc_lock across the loop, otherwise the process we are
about to signal could disappear.

Revision 1.159 / (download) - annotate - [select for diffs], Sat Jan 31 15:53:36 2009 UTC (14 years ago) by yamt
Branch: MAIN
CVS Tags: nick-hppapmap-base2
Branch point for: jym-xensuspend
Changes since 1.158: +2 -17 lines
Diff to previous 1.158 (colored)

settime1: fix a bug i introduced when i made l_stime use monotonic time.
from Matthias Drochner on tech-kern@.  PR/40511 from Martin Husemann.

Revision 1.158 / (download) - annotate - [select for diffs], Fri Jan 30 23:11:27 2009 UTC (14 years ago) by ad
Branch: MAIN
Changes since 1.157: +6 -8 lines
Diff to previous 1.157 (colored)

timer_intr: hold proc_lock across the loop, otherwise the process we are
about to signal could disappear.

Revision 1.155.2.1 / (download) - annotate - [select for diffs], Mon Jan 19 13:19:39 2009 UTC (14 years ago) by skrll
Branch: nick-hppapmap
Changes since 1.155: +59 -63 lines
Diff to previous 1.155 (colored)

Sync with HEAD.

Revision 1.140.6.4 / (download) - annotate - [select for diffs], Sat Jan 17 13:29:19 2009 UTC (14 years ago) by mjf
Branch: mjf-devfs2
Changes since 1.140.6.3: +173 -65 lines
Diff to previous 1.140.6.3 (colored) to branchpoint 1.140 (colored) next main 1.141 (colored)

Sync with HEAD.

Revision 1.157 / (download) - annotate - [select for diffs], Sun Jan 11 15:57:29 2009 UTC (14 years ago) by christos
Branch: MAIN
CVS Tags: mjf-devfs2-base
Changes since 1.156: +4 -3 lines
Diff to previous 1.156 (colored)

- fix leaked lock, thanks ad@ for noticing.
- remove unneeded cast.

Revision 1.156 / (download) - annotate - [select for diffs], Sun Jan 11 02:45:52 2009 UTC (14 years ago) by christos
Branch: MAIN
Changes since 1.155: +58 -63 lines
Diff to previous 1.155 (colored)

merge christos-time_t

Revision 1.141.2.3 / (download) - annotate - [select for diffs], Thu Nov 27 21:34:08 2008 UTC (14 years, 2 months ago) by christos
Branch: christos-time_t
Changes since 1.141.2.2: +3 -5 lines
Diff to previous 1.141.2.2 (colored) to branchpoint 1.141 (colored) next main 1.142 (colored)

delete unused variable (and don't use it!)

Revision 1.141.2.2 / (download) - annotate - [select for diffs], Sat Nov 1 21:22:27 2008 UTC (14 years, 3 months ago) by christos
Branch: christos-time_t
Changes since 1.141.2.1: +501 -315 lines
Diff to previous 1.141.2.1 (colored) to branchpoint 1.141 (colored)

Sync with head.

Revision 1.148.4.1 / (download) - annotate - [select for diffs], Sun Oct 19 22:17:28 2008 UTC (14 years, 3 months ago) by haad
Branch: haad-dm
Changes since 1.148: +237 -188 lines
Diff to previous 1.148 (colored) next main 1.149 (colored)

Sync with HEAD.

Revision 1.155 / (download) - annotate - [select for diffs], Thu Oct 16 18:21:45 2008 UTC (14 years, 3 months ago) by wrstuden
Branch: MAIN
CVS Tags: netbsd-5-base, netbsd-5-0-RC1, matt-mips64-base2, haad-nbase2, haad-dm-base2, haad-dm-base1, haad-dm-base, christos-time_t-nbase, christos-time_t-base, ad-audiomp2-base, ad-audiomp2
Branch point for: nick-hppapmap, netbsd-5
Changes since 1.154: +16 -15 lines
Diff to previous 1.154 (colored)

Adjust locking on the sadata::sa_vps list. The main time we
walk the list, we're looking for a vp to do something with. We do
this in the signal code and in the timer code. The signal code already
runs with proc::p_lock held, so it's a very natural lock to use. The
timer code, however, calls into the sa timer code with a spinlock held.
Since proc::p_lock is an adaptable mutex, we can sleep to get it. Sleeping
with a spinlock is BAD. So proc::p_lock is _not_ the right lock there,
and something like sadata::sa_mutex would be best.

Address this difficulty by noting that both uses actually just read
the list. Changing the list of VPs is rare - once one's added, it stays
until the process ends. So make the locking protocol that to write the
list you have to hold both proc::p_lock and sadata::sa_mutex (taken
in that order). Thus holding either one individually grants read access.

This removes a case where we could sleep with timer_lock, a spinlock at
IPL_SCHED (!!), while trying to get p_lock. If that ever happened, we'd
pretty much be dead. So don't do that!

This fixes a merge botch from how I handled our gaining p_lock - p_lock
should not have simply replaced p_smutex.

While here, tweak the sa_unblock_userret() code for the case
when the blessed vp is actually running (on another CPU). Make its
resched RESCHED_IMMED so we whack the CPU. Addresses a hang I've
observed in starting firefox on occasion when I see one thread running
in userland and another thread sitting in lwpublk, which means it's on
the list of threads for which we need an unblocked upcall. This list is
one on which things should NOT linger.

Revision 1.154 / (download) - annotate - [select for diffs], Wed Oct 15 06:51:20 2008 UTC (14 years, 3 months ago) by wrstuden
Branch: MAIN
Changes since 1.153: +117 -6 lines
Diff to previous 1.153 (colored)

Merge wrstuden-revivesa into HEAD.

Revision 1.146.2.11 / (download) - annotate - [select for diffs], Fri Oct 10 22:34:14 2008 UTC (14 years, 3 months ago) by skrll
Branch: wrstuden-revivesa
Changes since 1.146.2.10: +2 -78 lines
Diff to previous 1.146.2.10 (colored) next main 1.147 (colored)

Sync with HEAD.

Revision 1.140.6.3 / (download) - annotate - [select for diffs], Sun Sep 28 10:40:52 2008 UTC (14 years, 4 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.140.6.2: +119 -182 lines
Diff to previous 1.140.6.2 (colored) to branchpoint 1.140 (colored)

Sync with HEAD.

Revision 1.153 / (download) - annotate - [select for diffs], Thu Sep 25 17:17:10 2008 UTC (14 years, 4 months ago) by pooka
Branch: MAIN
CVS Tags: wrstuden-revivesa-base-4
Changes since 1.152: +2 -78 lines
Diff to previous 1.152 (colored)

Split rate-checking routines into their own module for easier reuse.

Revision 1.146.2.10 / (download) - annotate - [select for diffs], Thu Sep 25 06:12:28 2008 UTC (14 years, 4 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.9: +10 -11 lines
Diff to previous 1.146.2.9 (colored)

Hack a merge to the "new" wrstuden-revivesa-base-3 tag for this file.
It turns out the problems with regression tests were really with
VIRTUAL timers. The timers that the round-robin scheduling in libpthread
uses to switch stuff around. Fixing that make the "kill1" regression
test complete in a timely manner. So pull in the rev
between 1.151 and 1.152, which now lines us up with our new base.

Revision 1.152 / (download) - annotate - [select for diffs], Tue Sep 23 16:44:49 2008 UTC (14 years, 4 months ago) by christos
Branch: MAIN
CVS Tags: wrstuden-revivesa-base-3
Changes since 1.151: +10 -11 lines
Diff to previous 1.151 (colored)

fix half-assed change usec -> nsec that broke non-real timers.

Revision 1.146.2.9 / (download) - annotate - [select for diffs], Thu Sep 18 04:31:43 2008 UTC (14 years, 4 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.8: +115 -101 lines
Diff to previous 1.146.2.8 (colored)

Sync with wrstuden-revivesa-base-2.

Revision 1.151 / (download) - annotate - [select for diffs], Fri Aug 8 16:44:52 2008 UTC (14 years, 6 months ago) by christos
Branch: MAIN
CVS Tags: wrstuden-revivesa-base-2
Changes since 1.150: +4 -4 lines
Diff to previous 1.150 (colored)

Fix broken setitimer(). (Sverre Froyen)

Revision 1.146.2.8 / (download) - annotate - [select for diffs], Mon Jul 21 19:13:45 2008 UTC (14 years, 6 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.7: +10 -2 lines
Diff to previous 1.146.2.7 (colored)

Add support for compiling SA as an option. Implied by COMPAT_40.

i386 kernels both with COMPAT_40 and with no compat options (and thus
no SA) compile.

No functional changes intended.

Revision 1.148.2.1 / (download) - annotate - [select for diffs], Fri Jul 18 16:37:49 2008 UTC (14 years, 6 months ago) by simonb
Branch: simonb-wapbl
Changes since 1.148: +115 -101 lines
Diff to previous 1.148 (colored) next main 1.149 (colored)

Sync with head.

Revision 1.150 / (download) - annotate - [select for diffs], Tue Jul 15 16:18:08 2008 UTC (14 years, 6 months ago) by christos
Branch: MAIN
CVS Tags: simonb-wapbl-nbase, simonb-wapbl-base
Changes since 1.149: +86 -88 lines
Diff to previous 1.149 (colored)

Use more timespecs internally. From Alexander Shishkin and me.
Welcome to 4.99.70, 30 more to go for 100.

Revision 1.149 / (download) - annotate - [select for diffs], Tue Jul 8 20:53:02 2008 UTC (14 years, 7 months ago) by christos
Branch: MAIN
Changes since 1.148: +32 -16 lines
Diff to previous 1.148 (colored)

Fix to bug reported and tested by Alexander Shishkin. struct ptimer has
a union that contains either a callout [for CLOCK_REALTIME] or a flag
and a list [for other clock types]. Make sure we perform the right actions
on the right union member depending on the clock type. Otherwise this would
result in crashes.

Revision 1.146.2.7 / (download) - annotate - [select for diffs], Mon Jun 30 23:03:38 2008 UTC (14 years, 7 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.6: +3 -3 lines
Diff to previous 1.146.2.6 (colored)

lwp_need_userret() needs the lpw locked.

Revision 1.146.2.6 / (download) - annotate - [select for diffs], Mon Jun 30 04:55:56 2008 UTC (14 years, 7 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.5: +5 -9 lines
Diff to previous 1.146.2.5 (colored)

Change how we make SA threads not generate upcalls. Instead of clearing
LW_SA, use a private flag, LP_SA_NOBLOCK, that we set when we want
to not generate upcalls. This means we do NOT need to lock (l)
(ourselves) to set it.

Adjust tests that look at LW_SA. Now, we are an upcall-generating
lwp if ((l->l_flag & LW_SA) && (~l->l_pflag & LP_SA_NOBLOCK)).

Introduce code pattern to set & remember this:

	f = ~l->l_pflag & LP_SA_NOBLOCK;
	l->l_pflag |= LP_SA_NOBLOCK;

	...

	/* f is now LP_SA_NOBLOCK if it wasn't set in l_pflag before */

	l->l_pflag ^= f;

I updated a lot of the trap handlers to do trap handling iff LP_SA_NOBLOCK
is not set. I tried to figure out if the trap handler could be triggered
for user-based faults as opposed to kernel faults to user addresses, and
only look at LP_SA_NOBLOCK for the latter.

Above is a result of discussions with rmind at to reduce lock twiddling.

Also, per same discussions, add locking to sys_sa_preempt(). p_lock is
the lock we want.

Also, per same discussions, remove use of LSSUSPENDED as a thread state.
We needed to use it when we were emulating the 4.X and previous behavior
of hiding cached threads. For the moment, we now have them instead
remain visible to all and have them sleeping on the "lwpcache" wait
channel.

sa_newcachelwp(): sa_putcachelwp() wants savp_mutex held, not p_lock.

Tweak some comments.

Revision 1.146.2.5 / (download) - annotate - [select for diffs], Sun Jun 29 03:28:40 2008 UTC (14 years, 7 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.4: +3 -6 lines
Diff to previous 1.146.2.4 (colored)

Don't grab sa_mutex in timerupcall(). we don't need it, and sa_upcall()
needs it to not be locked.

Don't call wakeup(). Just don't. lwp_unsleep() is the thing to call.

Revision 1.146.2.4 / (download) - annotate - [select for diffs], Mon Jun 23 04:31:51 2008 UTC (14 years, 7 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.3: +38 -22 lines
Diff to previous 1.146.2.3 (colored)

Sync w/ -current. 34 merge conflicts to follow.

Revision 1.141.4.2 / (download) - annotate - [select for diffs], Wed Jun 4 02:05:39 2008 UTC (14 years, 8 months ago) by yamt
Branch: yamt-pf42
Changes since 1.141.4.1: +37 -20 lines
Diff to previous 1.141.4.1 (colored) to branchpoint 1.141 (colored) next main 1.142 (colored)

sync with head

Revision 1.140.6.2 / (download) - annotate - [select for diffs], Mon Jun 2 13:24:10 2008 UTC (14 years, 8 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.140.6.1: +321 -184 lines
Diff to previous 1.140.6.1 (colored) to branchpoint 1.140 (colored)

Sync with HEAD.

Revision 1.148 / (download) - annotate - [select for diffs], Thu May 29 15:27:51 2008 UTC (14 years, 8 months ago) by joerg
Branch: MAIN
CVS Tags: yamt-pf42-base4, yamt-pf42-base3, wrstuden-revivesa-base-1, wrstuden-revivesa-base
Branch point for: simonb-wapbl, haad-dm
Changes since 1.147: +37 -20 lines
Diff to previous 1.147 (colored)

Explicitly compute the next interval using 64bit arithmetic, if the time
was either stepped backwards or the timer has overflown. This fixes
PR 26470.

Revision 1.146.2.3 / (download) - annotate - [select for diffs], Tue May 27 03:16:30 2008 UTC (14 years, 8 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.2: +116 -6 lines
Diff to previous 1.146.2.2 (colored)

First cut at porting SA timer code to -current. Slightly modified
so that we now use the timer_intr soft interrupt to do what we used
to do in itimerfire(). Also, use sa_mutex and p_lock instead of
the kernel lock.

Open question about what locks we can lock while holding
the timer lock.

Revision 1.141.4.1 / (download) - annotate - [select for diffs], Sun May 18 12:35:09 2008 UTC (14 years, 8 months ago) by yamt
Branch: yamt-pf42
Changes since 1.141: +291 -171 lines
Diff to previous 1.141 (colored)

sync with head.

Revision 1.145.2.1 / (download) - annotate - [select for diffs], Fri May 16 02:25:26 2008 UTC (14 years, 8 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.145: +3 -11 lines
Diff to previous 1.145 (colored)

sync with head.

Revision 1.146.2.2 / (download) - annotate - [select for diffs], Wed May 14 01:35:13 2008 UTC (14 years, 8 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146.2.1: +2 -3 lines
Diff to previous 1.146.2.1 (colored)

Per discussion with ad, remove most of the #include <sys/sa.h> lines
as they were including sa.h just for the type(s) needed for syscallargs.h.

Instead, create a new file, sys/satypes.h, which contains just the
types needed for syscallargs.h. Yes, there's only one now, but that
may change and it's probably more likely to change if it'd be difficult
to handle. :-)

Per discussion with matt at n dot o, add an include of satypes.h to
sigtypes.h. Upcall handlers are kinda signal handlers, and signalling
is the header file that's already included for syscallargs.h that
closest matches SA.

This shaves about 3000 lines off of the diff of the branch relative
to the base. That also represents about 18% of the total before this
checkin.

I think this reduction is very good thing.

Revision 1.146.2.1 / (download) - annotate - [select for diffs], Sat May 10 23:49:04 2008 UTC (14 years, 9 months ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.146: +3 -2 lines
Diff to previous 1.146 (colored)

Initial checkin of re-adding SA. Everything except kern_sa.c
compiles in GENERIC for i386. This is still a work-in-progress, but
this checkin covers most of the mechanical work (changing signalling
to be able to accomidate SA's process-wide signalling and re-adding
includes of sys/sa.h and savar.h). Subsequent changes will be much
more interesting.

Also, kern_sa.c has received partial cleanup. There's still more
to do, though.

Revision 1.147 / (download) - annotate - [select for diffs], Thu May 8 18:56:58 2008 UTC (14 years, 9 months ago) by ad
Branch: MAIN
CVS Tags: yamt-pf42-base2, yamt-nfs-mp-base2, hpcarm-cleanup-nbase
Changes since 1.146: +3 -4 lines
Diff to previous 1.146 (colored)

- Add tc_gonebad(): allows timecounter to be flagged as bad and removed at
  the next clock tick.
- Remove time_lock, which is no longer required.

Revision 1.146 / (download) - annotate - [select for diffs], Mon Apr 28 20:24:03 2008 UTC (14 years, 9 months ago) by martin
Branch: MAIN
Branch point for: wrstuden-revivesa
Changes since 1.145: +2 -9 lines
Diff to previous 1.145 (colored)

Remove clause 3 and 4 from TNF licenses

Revision 1.145 / (download) - annotate - [select for diffs], Thu Apr 24 15:35:29 2008 UTC (14 years, 9 months ago) by ad
Branch: MAIN
CVS Tags: yamt-nfs-mp-base
Branch point for: yamt-nfs-mp
Changes since 1.144: +6 -6 lines
Diff to previous 1.144 (colored)

Network protocol interrupts can now block on locks, so merge the globals
proclist_mutex and proclist_lock into a single adaptive mutex (proc_lock).
Implications:

- Inspecting process state requires thread context, so signals can no longer
  be sent from a hardware interrupt handler. Signal activity must be
  deferred to a soft interrupt or kthread.

- As the proc state locking is simplified, it's now safe to take exit()
  and wait() out from under kernel_lock.

- The system spends less time at IPL_SCHED, and there is less lock activity.

Revision 1.144 / (download) - annotate - [select for diffs], Tue Apr 22 12:04:22 2008 UTC (14 years, 9 months ago) by ad
Branch: MAIN
Changes since 1.143: +6 -9 lines
Diff to previous 1.143 (colored)

Give callout_halt() an additional 'kmutex_t *interlock' argument. If there
is a need to block and wait for the callout to complete, and there is an
interlock, it will be dropped while waiting and reacquired before return.

Revision 1.143 / (download) - annotate - [select for diffs], Mon Apr 21 12:56:31 2008 UTC (14 years, 9 months ago) by ad
Branch: MAIN
Changes since 1.142: +10 -7 lines
Diff to previous 1.142 (colored)

Make ntp, pmc, reboot, sysarch, time syscalls MPSAFE.

Revision 1.142 / (download) - annotate - [select for diffs], Mon Apr 21 00:13:46 2008 UTC (14 years, 9 months ago) by ad
Branch: MAIN
Changes since 1.141: +284 -156 lines
Diff to previous 1.141 (colored)

timer fixes for PR 37093:

- Fix serious concurrency problems, making the code MT and MP safe in
  the process.
- Don't allocate memory or inspect process state from hardclock().

Revision 1.140.6.1 / (download) - annotate - [select for diffs], Thu Apr 3 12:43:02 2008 UTC (14 years, 10 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.140: +20 -14 lines
Diff to previous 1.140 (colored)

Sync with HEAD.

Revision 1.141.2.1 / (download) - annotate - [select for diffs], Sat Mar 29 20:47:00 2008 UTC (14 years, 10 months ago) by christos
Branch: christos-time_t
Changes since 1.141: +57 -60 lines
Diff to previous 1.141 (colored)

Welcome to the time_t=long long dev_t=uint64_t branch.

Revision 1.140.2.1 / (download) - annotate - [select for diffs], Mon Mar 24 07:16:14 2008 UTC (14 years, 10 months ago) by keiichi
Branch: keiichi-mipv6
Changes since 1.140: +22 -16 lines
Diff to previous 1.140 (colored) next main 1.141 (colored)

sync with head.

Revision 1.128.2.3 / (download) - annotate - [select for diffs], Sun Mar 23 02:05:00 2008 UTC (14 years, 10 months ago) by matt
Branch: matt-armv6
Changes since 1.128.2.2: +51 -85 lines
Diff to previous 1.128.2.2 (colored) to branchpoint 1.128 (colored) next main 1.129 (colored)

sync with HEAD

Revision 1.90.2.8 / (download) - annotate - [select for diffs], Wed Feb 27 08:36:55 2008 UTC (14 years, 11 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.7: +51 -31 lines
Diff to previous 1.90.2.7 (colored) next main 1.91 (colored)

sync with head.

Revision 1.141 / (download) - annotate - [select for diffs], Mon Feb 25 12:25:03 2008 UTC (14 years, 11 months ago) by yamt
Branch: MAIN
CVS Tags: yamt-pf42-baseX, yamt-pf42-base, yamt-lazymbuf-base15, yamt-lazymbuf-base14, matt-armv6-nbase, keiichi-mipv6-nbase, keiichi-mipv6-base, hpcarm-cleanup-base, ad-socklock-base1
Branch point for: yamt-pf42, christos-time_t
Changes since 1.140: +22 -16 lines
Diff to previous 1.140 (colored)

nanosleep1: handle kpause spontaneous wakeups.

Revision 1.140 / (download) - annotate - [select for diffs], Tue Feb 19 14:21:56 2008 UTC (14 years, 11 months ago) by yamt
Branch: MAIN
CVS Tags: nick-net80211-sync-base, nick-net80211-sync
Branch point for: mjf-devfs2, keiichi-mipv6
Changes since 1.139: +29 -15 lines
Diff to previous 1.139 (colored)

wrap long lines.  no functional change.

Revision 1.139 / (download) - annotate - [select for diffs], Tue Feb 19 14:17:39 2008 UTC (14 years, 11 months ago) by yamt
Branch: MAIN
Changes since 1.138: +3 -3 lines
Diff to previous 1.138 (colored)

nanosleep1: whitespace.  no functional change.

Revision 1.130.2.4 / (download) - annotate - [select for diffs], Mon Feb 18 21:06:46 2008 UTC (14 years, 11 months ago) by mjf
Branch: mjf-devfs
Changes since 1.130.2.3: +2 -56 lines
Diff to previous 1.130.2.3 (colored) to branchpoint 1.130 (colored) next main 1.131 (colored)

Sync with HEAD.

Revision 1.134.4.2 / (download) - annotate - [select for diffs], Wed Jan 23 19:27:41 2008 UTC (15 years ago) by bouyer
Branch: bouyer-xeni386
Changes since 1.134.4.1: +0 -54 lines
Diff to previous 1.134.4.1 (colored) to branchpoint 1.134 (colored) next main 1.135 (colored)

Sync with HEAD.

Revision 1.90.2.7 / (download) - annotate - [select for diffs], Mon Jan 21 09:46:14 2008 UTC (15 years ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.6: +51 -224 lines
Diff to previous 1.90.2.6 (colored)

sync with head

Revision 1.138 / (download) - annotate - [select for diffs], Sun Jan 20 18:09:12 2008 UTC (15 years ago) by joerg
Branch: MAIN
CVS Tags: mjf-devfs-base, bouyer-xeni386-nbase
Changes since 1.137: +2 -56 lines
Diff to previous 1.137 (colored)

Now that __HAVE_TIMECOUNTER and __HAVE_GENERIC_TODR are invariants,
remove the conditionals and the code associated with the undef case.

Revision 1.128.2.2 / (download) - annotate - [select for diffs], Wed Jan 9 01:56:11 2008 UTC (15 years, 1 month ago) by matt
Branch: matt-armv6
Changes since 1.128.2.1: +81 -217 lines
Diff to previous 1.128.2.1 (colored) to branchpoint 1.128 (colored)

sync with HEAD

Revision 1.134.4.1 / (download) - annotate - [select for diffs], Wed Jan 2 21:56:03 2008 UTC (15 years, 1 month ago) by bouyer
Branch: bouyer-xeni386
CVS Tags: bouyer-xeni386-merge1
Changes since 1.134: +49 -168 lines
Diff to previous 1.134 (colored)

Sync with HEAD

Revision 1.130.2.3 / (download) - annotate - [select for diffs], Thu Dec 27 00:46:04 2007 UTC (15 years, 1 month ago) by mjf
Branch: mjf-devfs
Changes since 1.130.2.2: +51 -170 lines
Diff to previous 1.130.2.2 (colored) to branchpoint 1.130 (colored)

Sync with HEAD.

Revision 1.133.2.2 / (download) - annotate - [select for diffs], Wed Dec 26 21:39:41 2007 UTC (15 years, 1 month ago) by ad
Branch: vmlocking2
Changes since 1.133.2.1: +49 -168 lines
Diff to previous 1.133.2.1 (colored) to branchpoint 1.133 (colored) next main 1.134 (colored)

Sync with head.

Revision 1.137 / (download) - annotate - [select for diffs], Sat Dec 22 01:14:55 2007 UTC (15 years, 1 month ago) by yamt
Branch: MAIN
CVS Tags: vmlocking2-base3, matt-armv6-base, bouyer-xeni386-base
Changes since 1.136: +3 -1 lines
Diff to previous 1.136 (colored)

use binuptime for l_stime/l_rtime.

Revision 1.136 / (download) - annotate - [select for diffs], Sat Dec 22 00:35:32 2007 UTC (15 years, 1 month ago) by yamt
Branch: MAIN
Changes since 1.135: +2 -123 lines
Diff to previous 1.135 (colored)

reduce #ifdef __HAVE_TIMECOUNTER.

Revision 1.135 / (download) - annotate - [select for diffs], Thu Dec 20 23:03:09 2007 UTC (15 years, 1 month ago) by dsl
Branch: MAIN
Changes since 1.134: +46 -46 lines
Diff to previous 1.134 (colored)

Convert all the system call entry points from:
    int foo(struct lwp *l, void *v, register_t *retval)
to:
    int foo(struct lwp *l, const struct foo_args *uap, register_t *retval)
Fixup compat code to not write into 'uap' and (in some cases) to actually
pass a correctly formatted 'uap' structure with the right name to the
next routine.
A few 'compat' routines that just call standard ones have been deleted.
All the 'compat' code compiles (along with the kernels required to test
build it).
98% done by automated scripts.

Revision 1.125.6.6 / (download) - annotate - [select for diffs], Sun Dec 9 19:38:21 2007 UTC (15 years, 2 months ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.125.6.5: +4 -4 lines
Diff to previous 1.125.6.5 (colored) to branchpoint 1.125 (colored) next main 1.126 (colored)

Sync with HEAD.

Revision 1.118.4.1 / (download) - annotate - [select for diffs], Sun Dec 9 16:04:01 2007 UTC (15 years, 2 months ago) by reinoud
Branch: reinoud-bufcleanup
Changes since 1.118: +7 -6 lines
Diff to previous 1.118 (colored) next main 1.119 (colored)

Pullup to HEAD

Revision 1.130.2.2 / (download) - annotate - [select for diffs], Sat Dec 8 18:20:33 2007 UTC (15 years, 2 months ago) by mjf
Branch: mjf-devfs
Changes since 1.130.2.1: +21 -50 lines
Diff to previous 1.130.2.1 (colored) to branchpoint 1.130 (colored)

Sync with HEAD.

Revision 1.133.2.1 / (download) - annotate - [select for diffs], Sat Dec 8 17:57:43 2007 UTC (15 years, 2 months ago) by ad
Branch: vmlocking2
Changes since 1.133: +4 -4 lines
Diff to previous 1.133 (colored)

Sync with head.

Revision 1.134 / (download) - annotate - [select for diffs], Sat Dec 8 13:31:56 2007 UTC (15 years, 2 months ago) by elad
Branch: MAIN
CVS Tags: yamt-kmem-base3, yamt-kmem-base2, yamt-kmem-base, yamt-kmem, vmlocking2-base2, reinoud-bufcleanup-nbase, jmcneill-pm-base, cube-autoconf-base, cube-autoconf
Branch point for: bouyer-xeni386
Changes since 1.133: +4 -4 lines
Diff to previous 1.133 (colored)

Replace usage of p_cred in kauth(9) call with kauth_cred_get().

okay yamt@.

Revision 1.90.2.6 / (download) - annotate - [select for diffs], Fri Dec 7 17:32:52 2007 UTC (15 years, 2 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.5: +34 -51 lines
Diff to previous 1.90.2.5 (colored)

sync with head

Revision 1.125.6.5 / (download) - annotate - [select for diffs], Tue Nov 27 19:38:07 2007 UTC (15 years, 2 months ago) by joerg
Branch: jmcneill-pm
Changes since 1.125.6.4: +21 -50 lines
Diff to previous 1.125.6.4 (colored) to branchpoint 1.125 (colored)

Sync with HEAD. amd64 Xen support needs testing.

Revision 1.133 / (download) - annotate - [select for diffs], Sun Nov 25 08:43:11 2007 UTC (15 years, 2 months ago) by elad
Branch: MAIN
CVS Tags: vmlocking2-base1, vmlocking-nbase, reinoud-bufcleanup-base
Branch point for: vmlocking2
Changes since 1.132: +3 -10 lines
Diff to previous 1.132 (colored)

Kill a KAUTH_REQ_SYSTEM_TIME_SYSTEM request that's no longer needed.

Revision 1.132 / (download) - annotate - [select for diffs], Sun Nov 25 00:35:27 2007 UTC (15 years, 2 months ago) by elad
Branch: MAIN
Changes since 1.131: +20 -42 lines
Diff to previous 1.131 (colored)

Refactor time modification checks and place them in the secmodel code.

okay christos@

Revision 1.125.6.4 / (download) - annotate - [select for diffs], Wed Nov 21 21:56:01 2007 UTC (15 years, 2 months ago) by joerg
Branch: jmcneill-pm
Changes since 1.125.6.3: +15 -3 lines
Diff to previous 1.125.6.3 (colored) to branchpoint 1.125 (colored)

Sync with HEAD.

Revision 1.130.2.1 / (download) - annotate - [select for diffs], Mon Nov 19 00:48:44 2007 UTC (15 years, 2 months ago) by mjf
Branch: mjf-devfs
Changes since 1.130: +15 -3 lines
Diff to previous 1.130 (colored)

Sync with HEAD.

Revision 1.129.2.2 / (download) - annotate - [select for diffs], Sun Nov 18 19:35:49 2007 UTC (15 years, 2 months ago) by bouyer
Branch: bouyer-xenamd64
Changes since 1.129.2.1: +13 -1 lines
Diff to previous 1.129.2.1 (colored) to branchpoint 1.129 (colored) next main 1.130 (colored)

Sync with HEAD

Revision 1.131 / (download) - annotate - [select for diffs], Thu Nov 15 20:12:04 2007 UTC (15 years, 2 months ago) by ad
Branch: MAIN
CVS Tags: bouyer-xenamd64-base2, bouyer-xenamd64-base
Changes since 1.130: +15 -3 lines
Diff to previous 1.130 (colored)

Add a bit of locking around timecounter attachment / selection.

Revision 1.128.2.1 / (download) - annotate - [select for diffs], Tue Nov 6 23:32:01 2007 UTC (15 years, 3 months ago) by matt
Branch: matt-armv6
CVS Tags: matt-armv6-prevmlocking
Changes since 1.128: +20 -19 lines
Diff to previous 1.128 (colored)

sync with HEAD

Revision 1.117.2.7 / (download) - annotate - [select for diffs], Mon Nov 5 15:01:35 2007 UTC (15 years, 3 months ago) by ad
Branch: vmlocking
Changes since 1.117.2.6: +4 -4 lines
Diff to previous 1.117.2.6 (colored) next main 1.118 (colored)

nanoslp -> sleep

Revision 1.90.2.5 / (download) - annotate - [select for diffs], Sat Oct 27 11:35:30 2007 UTC (15 years, 3 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.4: +20 -19 lines
Diff to previous 1.90.2.4 (colored)

sync with head.

Revision 1.125.6.3 / (download) - annotate - [select for diffs], Fri Oct 26 15:48:37 2007 UTC (15 years, 3 months ago) by joerg
Branch: jmcneill-pm
Changes since 1.125.6.2: +20 -19 lines
Diff to previous 1.125.6.2 (colored) to branchpoint 1.125 (colored)

Sync with HEAD.

Follow the merge of pmap.c on i386 and amd64 and move
pmap_init_tmp_pgtbl into arch/x86/x86/pmap.c. Modify the ACPI wakeup
code to restore CR4 before jumping back into kernel space as the large
page option might cover that.

Revision 1.129.2.1 / (download) - annotate - [select for diffs], Thu Oct 25 22:40:02 2007 UTC (15 years, 3 months ago) by bouyer
Branch: bouyer-xenamd64
Changes since 1.129: +3 -3 lines
Diff to previous 1.129 (colored)

Sync with HEAD.

Revision 1.117.2.6 / (download) - annotate - [select for diffs], Tue Oct 23 20:17:12 2007 UTC (15 years, 3 months ago) by ad
Branch: vmlocking
Changes since 1.117.2.5: +3 -3 lines
Diff to previous 1.117.2.5 (colored)

Sync with head.

Revision 1.130 / (download) - annotate - [select for diffs], Fri Oct 19 12:16:43 2007 UTC (15 years, 3 months ago) by ad
Branch: MAIN
CVS Tags: jmcneill-base
Branch point for: mjf-devfs
Changes since 1.129: +3 -3 lines
Diff to previous 1.129 (colored)

machine/{bus,cpu,intr}.h -> sys/{bus,cpu,intr}.h

Revision 1.128.4.1 / (download) - annotate - [select for diffs], Sun Oct 14 11:48:44 2007 UTC (15 years, 3 months ago) by yamt
Branch: yamt-x86pmap
Changes since 1.128: +19 -18 lines
Diff to previous 1.128 (colored) next main 1.129 (colored)

sync with head.

Revision 1.129 / (download) - annotate - [select for diffs], Mon Oct 8 20:06:19 2007 UTC (15 years, 4 months ago) by ad
Branch: MAIN
CVS Tags: yamt-x86pmap-base4, yamt-x86pmap-base3, vmlocking-base
Branch point for: bouyer-xenamd64
Changes since 1.128: +19 -18 lines
Diff to previous 1.128 (colored)

Merge run time accounting changes from the vmlocking branch. These make
the LWP "start time" per-thread instead of per-CPU.

Revision 1.90.2.4 / (download) - annotate - [select for diffs], Mon Sep 3 14:40:58 2007 UTC (15 years, 5 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.3: +64 -112 lines
Diff to previous 1.90.2.3 (colored)

sync with head.

Revision 1.117.2.5 / (download) - annotate - [select for diffs], Mon Aug 20 21:27:35 2007 UTC (15 years, 5 months ago) by ad
Branch: vmlocking
Changes since 1.117.2.4: +2 -36 lines
Diff to previous 1.117.2.4 (colored)

Sync with HEAD.

Revision 1.125.6.2 / (download) - annotate - [select for diffs], Thu Aug 16 11:03:35 2007 UTC (15 years, 5 months ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.125.6.1: +2 -30 lines
Diff to previous 1.125.6.1 (colored) to branchpoint 1.125 (colored)

Sync with HEAD.

Revision 1.125.2.1 / (download) - annotate - [select for diffs], Wed Aug 15 13:49:10 2007 UTC (15 years, 5 months ago) by skrll
Branch: nick-csl-alignment
Changes since 1.125: +2 -36 lines
Diff to previous 1.125 (colored) next main 1.126 (colored)

Sync with HEAD.

Revision 1.128 / (download) - annotate - [select for diffs], Thu Aug 9 07:36:19 2007 UTC (15 years, 6 months ago) by pooka
Branch: MAIN
CVS Tags: yamt-x86pmap-base2, yamt-x86pmap-base, nick-csl-alignment-base5
Branch point for: yamt-x86pmap, matt-armv6
Changes since 1.127: +2 -30 lines
Diff to previous 1.127 (colored)

Shuffle routines which just roll values around from kern_clock.c
and kern_time.c to subr_time.c.

Revision 1.125.6.1 / (download) - annotate - [select for diffs], Thu Aug 9 02:37:20 2007 UTC (15 years, 6 months ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.125: +2 -8 lines
Diff to previous 1.125 (colored)

Sync with HEAD.

Revision 1.127 / (download) - annotate - [select for diffs], Tue Aug 7 11:43:35 2007 UTC (15 years, 6 months ago) by ad
Branch: MAIN
Changes since 1.126: +2 -4 lines
Diff to previous 1.126 (colored)

No reason not to make itimespecfix() generally available..

Revision 1.126 / (download) - annotate - [select for diffs], Tue Aug 7 11:39:18 2007 UTC (15 years, 6 months ago) by ad
Branch: MAIN
Changes since 1.125: +2 -6 lines
Diff to previous 1.125 (colored)

Export itimespecfix() until itimerfix() dies.

Revision 1.117.2.4 / (download) - annotate - [select for diffs], Sat Jul 14 22:09:47 2007 UTC (15 years, 6 months ago) by ad
Branch: vmlocking
Changes since 1.117.2.3: +19 -18 lines
Diff to previous 1.117.2.3 (colored)

Make it possible to track time spent by soft interrupts as is done for
normal LWPs, and provide a sysctl to switch it on/off. Not enabled by
default because microtime() is not free. XXX Not happy with this but
I want it get it out of my local tree for the time being.

Revision 1.118.2.1 / (download) - annotate - [select for diffs], Wed Jul 11 20:09:58 2007 UTC (15 years, 7 months ago) by mjf
Branch: mjf-ufs-trans
Changes since 1.118: +60 -74 lines
Diff to previous 1.118 (colored) next main 1.119 (colored)

Sync with head.

Revision 1.125 / (download) - annotate - [select for diffs], Mon Jul 9 21:10:54 2007 UTC (15 years, 7 months ago) by ad
Branch: MAIN
CVS Tags: nick-csl-alignment-base, mjf-ufs-trans-base, matt-mips64-base, matt-mips64, hpcarm-cleanup
Branch point for: nick-csl-alignment, jmcneill-pm
Changes since 1.124: +10 -7 lines
Diff to previous 1.124 (colored)

Merge some of the less invasive changes from the vmlocking branch:

- kthread, callout, devsw API changes
- select()/poll() improvements
- miscellaneous MT safety improvements

Revision 1.117.2.3 / (download) - annotate - [select for diffs], Sun Jul 1 21:50:40 2007 UTC (15 years, 7 months ago) by ad
Branch: vmlocking
Changes since 1.117.2.2: +10 -7 lines
Diff to previous 1.117.2.2 (colored)

Adapt to callout API change.

Revision 1.117.2.2 / (download) - annotate - [select for diffs], Fri Jun 8 14:17:22 2007 UTC (15 years, 8 months ago) by ad
Branch: vmlocking
Changes since 1.117.2.1: +52 -69 lines
Diff to previous 1.117.2.1 (colored)

Sync with head.

Revision 1.124 / (download) - annotate - [select for diffs], Mon May 21 15:35:48 2007 UTC (15 years, 8 months ago) by christos
Branch: MAIN
Changes since 1.123: +4 -4 lines
Diff to previous 1.123 (colored)

rename si_sigval -> si_value to match POSIX RTS.

Revision 1.114.2.4 / (download) - annotate - [select for diffs], Thu May 17 13:41:46 2007 UTC (15 years, 8 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.114.2.3: +50 -67 lines
Diff to previous 1.114.2.3 (colored) next main 1.115 (colored)

sync with head.

Revision 1.123 / (download) - annotate - [select for diffs], Sun May 13 19:51:35 2007 UTC (15 years, 8 months ago) by dsl
Branch: MAIN
CVS Tags: yamt-idlelwp-base8
Changes since 1.122: +4 -3 lines
Diff to previous 1.122 (colored)

nanosleep1() shouldn't try to get the current time into a NULL address.

Revision 1.122 / (download) - annotate - [select for diffs], Sun May 13 14:43:53 2007 UTC (15 years, 8 months ago) by dsl
Branch: MAIN
Changes since 1.121: +3 -4 lines
Diff to previous 1.121 (colored)

Instead of the #define versions of tc_getfrequency() and nanouptime(), use
the function ones in kern_kern_clock.c (adding tc_getfrequency).
Adjust includes so this builds.

Revision 1.121 / (download) - annotate - [select for diffs], Sun May 13 10:58:51 2007 UTC (15 years, 8 months ago) by dsl
Branch: MAIN
Changes since 1.120: +2 -13 lines
Diff to previous 1.120 (colored)

Add a #define for nanouptime() in the !__HAVE_TIMECOUNTERS case.

Revision 1.120 / (download) - annotate - [select for diffs], Sun May 13 10:34:25 2007 UTC (15 years, 8 months ago) by dsl
Branch: MAIN
Changes since 1.119: +28 -41 lines
Diff to previous 1.119 (colored)

Split sys_nanosleep().

Revision 1.119 / (download) - annotate - [select for diffs], Sat May 12 20:27:57 2007 UTC (15 years, 8 months ago) by dsl
Branch: MAIN
Changes since 1.118: +22 -15 lines
Diff to previous 1.118 (colored)

Change interface to settimeofday1() so that it can also be used from
compat code in order to avoid the stackgap.

Revision 1.114.2.3 / (download) - annotate - [select for diffs], Sat Mar 24 14:56:03 2007 UTC (15 years, 10 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.114.2.2: +4 -4 lines
Diff to previous 1.114.2.2 (colored)

sync with head.

Revision 1.117.2.1 / (download) - annotate - [select for diffs], Tue Mar 13 16:51:56 2007 UTC (15 years, 10 months ago) by ad
Branch: vmlocking
Changes since 1.117: +4 -4 lines
Diff to previous 1.117 (colored)

Sync with head.

Revision 1.118 / (download) - annotate - [select for diffs], Mon Mar 12 18:18:33 2007 UTC (15 years, 10 months ago) by ad
Branch: MAIN
CVS Tags: thorpej-atomic-base, thorpej-atomic
Branch point for: reinoud-bufcleanup, mjf-ufs-trans
Changes since 1.117: +4 -4 lines
Diff to previous 1.117 (colored)

Pass an ipl argument to pool_init/POOL_INIT to be used when initializing
the pool's lock.

Revision 1.114.2.2 / (download) - annotate - [select for diffs], Mon Mar 12 05:58:38 2007 UTC (15 years, 11 months ago) by rmind
Branch: yamt-idlelwp
Changes since 1.114.2.1: +6 -6 lines
Diff to previous 1.114.2.1 (colored)

Sync with HEAD.

Revision 1.117 / (download) - annotate - [select for diffs], Fri Mar 9 14:11:26 2007 UTC (15 years, 11 months ago) by ad
Branch: MAIN
Branch point for: vmlocking
Changes since 1.116: +4 -4 lines
Diff to previous 1.116 (colored)

- Make the proclist_lock a mutex. The write:read ratio is unfavourable,
  and mutexes are cheaper use than RW locks.
- LOCK_ASSERT -> KASSERT in some places.
- Hold proclist_lock/kernel_lock longer in a couple of places.

Revision 1.116 / (download) - annotate - [select for diffs], Sun Mar 4 06:03:07 2007 UTC (15 years, 11 months ago) by christos
Branch: MAIN
Changes since 1.115: +4 -4 lines
Diff to previous 1.115 (colored)

Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.

Revision 1.114.2.1 / (download) - annotate - [select for diffs], Tue Feb 27 16:54:25 2007 UTC (15 years, 11 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.114: +4 -4 lines
Diff to previous 1.114 (colored)

- sync with head.
- move sched_changepri back to kern_synch.c as it doesn't know PPQ anymore.

Revision 1.90.2.3 / (download) - annotate - [select for diffs], Mon Feb 26 09:11:12 2007 UTC (15 years, 11 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.2: +21 -104 lines
Diff to previous 1.90.2.2 (colored)

sync with head.

Revision 1.115 / (download) - annotate - [select for diffs], Thu Feb 22 06:34:44 2007 UTC (15 years, 11 months ago) by thorpej
Branch: MAIN
CVS Tags: ad-audiomp-base, ad-audiomp
Changes since 1.114: +4 -4 lines
Diff to previous 1.114 (colored)

TRUE -> true, FALSE -> false

Revision 1.114 / (download) - annotate - [select for diffs], Fri Feb 16 02:53:43 2007 UTC (15 years, 11 months ago) by ad
Branch: MAIN
Branch point for: yamt-idlelwp
Changes since 1.113: +9 -8 lines
Diff to previous 1.113 (colored)

Remove spllowersoftclock() and CLKF_BASEPRI(), and always dispatch callouts
via a soft interrupt. In the near future, softclock will be run from process
context.

Revision 1.113 / (download) - annotate - [select for diffs], Fri Feb 9 21:55:31 2007 UTC (15 years, 11 months ago) by ad
Branch: MAIN
CVS Tags: post-newlock2-merge
Changes since 1.112: +14 -98 lines
Diff to previous 1.112 (colored)

Merge newlock2 to head.

Revision 1.105.4.9 / (download) - annotate - [select for diffs], Tue Jan 30 13:51:41 2007 UTC (16 years ago) by ad
Branch: newlock2
Changes since 1.105.4.8: +2 -88 lines
Diff to previous 1.105.4.8 (colored) to branchpoint 1.105 (colored) next main 1.106 (colored)

Remove support for SA. Ok core@.

Revision 1.105.4.8 / (download) - annotate - [select for diffs], Sun Jan 28 01:34:18 2007 UTC (16 years ago) by ad
Branch: newlock2
Changes since 1.105.4.7: +4 -4 lines
Diff to previous 1.105.4.7 (colored) to branchpoint 1.105 (colored)

- Remove the last use of mtsleep()
- sched_pause() -> kpause()

Revision 1.105.4.7 / (download) - annotate - [select for diffs], Fri Jan 12 01:04:07 2007 UTC (16 years ago) by ad
Branch: newlock2
Changes since 1.105.4.6: +3 -17 lines
Diff to previous 1.105.4.6 (colored) to branchpoint 1.105 (colored)

Sync with head.

Revision 1.105.4.6 / (download) - annotate - [select for diffs], Thu Jan 11 22:23:00 2007 UTC (16 years ago) by ad
Branch: newlock2
Changes since 1.105.4.5: +3 -3 lines
Diff to previous 1.105.4.5 (colored) to branchpoint 1.105 (colored)

Checkpoint work in progress.

Revision 1.90.2.2 / (download) - annotate - [select for diffs], Sat Dec 30 20:50:06 2006 UTC (16 years, 1 month ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90.2.1: +41 -40 lines
Diff to previous 1.90.2.1 (colored)

sync with head.

Revision 1.105.4.5 / (download) - annotate - [select for diffs], Fri Dec 29 20:27:44 2006 UTC (16 years, 1 month ago) by ad
Branch: newlock2
Changes since 1.105.4.4: +19 -30 lines
Diff to previous 1.105.4.4 (colored) to branchpoint 1.105 (colored)

Checkpoint work in progress.

Revision 1.112 / (download) - annotate - [select for diffs], Wed Dec 27 12:10:09 2006 UTC (16 years, 1 month ago) by yamt
Branch: MAIN
CVS Tags: newlock2-nbase, newlock2-base
Changes since 1.111: +2 -16 lines
Diff to previous 1.111 (colored)

remove nqnfs.

Revision 1.106.2.2 / (download) - annotate - [select for diffs], Sun Dec 10 07:18:45 2006 UTC (16 years, 2 months ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.106.2.1: +16 -17 lines
Diff to previous 1.106.2.1 (colored) to branchpoint 1.106 (colored) next main 1.107 (colored)

sync with head.

Revision 1.111 / (download) - annotate - [select for diffs], Wed Dec 6 10:02:22 2006 UTC (16 years, 2 months ago) by yamt
Branch: MAIN
CVS Tags: yamt-splraiseipl-base5, yamt-splraiseipl-base4, yamt-splraiseipl-base3
Changes since 1.110: +3 -3 lines
Diff to previous 1.110 (colored)

use KSI_INIT rather than memset.  no functional changes.

Revision 1.105.4.4 / (download) - annotate - [select for diffs], Sat Nov 18 21:39:22 2006 UTC (16 years, 2 months ago) by ad
Branch: newlock2
Changes since 1.105.4.3: +17 -11 lines
Diff to previous 1.105.4.3 (colored) to branchpoint 1.105 (colored)

Sync with head.

Revision 1.105.4.3 / (download) - annotate - [select for diffs], Fri Nov 17 16:34:37 2006 UTC (16 years, 2 months ago) by ad
Branch: newlock2
Changes since 1.105.4.2: +13 -15 lines
Diff to previous 1.105.4.2 (colored) to branchpoint 1.105 (colored)

Checkpoint work in progress.

Revision 1.110 / (download) - annotate - [select for diffs], Wed Nov 1 10:17:58 2006 UTC (16 years, 3 months ago) by yamt
Branch: MAIN
CVS Tags: wrstuden-fixsa-newbase, wrstuden-fixsa-base-1, wrstuden-fixsa-base, wrstuden-fixsa, netbsd-4-base, netbsd-4-0-RELEASE, netbsd-4-0-RC5, netbsd-4-0-RC4, netbsd-4-0-RC3, netbsd-4-0-RC2, netbsd-4-0-RC1, netbsd-4-0-1-RELEASE, netbsd-4-0, netbsd-4, matt-nb4-arm-base, matt-nb4-arm
Changes since 1.109: +15 -16 lines
Diff to previous 1.109 (colored)

remove some __unused from function parameters.

Revision 1.106.2.1 / (download) - annotate - [select for diffs], Sun Oct 22 06:07:11 2006 UTC (16 years, 3 months ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.106: +18 -17 lines
Diff to previous 1.106 (colored)

sync with head

Revision 1.105.4.2 / (download) - annotate - [select for diffs], Sat Oct 21 15:20:47 2006 UTC (16 years, 3 months ago) by ad
Branch: newlock2
Changes since 1.105.4.1: +13 -8 lines
Diff to previous 1.105.4.1 (colored) to branchpoint 1.105 (colored)

Checkpoint work in progress on locking and per-LWP signals. Very much a
a work in progress and there is still a lot to do.

Revision 1.109 / (download) - annotate - [select for diffs], Fri Oct 20 22:22:48 2006 UTC (16 years, 3 months ago) by elad
Branch: MAIN
CVS Tags: yamt-splraiseipl-base2
Changes since 1.108: +3 -3 lines
Diff to previous 1.108 (colored)

Add an XXX to remind me why it's there when grepping. (securelevel ref)

Revision 1.108 / (download) - annotate - [select for diffs], Thu Oct 12 01:32:17 2006 UTC (16 years, 3 months ago) by christos
Branch: MAIN
Changes since 1.107: +16 -15 lines
Diff to previous 1.107 (colored)

- sprinkle __unused on function decls.
- fix a couple of unused bugs
- no more -Wno-unused for i386

Revision 1.107 / (download) - annotate - [select for diffs], Mon Sep 25 18:28:56 2006 UTC (16 years, 4 months ago) by christos
Branch: MAIN
Changes since 1.106: +3 -3 lines
Diff to previous 1.106 (colored)

PR/34612: Bucky Katz: SA returns from sleep do not set the signal flags
Patch applied, many thanks for the example!

Revision 1.98.8.4 / (download) - annotate - [select for diffs], Thu Sep 14 12:31:48 2006 UTC (16 years, 4 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.98.8.3: +11 -9 lines
Diff to previous 1.98.8.3 (colored) to branchpoint 1.98 (colored) next main 1.99 (colored)

sync with head.

Revision 1.105.4.1 / (download) - annotate - [select for diffs], Mon Sep 11 18:07:25 2006 UTC (16 years, 4 months ago) by ad
Branch: newlock2
Changes since 1.105: +9 -3 lines
Diff to previous 1.105 (colored)

- Convert some lockmgr() locks to mutexes and RW locks.
- Acquire proclist_lock and p_crmutex in some obvious places.

Revision 1.98.4.1 / (download) - annotate - [select for diffs], Sat Sep 9 02:57:16 2006 UTC (16 years, 5 months ago) by rpaulo
Branch: rpaulo-netinet-merge-pcb
Changes since 1.98: +244 -30 lines
Diff to previous 1.98 (colored) next main 1.99 (colored)

sync with head

Revision 1.106 / (download) - annotate - [select for diffs], Fri Sep 8 20:58:57 2006 UTC (16 years, 5 months ago) by elad
Branch: MAIN
CVS Tags: yamt-splraiseipl-base, yamt-pdpolicy-base9
Branch point for: yamt-splraiseipl
Changes since 1.105: +11 -9 lines
Diff to previous 1.105 (colored)

First take at security model abstraction.

- Add a few scopes to the kernel: system, network, and machdep.

- Add a few more actions/sub-actions (requests), and start using them as
  opposed to the KAUTH_GENERIC_ISSUSER place-holders.

- Introduce a basic set of listeners that implement our "traditional"
  security model, called "bsd44". This is the default (and only) model we
  have at the moment.

- Update all relevant documentation.

- Add some code and docs to help folks who want to actually use this stuff:

  * There's a sample overlay model, sitting on-top of "bsd44", for
    fast experimenting with tweaking just a subset of an existing model.

    This is pretty cool because it's *really* straightforward to do stuff
    you had to use ugly hacks for until now...

  * And of course, documentation describing how to do the above for quick
    reference, including code samples.

All of these changes were tested for regressions using a Python-based
testsuite that will be (I hope) available soon via pkgsrc. Information
about the tests, and how to write new ones, can be found on:

	http://kauth.linbsd.org/kauthwiki

NOTE FOR DEVELOPERS: *PLEASE* don't add any code that does any of the
following:

  - Uses a KAUTH_GENERIC_ISSUSER kauth(9) request,
  - Checks 'securelevel' directly,
  - Checks a uid/gid directly.

(or if you feel you have to, contact me first)

This is still work in progress; It's far from being done, but now it'll
be a lot easier.

Relevant mailing list threads:

http://mail-index.netbsd.org/tech-security/2006/01/25/0011.html
http://mail-index.netbsd.org/tech-security/2006/03/24/0001.html
http://mail-index.netbsd.org/tech-security/2006/04/18/0000.html
http://mail-index.netbsd.org/tech-security/2006/05/15/0000.html
http://mail-index.netbsd.org/tech-security/2006/08/01/0000.html
http://mail-index.netbsd.org/tech-security/2006/08/25/0000.html

Many thanks to YAMAMOTO Takashi, Matt Thomas, and Christos Zoulas for help
stablizing kauth(9).

Full credit for the regression tests, making sure these changes didn't break
anything, goes to Matt Fleming and Jaime Fournier.

Happy birthday Randi! :)

Revision 1.98.8.3 / (download) - annotate - [select for diffs], Fri Aug 11 15:45:46 2006 UTC (16 years, 5 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.98.8.2: +35 -22 lines
Diff to previous 1.98.8.2 (colored) to branchpoint 1.98 (colored)

sync with head

Revision 1.105 / (download) - annotate - [select for diffs], Sun Jul 23 22:06:11 2006 UTC (16 years, 6 months ago) by ad
Branch: MAIN
CVS Tags: yamt-pdpolicy-base8, yamt-pdpolicy-base7, rpaulo-netinet-merge-pcb-base, abandoned-netbsd-4-base, abandoned-netbsd-4
Branch point for: newlock2
Changes since 1.104: +17 -17 lines
Diff to previous 1.104 (colored)

Use the LWP cached credentials where sane.

Revision 1.104 / (download) - annotate - [select for diffs], Sun Jul 16 19:23:11 2006 UTC (16 years, 6 months ago) by kardel
Branch: MAIN
Changes since 1.103: +5 -1 lines
Diff to previous 1.103 (colored)

fix another t{s,v}tohz() fallout (invalid remaining time)
now passes regression/sys/kern/sleeping

Revision 1.103 / (download) - annotate - [select for diffs], Fri Jul 14 22:45:20 2006 UTC (16 years, 6 months ago) by kardel
Branch: MAIN
Changes since 1.102: +6 -4 lines
Diff to previous 1.102 (colored)

keep NetBSD boottime semantics:
- only set at boot
- only tracking delta of set-time operations
-> will keep boottime stable across ACPI sleeps
   uptime(1) will report the time since last boot

Revision 1.101.2.1 / (download) - annotate - [select for diffs], Thu Jul 13 17:49:50 2006 UTC (16 years, 6 months ago) by gdamore
Branch: gdamore-uart
Changes since 1.101: +9 -2 lines
Diff to previous 1.101 (colored) next main 1.102 (colored)

Merge from HEAD.

Revision 1.102 / (download) - annotate - [select for diffs], Sat Jul 8 12:10:33 2006 UTC (16 years, 7 months ago) by kardel
Branch: MAIN
Changes since 1.101: +9 -2 lines
Diff to previous 1.101 (colored)

report true clock resolution based on the frequency information
from the underlying counter in clock_getres(). For frequencies
above 1GHz report a resolution if 1 nsec.

Revision 1.98.8.2 / (download) - annotate - [select for diffs], Mon Jun 26 12:52:56 2006 UTC (16 years, 7 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.98.8.1: +213 -16 lines
Diff to previous 1.98.8.1 (colored) to branchpoint 1.98 (colored)

sync with head.

Revision 1.90.2.1 / (download) - annotate - [select for diffs], Wed Jun 21 15:09:38 2006 UTC (16 years, 7 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.90: +365 -107 lines
Diff to previous 1.90 (colored)

sync with head.

Revision 1.100.2.1 / (download) - annotate - [select for diffs], Mon Jun 19 04:07:15 2006 UTC (16 years, 7 months ago) by chap
Branch: chap-midi
Changes since 1.100: +213 -16 lines
Diff to previous 1.100 (colored) next main 1.101 (colored)

Sync with head.

Revision 1.101 / (download) - annotate - [select for diffs], Wed Jun 7 22:33:40 2006 UTC (16 years, 8 months ago) by kardel
Branch: MAIN
CVS Tags: yamt-pdpolicy-base6, gdamore-uart-base, chap-midi-nbase, chap-midi-base
Branch point for: gdamore-uart
Changes since 1.100: +213 -16 lines
Diff to previous 1.100 (colored)

merge FreeBSD timecounters from branch simonb-timecounters
- struct timeval time is gone
  time.tv_sec -> time_second
- struct timeval mono_time is gone
  mono_time.tv_sec -> time_uptime
- access to time via
	{get,}{micro,nano,bin}time()
	get* versions are fast but less precise
- support NTP nanokernel implementation (NTP API 4)
- further reading:
  Timecounter Paper: http://phk.freebsd.dk/pubs/timecounter.pdf
  NTP Nanokernel: http://www.eecis.udel.edu/~mills/ntp/html/kern.html

Revision 1.98.6.3 / (download) - annotate - [select for diffs], Thu Jun 1 22:38:08 2006 UTC (16 years, 8 months ago) by kardel
Branch: simonb-timecounters
CVS Tags: simonb-timcounters-final
Changes since 1.98.6.2: +12 -8 lines
Diff to previous 1.98.6.2 (colored) to branchpoint 1.98 (colored) next main 1.99 (colored)

Sync with head.

Revision 1.98.12.1 / (download) - annotate - [select for diffs], Wed May 24 15:50:41 2006 UTC (16 years, 8 months ago) by tron
Branch: peter-altq
Changes since 1.98: +12 -8 lines
Diff to previous 1.98 (colored) next main 1.99 (colored)

Merge 2006-05-24 NetBSD-current into the "peter-altq" branch.

Revision 1.98.8.1 / (download) - annotate - [select for diffs], Wed May 24 10:58:41 2006 UTC (16 years, 8 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.98: +12 -8 lines
Diff to previous 1.98 (colored)

sync with head.

Revision 1.100 / (download) - annotate - [select for diffs], Thu May 18 10:09:12 2006 UTC (16 years, 8 months ago) by yamt
Branch: MAIN
CVS Tags: yamt-pdpolicy-base5, simonb-timecounters-base
Branch point for: chap-midi
Changes since 1.99: +1 -1 lines
Diff to previous 1.99 (colored)

timers_alloc: use PR_WAITOK.

Revision 1.99 / (download) - annotate - [select for diffs], Sun May 14 21:15:11 2006 UTC (16 years, 8 months ago) by elad
Branch: MAIN
Changes since 1.98: +11 -7 lines
Diff to previous 1.98 (colored)

integrate kauth.

Revision 1.98.10.3 / (download) - annotate - [select for diffs], Sat May 6 23:31:30 2006 UTC (16 years, 9 months ago) by christos
Branch: elad-kernelauth
Changes since 1.98.10.2: +3 -2 lines
Diff to previous 1.98.10.2 (colored) to branchpoint 1.98 (colored) next main 1.99 (colored)

- Move kauth_cred_t declaration to <sys/types.h>
- Cleanup struct ucred; forward declarations that are unused.
- Don't include <sys/kauth.h> in any header, but include it in the c files
  that need it.

Approved by core.

Revision 1.98.10.2 / (download) - annotate - [select for diffs], Fri Mar 10 13:53:24 2006 UTC (16 years, 11 months ago) by elad
Branch: elad-kernelauth
Changes since 1.98.10.1: +5 -5 lines
Diff to previous 1.98.10.1 (colored) to branchpoint 1.98 (colored)

generic_authorize() -> kauth_authorize_generic().

Revision 1.98.10.1 / (download) - annotate - [select for diffs], Wed Mar 8 00:53:40 2006 UTC (16 years, 11 months ago) by elad
Branch: elad-kernelauth
Changes since 1.98: +10 -7 lines
Diff to previous 1.98 (colored)

Adapt to kernel authorization KPI.

Revision 1.98.6.2 / (download) - annotate - [select for diffs], Tue Feb 28 21:07:13 2006 UTC (16 years, 11 months ago) by kardel
Branch: simonb-timecounters
Changes since 1.98.6.1: +39 -3 lines
Diff to previous 1.98.6.1 (colored) to branchpoint 1.98 (colored)

adjtime support for both __HAVE_TIMECOUNTER variants

Revision 1.98.6.1 / (download) - annotate - [select for diffs], Sat Feb 4 14:39:43 2006 UTC (17 years ago) by simonb
Branch: simonb-timecounters
Changes since 1.98: +176 -15 lines
Diff to previous 1.98 (colored)

Adapt for timecounters, borrowing some FreeBSD code in the process.
XXX: ifdef hell while supporting both timecounter and non-timecounter
     cases.

Revision 1.70.2.8 / (download) - annotate - [select for diffs], Sun Dec 11 10:29:12 2005 UTC (17 years, 1 month ago) by christos
Branch: ktrace-lwp
Changes since 1.70.2.7: +50 -36 lines
Diff to previous 1.70.2.7 (colored) next main 1.71 (colored)

Sync with head.

Revision 1.61.10.2 / (download) - annotate - [select for diffs], Wed Dec 7 10:43:07 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-1-6
Changes since 1.61.10.1: +3 -3 lines
Diff to previous 1.61.10.1 (colored) to branchpoint 1.61 (colored) next main 1.62 (colored)

Fix build problem caused by ticket #5952.

Revision 1.82.6.2 / (download) - annotate - [select for diffs], Wed Dec 7 10:25:02 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-2-1
Changes since 1.82.6.1: +3 -3 lines
Diff to previous 1.82.6.1 (colored) to branchpoint 1.82 (colored) next main 1.83 (colored)

Fix build problem cause by ticket #10184.

Revision 1.82.2.2 / (download) - annotate - [select for diffs], Wed Dec 7 10:06:26 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-2-0
Changes since 1.82.2.1: +3 -3 lines
Diff to previous 1.82.2.1 (colored) to branchpoint 1.82 (colored) next main 1.83 (colored)

Fix build problem caused by ticket #10184.

Revision 1.82.4.2 / (download) - annotate - [select for diffs], Wed Dec 7 10:05:54 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-2
Changes since 1.82.4.1: +3 -3 lines
Diff to previous 1.82.4.1 (colored) to branchpoint 1.82 (colored) next main 1.83 (colored)

Fix build problem caused by ticket #10184.

Revision 1.88.2.3 / (download) - annotate - [select for diffs], Wed Dec 7 09:53:55 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-3
CVS Tags: netbsd-3-1-RELEASE, netbsd-3-1-RC4, netbsd-3-1-RC3, netbsd-3-1-RC2, netbsd-3-1-RC1, netbsd-3-1-1-RELEASE, netbsd-3-1, netbsd-3-0-RELEASE, netbsd-3-0-RC6, netbsd-3-0-3-RELEASE, netbsd-3-0-2-RELEASE, netbsd-3-0-1-RELEASE, netbsd-3-0
Changes since 1.88.2.2: +3 -3 lines
Diff to previous 1.88.2.2 (colored) to branchpoint 1.88 (colored) next main 1.89 (colored)

Fix build problem caused by ticket #1031.

Revision 1.88.2.2 / (download) - annotate - [select for diffs], Tue Dec 6 23:33:19 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-3
Changes since 1.88.2.1: +24 -2 lines
Diff to previous 1.88.2.1 (colored) to branchpoint 1.88 (colored)

Apply patch (requested by christos in ticket #1031):
Avoid time wrap when setting the system time.

Revision 1.82.4.1 / (download) - annotate - [select for diffs], Tue Dec 6 16:52:19 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-2
Changes since 1.82: +24 -2 lines
Diff to previous 1.82 (colored)

Fix build problem caused by ticket #10184.

Revision 1.82.6.1 / (download) - annotate - [select for diffs], Tue Dec 6 16:51:35 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-2-1
Changes since 1.82: +24 -2 lines
Diff to previous 1.82 (colored)

Apply patch (requested by christos in ticket #10184):
Avoid time wrap when setting the system time.

Revision 1.82.2.1 / (download) - annotate - [select for diffs], Tue Dec 6 16:50:39 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-2-0
Changes since 1.82: +24 -2 lines
Diff to previous 1.82 (colored)

Apply patch (requested by christos in ticket #10184):
Avoid time wrap when setting the system time.

Revision 1.61.10.1 / (download) - annotate - [select for diffs], Tue Dec 6 16:44:47 2005 UTC (17 years, 2 months ago) by tron
Branch: netbsd-1-6
Changes since 1.61: +24 -2 lines
Diff to previous 1.61 (colored)

Apply patch (requested by christos in ticket #5966):
Avoid time wrap when setting the system time.

Revision 1.98 / (download) - annotate - [select for diffs], Mon Dec 5 00:16:34 2005 UTC (17 years, 2 months ago) by christos
Branch: MAIN
CVS Tags: yamt-uio_vmspace-base5, yamt-uio_vmspace, yamt-pdpolicy-base4, yamt-pdpolicy-base3, yamt-pdpolicy-base2, yamt-pdpolicy-base, peter-altq-base, ktrace-lwp-base, elad-kernelauth-base
Branch point for: yamt-pdpolicy, simonb-timecounters, rpaulo-netinet-merge-pcb, peter-altq, elad-kernelauth
Changes since 1.97: +42 -31 lines
Diff to previous 1.97 (colored)

- make settime take timespec.
- avoid wrapping of time in settime (from OpenBSD)
- pass struct proc down so that we can log a detailed message.

Revision 1.96.2.1 / (download) - annotate - [select for diffs], Tue Nov 29 21:23:29 2005 UTC (17 years, 2 months ago) by yamt
Branch: yamt-readahead
Changes since 1.96: +9 -5 lines
Diff to previous 1.96 (colored) next main 1.97 (colored)

sync with head.

Revision 1.97 / (download) - annotate - [select for diffs], Sat Nov 26 05:26:33 2005 UTC (17 years, 2 months ago) by simonb
Branch: MAIN
CVS Tags: yamt-readahead-base3
Changes since 1.96: +9 -5 lines
Diff to previous 1.96 (colored)

Convert malloc/free of struct ptimers to pools.
Move the ptimer pool to kern_time.c to keep like pools together,
and it wasn't used in kern_proc.c

Revision 1.96 / (download) - annotate - [select for diffs], Fri Nov 11 07:07:42 2005 UTC (17 years, 2 months ago) by simonb
Branch: MAIN
CVS Tags: yamt-readahead-pervnode, yamt-readahead-perfile, yamt-readahead-base2, yamt-readahead-base
Branch point for: yamt-readahead
Changes since 1.95: +3 -4 lines
Diff to previous 1.95 (colored)

Call nanotime() directly, instead of doing the
microtime()/TIMEVAL_TO_TIMESPEC() dance.

Revision 1.70.2.7 / (download) - annotate - [select for diffs], Thu Nov 10 14:09:45 2005 UTC (17 years, 3 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.6: +109 -77 lines
Diff to previous 1.70.2.6 (colored)

Sync with HEAD. Here we go again...

Revision 1.94.2.1 / (download) - annotate - [select for diffs], Wed Oct 26 08:32:51 2005 UTC (17 years, 3 months ago) by yamt
Branch: yamt-vop
Changes since 1.94: +4 -3 lines
Diff to previous 1.94 (colored) next main 1.95 (colored)

sync with head

Revision 1.95 / (download) - annotate - [select for diffs], Sun Oct 23 00:09:14 2005 UTC (17 years, 3 months ago) by cube
Branch: MAIN
CVS Tags: yamt-vop-base3, yamt-vop-base2, thorpej-vnode-attr-base, thorpej-vnode-attr
Changes since 1.94: +4 -3 lines
Diff to previous 1.94 (colored)

Implement a few changes needed to properly resolve PR#30924, as
discussed in the PR.

- introduce sys/timevar.h to hold kernel-specific stuff relevant to
  sys/time.h.  Ideally, timevar.h would contain all (or almost) of the
  #ifdef _KERNEL part of time.h, but that's a pretty big and tedious
  change to make.  For now, it will contain only the prototypes I
  introduced when working on COMPAT_NETBSD32.

- split copyinout_t into copyin_t and copyout_t, it makes prototypes more
  explicit about the meaning of a given argument.  Suggested by yamt@.

- move copyinout_t definition in sys/time.h to systm.h as copyin_t and
  copyout_t

- make everything uses the new types and include the proper headers at
  the proper places.

Revision 1.88.2.1 / (download) - annotate - [select for diffs], Fri Oct 21 17:39:40 2005 UTC (17 years, 3 months ago) by riz
Branch: netbsd-3
CVS Tags: netbsd-3-0-RC5, netbsd-3-0-RC4, netbsd-3-0-RC3, netbsd-3-0-RC2, netbsd-3-0-RC1
Changes since 1.88: +5 -7 lines
Diff to previous 1.88 (colored)

Pull up following revision(s) (requested by chs in ticket #901):
	sys/kern/kern_time.c: revision 1.94
	sys/sys/signalvar.h: revision 1.59
	sys/sys/savar.h: revision 1.16
	sys/kern/kern_sig.c: revision 1.209
	sys/kern/kern_sa.c: revision 1.66
	sys/kern/kern_synch.c: revision 1.150
avoid calling into the pool code while holding sched_lock
since both pool_get() and pool_put() can call wakeup().
instead, allocate the struct sadata_upcall before taking
sched_lock in mi_switch() and free it after releasing sched_lock.
clean up some modularity warts by adding a callback to
struct sadata_upcall for freeing sa_arg.

Revision 1.94 / (download) - annotate - [select for diffs], Sun Oct 2 17:51:27 2005 UTC (17 years, 4 months ago) by chs
Branch: MAIN
CVS Tags: yamt-vop-base
Branch point for: yamt-vop
Changes since 1.93: +5 -7 lines
Diff to previous 1.93 (colored)

avoid calling into the pool code while holding sched_lock
since both pool_get() and pool_put() can call wakeup().
instead, allocate the struct sadata_upcall before taking
sched_lock in mi_switch() and free it after releasing sched_lock.

clean up some modularity warts by adding a callback to
struct sadata_upcall for freeing sa_arg.

Revision 1.93 / (download) - annotate - [select for diffs], Fri Sep 23 12:10:33 2005 UTC (17 years, 4 months ago) by jmmv
Branch: MAIN
Changes since 1.92: +3 -2 lines
Diff to previous 1.92 (colored)

Apply the NFS exports list rototill patch:

- Remove all NFS related stuff from file system specific code.
- Drop the vfs_checkexp hook and generalize it in the new nfs_check_export
  function, thus removing redundancy from all file systems.
- Move all NFS export-related stuff from kern/vfs_subr.c to the new
  file sys/nfs/nfs_export.c.  The former was becoming large and its code
  is always compiled, regardless of the build options.  Using the latter,
  the code is only compiled in when NFSSERVER is enabled.  While doing this,
  also make some functions in nfs_subs.c conditional to NFSSERVER.
- Add a new command in nfssvc(2), called NFSSVC_SETEXPORTSLIST, that takes a
  path and a set of export entries.  At the moment it can only clear the
  exports list or append entries, one by one, but it is done in a way that
  allows setting the whole set of entries atomically in the future (see the
  comment in mountd_set_exports_list or in doc/TODO).
- Change mountd(8) to use the nfssvc(2) system call instead of mount(2) so
  that it becomes file system agnostic.  In fact, all this whole thing was
  done to remove a 'XXX' block from this utility!
- Change the mount*, newfs and fsck* userland utilities to not deal with NFS
  exports initialization; done internally by the kernel when initializing
  the NFS support for each file system.
- Implement an interface for VFS (called VFS hooks) so that several kernel
  subsystems can run arbitrary code upon receipt of specific VFS events.
  At the moment, this only provides support for unmount and is used to
  destroy NFS exports lists from the file systems being unmounted, though it
  has room for extension.

Thanks go to yamt@, chs@, thorpej@, wrstuden@ and others for their comments
and advice in the development of this patch.

Revision 1.92 / (download) - annotate - [select for diffs], Sat Jul 23 18:54:07 2005 UTC (17 years, 6 months ago) by cube
Branch: MAIN
Changes since 1.91: +64 -38 lines
Diff to previous 1.91 (colored)

Split sys_timer_create, sys_timer_gettime and sys_timer_settime so they
can be easily used by netbsd32 code.

XXX Meanwhile, introduce a copyinout_t type that matches the prototype of
XXX copyin(9) and copyout(9).  Its logical place would be in systm.h, near
XXX the definition of copyin, but, well, see the comment.

Revision 1.91 / (download) - annotate - [select for diffs], Mon Jul 11 19:50:42 2005 UTC (17 years, 7 months ago) by cube
Branch: MAIN
Changes since 1.90: +32 -15 lines
Diff to previous 1.90 (colored)

Split sys_getitimer and sys_setitimer to make it possible to share the
relevant code with the COMPAT_NETBSD32 version, and make the latter use
the new functions.

This fixes netbsd32_setitimer() which had drifted from the native syscall
and did not work properly anymore.

Revision 1.90 / (download) - annotate - [select for diffs], Thu Jun 23 23:15:12 2005 UTC (17 years, 7 months ago) by thorpej
Branch: MAIN
Branch point for: yamt-lazymbuf
Changes since 1.89: +7 -17 lines
Diff to previous 1.89 (colored)

Use ANSI function decls.  Apply some static.

Revision 1.89 / (download) - annotate - [select for diffs], Sun May 29 22:24:15 2005 UTC (17 years, 8 months ago) by christos
Branch: MAIN
Changes since 1.88: +7 -8 lines
Diff to previous 1.88 (colored)

- add const.
- remove unnecessary casts.
- add __UNCONST casts and mark them with XXXUNCONST as necessary.

Revision 1.86.2.1 / (download) - annotate - [select for diffs], Fri Apr 29 11:29:23 2005 UTC (17 years, 9 months ago) by kent
Branch: kent-audio2
Changes since 1.86: +5 -5 lines
Diff to previous 1.86 (colored) next main 1.87 (colored)

sync with -current

Revision 1.86.4.1 / (download) - annotate - [select for diffs], Sat Mar 19 08:36:11 2005 UTC (17 years, 10 months ago) by yamt
Branch: yamt-km
Changes since 1.86: +5 -5 lines
Diff to previous 1.86 (colored) next main 1.87 (colored)

sync with head.  xen and whitespace.  xen part is not finished.

Revision 1.70.2.6 / (download) - annotate - [select for diffs], Fri Mar 4 16:51:59 2005 UTC (17 years, 11 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.5: +5 -5 lines
Diff to previous 1.70.2.5 (colored)

Sync with HEAD.

Hi Perry!

Revision 1.88 / (download) - annotate - [select for diffs], Wed Mar 2 11:05:34 2005 UTC (17 years, 11 months ago) by mycroft
Branch: MAIN
CVS Tags: yamt-km-base4, yamt-km-base3, netbsd-3-base, kent-audio2-base
Branch point for: netbsd-3
Changes since 1.87: +3 -3 lines
Diff to previous 1.87 (colored)

Copyright maintenance.

Revision 1.87 / (download) - annotate - [select for diffs], Sat Feb 26 21:34:55 2005 UTC (17 years, 11 months ago) by perry
Branch: MAIN
Changes since 1.86: +4 -4 lines
Diff to previous 1.86 (colored)

nuke trailing whitespace

Revision 1.70.2.5 / (download) - annotate - [select for diffs], Mon Jan 17 19:32:25 2005 UTC (18 years ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.4: +6 -3 lines
Diff to previous 1.70.2.4 (colored)

Sync with HEAD.

Revision 1.86 / (download) - annotate - [select for diffs], Thu Jan 6 19:26:41 2005 UTC (18 years, 1 month ago) by mycroft
Branch: MAIN
CVS Tags: yamt-km-base2, yamt-km-base, kent-audio1-beforemerge
Branch point for: yamt-km, kent-audio2
Changes since 1.85: +6 -3 lines
Diff to previous 1.85 (colored)

If sa_upcall() fails (which is always going to be due to resource exhaustion),
do not leak siginfo structures.

Note that in the cases of trap signals and timer events, losing this
information could be very bad; right now it will cause us to spin until the
process is SIGKILLed.

"Needs work."

Revision 1.70.2.4 / (download) - annotate - [select for diffs], Mon Nov 29 07:24:51 2004 UTC (18 years, 2 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.3: +3 -3 lines
Diff to previous 1.70.2.3 (colored)

Sync with HEAD.

Revision 1.85 / (download) - annotate - [select for diffs], Sun Nov 14 03:30:09 2004 UTC (18 years, 2 months ago) by atatat
Branch: MAIN
CVS Tags: kent-audio1-base, kent-audio1
Changes since 1.84: +3 -3 lines
Diff to previous 1.84 (colored)

Wrap TIMEVAL_TO_TIMESPEC and TIMESPEC_TO_TIMEVAL macros in

	do { ... } while(/*CONSTCOND*/0)

so that they can be used unadorned in if/else blocks, etc.  This means
that you now *have* to put a ; at the end of the "call" to these
macros.

Revision 1.70.2.3 / (download) - annotate - [select for diffs], Tue Sep 21 13:35:11 2004 UTC (18 years, 4 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.2: +2 -2 lines
Diff to previous 1.70.2.2 (colored)

Fix the sync with head I botched.

Revision 1.70.2.2 / (download) - annotate - [select for diffs], Sat Sep 18 14:53:03 2004 UTC (18 years, 4 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70.2.1: +0 -0 lines
Diff to previous 1.70.2.1 (colored)

Sync with HEAD.

Revision 1.70.2.1 / (download) - annotate - [select for diffs], Tue Aug 3 10:52:54 2004 UTC (18 years, 6 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.70: +58 -41 lines
Diff to previous 1.70 (colored)

Sync with HEAD

Revision 1.84 / (download) - annotate - [select for diffs], Tue Apr 27 05:25:33 2004 UTC (18 years, 9 months ago) by simonb
Branch: MAIN
Changes since 1.83: +4 -4 lines
Diff to previous 1.83 (colored)

Fix "comments within comments" problem pointed out by Geoff Wing on
source-changes.

Revision 1.83 / (download) - annotate - [select for diffs], Tue Apr 27 01:12:44 2004 UTC (18 years, 9 months ago) by kleink
Branch: MAIN
Changes since 1.82: +4 -4 lines
Diff to previous 1.82 (colored)

POSIX-2001: Add restrict keywords to gettimeofday(2) and setitimer(2);
further deprecate struct timezone usage by changing `tzp' argument to
gettimeofday() to void *; align utimes(2) declaration by changing `times`
argument from struct timeval * to struct timeval[2].  From Murray
Armfield in PR standards/25331.

In due curse, reflect these changes in futimes(2), lutimes(2), and
settimeofday(2).

Revision 1.82 / (download) - annotate - [select for diffs], Sun Mar 14 01:08:47 2004 UTC (18 years, 10 months ago) by cl
Branch: MAIN
CVS Tags: netbsd-2-base, netbsd-2-1-RELEASE, netbsd-2-1-RC6, netbsd-2-1-RC5, netbsd-2-1-RC4, netbsd-2-1-RC3, netbsd-2-1-RC2, netbsd-2-1-RC1, netbsd-2-0-base, netbsd-2-0-RELEASE, netbsd-2-0-RC5, netbsd-2-0-RC4, netbsd-2-0-RC3, netbsd-2-0-RC2, netbsd-2-0-RC1, netbsd-2-0-3-RELEASE, netbsd-2-0-2-RELEASE, netbsd-2-0-1-RELEASE
Branch point for: netbsd-2-1, netbsd-2-0, netbsd-2
Changes since 1.81: +11 -8 lines
Diff to previous 1.81 (colored)

add kernel part of concurrency support for SA on MP systems
- move per VP data into struct sadata_vp referenced from l->l_savp
  * VP id
  * lock on VP data
  * LWP on VP
  * recently blocked LWP on VP
  * queue of LWPs woken which ran on this VP before sleep
  * faultaddr
  * LWP cache for upcalls
  * upcall queue
- add current concurrency and requested concurrency variables
- make process exit run LWP on all VPs
- make signal delivery consider all VPs
- make timer events consider all VPs
- add sa_newsavp to allocate new sadata_vp structure
- add sa_increaseconcurrency to prepare new VP
- make sys_sa_setconcurrency request new VP or wakeup idle VP
- make sa_yield lower current concurrency
- set sa_cpu = VP id in upcalls
- maintain cached LWPs per VP

Revision 1.81 / (download) - annotate - [select for diffs], Fri Jan 2 18:52:17 2004 UTC (19 years, 1 month ago) by cl
Branch: MAIN
Changes since 1.80: +7 -13 lines
Diff to previous 1.80 (colored)

kernel part of no-syscall upcall stack return:  libpthread registers
an offset between ss_sp and struct sa_stackinfo_t (located in struct
__pthread_st) when calling sa_register.  The kernel increments the
sast_gen counter in struct sastack when an upcall stack is used.
libpthread increments the sasi_stackgen counter in struct
sa_stackinfo_t when an upcall stack is freed.  The kernel compares the
two counters to decide if a stack is free or in use.

- add struct sa_stackinfo_t with sasi_stackgen to count stack use in
  userland
- add sast_gen to struct sastack to count stack use in kernel
- add SA_FLAG_STACKINFO to enable the stackinfo_offset argument in the
  sa_register syscall
- add sa_stackinfo_offset to struct sadata for offset between ss_sp
  and struct sa_stackinfo_t
- add ssize_t stackinfo_offset argument to sa_register, initialize
  struct sadata's sa_stackinfo_offset from it if SA_FLAG_STACKINFO is
  set
- add sa_getstack, sa_getstack0, sa_stackused and sa_setstackfree
  functions to find/use/free upcall stacks and use these where
  appropriate
- don't record stack for upcall in sa_upcall0
- pass sau to sa_switchcall instead of l2 (l2 = curlwp in sa_switchcall)
- add sa_vp_blocker to struct sadata to pass recently blocked lwp to
  sa_switchcall
- delay finding a stack for blocked upcalls to sa_switchcall
- add sa_stacknext to struct sadata pointing to next most likely free
  upcall stack; also g/c sa_stackslist in struct sadata and sast_list
  in struct sastack
- add L_SA_WOKEN flag: LWP is on sa_woken queue
- add L_SA_RECYCLE flag: LWP should be recycled in sa_setwoken
- replace l_upcallstack with L_SA_WOKEN/L_SA_RECYCLE/L_SA_BLOCKING
  flags
- g/c now unused sast_blocker in struct sastack
- make sa_switchcall, sa_upcall0 and sa_upcall_getstate static in
  kern_sa.c
- call sa_upcall_userret only once in userret
- split sa_makeupcalls out of sa_upcall_userret and use to process
  the sa_upcalls queue
- on process exit: mark LWPs sleeping in saunblock interruptible; also
  there are no LWPs sleeping on l->l_upcallstack anymore; also clear
  sa_wokenq_head to prevent unblocked upcalls

additional changes:
- cleanup timerupcall sa_vp == curlwp check
- add check in sa_yield if we didn't block on our way here and we
  wouldn't any longer be the LWP on the VP
- invalidate sa_vp_ofaultaddr after resolving pagefault

Revision 1.80 / (download) - annotate - [select for diffs], Tue Dec 2 01:34:30 2003 UTC (19 years, 2 months ago) by christos
Branch: MAIN
Changes since 1.79: +3 -3 lines
Diff to previous 1.79 (colored)

PR/23613: Christian Biere: Bogus bounds check in nanosleep.

Revision 1.79 / (download) - annotate - [select for diffs], Thu Nov 13 03:09:30 2003 UTC (19 years, 2 months ago) by chs
Branch: MAIN
Changes since 1.78: +4 -10 lines
Diff to previous 1.78 (colored)

eliminate uvm_useracc() in favor of checking the return value of
copyin() or copyout().

uvm_useracc() tells us whether the mapping permissions allow access to
the desired part of an address space, and many callers assume that
this is the same as knowing whether an attempt to access that part of
the address space will succeed.  however, access to user space can
fail for reasons other than insufficient permission, most notably that
paging in any non-resident data can fail due to i/o errors.  most of
the callers of uvm_useracc() make the above incorrect assumption.  the
rest are all misguided optimizations, which optimize for the case
where an operation will fail.  we'd rather optimize for operations
succeeding, in which case we should just attempt the access and handle
failures due to insufficient permissions the same way we handle i/o
errors.  since there appear to be no good uses of uvm_useracc(), we'll
just remove it.

Revision 1.78 / (download) - annotate - [select for diffs], Sun Nov 2 16:26:10 2003 UTC (19 years, 3 months ago) by cl
Branch: MAIN
Changes since 1.77: +14 -19 lines
Diff to previous 1.77 (colored)

Cleanup signal delivery for SA processes:
General idea:  only consider the LWP on the VP for signal delivery, all
other LWPs are either asleep or running from waking up until repossessing
the VP.

- in kern_sig.c:kpsignal2: handle all states the LWP on the VP can be in
- in kern_sig.c:proc_stop: only try to stop the LWP on the VP.  All other
  LWPs will suspend in sa_vp_repossess() until the VP-LWP donates the VP.
  Restore original behaviour (before SA-specific hacks were added) for
  non-SA processes.
- in kern_sig.c:proc_unstop: only return the LWP on the VP
- handle sa_yield as case 0 in sa_switch instead of clearing L_SA, add an
  L_SA_YIELD flag
- replace sa_idle by L_SA_IDLE flag since it was either NULL or == sa_vp

Also don't output itimerfire overrun warning if the process is already
exiting.
Also g/c sa_woken because it's not used.
Also g/c some #if 0 code.

Revision 1.77 / (download) - annotate - [select for diffs], Wed Oct 8 00:28:42 2003 UTC (19 years, 4 months ago) by thorpej
Branch: MAIN
Changes since 1.76: +3 -3 lines
Diff to previous 1.76 (colored)

* Shuffle some data structures so, and add a flags word to ksiginfo_t.
  Right now the only flag is used to indicate if a ksiginfo_t is a
  result of a trap.  Add a predicate macro to test for this flag.
* Add initialization macros for ksiginfo_t's.
* Add accssor macro for ksi_trap.  Expands to 0 if the ksiginfo_t was
  not the result of a trap.  This matches the sigcontext trapcode semantics.
* In kpsendsig(), use KSI_TRAP_P() to select the lwp that gets the signal.
  Inspired by Matthias Drochner's fix to kpsendsig(), but correctly handles
  the case of non-trap-generated signals that have a > 0 si_code.

This patch fixes a signal delivery problem with threaded programs noted by
Matthias Drochner on tech-kern.

As discussed on tech-kern.  Reviewed and OK's by Christos.

Revision 1.76 / (download) - annotate - [select for diffs], Sun Sep 14 06:56:22 2003 UTC (19 years, 4 months ago) by christos
Branch: MAIN
Changes since 1.75: +3 -2 lines
Diff to previous 1.75 (colored)

set the sigval in the setitimer case.

Revision 1.75 / (download) - annotate - [select for diffs], Sat Sep 13 22:39:18 2003 UTC (19 years, 4 months ago) by christos
Branch: MAIN
Changes since 1.74: +8 -3 lines
Diff to previous 1.74 (colored)

enable SI_TIMER notification.

Revision 1.74 / (download) - annotate - [select for diffs], Tue Sep 9 15:16:30 2003 UTC (19 years, 5 months ago) by cl
Branch: MAIN
Changes since 1.73: +12 -5 lines
Diff to previous 1.73 (colored)

fix timerupcall breakage after SA_SIGINFO changes:
- sa_upcall only stores a pointer to the `arg'

Revision 1.73 / (download) - annotate - [select for diffs], Sat Sep 6 22:03:10 2003 UTC (19 years, 5 months ago) by christos
Branch: MAIN
Changes since 1.72: +15 -12 lines
Diff to previous 1.72 (colored)

SA_SIGINFO changes.

Revision 1.72 / (download) - annotate - [select for diffs], Thu Aug 7 16:31:51 2003 UTC (19 years, 6 months ago) by agc
Branch: MAIN
Changes since 1.71: +3 -7 lines
Diff to previous 1.71 (colored)

Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.

Revision 1.71 / (download) - annotate - [select for diffs], Thu Jul 17 18:16:59 2003 UTC (19 years, 6 months ago) by fvdl
Branch: MAIN
Changes since 1.70: +22 -3 lines
Diff to previous 1.70 (colored)

Changes from Stephan Uphoff to patch problems with LWPs blocking when they
shouldn't, and MP.

Revision 1.70 / (download) - annotate - [select for diffs], Wed May 28 22:27:57 2003 UTC (19 years, 8 months ago) by nathanw
Branch: MAIN
Branch point for: ktrace-lwp
Changes since 1.69: +9 -3 lines
Diff to previous 1.69 (colored)

Expand the test in itimerfire() to only wake up an idle SA LWP if the
process isn't stopped.

Revision 1.69 / (download) - annotate - [select for diffs], Mon May 19 03:23:37 2003 UTC (19 years, 8 months ago) by dyoung
Branch: MAIN
Changes since 1.68: +4 -4 lines
Diff to previous 1.68 (colored)

Make ppsratecheck conform with its man page, which says, "If maxpps
is set to 0, the function will always return 0 (no packets/events
are permitted)." Before this patch, ppsratecheck returned 1 once
a second when maxpps was 0.

Revision 1.68 / (download) - annotate - [select for diffs], Wed Apr 16 21:34:15 2003 UTC (19 years, 9 months ago) by dsl
Branch: MAIN
Changes since 1.67: +6 -2 lines
Diff to previous 1.67 (colored)

Flag that adjtime has happened, hardware RTC might be wrong

Revision 1.67 / (download) - annotate - [select for diffs], Mon Mar 10 21:49:56 2003 UTC (19 years, 11 months ago) by nathanw
Branch: MAIN
Changes since 1.66: +34 -11 lines
Diff to previous 1.66 (colored)

Change the contract for timer_settime() (the internal routine, not the
syscall sys_timer_settime()) to take an absolute value for realtime
timers. This avoids a pair of gratiuitous conversions with the
possibility that the timer's intermediate value would be 0.0, which
would signal timer_settime() to cancel the timer.

Adjust callers of timer_settime() to compensate; catch the case where
sys_timer_settime() with an absolute time value of now and a virtual
timer would also be subtracted down to a timer-cancelling 0.0.

This should fix the bug seen in libpthread's nanosleep() where certain
applications, such as xmms, would wedge with unexpired userlevel
alarms.

Revision 1.66 / (download) - annotate - [select for diffs], Tue Feb 4 15:50:06 2003 UTC (20 years ago) by jdolecek
Branch: MAIN
Changes since 1.65: +3 -3 lines
Diff to previous 1.65 (colored)

itimerfire(): fix bug in previous - if two or more timers would
fire close together, the second (and every other) timer would be
added to mask incorrectly - timerid value would be shifted twice,
and sa_upcall() would later kill process with SIGILL

Revision 1.65 / (download) - annotate - [select for diffs], Tue Feb 4 15:46:39 2003 UTC (20 years ago) by jdolecek
Branch: MAIN
Changes since 1.64: +5 -4 lines
Diff to previous 1.64 (colored)

cosmetic - use type 'timer_t' for timerid local in sys_timer_create()
and sys_timer_delete()

Revision 1.64 / (download) - annotate - [select for diffs], Mon Feb 3 23:39:41 2003 UTC (20 years ago) by nathanw
Branch: MAIN
Changes since 1.63: +43 -12 lines
Diff to previous 1.63 (colored)

Prevent one timer from overrunning another with the current userret
mechanism by keeping a list (bitset) of which timers have fired and using
that list in the upcall (Does this sound familiar? SEND HELP NEED SIGINFO).

Provoke the idle LWP into running again with setrunnable(sa->sa_idle)
instead of a wakeup() call, since we know what it is.

Revision 1.63 / (download) - annotate - [select for diffs], Sat Jan 18 10:06:32 2003 UTC (20 years ago) by thorpej
Branch: MAIN
Changes since 1.62: +601 -137 lines
Diff to previous 1.62 (colored)

Merge the nathanw_sa branch.

Revision 1.54.2.24 / (download) - annotate - [select for diffs], Wed Dec 11 06:43:07 2002 UTC (20 years, 2 months ago) by thorpej
Branch: nathanw_sa
CVS Tags: nathanw_sa_end
Changes since 1.54.2.23: +3 -5 lines
Diff to previous 1.54.2.23 (colored) to branchpoint 1.54 (colored) next main 1.55 (colored)

Sync with HEAD.

Revision 1.54.2.23 / (download) - annotate - [select for diffs], Tue Dec 3 23:22:16 2002 UTC (20 years, 2 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.22: +6 -2 lines
Diff to previous 1.54.2.22 (colored) to branchpoint 1.54 (colored)

Get the kernel lock in the userret timer upcall callback.

Revision 1.54.2.22 / (download) - annotate - [select for diffs], Mon Nov 11 22:13:54 2002 UTC (20 years, 2 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.21: +2 -4 lines
Diff to previous 1.54.2.21 (colored) to branchpoint 1.54 (colored)

Catch up to -current

Revision 1.54.2.21 / (download) - annotate - [select for diffs], Sat Nov 9 02:14:52 2002 UTC (20 years, 3 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.20: +6 -3 lines
Diff to previous 1.54.2.20 (colored) to branchpoint 1.54 (colored)

Separately track timer overruns presently occurring, and timer
overruns associated with the most recent successful delivery.

Revision 1.54.2.20 / (download) - annotate - [select for diffs], Sun Oct 27 21:12:38 2002 UTC (20 years, 3 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.19: +40 -40 lines
Diff to previous 1.54.2.19 (colored) to branchpoint 1.54 (colored)

Clean up some trailing whitespace.

Revision 1.62 / (download) - annotate - [select for diffs], Tue Oct 22 03:23:24 2002 UTC (20 years, 3 months ago) by simonb
Branch: MAIN
CVS Tags: nathanw_sa_before_merge, nathanw_sa_base, kqueue-beforemerge, kqueue-aftermerge, gmcgarry_ucred_base, gmcgarry_ucred, gmcgarry_ctxsw_base, gmcgarry_ctxsw, fvdl_fs64_base
Changes since 1.61: +2 -4 lines
Diff to previous 1.61 (colored)

"oatv" in adjtime1() isn't used after being set; remove it.

Revision 1.54.2.19 / (download) - annotate - [select for diffs], Thu Oct 3 23:49:31 2002 UTC (20 years, 4 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.18: +261 -132 lines
Diff to previous 1.54.2.18 (colored) to branchpoint 1.54 (colored)

Implement CLOCK_VIRTUAL and CLOCK_PROF support for POSIX timers. Factor
out some common code between POSIX timers and BSD timers along the way.

Revision 1.54.2.18 / (download) - annotate - [select for diffs], Thu Sep 26 19:50:32 2002 UTC (20 years, 4 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.17: +7 -14 lines
Diff to previous 1.54.2.17 (colored) to branchpoint 1.54 (colored)

Pass SA_UPCALL_DEFER to sa_upcall() in realtimerupcall().
Instead of incrementing pt_overruns when sa_upcall() fails, leave
p_userret set so that it gets to try again. Avoids dropping timer upcalls
in some situations.

Revision 1.54.2.17 / (download) - annotate - [select for diffs], Fri Aug 30 23:59:43 2002 UTC (20 years, 5 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.16: +5 -4 lines
Diff to previous 1.54.2.16 (colored) to branchpoint 1.54 (colored)

In realtimerupcall, check the return value of sa_upcall() for errors,
and increment the overrun count if there is an error.

Revision 1.54.2.16 / (download) - annotate - [select for diffs], Wed Jul 17 19:56:54 2002 UTC (20 years, 6 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.15: +9 -33 lines
Diff to previous 1.54.2.15 (colored) to branchpoint 1.54 (colored)

Use sa_idle information to simplify timer upcalls, and always use the
upcallret hook to avoid calling sa_upcall, alloc, cpu_setfunc, and all
that garbage from inside an asynchronous event.

Revision 1.54.2.15 / (download) - annotate - [select for diffs], Fri Jul 12 03:05:34 2002 UTC (20 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.14: +22 -6 lines
Diff to previous 1.54.2.14 (colored) to branchpoint 1.54 (colored)

Make timers_free() take another argument indicating whether it should
free all the timers (as on process teardown) or just the POSIX timers
(as on exec).

Revision 1.54.2.14 / (download) - annotate - [select for diffs], Fri Jul 12 01:40:20 2002 UTC (20 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.13: +2 -3 lines
Diff to previous 1.54.2.13 (colored) to branchpoint 1.54 (colored)

No longer need to pull in lwp.h; proc.h pulls it in for us.

Revision 1.54.2.13 / (download) - annotate - [select for diffs], Fri Apr 12 04:52:53 2002 UTC (20 years, 10 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.12: +8 -2 lines
Diff to previous 1.54.2.12 (colored) to branchpoint 1.54 (colored)

Actually track the LWP that should be running on the process's "virtual
processor" (sa->sa_vp, which will become an actual data structure for MP
purposes).

Use this to determine what was interrupted in the re-BLOCKING case and the
unblocked case.

Revision 1.54.2.12 / (download) - annotate - [select for diffs], Tue Apr 2 00:16:00 2002 UTC (20 years, 10 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.11: +2 -3 lines
Diff to previous 1.54.2.11 (colored) to branchpoint 1.54 (colored)

- Centralize p_nrlwps handling in those functions which actually
  set the LWP state to LSRUN. Simplifies matters considerably.

- Trying to keep track of the preempted LWP was a bad idea; go back
  to searching for now.

- Send a PREEMPTED upcall from proc_unstop(), so that stopped processes
  know that something happened, and so that all runnable LWPs of a unstopped
  process have an upcall to deliver (Ideally, the LWP that was runnable
  when the process was stopped should return first, and any LWPs that were
  woken up while the process was stopped would interrupt it, but that's
  difficult to arrange).

Revision 1.54.2.11 / (download) - annotate - [select for diffs], Thu Feb 28 04:14:45 2002 UTC (20 years, 11 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.10: +35 -16 lines
Diff to previous 1.54.2.10 (colored) to branchpoint 1.54 (colored)

Catch up to -current.

Revision 1.54.2.10 / (download) - annotate - [select for diffs], Tue Feb 19 23:25:10 2002 UTC (20 years, 11 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.9: +15 -7 lines
Diff to previous 1.54.2.9 (colored) to branchpoint 1.54 (colored)

When making a timer-expiration upcall, copy out a siginfo_t, not a struct
sigevent.

Revision 1.55.2.2 / (download) - annotate - [select for diffs], Mon Feb 11 20:10:24 2002 UTC (20 years, 11 months ago) by jdolecek
Branch: kqueue
Changes since 1.55.2.1: +35 -16 lines
Diff to previous 1.55.2.1 (colored) to branchpoint 1.55 (colored) next main 1.56 (colored)

Sync w/ -current.

Revision 1.54.2.9 / (download) - annotate - [select for diffs], Mon Feb 4 23:51:00 2002 UTC (21 years ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.8: +5 -3 lines
Diff to previous 1.54.2.8 (colored) to branchpoint 1.54 (colored)

Get the scheduler lock around SA cache manipulation and setrunnable()(!).

Revision 1.54.2.8 / (download) - annotate - [select for diffs], Sat Feb 2 00:04:33 2002 UTC (21 years ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.7: +29 -4 lines
Diff to previous 1.54.2.7 (colored) to branchpoint 1.54 (colored)

Create a new activation to handle a timer expiration if nothing is running.

Revision 1.61 / (download) - annotate - [select for diffs], Thu Jan 31 00:13:08 2002 UTC (21 years ago) by simonb
Branch: MAIN
CVS Tags: newlock-base, newlock, netbsd-1-6-base, netbsd-1-6-RELEASE, netbsd-1-6-RC3, netbsd-1-6-RC2, netbsd-1-6-RC1, netbsd-1-6-PATCH002-RELEASE, netbsd-1-6-PATCH002-RC4, netbsd-1-6-PATCH002-RC3, netbsd-1-6-PATCH002-RC2, netbsd-1-6-PATCH002-RC1, netbsd-1-6-PATCH002, netbsd-1-6-PATCH001-RELEASE, netbsd-1-6-PATCH001-RC3, netbsd-1-6-PATCH001-RC2, netbsd-1-6-PATCH001-RC1, netbsd-1-6-PATCH001, kqueue-base, ifpoll-base, gehenna-devsw-base, gehenna-devsw, eeh-devprop-base, eeh-devprop
Branch point for: netbsd-1-6
Changes since 1.60: +35 -16 lines
Diff to previous 1.60 (colored)

Implement the CLOCK_MONOTONIC clock for the posix/opengroup realtime
clock_() functions.  This simply returns the kernel mono_time variable.
As discussed on tech-kern.

Revision 1.54.2.7 / (download) - annotate - [select for diffs], Mon Jan 28 18:02:53 2002 UTC (21 years ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.6: +4 -6 lines
Diff to previous 1.54.2.6 (colored) to branchpoint 1.54 (colored)

Don't refuse a SIGEV_SA sigevent registration for timer_create() for a
process that doesn't have P_SA set; it may be setting up the timer
before enabling SA's. Instead, check for P_SA before invoking the
upcall in realtimerexpire().

Revision 1.55.2.1 / (download) - annotate - [select for diffs], Thu Jan 10 19:59:57 2002 UTC (21 years, 1 month ago) by thorpej
Branch: kqueue
Changes since 1.55: +81 -35 lines
Diff to previous 1.55 (colored)

Sync kqueue branch with -current.

Revision 1.54.2.6 / (download) - annotate - [select for diffs], Tue Jan 8 00:32:35 2002 UTC (21 years, 1 month ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.5: +52 -46 lines
Diff to previous 1.54.2.5 (colored) to branchpoint 1.54 (colored)

Catch up to -current.

Revision 1.60 / (download) - annotate - [select for diffs], Sun Dec 9 16:10:43 2001 UTC (21 years, 2 months ago) by manu
Branch: MAIN
Changes since 1.59: +48 -50 lines
Diff to previous 1.59 (colored)

Changed clocktl interface to use syscallargs structures

Revision 1.54.2.5 / (download) - annotate - [select for diffs], Sat Nov 17 01:13:51 2001 UTC (21 years, 2 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.4: +434 -141 lines
Diff to previous 1.54.2.4 (colored) to branchpoint 1.54 (colored)

Implement POSIX realtime timers, and reimplement getitimer() and setitimer()
in terms of them.

Revision 1.54.2.4 / (download) - annotate - [select for diffs], Wed Nov 14 19:16:39 2001 UTC (21 years, 2 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.3: +6 -4 lines
Diff to previous 1.54.2.3 (colored) to branchpoint 1.54 (colored)

Catch up to -current.

Revision 1.59 / (download) - annotate - [select for diffs], Tue Nov 13 00:34:21 2001 UTC (21 years, 2 months ago) by christos
Branch: MAIN
Changes since 1.58: +4 -5 lines
Diff to previous 1.58 (colored)

PR/8657: z@rentaboat.se: alarm takes more seconds that it can handle.

This is a followup to PR/14558.

    - itimerfix(9) limited the number of seconds to 100M, before I changed
      it to 1000M for PR/14558.
    - nanosleep(2) documents a limit of 1000M seconds.
    - setitimer(2), select(2), and other library functions that indirectly
      use setitimer(2) for example alarm(3) don't specify a limit.

So it only seems appropriate that any positive number of seconds in
struct timeval should be accepted by any code that uses itimerfix(9)
directly, except nanosleep(2) which should check for 1000M seconds
manually. This changes makes the manual pages of select(2), nanosleep(2),
setitimer(2), and alarm(3) consistent with the code.

Revision 1.56.2.1 / (download) - annotate - [select for diffs], Mon Nov 12 21:18:51 2001 UTC (21 years, 2 months ago) by thorpej
Branch: thorpej-mips-cache
Changes since 1.56: +5 -2 lines
Diff to previous 1.56 (colored) next main 1.57 (colored)

Sync the thorpej-mips-cache branch with -current.

Revision 1.58 / (download) - annotate - [select for diffs], Mon Nov 12 15:25:18 2001 UTC (21 years, 2 months ago) by lukem
Branch: MAIN
CVS Tags: thorpej-mips-cache-base
Changes since 1.57: +4 -1 lines
Diff to previous 1.57 (colored)

add RCSIDs

Revision 1.57 / (download) - annotate - [select for diffs], Mon Nov 12 14:52:33 2001 UTC (21 years, 2 months ago) by christos
Branch: MAIN
Changes since 1.56: +2 -2 lines
Diff to previous 1.56 (colored)

PR/14558: Tero Kivinen: There is no point in limiting the number of seconds
to 100 million. Use 1000 million like the man page for nanosleep suggests.
This is much closer to MAXINT, and it conforms to POSIX.

Revision 1.55.4.1 / (download) - annotate - [select for diffs], Mon Oct 1 12:46:54 2001 UTC (21 years, 4 months ago) by fvdl
Branch: thorpej-devvp
Changes since 1.55: +74 -28 lines
Diff to previous 1.55 (colored) next main 1.56 (colored)

Catch up with -current.

Revision 1.54.2.3 / (download) - annotate - [select for diffs], Fri Sep 21 22:36:26 2001 UTC (21 years, 4 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.2: +74 -28 lines
Diff to previous 1.54.2.2 (colored) to branchpoint 1.54 (colored)

Catch up to -current.

Revision 1.56 / (download) - annotate - [select for diffs], Sun Sep 16 06:50:06 2001 UTC (21 years, 4 months ago) by manu
Branch: MAIN
CVS Tags: thorpej-devvp-base3, thorpej-devvp-base2
Branch point for: thorpej-mips-cache
Changes since 1.55: +74 -28 lines
Diff to previous 1.55 (colored)

Split root-only time-related system calls so that we have an upper part, that
checks root privs, and a lower part that does the actual job. The lower part
will be called by the upcoming clockctl driver. Approved by Christos
Also fixed a few cosmetic things

Revision 1.54.2.2 / (download) - annotate - [select for diffs], Thu Jun 21 20:06:57 2001 UTC (21 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54.2.1: +7 -3 lines
Diff to previous 1.54.2.1 (colored) to branchpoint 1.54 (colored)

Catch up to -current.

Revision 1.47.2.3 / (download) - annotate - [select for diffs], Mon Jun 11 19:31:16 2001 UTC (21 years, 8 months ago) by he
Branch: netbsd-1-5
CVS Tags: netbsd-1-5-PATCH003, netbsd-1-5-PATCH002, netbsd-1-5-PATCH001
Changes since 1.47.2.2: +7 -3 lines
Diff to previous 1.47.2.2 (colored) to branchpoint 1.47 (colored) next main 1.48 (colored)

Pull up revision 1.55 (requested by tron):
  Lower interrupt priority properly in the error path of settime(),
  e.g. when it's denied due to securelevel being above 1.  Fixes
  PR#13158.

Revision 1.55 / (download) - annotate - [select for diffs], Mon Jun 11 07:07:12 2001 UTC (21 years, 8 months ago) by tron
Branch: MAIN
CVS Tags: thorpej-devvp-base, pre-chs-ubcperf, post-chs-ubcperf
Branch point for: thorpej-devvp, kqueue
Changes since 1.54: +7 -3 lines
Diff to previous 1.54 (colored)

Lower interrupt priortiy properly if setting the setting the kernel time
is denied in a securelevel above 1. This fixes PR kern/13158.

Revision 1.54.2.1 / (download) - annotate - [select for diffs], Mon Mar 5 22:49:43 2001 UTC (21 years, 11 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.54: +26 -20 lines
Diff to previous 1.54 (colored)

Initial commit of scheduler activations and lightweight process support.

Revision 1.41.2.1 / (download) - annotate - [select for diffs], Mon Nov 20 18:09:05 2000 UTC (22 years, 2 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.41: +162 -21 lines
Diff to previous 1.41 (colored) next main 1.42 (colored)

Update thorpej_scsipi to -current as of a month ago

Revision 1.54 / (download) - annotate - [select for diffs], Tue Sep 19 23:26:25 2000 UTC (22 years, 4 months ago) by bjh21
Branch: MAIN
CVS Tags: thorpej_scsipi_nbase, thorpej_scsipi_beforemerge, thorpej_scsipi_base
Branch point for: nathanw_sa
Changes since 1.53: +3 -2 lines
Diff to previous 1.53 (colored)

Extend NFS_V2_ONLY to remove NQNFS lease support as well.  Saves another 10k.

Revision 1.47.2.2 / (download) - annotate - [select for diffs], Wed Aug 16 01:20:31 2000 UTC (22 years, 5 months ago) by itojun
Branch: netbsd-1-5
CVS Tags: netbsd-1-5-RELEASE, netbsd-1-5-BETA2, netbsd-1-5-BETA
Changes since 1.47.2.1: +62 -4 lines
Diff to previous 1.47.2.1 (colored) to branchpoint 1.47 (colored)

pullup (approved by releng-1-5)

add ppsratecheck(9).

distrib/sets/lists/comp/mi      1.251 -> 1.252
share/man/man9/Makefile         1.67 -> 1.68 (equivalent to)
share/man/man9/ppsratecheck.9   (new)
sys/kern/kern_time.c            1.49 -> 1.51, 1.52 -> 1.53
sys/sys/time.h                  1.29 -> 1.30

Revision 1.53 / (download) - annotate - [select for diffs], Wed Aug 2 12:24:11 2000 UTC (22 years, 6 months ago) by itojun
Branch: MAIN
Changes since 1.52: +4 -2 lines
Diff to previous 1.52 (colored)

allow admins to disable pps rate limitation, by setting "maxpps"
parameter to negative value.

Revision 1.47.2.1 / (download) - annotate - [select for diffs], Thu Jul 13 20:18:12 2000 UTC (22 years, 6 months ago) by thorpej
Branch: netbsd-1-5
CVS Tags: netbsd-1-5-ALPHA2
Changes since 1.47: +9 -1 lines
Diff to previous 1.47 (colored)

Pull up rev. 1.52:
Add a comment about the hzto() return value.

Revision 1.52 / (download) - annotate - [select for diffs], Thu Jul 13 17:33:39 2000 UTC (22 years, 6 months ago) by thorpej
Branch: MAIN
Changes since 1.51: +9 -1 lines
Diff to previous 1.51 (colored)

Add a comment about the hzto() return value.

Revision 1.51 / (download) - annotate - [select for diffs], Sun Jul 9 14:13:04 2000 UTC (22 years, 7 months ago) by jhawk
Branch: MAIN
Changes since 1.50: +3 -3 lines
Diff to previous 1.50 (colored)

Comment police. s/DIAGNOSTICS/DIAGNOSTIC/

Revision 1.50 / (download) - annotate - [select for diffs], Sun Jul 9 06:44:59 2000 UTC (22 years, 7 months ago) by itojun
Branch: MAIN
Changes since 1.49: +55 -1 lines
Diff to previous 1.49 (colored)

add ppsratelimit(9), which does event-per-sec rate limitation.
use it from icmp6 error rate limitation code.
XXX better name for the function?

Revision 1.49 / (download) - annotate - [select for diffs], Sun Jul 9 06:40:08 2000 UTC (22 years, 7 months ago) by itojun
Branch: MAIN
Changes since 1.48: +7 -5 lines
Diff to previous 1.48 (colored)

shorten splclock() period in ratelimit().
From: onoe

Revision 1.48 / (download) - annotate - [select for diffs], Tue Jun 27 17:41:31 2000 UTC (22 years, 7 months ago) by mrg
Branch: MAIN
Changes since 1.47: +1 -2 lines
Diff to previous 1.47 (colored)

remove include of <vm/vm.h>

Revision 1.46.2.1 / (download) - annotate - [select for diffs], Thu Jun 22 17:09:12 2000 UTC (22 years, 7 months ago) by minoura
Branch: minoura-xpg4dl
Changes since 1.46: +11 -3 lines
Diff to previous 1.46 (colored) next main 1.47 (colored)

Sync w/ netbsd-1-5-base.

Revision 1.47 / (download) - annotate - [select for diffs], Wed May 31 05:02:34 2000 UTC (22 years, 8 months ago) by thorpej
Branch: MAIN
CVS Tags: netbsd-1-5-base
Branch point for: netbsd-1-5
Changes since 1.46: +11 -3 lines
Diff to previous 1.46 (colored)

Track which process a CPU is running/has last run on by adding a
p_cpu member to struct proc.  Use this in certain places when
accessing scheduler state, etc.  For the single-processor case,
just initialize p_cpu in fork1() to avoid having to set it in the
low-level context switch code on platforms which will never have
multiprocessing.

While I'm here, comment a few places where there are known issues
for the SMP implementation.

Revision 1.46 / (download) - annotate - [select for diffs], Fri May 26 21:20:32 2000 UTC (22 years, 8 months ago) by thorpej
Branch: MAIN
CVS Tags: minoura-xpg4dl-base
Branch point for: minoura-xpg4dl
Changes since 1.45: +3 -2 lines
Diff to previous 1.45 (colored)

First sweep at scheduler state cleanup.  Collect MI scheduler
state into global and per-CPU scheduler state:

	- Global state: sched_qs (run queues), sched_whichqs (bitmap
	  of non-empty run queues), sched_slpque (sleep queues).
	  NOTE: These may collectively move into a struct schedstate
	  at some point in the future.

	- Per-CPU state, struct schedstate_percpu: spc_runtime
	  (time process on this CPU started running), spc_flags
	  (replaces struct proc's p_schedflags), and
	  spc_curpriority (usrpri of processes on this CPU).

	- Every platform must now supply a struct cpu_info and
	  a curcpu() macro.  Simplify existing cpu_info declarations
	  where appropriate.

	- All references to per-CPU scheduler state now made through
	  curcpu().  NOTE: this will likely be adjusted in the future
	  after further changes to struct proc are made.

Tested on i386 and Alpha.  Changes are mostly mechanical, but apologies
in advance if it doesn't compile on a particular platform.

Revision 1.45 / (download) - annotate - [select for diffs], Thu Mar 30 09:27:12 2000 UTC (22 years, 10 months ago) by augustss
Branch: MAIN
Changes since 1.44: +14 -14 lines
Diff to previous 1.44 (colored)

Get rid of register declarations.

Revision 1.44 / (download) - annotate - [select for diffs], Thu Mar 23 06:30:12 2000 UTC (22 years, 10 months ago) by thorpej
Branch: MAIN
Changes since 1.43: +6 -5 lines
Diff to previous 1.43 (colored)

New callout mechanism with two major improvements over the old
timeout()/untimeout() API:
- Clients supply callout handle storage, thus eliminating problems of
  resource allocation.
- Insertion and removal of callouts is constant time, important as
  this facility is used quite a lot in the kernel.

The old timeout()/untimeout() API has been removed from the kernel.

Revision 1.36.6.3 / (download) - annotate - [select for diffs], Fri Feb 18 20:25:34 2000 UTC (22 years, 11 months ago) by he
Branch: netbsd-1-4
CVS Tags: netbsd-1-4-PATCH003, netbsd-1-4-PATCH002
Changes since 1.36.6.2: +66 -1 lines
Diff to previous 1.36.6.2 (colored) to branchpoint 1.36 (colored) next main 1.37 (colored)

Pull up revisions 1.42-1.43 (requested by thorpej):
  Implement ratecheck(), a function which can help kernel programmers
  implement rate-limited actions.

Revision 1.43 / (download) - annotate - [select for diffs], Wed Feb 16 12:36:19 2000 UTC (22 years, 11 months ago) by itojun
Branch: MAIN
Changes since 1.42: +2 -2 lines
Diff to previous 1.42 (colored)

correct ratecheck() signedness.  without this fix, ratecheck() will never
success again after first success with lasttime=(0,0).

Revision 1.42 / (download) - annotate - [select for diffs], Thu Feb 3 23:04:46 2000 UTC (23 years ago) by cgd
Branch: MAIN
CVS Tags: chs-ubc2-newbase
Changes since 1.41: +66 -1 lines
Diff to previous 1.41 (colored)

Implement ratecheck(), a function which can help programmers implement
rate-limited actions.  See ratecheck(9) for details of its use.

Revision 1.40.2.1 / (download) - annotate - [select for diffs], Mon Dec 27 18:35:52 1999 UTC (23 years, 1 month ago) by wrstuden
Branch: wrstuden-devbsize
Changes since 1.40: +2 -2 lines
Diff to previous 1.40 (colored) next main 1.41 (colored)

Pull up to last week's -current.

Revision 1.36.10.1 / (download) - annotate - [select for diffs], Tue Nov 30 13:34:43 1999 UTC (23 years, 2 months ago) by itojun
Branch: kame
CVS Tags: kame_141_19991130
Changes since 1.36: +8 -1 lines
Diff to previous 1.36 (colored) next main 1.37 (colored)

bring in latest KAME (as of 19991130, KAME/NetBSD141) into kame branch
just for reference purposes.
This commit includes 1.4 -> 1.4.1 sync for kame branch.

The branch does not compile at all (due to the lack of ALTQ and some other
source code).  Please do not try to modify the branch, this is just for
referenre purposes.

synchronization to latest KAME will take place on HEAD branch soon.

Revision 1.36.6.2 / (download) - annotate - [select for diffs], Wed Oct 20 23:48:33 1999 UTC (23 years, 3 months ago) by he
Branch: netbsd-1-4
Changes since 1.36.6.1: +2 -2 lines
Diff to previous 1.36.6.1 (colored) to branchpoint 1.36 (colored)

Pull up revision 1.41 (requested by hwr):
  If time delta is larger than thresh, use 10* adjustment factor.
  Make this work for negative deltas too.  Fixes PR#8589.

Revision 1.41 / (download) - annotate - [select for diffs], Sun Oct 10 18:41:53 1999 UTC (23 years, 4 months ago) by hwr
Branch: MAIN
CVS Tags: wrstuden-devbsize-base, wrstuden-devbsize-19991221, fvdl-softdep-base, fvdl-softdep, comdex-fall-1999-base, comdex-fall-1999
Branch point for: thorpej_scsipi
Changes since 1.40: +2 -2 lines
Diff to previous 1.40 (colored)

If time delta is larger than thresh. Use 10* adj factor. Make this
work for negative deltas too. From NAKAJIMA Yoshihiro <nakayosh@kcn.ne.jp>
in kern/8589.

Revision 1.40 / (download) - annotate - [select for diffs], Mon Aug 16 18:53:55 1999 UTC (23 years, 5 months ago) by tron
Branch: MAIN
Branch point for: wrstuden-devbsize
Changes since 1.39: +1 -3 lines
Diff to previous 1.39 (colored)

Remove the prototype for settime(), it is in "sys/time.h" now.

Revision 1.39 / (download) - annotate - [select for diffs], Mon Aug 16 18:42:25 1999 UTC (23 years, 5 months ago) by tron
Branch: MAIN
Changes since 1.38: +3 -3 lines
Diff to previous 1.38 (colored)

Make settime() public because we need to use it for the Linux emulation.

Revision 1.38 / (download) - annotate - [select for diffs], Thu Aug 5 18:08:15 1999 UTC (23 years, 6 months ago) by thorpej
Branch: MAIN
Changes since 1.37: +2 -2 lines
Diff to previous 1.37 (colored)

Change the semantics of splsoftclock() to be like other spl*() functions,
that is priority is rasied.  Add a new spllowersoftclock() to provide the
atomic drop-to-softclock semantics that the old splsoftclock() provided,
and update calls accordingly.

This fixes a problem with using the "rnd" pseudo-device from within
interrupt context to extract random data (e.g. from within the softnet
interrupt) where doing so would incorrectly unblock interrupts (causing
all sorts of lossage).

XXX 4 platforms do not have priority-raising capability: newsmips, sparc,
XXX sparc64, and VAX.  This platforms still have this bug until their
XXX spl*() functions are fixed.

Revision 1.36.8.1 / (download) - annotate - [select for diffs], Mon Jun 21 01:24:03 1999 UTC (23 years, 7 months ago) by thorpej
Branch: chs-ubc2
Changes since 1.36: +8 -1 lines
Diff to previous 1.36 (colored) next main 1.37 (colored)

Sync w/ -current.

Revision 1.36.6.1 / (download) - annotate - [select for diffs], Fri Jun 18 17:12:28 1999 UTC (23 years, 7 months ago) by perry
Branch: netbsd-1-4
CVS Tags: netbsd-1-4-PATCH001
Changes since 1.36: +8 -1 lines
Diff to previous 1.36 (colored)

pullup 1.36->1.37 (thorpej): Make sure "olddelta" is a valid pointer

Revision 1.37 / (download) - annotate - [select for diffs], Mon Jun 7 22:33:53 1999 UTC (23 years, 8 months ago) by thorpej
Branch: MAIN
CVS Tags: chs-ubc2-base
Changes since 1.36: +8 -1 lines
Diff to previous 1.36 (colored)

Make sure `olddelta' is a valid pointer before performing the guts of
the adjtime(2) system call.  Fixes PR #7721, Darren Reed.

Revision 1.36 / (download) - annotate - [select for diffs], Tue Aug 18 06:27:01 1998 UTC (24 years, 5 months ago) by thorpej
Branch: MAIN
CVS Tags: netbsd-1-4-base, netbsd-1-4-RELEASE, kenh-if-detach-base, kenh-if-detach, kame_14_19990705, kame_14_19990628, chs-ubc-base, chs-ubc
Branch point for: netbsd-1-4, kame, chs-ubc2
Changes since 1.35: +3 -2 lines
Diff to previous 1.35 (colored)

Add some braces to make egcs happy (ambiguous else warning).

Revision 1.34.2.1 / (download) - annotate - [select for diffs], Sat Aug 8 03:06:56 1998 UTC (24 years, 6 months ago) by eeh
Branch: eeh-paddr_t
Changes since 1.34: +5 -5 lines
Diff to previous 1.34 (colored) next main 1.35 (colored)

Revert cdevsw mmap routines to return int.

Revision 1.35 / (download) - annotate - [select for diffs], Fri Jul 31 22:50:51 1998 UTC (24 years, 6 months ago) by perry
Branch: MAIN
Changes since 1.34: +5 -5 lines
Diff to previous 1.34 (colored)

fix sizeofs so they comply with the KNF style guide. yes, it is pedantic.

Revision 1.34 / (download) - annotate - [select for diffs], Thu Jun 25 22:17:37 1998 UTC (24 years, 7 months ago) by thorpej
Branch: MAIN
CVS Tags: eeh-paddr_t-base
Branch point for: eeh-paddr_t
Changes since 1.33: +2 -1 lines
Diff to previous 1.33 (colored)

defopt NFSSERVER

Revision 1.33 / (download) - annotate - [select for diffs], Sun Mar 1 02:22:31 1998 UTC (24 years, 11 months ago) by fvdl
Branch: MAIN
Changes since 1.32: +2 -2 lines
Diff to previous 1.32 (colored)

Merge with Lite2 + local changes

Revision 1.1.1.3 / (download) - annotate - [select for diffs] (vendor branch), Sun Mar 1 02:13:00 1998 UTC (24 years, 11 months ago) by fvdl
Branch: WFJ-920714, CSRG
CVS Tags: lite-2
Changes since 1.1.1.2: +73 -56 lines
Diff to previous 1.1.1.2 (colored)

Import 4.4BSD-Lite2

Revision 1.1.1.2 / (download) - annotate - [select for diffs] (vendor branch), Sun Mar 1 02:09:43 1998 UTC (24 years, 11 months ago) by fvdl
Branch: WFJ-920714, CSRG
CVS Tags: lite-1, date-03-may-96
Changes since 1.1.1.1: +99 -60 lines
Diff to previous 1.1.1.1 (colored)

Import 4.4BSD-Lite for reference

Revision 1.32 / (download) - annotate - [select for diffs], Fri Feb 20 07:22:14 1998 UTC (24 years, 11 months ago) by mycroft
Branch: MAIN
Changes since 1.31: +4 -4 lines
Diff to previous 1.31 (colored)

Fix missing newline in time zone warning.

Revision 1.31 / (download) - annotate - [select for diffs], Thu Feb 19 00:51:38 1998 UTC (24 years, 11 months ago) by thorpej
Branch: MAIN
Changes since 1.30: +3 -1 lines
Diff to previous 1.30 (colored)

Include the NFS option header.

Revision 1.30 / (download) - annotate - [select for diffs], Wed Oct 15 17:04:08 1997 UTC (25 years, 3 months ago) by mycroft
Branch: MAIN
CVS Tags: netbsd-1-3-base, netbsd-1-3-RELEASE, netbsd-1-3-PATCH003-CANDIDATE2, netbsd-1-3-PATCH003-CANDIDATE1, netbsd-1-3-PATCH003-CANDIDATE0, netbsd-1-3-PATCH003, netbsd-1-3-PATCH002, netbsd-1-3-PATCH001, netbsd-1-3-BETA, netbsd-1-3
Changes since 1.29: +12 -10 lines
Diff to previous 1.29 (colored)

Adjust u_int arguments of some system calls to int, to match user-level
prototypes.

Revision 1.29 / (download) - annotate - [select for diffs], Sat Apr 26 21:22:57 1997 UTC (25 years, 9 months ago) by tls
Branch: MAIN
CVS Tags: thorpej-signal-base, thorpej-signal, marc-pcmcia-bp, marc-pcmcia-base, marc-pcmcia, bouyer-scsipi
Changes since 1.28: +14 -5 lines
Diff to previous 1.28 (colored)

Don't allow the time to be set backwards if in highly secure mode, since this would allow inode change times to be manipulated.

Revision 1.28 / (download) - annotate - [select for diffs], Mon Apr 21 16:56:54 1997 UTC (25 years, 9 months ago) by jtc
Branch: MAIN
Changes since 1.27: +6 -2 lines
Diff to previous 1.27 (colored)

In nanosleep, use local error variable when storing rqtp in so that
an error from a failed tsleep will still be returned to the caller.

Revision 1.27 / (download) - annotate - [select for diffs], Wed Apr 16 14:41:29 1997 UTC (25 years, 9 months ago) by jtc
Branch: MAIN
Changes since 1.26: +59 -2 lines
Diff to previous 1.26 (colored)

Add POSIX.1b nanosleep().

Revision 1.26 / (download) - annotate - [select for diffs], Fri Jan 31 02:34:23 1997 UTC (26 years ago) by thorpej
Branch: MAIN
CVS Tags: mrg-vm-swap, is-newarp-before-merge, is-newarp-base, is-newarp
Changes since 1.25: +3 -3 lines
Diff to previous 1.25 (colored)

NFSCLIENT -> NFS

Revision 1.20.4.1 / (download) - annotate - [select for diffs], Sun Jan 26 02:11:52 1997 UTC (26 years ago) by rat
Branch: netbsd-1-2
CVS Tags: netbsd-1-2-PATCH001
Changes since 1.20: +8 -4 lines
Diff to previous 1.20 (colored) next main 1.21 (colored)

Pullup 1.20 -> 1.21 (code clarification)

Revision 1.24.2.2 / (download) - annotate - [select for diffs], Sat Jan 18 04:31:43 1997 UTC (26 years ago) by thorpej
Branch: thorpej-setroot
Changes since 1.24.2.1: +19 -4 lines
Diff to previous 1.24.2.1 (colored) next main 1.25 (colored)

Update from trunk.

Revision 1.25 / (download) - annotate - [select for diffs], Wed Jan 15 01:37:53 1997 UTC (26 years ago) by perry
Branch: MAIN
Changes since 1.24: +19 -4 lines
Diff to previous 1.24 (colored)

Eliminate obsolete TIMEZONE and DST options.
Eliminate obsolete global kernel variable "struct timezone tz"
Add RTC_OFFSET option
Add global kernel variable rtc_offset, which is initialized by
RTC_OFFSET at kernel compile time.
on i386, x68k, mac68k, pc532 and arm32, RTC_OFFSET indicates how many
minutes west (east) of GMT the hardware RTC runs. Defaults to 0.
Places where tz variable was used to indicate this in the past have
been replaced with rtc_offset.
Add sysctl interface to rtc_offset.
Kill obsolete DST_* macros in sys/time.h
gettimeofday now always returns zeroed timezone if zone is requested.
settimeofday now ignores and logs attempts to set non-existant kernel
timezone.

Revision 1.24.2.1 / (download) - annotate - [select for diffs], Tue Jan 14 21:27:06 1997 UTC (26 years ago) by thorpej
Branch: thorpej-setroot
Changes since 1.24: +3 -3 lines
Diff to previous 1.24 (colored)

Snapshot of work-in-progress, committed to private branch.

These changes implement machine-independent root device and file system
selection.  Notable features:

	- All ports behave in a consistent manner regarding root
	  device selection.
	- No more "options GENERIC"; all kernels have the ability
	  to boot with RB_ASKNAME to select root device and file system
	  type.
	- Root file system type can be wildcarded; a machine-independent
	  function will try all possible file systems for the selected
	  root device until one succeeds.
	- If the root file system fails to mount, the operator will
	  be given the chance to select a new root device and file
	  system type, rather than having the machine simply panic.
	- nfs_mountroot() no longer panics if any part of the NFS
	  mount process fails; it now returns an error, giving the
	  operator a chance to recover.
	- New, more consistent, config(8) grammar.  The constructs:

		config netbsd swap generic
		config netbsd root on nfs

	  have been replaced with:

		config netbsd root on ? type ?
		config netbsd root on ? type nfs

	  Additionally, the operator may select or wildcard root file
	  system type in the kernel configuration file:

		config netbsd root on cd0a type cd9660

	  config(8) now requires that a "root" specification be
	  made.  "root" may be wired down or wildcarded.  "swap" and
	  "dump" specifications are optional, and follow previous
	  semantics.

	- config(8) has a new "file-system" keyword, used to configure
	  file systems into the kernel.  Eventually, this will be used
	  to generate the default vfssw[].

	- "options NFSCLIENT" is obsolete, and is replaced by
	  "file-system NFS".  "options NFSSERVER" still exists, since
	  NFS server support is independent of the NFS file system
	  client.

	- sys/arch/<foo>/<foo>/swapgeneric.c is no longer used, and
	  will be removed; all information is now generated by config(8).

As of this commit, all ports except arm32 have been updated to use
the new setroot().  Only SPARC, i386, and Alpha ports have been
tested at this time.  Port masters should test these changes on their
ports, and report any problems back to me.

More changes are on their way, including RB_ASKNAME support in
nfs_mountroot() (to prompt for server address and path) and, potentially,
the ability to select rarp/bootparam or bootp in nfs_mountroot().

Revision 1.24 / (download) - annotate - [select for diffs], Sun Dec 22 10:21:11 1996 UTC (26 years, 1 month ago) by cgd
Branch: MAIN
Branch point for: thorpej-setroot
Changes since 1.23: +19 -26 lines
Diff to previous 1.23 (colored)

* catch up with system call argument type fixups/const poisoning.
* Fix arguments to various copyin()/copyout() invocations, to avoid
  gratuitous casts.
* Some KNF formatting fixes

Revision 1.23 / (download) - annotate - [select for diffs], Fri Nov 15 23:53:32 1996 UTC (26 years, 2 months ago) by cgd
Branch: MAIN
Changes since 1.22: +15 -12 lines
Diff to previous 1.22 (colored)

clean up a few spaces vs. tabs and KNF bogons.  Make this compile
cleanly with -Wall -Wstrict-prototypes -Wmissing-prototypes -Wcast-qual.

Revision 1.22 / (download) - annotate - [select for diffs], Fri Nov 15 22:44:26 1996 UTC (26 years, 2 months ago) by jtc
Branch: MAIN
Changes since 1.21: +115 -17 lines
Diff to previous 1.21 (colored)

Add clock_gettime, clock_settime, and clock_getres

Revision 1.21 / (download) - annotate - [select for diffs], Thu Oct 24 04:35:33 1996 UTC (26 years, 3 months ago) by cgd
Branch: MAIN
Changes since 1.20: +8 -4 lines
Diff to previous 1.20 (colored)

replace a construction in sys_setitimer() that was too tricky for its
(and my!) own good with a more straightforward one that is equally (and
more apparently) correct.

Revision 1.20 / (download) - annotate - [select for diffs], Sun Feb 18 11:57:06 1996 UTC (26 years, 11 months ago) by fvdl
Branch: MAIN
CVS Tags: netbsd-1-2-base, netbsd-1-2-RELEASE, netbsd-1-2-BETA
Branch point for: netbsd-1-2
Changes since 1.19: +4 -2 lines
Diff to previous 1.19 (colored)

Changes for NVSv3 code: pull in more NFS include files into kern_time.c
to get types right (overkill for just one function call, but oh well).
Clear B_NEEDCOMMIT in bdwrite().

Revision 1.19 / (download) - annotate - [select for diffs], Tue Feb 13 21:10:43 1996 UTC (26 years, 11 months ago) by christos
Branch: MAIN
Changes since 1.18: +5 -1 lines
Diff to previous 1.18 (colored)

uipc_proto.c: No need for the forward decls anymore; everything is prototyped.
kern_time.c: add header to get the NFS prototypes if needed.

Revision 1.18 / (download) - annotate - [select for diffs], Fri Feb 9 18:59:53 1996 UTC (27 years ago) by christos
Branch: MAIN
Changes since 1.17: +1 -3 lines
Diff to previous 1.17 (colored)

More proto fixes

Revision 1.17 / (download) - annotate - [select for diffs], Sun Feb 4 02:16:26 1996 UTC (27 years ago) by christos
Branch: MAIN
Changes since 1.16: +14 -8 lines
Diff to previous 1.16 (colored)

First pass at prototyping

Revision 1.16 / (download) - annotate - [select for diffs], Sat Oct 7 06:28:28 1995 UTC (27 years, 4 months ago) by mycroft
Branch: MAIN
CVS Tags: netbsd-1-1-base, netbsd-1-1-RELEASE, netbsd-1-1-PATCH001, netbsd-1-1
Changes since 1.15: +12 -12 lines
Diff to previous 1.15 (colored)

Prefix names of system call implementation functions with `sys_'.

Revision 1.15 / (download) - annotate - [select for diffs], Tue Sep 19 21:45:09 1995 UTC (27 years, 4 months ago) by thorpej
Branch: MAIN
Changes since 1.14: +26 -21 lines
Diff to previous 1.14 (colored)

Make system calls conform to a standard prototype and bring those
prototypes into scope.

Revision 1.14 / (download) - annotate - [select for diffs], Tue Mar 21 13:33:41 1995 UTC (27 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.13: +8 -9 lines
Diff to previous 1.13 (colored)

Update to use timer{add,sub}().

Revision 1.13 / (download) - annotate - [select for diffs], Tue Dec 13 22:19:45 1994 UTC (28 years, 2 months ago) by mycroft
Branch: MAIN
Changes since 1.12: +4 -2 lines
Diff to previous 1.12 (colored)

LEASE_UPDATETIME -> lease_updatetime

Revision 1.12 / (download) - annotate - [select for diffs], Sun Dec 11 18:06:10 1994 UTC (28 years, 2 months ago) by mycroft
Branch: MAIN
Changes since 1.11: +9 -55 lines
Diff to previous 1.11 (colored)

Use __timer{add,sub}(), not timeval{add,sub}().  Remove the latter completely.

Revision 1.11 / (download) - annotate - [select for diffs], Thu Oct 20 04:22:59 1994 UTC (28 years, 3 months ago) by cgd
Branch: MAIN
Changes since 1.10: +54 -54 lines
Diff to previous 1.10 (colored)

update for new syscall args description mechanism

Revision 1.10 / (download) - annotate - [select for diffs], Sun Sep 18 21:49:07 1994 UTC (28 years, 4 months ago) by mycroft
Branch: MAIN
Changes since 1.9: +1 -2 lines
Diff to previous 1.9 (colored)

Remove extern of tickadj.

Revision 1.9 / (download) - annotate - [select for diffs], Wed Jun 29 06:32:48 1994 UTC (28 years, 7 months ago) by cgd
Branch: MAIN
CVS Tags: netbsd-1-0-base, netbsd-1-0-RELEASE, netbsd-1-0-PATCH1, netbsd-1-0-PATCH06, netbsd-1-0-PATCH05, netbsd-1-0-PATCH04, netbsd-1-0-PATCH03, netbsd-1-0-PATCH02, netbsd-1-0-PATCH0, netbsd-1-0
Changes since 1.8: +3 -2 lines
Diff to previous 1.8 (colored)

New RCS ID's, take two.  they're more aesthecially pleasant, and use 'NetBSD'

Revision 1.8 / (download) - annotate - [select for diffs], Fri May 20 07:24:51 1994 UTC (28 years, 8 months ago) by cgd
Branch: MAIN
Changes since 1.7: +62 -38 lines
Diff to previous 1.7 (colored)

update to Lite

Revision 1.7 / (download) - annotate - [select for diffs], Thu May 5 09:15:48 1994 UTC (28 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.6: +4 -4 lines
Diff to previous 1.6 (colored)

Remove now-bogus casts.

Revision 1.6 / (download) - annotate - [select for diffs], Thu May 5 05:38:20 1994 UTC (28 years, 9 months ago) by cgd
Branch: MAIN
Changes since 1.5: +11 -9 lines
Diff to previous 1.5 (colored)

lots of changes: prototype migration, move lots of variables, definitions,
and structure elements around.  kill some unnecessary type and macro
definitions.  standardize clock handling.  More changes than you'd want.

Revision 1.5 / (download) - annotate - [select for diffs], Sat Dec 18 04:21:18 1993 UTC (29 years, 1 month ago) by mycroft
Branch: MAIN
Changes since 1.4: +7 -7 lines
Diff to previous 1.4 (colored)

Canonicalize all #includes.

Revision 1.4.4.1 / (download) - annotate - [select for diffs], Sun Nov 14 20:32:14 1993 UTC (29 years, 2 months ago) by mycroft
Branch: magnum
Changes since 1.4: +7 -7 lines
Diff to previous 1.4 (colored) next main 1.5 (colored)

Canonicalize all #includes.

Revision 1.4 / (download) - annotate - [select for diffs], Tue Jul 13 22:13:28 1993 UTC (29 years, 7 months ago) by cgd
Branch: MAIN
CVS Tags: netbsd-0-9-patch-001, netbsd-0-9-base, netbsd-0-9-RELEASE, netbsd-0-9-BETA, netbsd-0-9-ALPHA2, netbsd-0-9-ALPHA, netbsd-0-9, magnum-base
Branch point for: magnum
Changes since 1.3: +32 -21 lines
Diff to previous 1.3 (colored)

break args structs out, into syscallname_args structs, so gcc2 doesn't
whine so much.

Revision 1.3 / (download) - annotate - [select for diffs], Sun Jun 27 06:01:48 1993 UTC (29 years, 7 months ago) by andrew
Branch: MAIN
Changes since 1.2: +16 -4 lines
Diff to previous 1.2 (colored)

ANSIfications - removed all implicit function return types and argument
definitions.  Ensured that all files include "systm.h" to gain access to
general prototypes.  Casts where necessary.

Revision 1.2 / (download) - annotate - [select for diffs], Thu May 20 02:54:44 1993 UTC (29 years, 8 months ago) by cgd
Branch: MAIN
Changes since 1.1: +2 -1 lines
Diff to previous 1.1 (colored)

add $Id$ strings, and clean up file headers where necessary

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Sun Mar 21 09:45:37 1993 UTC (29 years, 10 months ago) by cgd
Branch: WFJ-920714, CSRG
CVS Tags: patchkit-0-2-2, netbsd-alpha-1, netbsd-0-8, WFJ-386bsd-01
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of 386bsd-0.1 sources

Revision 1.1 / (download) - annotate - [select for diffs], Sun Mar 21 09:45:37 1993 UTC (29 years, 10 months ago) by cgd
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>