- Disallow setting of flags not supported by ext2fs.
- Map EXT2_APPEND_FL to SF_APPEND.
- Map EXT2_IMMUTABLE_FL to SF_IMMUTABLE.
- Map EXT2_NODUMP_FL to UF_NODUMP.
Note that ext2fs doesn't support user settable append and immutable flags.
EXT2_NODUMP_FL is an user settable flag also on Linux.
ed [Thu, 31 Dec 2009 10:53:04 +0000 (10:53 +0000)]
MFC r198185:
Print backspaces after echoing an EOF.
Applications like shells expect EOF to give no graphical output, while
our implementation prints ^D by default (tunable with stty echoctl).
Make the new implementation behave like the old TTY code. Print two
backspaces afterwards.
I totally forgot to MFC this, because the 8.0 freeze took a little
longer than I expected.
jh [Thu, 31 Dec 2009 07:34:38 +0000 (07:34 +0000)]
MFC r198291:
Unloading of the nfscl module is unsupported because newnfslock doesn't
support unloading. It's not trivial to implement newnfslock unloading so
for now just admit that unloading is unsupported and refuse to attempt
unload in all nfscl module event handlers.
jh [Thu, 31 Dec 2009 07:32:04 +0000 (07:32 +0000)]
MFC r198290:
Fix ordering of nfscl_modevent() and ncl_uninit(). nfscl_modevent() must
be called after ncl_uninit() when unloading the nfscl module because
ncl_uninit() uses ncl_iod_mutex which is destroyed in nfscl_modevent().
thompsa [Thu, 31 Dec 2009 00:10:26 +0000 (00:10 +0000)]
MFC r200653
Use the EVENTHANDLER system to hook into the usb device configuration and
perform a function such as ejecting a 3G autoinstaller disk. The eventhandler
system properly tracks threads and is safe to unload, remove the
setting/clearing of a function pointer in the kernel by u3g(4) which included a
tsleep for safety.
thompsa [Thu, 31 Dec 2009 00:09:47 +0000 (00:09 +0000)]
MFC r200652
If the runcount is non-zero in eventhandler_deregister() then one or more
threads are executing the eventhandler, sleep in this case to make it safe for
module unload. If the runcount was up then an entry would have been marked
EHE_DEAD_PRIORITY so use this as a trigger to do the wakeup in
eventhandler_prune_list().
dougb [Wed, 30 Dec 2009 19:36:40 +0000 (19:36 +0000)]
MFC r200743:
The service command is an easy interface to the rc.d system.
Its primary purpose is to start and stop services provided by
the rc.d scripts, however it can also be used to list the scripts
using various criteria.
MFC r200809, r200980, r201035, r201069, 201070:
Updates/fixes suggested after the initial introducition
jhb [Wed, 30 Dec 2009 17:53:07 +0000 (17:53 +0000)]
MFC 200919:
Fix a bug in gzipfs that prevented lseek() from working and add lseek()
support to bzip2fs. This fixes problems with loading compressed amd64
kernel modules containing debug symbols.
jh [Wed, 30 Dec 2009 17:22:00 +0000 (17:22 +0000)]
MFC r199844:
Reset path name back to original correctly in fts_build() when
FTS_NOCHDIR option is used. fts_build() could strip a trailing slash
from path name in post-order visit if a path pointing to an empty
directory was given for fts_open().
markus [Wed, 30 Dec 2009 16:37:58 +0000 (16:37 +0000)]
MFC r200992:
Use a local copy of entry_d for finding matches. Otherwise, if entry_d pointed
to an entry of 'acl', all ACL entries starting with entry_d would be deleted.
mav [Tue, 29 Dec 2009 21:23:18 +0000 (21:23 +0000)]
MFC r200821:
Make graid3 fallback to malloc() when component request size is bigger
then maximal prepared UMA zone size. This fixes crash with MAXPHYS > 128K.
dougb [Tue, 29 Dec 2009 07:08:48 +0000 (07:08 +0000)]
MFC r200448:
Since the change to rc.subr in r198162 it's not necessary to specify
command in the rc.d script if we have a corresponding ${name}_program
entry, which we do for named.
Rename named_precmd to named_prestart to make it more clear and match
convention.
Move the command_args definition related to -u up into _prestart().
It (and the associated $named_uid value) are only used there, and
unlike required_* and pidfile don't need to be used until this stage.
Fix a silly bug that would only have affected people who were using
the new named_wait or named_auto_forward features, AND had set up an
rndc.conf file instead of using the automatically generated rndc.key.
For named_conf:
Add "-c $named_conf" to command_args if it's not set to the
default. If it is set to the default and we're using the base
BIND it's not necessary. If we're using BIND from the ports
the user is likely to have included it in _flags (due to long
necessity for doing so) so don't duplicate that if it's set.
Add $named_conf to required_files
MFC r200563:
The named process needs to have a "working directory" that it can
write to. This is specified in "options { directory }" in named.conf.
So, create /etc/namedb/working with appropriate permissions, and
update the entry in named.conf to match.
In addition to specifying the working directory, file and path names
in named.conf can be specified relative to the directory listed.
However, since that directory is now different from /etc/namedb
(where the configuration, zone, rndc.*, and other files are located)
further update named.conf to specify all file names with fully
qualified paths. Also update the comment about file and path names
so users know this should be done for all file/path names in the file.
This change will eliminate the 'working directory is not writable'
messages at boot time without sacrificing security. It will also
allow for features in newer versions of BIND (9.7+) to work as
designed.
bz [Mon, 28 Dec 2009 14:40:58 +0000 (14:40 +0000)]
MFC r200473:
Throughout the network stack we have a few places of
if (jailed(cred))
left. If you are running with a vnet (virtual network stack) those will
return true and defer you to classic IP-jails handling and thus things
will be "denied" or returned with an error.
Work around this problem by introducing another "jailed()" function,
jailed_without_vnet(), that also takes vnets into account, and permits
the calls, should the jail from the given cred have its own virtual
network stack.
We cannot change the classic jailed() call to do that, as it is used
outside the network stack as well.
Discussed with: julian, zec, jamie, rwatson (back in Sept)
kib [Sun, 27 Dec 2009 20:39:58 +0000 (20:39 +0000)]
MFC r200038:
Properly support -fPIE by linking PIE binaries with specially-built
Scrt1.o instead of crt1.o, since the later is built as non-PIC.
Separate i386-elf crt1.c into the pure assembler part and C code,
supplying all data extracted by assembler stub as explicit parameters.
Hide and localize _start1 symbol used as an interface between asm and
C code.
delphij [Sun, 27 Dec 2009 07:04:27 +0000 (07:04 +0000)]
Explicitly say that this is an internal library which is intended to be
used within FreeBSD base system only, and discourage user applications
from using it. User applications should use the expat version from the
ports/package collection.
mav [Fri, 25 Dec 2009 08:06:35 +0000 (08:06 +0000)]
MFC r200668:
Remove duplicate devstat_start_transaction_bio() call. It is already called
from geom_disk. Dulicate call causes wrong queue depth and busy accounting.
mav [Tue, 22 Dec 2009 19:56:35 +0000 (19:56 +0000)]
MFC r200218:
- Cleanup kernel messages, mostly PMP.
- Took references on devices, while PMP reinitializes them, to not let them
go and distort freeze reference counting.
yongari [Mon, 21 Dec 2009 18:52:38 +0000 (18:52 +0000)]
MFC r199563,199608-199613
r199563:
Fix copy & paste error and remove extra space before colon.
r199608:
Remove unnecessary structure packing.
r199609:
Add initial endianness support. It seems the controller supports
both big-endian and little-endian format in descriptors for Rx path
but I couldn't find equivalent feature in Tx path. So just stick to
little-endian for now.
r199610:
Because we know received bytes including CRC there is no reason to
call m_adj(9). The controller also seems to have a capability to
strip CRC bytes but I failed to activate this feature except for
loopback traffic.
r199611:
Add IPv4/TCP/UDP Tx checksum offloading support. It seems the
controller also has support for IP/TCP checksum offloading for Rx
path. But I failed to find to way to enable Rx MAC to compute the
checksum of received frames.
r199612:
Add __FBSDID.
r199613:
Only Tx checksum offloading is supported now. Remove experimental
code sneaked in r199611.
yongari [Mon, 21 Dec 2009 18:34:18 +0000 (18:34 +0000)]
MFC r199558,199561
r199558:
Use bus_{read,write}_4 rather than bus_space_{read,write}_4.
r199561:
Use capability pointer to access PCIe registers rather than
directly access them at fixed address. Frequently the register
offset could be changed if additional PCI capabilities are added to
controller.
One odd thing is ET_PCIR_L0S_L1_LATENCY register. I think it's PCIe
link capabilities register but the location of the register does
not match with PCIe capability pointer + offset. I'm not sure it's
shadow register of PCIe link capabilities register.
yongari [Mon, 21 Dec 2009 18:07:15 +0000 (18:07 +0000)]
MFC r199548:
Remove complex macros that were used to compute bits values.
Although these macros may have its own strength, its complex
definition make hard to read the code.
jilles [Sun, 20 Dec 2009 20:51:20 +0000 (20:51 +0000)]
MFC r198173: sh: show more info about syntax errors in command substitution:
the line number where the command substitution started.
This applies to both the $() and `` forms but is most useful for ``
because the other line number is relative to the enclosed text there.
(For older versions, -v can be used as a workaround.)
kan [Sun, 20 Dec 2009 02:35:10 +0000 (02:35 +0000)]
MFC r198471.
Log:
Compile libgcov without stack protection. It can be linked into
both static and dynamic binaries compiled with or without stack
protection and should not depend on libssp_nonshared.a symbols.
marius [Sun, 20 Dec 2009 01:44:47 +0000 (01:44 +0000)]
MFC: r200482, r200485
o Properly support M5229 revision 0xc7 and 0xc8:
- These revisions no longer have cable detection capability.
- The UDMA support bit of register 0x4b has been dropped without an
replacement.
- According to Linux it's crucial for working ATAPI DMA support to
also set the reserved bit 1 of regsiter 0x53 with these revisions.
o Only set ATA_CHECKS_CABLE for chip versions that actually support
cable detection, i.e. neither for ALI_OLD nor for ALI_NEW revisions
>= 0xc7.