Commit Graph

2025 Commits

Author SHA1 Message Date
enami 3669884c32 Factor out a common functionality into a subroutine. 2000-02-01 05:28:01 +00:00
danw f77befbc84 #define __HAVE_DEVICE_REGISTER on ports that have it, and check for
that, rather than a list of architecture defines, in config_attach
2000-02-01 04:01:19 +00:00
assar a49e53d3df (sys_open, sys_fhopen): remove declaration of vnops, now in
<sys/file.h>
2000-02-01 01:24:38 +00:00
assar e4b59906e1 (exec_script_makecmds): remove declaration of vnops, now in
<sys/file.h>
2000-02-01 01:23:29 +00:00
christos 3d9c5d0450 Regen 2000-01-31 15:13:24 +00:00
christos 3cbe025990 __semctl13 -> ____semctl13 because this now is not called directly.
The fourth argument to it is a pointer to union semun not union semun,
because passing structs and unions to syscalls cannot be handled portably.
2000-01-31 15:12:30 +00:00
hannken a6ee792cee The decision that `disksort_cylinder' uses to decide if the buffer needs
to go to the inversion list is incomplete. If the cylinders are equal
block numbers must be checked.

This caused lockups if some buffers with the same cylinder were cycling
through the list, as it may happen with softdep enabled.

Fixes PR #9197.
2000-01-28 09:27:38 +00:00
thorpej b58f7c1079 Remove unused global `consintr'. Rob Black, kern/3841. 2000-01-26 07:50:33 +00:00
enami a119cb3677 In the diagnostic check in config_detach, inform the name of parent and
its child who shouldn't be exist.
2000-01-25 13:23:26 +00:00
enami 65c138fea0 - Print a name of root device even if it is a network device.
- If RB_ASKNAME, only dumpdv holds the results asked interactively.
  Examie dumpspec only when !RB_ASKNAME.  This allows us to override
  dumps on none in kernel config file by booting kernel with RB_ASKNAME.
- Slightly rearrange code so that it more matches to comment.
2000-01-25 09:23:59 +00:00
enami 047cc5e94f Cleanup setroot() a bit:
- No longer necessary to use goto, just breaking the loop like other case
  is enough.
