imp [Thu, 18 Feb 2010 16:05:09 +0000 (16:05 +0000)]
The kdump data stream is an unaligned data stream for stat and
sockaddr structures. As such, we have top copy the data structure
into a local buffer before we can reference it, otherwise we have
unaligned references (these are fixed up automatically on some CPUs,
but not on others). We do this unconditionally to make the code
easier to read and understand.
kensmith [Thu, 18 Feb 2010 15:45:43 +0000 (15:45 +0000)]
Provide a script that can be used to create the memstick images. For now
it isn't being integrated into 'make release' because for the forseeable
future the memstick images will be identical to what's on the DVD except
for which package set is provided. If/when what's on the memstick diverges
from what's on the DVD it would make more sense to generate a "memstick"
directory in $CHROOT/R/cdrom and build the memstick image along with the
ISO images.
Reviewed by: jhb, ru, Garrett Cooper (yanefbsd at gmail dot com)
nwhitehorn [Thu, 18 Feb 2010 15:00:43 +0000 (15:00 +0000)]
Fix a bug where pages being removed from memory entirely no longer have
PVOs, and so the modified state of the page can no longer be communicated
to the VM layer, causing pages not to be flushed to swap when needed, in
turn causing memory corruption. Also make several correctness adjustments
to I-Cache synchronization and TLB invalidation for 64-bit Book-S CPUs.
ed [Thu, 18 Feb 2010 14:28:38 +0000 (14:28 +0000)]
Allow the pmap code to be built with GCC from FreeBSD 7 again.
This patch basically gives us the best of both worlds. Instead of
forcing the compiler to emulate GNU-style inline semantics even though
we're using ISO C99, it will only use GNU-style inlining when the
compiler is configured that way (__GNUC_GNU_INLINE__).
marcel [Thu, 18 Feb 2010 02:06:57 +0000 (02:06 +0000)]
Allow suppression of -Wcast-align for WARNS>=4 by defining
NO_WCAST_ALIGN. The headers of the standard C++ library are
not 64-bit clean and trigger the warning. This prevents use
of WARNS>=4 on ia64 for example.
jilles [Wed, 17 Feb 2010 22:25:22 +0000 (22:25 +0000)]
sh: arith: Add a test for a bug in the dash arith code,
which I plan to import at some point.
Our current code handles it fine and it should stay that way.
neel [Wed, 17 Feb 2010 06:43:37 +0000 (06:43 +0000)]
Various fixes to get the SWARM config working on a big-endian Sibyte CPU.
Getting the little-endian PCI bus working on the big-endian CPU proved to be
quite challenging. We let the PCI devices be mapped in the "match byte lanes"
address window. This is where they are mapped by the CFE and DMA transfers
generated to or from addresses within this window are not subject to automatic
byte-swapping.
However any access by the driver to memory-mapped pci space is redirected
via the "match bit lanes" address window. We get the benefit of automatic
byte swapping through this address window and drivers don't need to change
to deal with CPU big-endianness.
gavin [Tue, 16 Feb 2010 22:53:18 +0000 (22:53 +0000)]
Implement the rename query, for when a file with the same name as the one
about to be extracted already exists. The question, and interpretation
of the response is deliberately compatible with Info-Zip.
This change was originally obtained from NetBSD, but has three changes:
- better compatibility with Info-Zip in the handling of ^D
- Use getdelim() rather than getline()
- bug fix: != changed to == in the "file rename" code
I suspect the latter is also a bug in NetBSD, but I can't easily confirm
this.
marius [Tue, 16 Feb 2010 20:00:21 +0000 (20:00 +0000)]
Factor out the code shared between NFS client and server into its own
module. With r203732 it became apparent that creating the sysctl nodes
twice causes at least a warning, however the whole code shouldn't be
present twice in the first place.
marcel [Tue, 16 Feb 2010 06:47:00 +0000 (06:47 +0000)]
Unbreak ia64: tls_model("initial-exec") is invalid, because it assumes
the static TLS model, which is fundamentally different from the dynamic
TLS model. The consequence was data corruption. Limit the attribute to
i386 and amd64.
marcel [Tue, 16 Feb 2010 02:48:11 +0000 (02:48 +0000)]
Improve TLS variant I:
o Use obj->tlsinitsize to determine whether there's initialized data.
o If obj->tlssize > obj->tlsinitsize, then bzero uninitialized data.
o Don't exclude variant I from the work-around in free_tls_offset().
weongyo [Tue, 16 Feb 2010 01:44:14 +0000 (01:44 +0000)]
adds bwn(4) driver for supporting Broadcom BCM43xx chipsets.
o uses v4 firmware instead of v3. A port will be committed to create
the bwn firmware module.
o supports B/G and LP(low power) PHYs.
o supports 32 / 64 bits DMA operations.
o tested on big / little endian machines so should work on all
architectures.
It'd not connected to the build until the firmware port is committed.
marcel [Sun, 14 Feb 2010 16:56:24 +0000 (16:56 +0000)]
Some code churn:
o Eliminate IA64_PHYS_TO_RR6 and change all places where the macro is used
by calling either bus_space_map() or pmap_mapdev().
o Implement bus_space_map() in terms of pmap_mapdev() and implement
bus_space_unmap() in terms of pmap_unmapdev().
o Have ia64_pib hold the uncached virtual address of the processor interrupt
block throughout the kernel's life and access the elements of the PIB
through this structure pointer.
This is a non-functional change with the exception of using ia64_ld1() and
ia64_st8() to write to the PIB. We were still using assignments, for which
the compiler generates semaphore reads -- which cause undefined behaviour
for uncacheable memory. Note also that the memory barriers in ipi_send() are
critical for proper functioning.
With all the mapping of uncached memory done by pmap_mapdev(), we can keep
track of the translations and wire them in the CPU. This then eliminates
the need to reserve a whole region for uncached I/O and it eliminates
translation traps for device I/O accesses.
rpaulo [Sun, 14 Feb 2010 16:26:32 +0000 (16:26 +0000)]
Revert part of the 9285 support because it breaks the 9280 support. I'll
try to do the 9285 support without interfering with any other chipset
revisions support.
luigi [Sun, 14 Feb 2010 15:51:36 +0000 (15:51 +0000)]
a minimal set of changes to adapt to the utmp->utmpx changes.
lastlog still not implemented, i am hoping that Ed or someone
has some idea on how to fix this, but it is really not important.
kib [Sun, 14 Feb 2010 12:31:28 +0000 (12:31 +0000)]
Rename fields to match better the msdosfs headers. This work is still
incomplete as some info doesn't really belong to the structs where it is
defined.
Submitted by: Pedro F. Giffuni <giffunip tutopia com>
Reviewed by: bde
MFC after: 2 weeks
mav [Sun, 14 Feb 2010 12:30:35 +0000 (12:30 +0000)]
MFp4:
With FBS enabled, we have no idea what command caused timeout.
Implement same logic as in siis(4) - wait for other commands
complete or timeout and then give some more time.
kib [Sun, 14 Feb 2010 12:30:30 +0000 (12:30 +0000)]
Bug fixes from NetBSD
- fix sign-compare issues.
- ANSIfy a couple of functions.
- Remove more duplicate #includes.
- Memory leak found by Coverity on NetBSD.
Submitted by: Pedro F. Giffuni <giffunip tutopia com>
Reviewed by: bde
MFC after: 2 weeks
kib [Sun, 14 Feb 2010 12:25:03 +0000 (12:25 +0000)]
Some cleanups from NetBSD:
- C99 initializers.
- Change the default volume label from "NO NAME" to "NO_NAME".
- Set OEM String to "BSD4.4 " following the unnamed spacing convention
in that other OS that suggests "MSWIN4.1"
Also, David Naylor's changes for Clang, mostly changing the signess
of constants.
Submitted by: Pedro F. Giffuni <giffunip tutopia com>
Clang fixes by: David Naylor <naylor.b.david gmail com>
Reviewed by: bde (with some disagreement about Clang issues)
MFC after: 2 weeks
ed [Sun, 14 Feb 2010 12:00:42 +0000 (12:00 +0000)]
Make <sys/timeb.h> work without including <sys/types.h>.
According to the last POSIX specification that contained <sys/timeb.h>,
this header should also typedef time_t properly. Also add a proper
comment to the final #endif.