1) Eliminate all of the null component name special cases; handle runs of
slashes and leading and trailing slashes completely differently.
2) Return ENOENT when doing a lookup through an empty symlink.
3) Enforce that we're doing a lookup through a directory in in chdir() and
lookup() rather than in foo_lookup().
Not yet finished.
have any signals delivered while exiting, so this should be okay. Change the
test for a traced process in wait4() to exclude a process that was started by
the debugger; in this case, only one SIGCHLD should be delivered.
* When a delayed write buffer falls off the LRU queue, arrange for it to go on
the AGE queue after being flushed out to disk.
* When a delayed write buffer is synced, leave it in its relative position in
the LRU queue.
(1) "" no longer refers to the current working directory;
looking this up will now result in ENOENT.
(2) by stripping off trailing slashes and setting a `forcedir'
flag, make code such as { mkdir("dir", m); rmdir("dir/"); }
actually work.
external storage. Highlights:
- additional "void *" argument to (*ext_free)(), an opaque
cookie for use by the free function.
- MCLALLOC() and MCLFREE() calls are gone. They are replaced
by MEXTADD() (add external storage to mbuf), MEXTMALLOC()
(malloc() external storage and attach to mbuf), and
MEXTREMOVE() (remove external storage from mbuf).
- completely new external storage reference counting
mechanism; mclrefcnt[] is gone.
These changes will eventually be used to pass driver DMA buffers up
the network stack, and reduce/eliminate copies in certain code paths
(e.g. NFS writes).
From Matt Thomas <matt@3am-software.com> and myself <thorpej@nas.nasa.gov>,
with some input from Chris Demetriou <cgd@cs.cmu.edu> and review by
Charles Hannum <mycroft@mit.edu>.
Some of the stuff (e.g., rarpd, bootpd, dhcpd etc., libsa) still will
only support Ethernet. Tcpdump itself should be ok, but libpcap needs
lot of work.
For the detailed change history, look at the commit log entries for
the is-newarp branch.
work. Not quite as good as with the Lite2 merges, but it'll do until then.
* dounmount() expects to be called with the mountpoint marked busy
* all callers of dounmount() thus make the call themselves
* if a filesystem was being unmounted, and we're woken up in vfs_busy(),
don't reference the mountpoint struct pointer, as it has very probably
been freed.
in the assembly file genassym.s into the usual assym.h file. The
assym.h file generated this way is identical to the output generated
if I simply compile and run the genassym.s file. "Heh, Kewl!"
Thanks to Matthias Pfaller for the "translate the .s file" idea!
* prototype it before it is used (several ports compile with
-Wstrict-prototypes -Wmissing-prototypes), so this is _necessary_.
* conform to C syntax (yes, that's right, it wouldn't parse).
* make error check less error-prone, + style fixups.
mount the root file system. If the operator specified the root
file system type in the kernel configuration file, attempt to
mount that file system type on the root device. If the root
file system type was wildcarded (or unspecified), try all of
the file systems statically built into the kernel until one
succeeds. If no file systems succeed, return an error. The
system will recover from this condition.
- Implement vfs_getopsbyname(). This function returns the file
system ops vector given a file system name.
from the version used by NetBSD/alpha, with several changes by me.
Support for asking for root device and root file system type on any
kernel, obsoleting "options GENERIC".
- Make my mountroothook implementation used by the sparc and x68k
ports machine-independent, and use it here. Mountroothooks allow
devices to execute special functions before being mounted as the
root device (such as ejecting the floppy and prompting for a new
floppy disk).
- Make swapconf() machine-independent. It was identical on all ports.
- Run mountroot hooks before we attempt to mount the root device, and
destroy mountroot hooks after the root file system has been sucessfully
mounted.
- Don't panic if we can't mount root. Instead, set RB_ASKNAME and
call setroot(), which will prompt the operator for the root device
and file system type.
is running (and NTP is not enabled), the adjtime()-handling code clobbers
any tickfix that may be necessary for systems with clocks with frequency
greater than 1000Hz.
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.
* Fix arguments to various copyin()/copyout() invocations, to avoid
gratuitous casts.
* Some KNF formatting fixes
* Change sockargs()'s second argument to be a const void *, to help
with dealing with the syscall argument type fixups/const poisoning.
* change in-kernel syscall prototypes to match user-land prototypes in
the following ways:
+ add 'const' where appropriate.
+ make the following "safe" type changes where appropriate:
caddr_t -> struct msghdr *
caddr_t -> struct sockaddr *
caddr_t -> void *
char * -> void *
int -> uid_t (safe because uid_t not used as index/count)
int -> gid_t (safe because gid_t not used as index/count)
u_int -> size_t
+ change "int" to "u_long" in flags arguments to chflags() and
fchflags(). This is safe because the arguments are used as
flag bits and there's nothing that would cause the top bit
of the int to be set yet, and because the user-land definitions
already specified u_long, so a u_long's worth of argument was
already being passed in.
wrong for a bunch of functions:
void: sys_exit, sys_sync
ssize_t: sys_read, sys_write, sys_recvmsg, sys_sendmsg,
sys_recvfrom, sys_readv, sys_writev, sys_sendto
long: sys_pathconf, sys_fpathconf
void *: sys_shmat
* Note that sys_open, sys_ioctl, and sys_fcntl are defined such that their
last argument is optional.
These changes should not have any real effect, because right now this
information is not actually used for anything.
* Don't output prototypes for INDIR syscalls (since they always show up as
sys_nosys() in the syscall table).
* Add "indir" to the comment for INDIR syscalls in the syscalls table, so
it's more obvious why they call sys_nosys().
* Deal with multi-word system call return types (i.e. foo *, or
struct foo *, or struct foo, etc.).
* Add a new class of system calls "INDIR" (for "indirect"), which
is to be used to represent indirect syscalls like syscall() and
__syscall() which are implemented in MD code and which don't want
args structures defined. (The old way of declaring this type of
syscalls still works.)
* Allow system calls to be marked as having a variable number of
arguments, by inserting "..." (no trailing comma) before the
first hf the optional arguments in the syscall definition. Because
of the way syscall arguments are handled by MI code, _ALL_ syscall
arguments must actually be included in the definition, i.e.
"optional" arguments are either "are there or aren't," i.e. these
aren't really varargs functions. Therefore, for normal syscalls,
there _must_ be arguments listed after the "...". For INDIR
syscalls, which really do have a variable number of arguments and
which aren't handled via the normal mechanism, that requirement is
not in force.
* output primitive (machine-parsable) syscall descriptions as comments
in <sys/syscall.h>. These can be used to easily build real function
prototypes, or to build stub functions for use by lint.
>- Optional systems calls are "UNIMPL" if the support is not being
> compiled into the kernel.
It had implications that didn't occurr to me at the time. *sigh*
>- Optional systems calls are "UNIMPL" if the support is not being
> compiled into the kernel.
It had implications that didn't occur to me at the time. *sigh*
defined:
define match functions to take a struct cfdata * as their second
argument, config_search() to take a struct cfdata * as its second
argument, and config_{root,}search() to return struct cfdata *.
remove 'cd_indirect' cfdriver element.
remove config_scan().
remove config_make_softc() as a seperate function, reintegrating
its functionality into config_attach().
Ports will define __BROKEN_INDIRECT_CONFIG until their drivers prototypes
are updated to work with the new definitions, and until it is sure that
their indirect-config drivers do not assume that they have a softc
in their match routine.
the client and server/shared data initialization into separate functions,
and calling the server/shared initialization directly from main().
Problem noted in PR #1308 (Kenneth Stailey) and PR #1780 (Chris Demetriou).
Fix suggested in PR #1780 by Chris Demetriou, and munged a bit by me,
and OK'd by Frank van der Linden <fvdl@netbsd.org>.
(1) after removing a shutdown hook (in shutdownhook_disestablish()),
free it. We created it, we have to free it. Without this,
shutdownhook_disestablish() leaks memory.
(2) in doshutdownhooks(), before running each hook, remove it from the
shutdown hook list. This makes sure that every hook is tried once
(because doshutdownhooks() is called from before rebooting, and
a fault in a shutdown hook will cause doshutdownhooks() to be called
again), but prevents the hooks from potentially being run infinitely
(as used to be possible, in the above-mentioned situation).
If not compiled with -D_KERNEL, include different includes and
do so macro magic so that this will fit sanely into test harnesses.
When used in user-land, this should be compiled with -D_EXTENT_TESTING.
Bug fixes:
(extent_insert_and_optimize) You can't do things like:
LIST_REMOVE(elem->...le_next, ...);
free(elem->...le_next, ...);
They just don't work (and will corrupt your list and/or malloc free list).
(extent_alloc_region_descriptor) Unless you wait, malloc can fail.
Don't accidentally deref a potentially-NULL pointer.