- Don't caliculate loop invariant every time.  Just reuse.
2000-01-25 03:42:36 +00:00
fvdl 65e677bd99 Add an exec hook mechanism, where kernel subsystem can register to
execute certain functions when a process does an exec(). Currently
uses a global list. Could possibly be done using a per-process list,
but this needs more thought.
2000-01-25 01:15:14 +00:00
thorpej 5aa64075cc Add a `config_pending' semaphore to block mounting of the root file system
until all device driver discovery threads have had a chance to do their
work.  This in turn blocks initproc's exec of init(8) until root is
mounted and process start times and CWD info has been fixed up.

Addresses kern/9247.
2000-01-24 18:03:19 +00:00
thorpej 6068308fcd In cwdinit(), if there isn't a cdir vnode yet, don't VREF() it. 2000-01-24 17:57:34 +00:00
mycroft 0153fa8a4d Regen. 2000-01-23 01:01:51 +00:00
mycroft db70ed30f4 Use proper varargs format for __semctl13. 2000-01-23 01:01:30 +00:00
thorpej 2ad35b74df After some discussion with Mycroft, change splstatclock() to splclock().
The rule is that you don't get to call scheduler-related functions (e.g.
wakeup()) above the clock interrupt.  Going to statclock unnecessarily
hoses e.g. serial interrupts on the SPARC.
2000-01-22 16:53:50 +00:00
thorpej 2ab34248eb Back out rev 1.36... what was I thinking? Also, update the comment that
led me astray to reflect reality.
2000-01-22 16:32:02 +00:00
thorpej 0ef111e8ee - Implement bowrite() -- perform an asynchronous, ordered write. 2000-01-21 23:22:24 +00:00
thorpej e3d3905ac7 Preserve B_ORDERED. 2000-01-21 23:21:46 +00:00
thorpej 05c6b5a9a0 - Add a B_ORDERED flag to communicate to drivers that an I/O request should
be issued/completed in order; that is, provide a barrier for I/O queues.
- Change the buffer driver queue links to a TAILQ, rather than using
  a home-grown equivalent.  Provide BUFQ_*() macros to manipulate buffer
  queues; these deal with the barrier provided by B_ORDERED.
- Update disksort() accordingly, and provide 3 versions:
	- disksort_cylinder(): historical disksort(), which keys on
	  b_cylinder (and b_blkno for the case when b_cylinder matches).
	- disksort_blkno(): sorts only on b_blkno.  Essentially the
	  same as disksort_cylinder(), but with fewer comparisons.
	- disksort_tail(): requests are simply inserted into the queue
	  at the tail.  This is provided as an option so that drivers
	  can simply have a pointer to the appropriate sort function.
  Note that disksort() now pays attention to B_ORDERED.
2000-01-21 23:20:51 +00:00
thorpej a0397a2573 Move callout initialization to a single location; no need to duplicate
that code all over the place.
2000-01-19 20:05:30 +00:00
cgd ccfb44f360 use the old cloning-device cf_unit increment behaviour, if
__BROKEN_CONFIG_UNIT_USAGE is defined.
2000-01-18 07:45:04 +00:00
matt 2dd872c9b4 defopt COMPAT_VAX1K 2000-01-17 02:59:25 +00:00
assar 70aab8de7d (sysctl_doeproc): make sure we release the proclist_lock even if
copyout fails
2000-01-16 15:07:48 +00:00
thorpej c194b71ab0 Per my comment earlier in the file, we only need to go do splsoftclock()
when write-locking the proclist; splstatclock() is a wee bit overkill.
2000-01-13 21:55:36 +00:00
mrg e7552e93d7 reverse (and fix) the logic of the other change; it cause semi-random alpha SIGABRT for longer command lines 2000-01-05 08:11:31 +00:00
msaitoh da3eeac505 EXEC_COFF cleanup 2000-01-02 13:39:49 +00:00
mycroft 40d251bc94 Update for y2k. 2000-01-01 05:00:03 +00:00
eeh 3bd42b03a7 Make getcwd_common() available to COMPAT_NETBSD32 code as well. 1999-12-30 16:01:34 +00:00
eeh f293acc959 Dump cores for 32-bit processes. 1999-12-30 16:00:23 +00:00
eeh b142754870 Handle args for 32-bit emulation processes properly. 1999-12-30 15:59:26 +00:00
eeh 7aeaf762e5 Move netbsd32_exec BEFORE normal 32-bit exec so 32-bit binaries are not executed
on 64-bit kernels without emulation mode.
1999-12-30 15:57:31 +00:00
cgd 71a030cab6 avoid 'marching unit numbers' for cloning devices. (e.g., previously,
if you com* at pcmcia?, and com3 and com4 as pcmcia cards, and removed
and reinserted the card that was com3, it would become com5.  if you then
removed and reinserted com4, it would become com6.  etc.)  Now, instead
of incrementing FSTATE_STAR configuration entries for a driver when
a cloning instance is attached, leave it alone, and scan the device softc
array (starting at the first cloning unit number) for units which are
available for use.  This wastes a tiny bit of time (can require a linear
scan of the softc table for the device), but device attachment should be
relatively infrequent and the number of units of each type of device
is never particularly large anyway.
1999-12-30 01:03:43 +00:00
thorpej 51fcba3845 Explicitly set secondary processors in motion before calling uvm_scheduler(). 1999-12-16 19:59:17 +00:00
jdolecek f7f3de79e0 g/c redundant vn_isunder() prototype (it.s in <sys/vnode.h>)
minor KNF changes
1999-12-15 08:36:44 +00:00
perseant fa6a733240 In lfs_bwrite, don't mark buffers dirty if lfs is mounted read-only.
(Previously buffers could be marked dirty by the cleaner, and possibly by
other means.)

Also check for softdep mount in vfs_shutdown before trying to bawrite
buffers, since other filesystems don't need it and lfs doesn't bawrite.
(This fragment reviewed by fvdl.)

Partially addresses PR#8964.
1999-12-15 07:10:32 +00:00
itojun ea861f0183 sync IPv6 part with latest KAME tree. IPsec part is left unmodified
due to massive changes in KAME side.
- IPv6 output goes through nd6_output
- faith can capture IPv4 packets as well - you can run IPv4-to-IPv6 translator
  using heavily modified DNS servers
- per-interface statistics (required for IPv6 MIB)
- interface autoconfig is revisited
- udp input handling has a big change for mapped address support.
- introduce in4_cksum() for non-overwriting checksumming
- introduce m_pulldown()
- neighbor discovery cleanups/improvements
- netinet/in.h strictly conforms to RFC2553 (no extra defs visible to userland)
- IFA_STATS is fixed a bit (not tested)
- and more more more.

TODO:
- cleanup os-independency #ifdef
- avoid rcvif dual use (for IPsec) to help ifdetach

(sorry for jumbo commit, I can't separate this any more...)
1999-12-13 15:17:17 +00:00
sommerfeld 8933230897 bitmask_snprintf: avoid returning too soon if we're using the
new-style format.
1999-12-13 01:29:03 +00:00
sommerfeld c3ddfa524d Fix bug observed by Perry and myself: when emacs was shut down
uncleanly due to a lost connection, it would hang in closef() waiting
for the usecount to go back to 1.

An audit of FILE_USE() vs FILE_UNUSE() usage led me to discover some
incorrect error-path code..

In sys_fcntl(), avoid leaking a file descriptor usecount in an error
case of F_SETFL; don't return, instead go to "out" to clean up.  I
suspect that the F_SETFL would fail because vop_fcntl is not
implemented in deadfs.
1999-12-08 18:53:56 +00:00
thorpej 33c520ace6 Regen. 1999-12-07 23:58:27 +00:00
thorpej 0bd5e93b0e Remove duplicate vop_balloc definition accidentally added in rev 1.21. 1999-12-07 23:57:49 +00:00
wrstuden 17afd02c47 Regen. 1999-12-07 21:07:38 +00:00
wrstuden 7cbac78932 Add comments to describe the lookup parameters needed in the various
component name fragments passed into VOP calls.
1999-12-07 21:06:48 +00:00
tron 0f8b4e4579 Revert order of formula to calculate the number of buffer pages if the
BUFCACHE option is defined. With the new formular a few pages less will
be used (22 on a system with 256MB) but we avoid a possible integer
overflow.
1999-12-05 17:12:43 +00:00
tron 8b7af21483 Correct calculation of buffer pages if BUFCACHE is defined. Patch supplied
by kern/8954 by URA Hiroshi.
1999-12-05 15:53:37 +00:00
ragge 184f8b2c39 First round of discarding the CL* macros. 1999-12-03 21:43:19 +00:00
itojun bbb8727584 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.
1999-11-30 13:34:47 +00:00
fvdl 2aea14c604 Clear B_AGE in bdirty(), this buffer must go through the LRU again
to be back on the AGE queue. Otherwise we risk recycling a set
of buffers with (soft) dependencies on the AGE list, which may
last forever if the vnode they belong to is locked (i.e. the syncer
won't get to the buffers they depend on, so their dependencies
are never flushed).
1999-11-26 17:18:15 +00:00
fvdl d901f6eae0 Be more careful to block bio interrupts for some data structures. There
were at least a few missed cases where vp->v_{clean,dirty}blkhd were
unprotected since the softdep/trickle sync merge.
1999-11-23 23:52:40 +00:00