around meant that the higher level close routine never gets called.
(phk is on the road; this is a quick fix to get things working and may need
more polish)
doscmd heavily depends on struct sigcontext which luckily is mostly passed
between functions as usion regcontext_t. By redefining union regcontext_t in
terms of mcontext_t almost all bases are covered.
It also seems to me that doscmd was in a transitional state. The redundant
definitions made it difficult to get a clear overview and could easily cause
oversight. To make sure my changes were ok, I went as far as to complete the
transition. It was not exactly necessary, but I expect to have to come back
here some more ("whistle" if I'm wrong :-).
error for a directory. I have made this change after a great deal of
review although I cannot be absolutely sure that this meets the spec.
The issue devolves into whether changes in an underlying (UFS) directory
can cause NFS directory blocks to be renumbered. My read of the code
indicates that NFS directory blocks will not be renumbered, which means
that the cookies should still remain valid after a change is made to
the underlying directory. This being the case, a cookie error should
not be returned when a change is made to the underlying directory and,
instead, the NFS client should rely on mtime detection to invalidate and
reload the directory.
The use of mtime is problematic in of itself, due to insufficient
resolution, which is why I believe the original conservative error
handling was done. Still, there have been dozens of bug reports by
people needing solaris<->FreeBSD interoperability and these have to
be accomodated.
-----------------------------
Most of the userland changes are in libc. For both the alpha
and the i386 setjmp has been changed to accomodate for the
new sigset_t. Internally, libc is mostly rewritten to use the
new syscalls. The exception is in compat-43/sigcompat.c
The POSIX thread library has also been rewritten to use the
new sigset_t. Except, that it currently only handles NSIG
signals instead of the maximum _SIG_MAXSIG. This should not
be a problem because current applications don't use any
signals higher than NSIG.
There are version bumps for the following libraries:
libdialog
libreadline
libc
libc_r
libedit
libftpio
libss
These libraries either a) have one of the modified structures
visible in the interface, or b) use sigset_t internally and
may cause breakage if new binaries are used against libraries
that don't have the sigset_t change. This not an immediate
issue, but will be as soon as applications start using the
new range to its fullest.
NOTE: libncurses already had an version bump and has not been
given one now.
NOTE: doscmd is a real casualty and has been disconnected for
the moment. Reconnection will eventually happen after
doscmd has been fixed. I'm aware that being the last one
to touch it, I'm automaticly promoted to being maintainer.
According to good taste this means that I will receive a
badge which either will be glued or mechanically stapled,
drilled or otherwise violently forced onto me :-)
NOTE: pcvt/vttest cannot be compiled with -traditional. The
change cause sys/types to be included along the way which
contains the const and volatile modifiers. I don't consider
this a solution, but more a workaround.
-----------------------------
The compatibility code and/or emulators have been updated:
iBCS2 now mostly uses the older syscalls. SVR4 now properly
handles all signals. This has been achieved by using the
new sigset_t throughout the emulator. The Linuxulator has
been severely updated. Internally the new Linux sigset_t is
made the default. These are then mapped to and from the
new FreeBSD sigset_t.
Also, rt_sigsuspend has been implemented in the Linuxulator.
Implementing this syscall basicly caused all this sigset_t
changing in the first place and the syscall has been used
throughout the change as a means for testing. It basicly is
too much work to undo the implementation so that it can
later be added again.
A special note on the use of sv_sigtbl and sv_sigsize in
struct sysentvec:
Every signal larger than sv_sigsize is not translated and is
passed on to the signal handler unmodified. Signals in the
range 1 upto and including sv_sigsize are translated.
The rationale is that only the system defined signals need to
be translated.
The emulators also have been updated so that the translation
tables are only indexed for valid (system defined) signals.
This change also fixes the translation bug already in the
SVR4 emulator.
-----------------------------
By introducing a new sigframe so that the signal handler operates
on the new siginfo_t and on ucontext_t instead of sigcontext, we
now need two version of sendsig and sigreturn.
A flag in struct proc determines whether the process expects an
old sigframe or a new sigframe. The signal trampoline handles
which sigreturn to call. It does this by testing for a magic
cookie in the frame.
The alpha uses osigreturn to implement longjmp. This means that
osigreturn is not only used for compatibility with existing
binaries. To handle the new sigset_t, setjmp saves it in
sc_reserved (see NOTE).
the struct sigframe has been moved from frame.h to sigframe.h
to handle the complex header dependencies that was caused by
the new sigframe.
NOTE: For the i386, the size of jmp_buf has been increased to hold
the new sigset_t. On the alpha this has been prevented by
using sc_reserved in sigcontext.
-----------------------------
The core of the signalling code has been rewritten to operate
on the new sigset_t. No methodological changes have been made.
Most references to a sigset_t object are through macros (see
signalvar.h) to create a level of abstraction and to provide
a basis for further improvements.
The NSIG constant has not been changed to reflect the maximum
number of signals possible. The reason is that it breaks
programs (especially shells) which assume that all signals
have a non-null name in sys_signame. See src/bin/sh/trap.c
for an example. Instead _SIG_MAXSIG has been introduced to
hold the maximum signal possible with the new sigset_t.
struct sigprop has been moved from signalvar.h to kern_sig.c
because a) it is only used there, and b) access must be done
though function sigprop(). The latter because the table doesn't
holds properties for all signals, but only for the first NSIG
signals.
signal.h has been reorganized to make reading easier and to
add the new and/or modified structures. The "old" structures
are moved to signalvar.h to prevent namespace polution.
Especially the coda filesystem suffers from the change, because
it contained lines like (p->p_sigmask == SIGIO), which is easy
to do for integral types, but not for compound types.
NOTE: kdump (and port linux_kdump) must be recompiled.
Thanks to Garrett Wollman and Daniel Eischen for pressing the
importance of changing sigreturn as well.
-----------------------------
Rename sigaction, sigprocmask, sigpending and sigsuspend to
osigaction, osigprocmask, osigpending and osigsuspend (resp)
and add new syscalls for them to support the new sisgset_t
without breaking existing binaries.
Change the prototype of sigaltstack to use the typedef stack_t
instead of struct sigaltstack to reflect that it is SUSv2
compliant.
Also, rename sigreturn to osigreturn and add a new syscall
to support the modified stackframe. The change is caused by
sigreturn operating on ucontext_t now and the fact that
siginfo_t has been updated to conform to SUSv2.
This happened to be my first "for real" broken world. I had broken
it once before, but nobody noticed, so it didn't count.
So, how do I get the "I broke world and all I got was the lousy t-shirt"
t-shirt?
vinum_lpi: Add information about progress of rebuildparity and
checkparity commands.
listconfig: Print object counts in a different format, don't refer to
the internal number of slots allocated:
Caused-confusion-to: Norbert Meissner <norbert.meissner@daimlerchrysler.com>
vinum_info: Change format of device numbers so that they fit in the
column (ignore high-order minor number bits, which aren't really of
much interest).
vinum_start: bzero the statinfo.dinfo struct. The lack of this was
causing sporadic failures of the start command.
Add body of vinum_checkparity command.
of parity check and rebuild operations. This enables us
to stop the operation and restart at a later time.
enum parityop: Trivial enum to decide what parityops() is going to do.
could stand.
Define the correct return lengths for a number of ioctls.
Add ioctls VINUM_CHECKPARITY and VINUM_RESETPARITY, still to be fully
implemented.
ourselves. This breaks a vicious circle which caused
vinum to dereference a null vp if device nodes were
missing.
Reported-by: Brad Chisholm <sasblc@unx.sas.com>
Alec Wolman <wolman@cs.washington.edu>
check_drive: Don't take a drive down if it's only referenced.
read_drive: Remove unused variable.
get_empty_volume: initialize plexes to -1 (not allocated)
remove_drive_entry:
Remove recurse parameter (there's nothing below a drive in the hierarchy).
Use remove_sd_entry to remove sds, don't do it ourselves.
Log errors, don't throw rude remarks.
remove_plex_entry:
Don't use plex->subdisks as a loop limit, it gets changed in the
loop. This caused some removals to only remove half the subdisks.
Change logging of some "impossible" situations.
remove_volume_entry:
Use remove_plex_entry to remove plexes, don't do it ourselves.
update_sd_config:
Use set_sd_state to do the work.
will have to mknod yourself for now.
* don't eat the first write()
* partial rvplayer fix- don't panic on unaligned writes unless our
feeder chain requires them for downconversion. a fuller fix is
on the way.
I386_BUS_SPACE_IO. Compiles now on the Alpha, but likely will not
work due to bus space address <-> virtual address mapping bogons that
work for i386 but not alpha.
required to be "announced" by a new bit in sa_flags to indicate the
program is aware of and has taken care of them. eg: SA_SIGINFO means
the program has used the sa_siginfo field (versus sa_handler).
sigaction, used to describe an action to be taken, is defined in the
header <signal.h> to include at least the following members:"
^^^^^^^^
A sigaction defined on stack with essentially random contents may have
just about anything underneath fields that the program doesn't know about.
It is not safe to delete the bzero.
initialization of sa_flags added so that we can lose the bzero.
IIRC, this code is not used anymore since the addition of
ncurses. Commit the change anyway so, just to be safe.
$FreeBSD$ tag added
initialization of sa_flags added so that the 'struct sigaction'
can be declared local in both functions that use the global
(static) declaration. Remove the global declaration.
an empty mbuf to stay in the queue, then causing a needless panic
because sb_cc == 0 and sb_mbcnt != 0.
But we still need to panic rather than endlessly looping if, for
some reason, sb_cc == 0 and there are non-empty mbufs in the queue.
PR: kern/11988
Reviewed by: fenner