imp [Sun, 2 Nov 2003 20:18:19 +0000 (20:18 +0000)]
MFp4:
o Fix MFC cards. We were bogusly setting CCR_IOBASE[01] and CCR_IOLIMIT.
now when we activate the resource, we adjust these for MFC cards, per the
spec.
o Change type of pf_mfc_* to be bus_addr_t, which is more correct than
long.
This makes my 3C362D/3C363D and 3CXEM556 cards work! Woo Hoo!
imp [Sun, 2 Nov 2003 20:13:39 +0000 (20:13 +0000)]
MFp4:
o Remove redundant $FreeBSD$
o Better comments about ep_get_macaddr.
o remove one tab in a switch statement (style only)
o Recognize ID 0x0035 as the device ID for the 3CXEM556 that I have. This
makes the 3CXEM556 work for me. Not 100% sure this is the assigned ID,
as I don't have the datasheets for this part, but it does work and get
the correct ethrnet address.
o Comment about the whole fake IRQ 3 thing. some need it, some don't, all
work with it.
ceri [Sun, 2 Nov 2003 17:35:33 +0000 (17:35 +0000)]
Since we do not honour the Confidential: field, and as an attempt to
decrease the number of misfiled PR submissions in general, do not
allow users to send a PR that contains errors.
jeff [Sun, 2 Nov 2003 10:56:48 +0000 (10:56 +0000)]
- Remove the ksq_loads[] array. We are only interested in three counts,
the total load, the timeshare load, and the number of threads that can
be migrated to another cpu. Account for these seperately.
- Introduce a KSE_CAN_MIGRATE() macro which determines whether or not a KSE
can be migrated to another CPU. Currently, this only checks to see if
we're an interrupt handler. Eventually this will also be used to support
CPU binding.
tjr [Sun, 2 Nov 2003 10:09:33 +0000 (10:09 +0000)]
Convert the Big5, EUC, MSKanji and UTF-8 encoding methods to implement
mbrtowc() and wcrtomb() directly. GB18030, GBK and UTF2 are left
unconverted; GB18030 will be done eventually, but GBK and UTF2 may just
be removed, as they are subsets of GB18030 and UTF-8 respectively.
marcel [Sun, 2 Nov 2003 09:19:07 +0000 (09:19 +0000)]
Remove headers copied from i386 and either useless or wrong on ia64.
An example of useless is bios.h. An example of wrong is msdos.h (due
to the use of long for 32-bit fields).
display.h cannot be removed because it's used by syscons. That header
however has no platform dependency and shouldn't really be here.
Removal if these headers may cause build failures in the ports tree.
It's the ports that need fixing in that case.
marcel [Sun, 2 Nov 2003 08:58:57 +0000 (08:58 +0000)]
o Add PART_EFI so that we can use it instead of PART_FAT on ia64
to better deal with the fact that we need an EFI partition and
that we need to have a mountpoint for it.
o When creating a new partition, add EFI to the list of types
the user can select from. This makes it easy to create an EFI.
o Do not include wizard.c on ia64.
o The user cannot create a partition on ia64 that's a multiple of
the cylinder size. We don't have a notion of cyclinders.
marcel [Sun, 2 Nov 2003 08:39:08 +0000 (08:39 +0000)]
o Move Int_Open_Disk() from disk.c to open_disk.c for use by all
platforms except ia64 and use Int_Open_Disk() in open_ia64_disk.c
on ia64. We need to know more than GEOM can provide us so we're
forced to read from the disk. Move uuid_type() to open_ia64_disk.c
and remove all references on non-ia64.
o Pass the GEOM conftxt to Int_Open_Disk() so that only Open_Disk()
needs to know about GEOM and libdisk can more easily be used with
media not handled by GEOM.
o Create an ia64 specific definiton of struct disk on ia64, because
we don't need/have most of the fields other platforms need and
other fields not applicable on platforms other than ia64.
o Do not compile change.c on ia64. It's too PC specific.
o In Fixup_Names() in create_chunk.c, try all partition numbers
that are valid for the GPT disk. We have the total number of
partitions that can be allocated in the disk structure on ia64.
Also, use the GPT partition naming if we're creating one under
a chunk of type "whole". It's a GPT partition in that case.
o In Create_Chunk(), compile-out the PC specific code on ia64 that
checks BIOS geometry restrictions.
o In Debug_Disk() in disk.c, dump the ia64 specific fields.
o Save the partition index in the chunk on ia64 so that we can
preserve it when we write the data back to disk. This avoids that
partitions get moved around or swapped after installing FreeBSD,
which may render a disk unusable.
marcel [Sun, 2 Nov 2003 08:07:25 +0000 (08:07 +0000)]
Do not fill in d_ncylinders, d_ntracks and d_nsectors in the disklabel
on ia64. Not only do we not have a disklabel by default, we also do
not have a notion of cylinders, tracks and sectors.
marcel [Sun, 2 Nov 2003 07:58:19 +0000 (07:58 +0000)]
Turn Track_Aligned(), Prev_Track_Aligned(), Next_Track_Aligned(),
Cyl_Aligned(), Prev_Cyl_Aligned() and Next_Cyl_Aligned() into
tautologies on ia64. GPT removes all notion of tracks, heads and
sectors per track, so there are no alignment considerations.
silby [Sun, 2 Nov 2003 07:47:03 +0000 (07:47 +0000)]
Add an additional check to the tcp_twrecycleable function; I had
previously only considered the send sequence space. Unfortunately,
some OSes (windows) still use a random positive increments scheme for
their syn-ack ISNs, so I must consider receive sequence space as well.
The value of 250000 bytes / second for Microsoft's ISN rate of increase
was determined by testing with an XP machine.
marcel [Sun, 2 Nov 2003 07:44:59 +0000 (07:44 +0000)]
o In Print_Chunk(), don't print the address of the chunk on ia64. It
doesn't have any meaning and only results in lines longer than 80
characters.
o In Delete_Chunk2(), also look for chunks of type "part" under
chunks of type "whole" on ia64. They're not only under chunks of
type "freebsd" there.
kan [Sun, 2 Nov 2003 04:52:53 +0000 (04:52 +0000)]
Take care not to call vput if thread used in corresponding vget
wasn't curthread, i.e. when we receive a thread pointer to use
as a function argument. Use VOP_UNLOCK/vrele in these cases.
The only case there td != curthread known at the moment is
boot() calling sync with thread0 pointer.
This fixes the panic on shutdown people have reported.
jeff [Sun, 2 Nov 2003 04:10:15 +0000 (04:10 +0000)]
- Rename SCHED_PRI_NTHRESH to SCHED_SLICE_NTHRESH since it is only used in
slice assignment. Add a comment describing what it does.
- Remove a stale XXX comment, the nice should not impact the interactivity,
nice adjustments only effect non-interactive tasks in ULE.
- Don't allow nice -20 tasks to totally starve nice 0 tasks. Give them at
least SCHED_SLICE_MIN ticks. We still allow nice 0 tasks to starve nice
+20 tasks as intended.
jeff [Sun, 2 Nov 2003 03:49:32 +0000 (03:49 +0000)]
- Remove uses of PRIO_TOTAL and replace them with SCHED_PRI_NRESV
- SCHED_PRI_NRESV does not have the off by one error in PRIO_TOTAL so we
do not have to account for it in the few places that we use it.
jeff [Sun, 2 Nov 2003 03:36:33 +0000 (03:36 +0000)]
- Change sched_interact_update() to only accept slp+runtime values between
0 and SCHED_SLP_RUN_MAX * 2. This allows us to simplify the algorithm
quite a bit. Before, it dealt with arbitrary values which required us
to do nasty integer division tricks that didn't quite work out correctly.
- Chnage sched_wakeup() to detect conditions where the slp+runtime could
exceed SCHED_SLP_RUN_MAX * 2. This can happen if we go to sleep for
longer than 6 seconds. In this case, we'll just clear the runtime and
set the sleep time to the max.
- Define a new function, sched_interact_fork() which updates the slp+runtime
of a newly forked thread. We want to limit the amount of history retained
from the parent so that we learn the child's behavior quickly. We don't,
however want to decay it to nothing. Previously, we would simply divide
each parameter by 100 whenever we forked. After a few forks the values
would reach 0 and tasks would not be considered interactive.
- Add another KTR entry, cleanup some existing entries.
- Remove a useless sched_interact_update() from sched_priority(). This is
already done by the callers that require it.
marcel [Sat, 1 Nov 2003 20:17:11 +0000 (20:17 +0000)]
o Do not define WITH_SYSCONS and WITH_MICE on ia64. We cannot have
a generic kernel with syscons.
o Do not define WITH_SLICES on ia64. We only label because we're
going to create GPT disks.
marcel [Sat, 1 Nov 2003 20:14:06 +0000 (20:14 +0000)]
o Compile-out "wizard" mode on ia64.
o Also allow swap and filesystem partitions outside a freebsd slice.
This is typically the case for GPT.
o Allow chunks of type "whole" to be displayed at the top. This is
to allow a GPT disk to be labeled. We need a slice out of which we
can make partitions, but a GPT disk doesn't have slices. For GPT
disks a chunk of type "whole" can then be used as a placeholder.
alc [Sat, 1 Nov 2003 08:57:26 +0000 (08:57 +0000)]
- Modify swap_pager_copy() and its callers such that the source and
destination objects are locked on entry and exit. Add comments to
the callers noting that the locks can be released by swap_pager_copy().
- Remove several instances of GIANT_REQUIRED.
bde [Sat, 1 Nov 2003 08:43:54 +0000 (08:43 +0000)]
Fixed breakage of my world in rev.1.30. #include <sys/time.h> instead of
depending on namespace pollution in <sys/stat.h> for the declarations of
struct timeval and utimes().
Fixed some style bugs in rev.1.30 and some nearby style bugs (mainly
unsorting and missing or extra blank lines).
Removed a wrong comment that was obtained from NetBSD in rev.1.14. It said
that chflags() reset the times that were set "above" by utimes(), but
utimes wasn't "above" in FreeBSD until rev.1.30, and chflags() does't
actually reset the times.
silby [Sat, 1 Nov 2003 07:30:08 +0000 (07:30 +0000)]
- Add a new function tcp_twrecycleable, which tells us if the ISN which
we will generate for a given ip/port tuple has advanced far enough
for the time_wait socket in question to be safely recycled.
- Have in_pcblookup_local use tcp_twrecycleable to determine if
time_Wait sockets which are hogging local ports can be safely
freed.
This change preserves proper TIME_WAIT behavior under normal
circumstances while allowing for safe and fast recycling whenever
ephemeral port space is scarce.
tjr [Sat, 1 Nov 2003 05:13:13 +0000 (05:13 +0000)]
Allow mbrtowc() and wcrtomb() to be implemented directly, instead of
as wrappers around the deprecated 4.4BSD rune functions. This paves the
way for state-dependent encodings, which the rune API does not support.
- Add __emulated_sgetrune() and __emulated_sputrune(), which are
implementations of sgetrune() and sputrune() in terms of
mbrtowc() and wcrtomb().
- Rename the old rune-wrapper mbrtowc() and wcrtomb() functions to
__emulated_mbrtowc() and __emulated_wcrtomb().
- Add __mbrtowc and __wcrtomb function pointers, which point to the
current locale's conversion functions, or the __emulated versions.
- Implement mbrtowc() and wcrtomb() as calls to these function pointers.
- Make the "NONE" encoding implement mbrtowc() and wcrtomb() directly.
All of this emulation mess will be removed, together with rune support,
in FreeBSD 6.
bmah [Sat, 1 Nov 2003 04:41:32 +0000 (04:41 +0000)]
More trimming of specific device instances from the hardware notes to
reduce duplication of information from the manual pages: xl(4), cs(4),
ath(4), sbni(4), lmc(4).
sam [Sat, 1 Nov 2003 03:19:51 +0000 (03:19 +0000)]
Version 0.9.5.17:
o change os glue API to be compatible with Linux so hal.o's can
be used on any system
o add ABI version to catch driver-HAL mismatches
o move hal version information from ah_osdep.c to binary component
o remove ath_hal_wait os glue component
o assign constant values to all enums to avoid potential compiler
incompatibilities
o add support for 3Com badged cards (PCI vendor ID)
o add support for IBM mini-pci cards (PCI device ID)
o expose MAC, PHY, and radio hardware revisions
o support for big-endian platforms
o new method to set slot time in us
o bug fix for 5211: beacon timers not setup correctly
o bug fix for 5212: don't crash when handed a 5112 radio
tjr [Sat, 1 Nov 2003 02:06:02 +0000 (02:06 +0000)]
Copy cur's snap_time to last when refreshing statistics. Fixes problem
where MB/s and tps statistics would always be zero, presumably because
they were being averaged out over the time between now and when the
system booted instead of a few seconds.
jhb [Fri, 31 Oct 2003 21:02:04 +0000 (21:02 +0000)]
For physical address regions between 0 and KERNLOAD, allow pmap_mapdev()
to use the direct mapped KVA at KERNBASE to service the request. This also
allows pmap_mapdev() to be used for such addresses very early during the
boot process and might provide some small savings on KVA.
alc [Fri, 31 Oct 2003 20:17:00 +0000 (20:17 +0000)]
- Revert a part of revision 1.73: Make vm_object_set_flag() an inline
function. This function is so trivial that inlining reduces the size
of the kernel.
brooks [Fri, 31 Oct 2003 18:32:15 +0000 (18:32 +0000)]
Replace the if_name and if_unit members of struct ifnet with new members
if_xname, if_dname, and if_dunit. if_xname is the name of the interface
and if_dname/unit are the driver name and instance.
This change paves the way for interface renaming and enhanced pseudo
device creation and configuration symantics.
Approved By: re (in principle)
Reviewed By: njl, imp
Tested On: i386, amd64, sparc64
Obtained From: NetBSD (if_xname)
alc [Fri, 31 Oct 2003 18:32:03 +0000 (18:32 +0000)]
- Take advantage of the swap pager locking: Eliminate the use of Giant
from vm_object_madvise().
- Remove excessive blank lines from vm_object_madvise().
bmah [Fri, 31 Oct 2003 16:58:43 +0000 (16:58 +0000)]
A grab bag of new (but overdue) release note items: dcons(4) and
friends, Pentium 4 and related workarounds, some MPSAFE network
drivers, IPv6 supports RFC 3542 (Advanced Sockets API), ifconfig(8)
staticarp, libkse default threading library for ia64.
ume [Fri, 31 Oct 2003 16:21:26 +0000 (16:21 +0000)]
(icmp6_rip6_input) if the received data is small enough but in an
mbuf cluster, copy the data to a separate mbuf that do not use a
cluster. this change will reduce the possiblity of packet loss
in the socket layer.
harti [Fri, 31 Oct 2003 13:35:22 +0000 (13:35 +0000)]
Fix breakage on ia64: PAGE_SIZE on ia64 is large enough that more than
256 raw receive buffers (96 byte each) fit into one page. This breaks the
limit imposed by the usage of an uint8_t for the buffer number. Restrict
the allocation size for buffers to a maximum of 8192.
tjr [Fri, 31 Oct 2003 13:29:00 +0000 (13:29 +0000)]
Don't bother passing a freshly-zeroed mbstate to mbsrtowcs() etc.
when the current implementation won't use it, anyway. Just pass NULL.
This will need to be changed when state-dependent encodings are
supported, but there's no need to take the performance hit
in the meantime.
ru [Fri, 31 Oct 2003 13:15:07 +0000 (13:15 +0000)]
Combining "all" and "install" in one invocation is a very bad idea as
conditional evaluation is done only once in this case, and this may
not account for the fact that some conditionals would be evaluated
differently if "all" has already been run, like is the case with the
loader.help existance check in sys/boot/alpha/common/Makefile.common,
beforeinstall target. This should fix Alpha snapshot builds.