]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
19 years agoRemove an unused field from the struct pv_entry.
cognet [Sun, 5 Dec 2004 22:46:30 +0000 (22:46 +0000)]
Remove an unused field from the struct pv_entry.
While I'm there, fix style.

19 years agoVFS_STATFS(mp, ...) is mostly called with &mp->mnt_stat, but a few cases
phk [Sun, 5 Dec 2004 22:41:02 +0000 (22:41 +0000)]
VFS_STATFS(mp, ...) is mostly called with &mp->mnt_stat, but a few cases
doesn't.  Most of the implementations have grown weeds for this so they
copy some fields from mnt_stat if the passed argument isn't that.

Fix this the cleaner way:  Always call the implementation on mnt_stat
and copy that in toto to the VFS_STATFS argument if different.

19 years agoFix null-pointer indirect function calls introduced in the previous
marcel [Sun, 5 Dec 2004 22:30:28 +0000 (22:30 +0000)]
Fix null-pointer indirect function calls introduced in the previous
commit. In the new world order, the transitive closure on the vector
operations is not precomputed. As such, it's unsafe to actually use
any of the function pointers in an indirect function call. They can
be null, and we need to use the default vector in that case.
This is mostly a quick fix for the four function pointers that are
ed explicitly. A more generic or scalable solution is likely to see
the light of day.

No pathos on: current@

19 years agoAssert inpcb lock in:
rwatson [Sun, 5 Dec 2004 22:27:53 +0000 (22:27 +0000)]
Assert inpcb lock in:

  tcpip_fillheaders()
  tcp_discardcb()
  tcp_close()
  tcp_notify()
  tcp_new_isn()
  tcp_xmit_bandwidth_limit()

Fix a locking comment in tcp_twstart(): the pcbinfo will be locked (and
is asserted).

MFC after: 2 weeks

19 years agoMinor grammer fix in comment.
rwatson [Sun, 5 Dec 2004 22:20:59 +0000 (22:20 +0000)]
Minor grammer fix in comment.

19 years agoPass the inpcb reference into ip_getmoptions() rather than just the
rwatson [Sun, 5 Dec 2004 22:08:37 +0000 (22:08 +0000)]
Pass the inpcb reference into ip_getmoptions() rather than just the
inp->inp_moptions pointer, so that ip_getmoptions() can perform
necessary locking when doing non-atomic reads.

Lock the inpcb by default to copy any data to local variables, then
unlock before performing sooptcopyout().

MFC after: 2 weeks

19 years agoDefine INP_UNLOCK_ASSERT() to assert that an inpcb is unlocked.
rwatson [Sun, 5 Dec 2004 22:07:14 +0000 (22:07 +0000)]
Define INP_UNLOCK_ASSERT() to assert that an inpcb is unlocked.

MFC after: 2 weeks

19 years agoCorrect a sanity check in vnode_pager_generic_putpages(). The cast used
alc [Sun, 5 Dec 2004 21:48:11 +0000 (21:48 +0000)]
Correct a sanity check in vnode_pager_generic_putpages().  The cast used
to implement the sanity check should have been changed when we converted
the implementation of vm_pindex_t from 32 to 64 bits.  (Thus, RELENG_4 is
not affected.)  The consequence of this error would be a legimate write to
an extremely large file being treated as an errant attempt to write meta-
data.

Discussed with: tegge@

19 years ago'all' argument for list_net_interfaces() is now unused, remove it.
pjd [Sun, 5 Dec 2004 21:45:36 +0000 (21:45 +0000)]
'all' argument for list_net_interfaces() is now unused, remove it.

19 years agoPush the inpcb argument into ip_setmoptions() when setting IP multicast
rwatson [Sun, 5 Dec 2004 21:38:33 +0000 (21:38 +0000)]
Push the inpcb argument into ip_setmoptions() when setting IP multicast
socket options, so that it is available for locking.

19 years agoMake sure the first argument to the user function is 16-byte aligned.
deischen [Sun, 5 Dec 2004 21:22:08 +0000 (21:22 +0000)]
Make sure the first argument to the user function is 16-byte aligned.

Submitted by: tegge

19 years agoWhen panicing in device_unbusy(), actually tell what device has the issue.
obrien [Sun, 5 Dec 2004 20:58:56 +0000 (20:58 +0000)]
When panicing in device_unbusy(), actually tell what device has the issue.

19 years agoForced commit to note that the previous revision, 1.233, should be:
rwatson [Sun, 5 Dec 2004 19:12:06 +0000 (19:12 +0000)]
Forced commit to note that the previous revision, 1.233, should be:

MFC after: 2 weeks

19 years agoStart working through inpcb locking for ip_ctloutput() by cleaning up
rwatson [Sun, 5 Dec 2004 19:11:09 +0000 (19:11 +0000)]
Start working through inpcb locking for ip_ctloutput() by cleaning up
modifications to the inpcb IP options mbuf:

- Lock the inpcb before passing it into ip_pcbopts() in order to prevent
  simulatenous reads and read-modify-writes that could result in races.
- Pass the inpcb reference into ip_pcbopts() instead of the option chain
  pointer in the inpcb.
- Assert the inpcb lock in ip_pcbots.
- Convert one or two uses of a pointer as a boolean or an integer
  comparison to a comparison with NULL for readability.

19 years ago- Use uint16_t to pass argument for NGM_NETFLOW_IFINFO, bump cookie.
glebius [Sun, 5 Dec 2004 14:30:38 +0000 (14:30 +0000)]
- Use uint16_t to pass argument for NGM_NETFLOW_IFINFO, bump cookie.
- Always check that index number passed from userland
  is <= NG_NETFLOW_MAXIFACES. [1]
- Increase NG_NETFLOW_MAXIFACES up to 512. [2]

Noticed by: Roman Palagin [1]
Requested by: Yuri Y. Bushmelev [2]
MFC after: 1 week

19 years agoShow divert(4) sockets as well.
ru [Sun, 5 Dec 2004 14:17:14 +0000 (14:17 +0000)]
Show divert(4) sockets as well.

19 years agoCorrect a misspelling in a comment.
rwatson [Sun, 5 Dec 2004 13:28:52 +0000 (13:28 +0000)]
Correct a misspelling in a comment.

19 years agoAcquire socket receive buffer mutex before appending and then waking up
rwatson [Sun, 5 Dec 2004 13:27:30 +0000 (13:27 +0000)]
Acquire socket receive buffer mutex before appending and then waking up
a receive socket in DDP.  This reduces the number of mutex operations
required to deliver to a socket by two, and is the model used in other
protocols.

19 years agoDDB_UNATTENDED is now called KDB_UNATTENDED.
simon [Sun, 5 Dec 2004 12:48:07 +0000 (12:48 +0000)]
DDB_UNATTENDED is now called KDB_UNATTENDED.

MFC after: 3 days

19 years agoIPv6 packets can contain headers (like options) before the TCP/UDP/ICMP6
dhartmei [Sun, 5 Dec 2004 12:15:43 +0000 (12:15 +0000)]
IPv6 packets can contain headers (like options) before the TCP/UDP/ICMP6
header. pf finds the first TCP/UDP/ICMP6 header to filter by traversing
the header chain. In the case where headers are skipped, the protocol
checksum verification used the wrong length (included the skipped headers),
leading to incorrectly mismatching checksums. Such IPv6 packets with
headers were silently dropped.

Discovered by: Bernhard Schmidt
MFC after: 1 week

19 years agoUse "ifconfig -l" instead of "list_network_interfaces all" in
rse [Sun, 5 Dec 2004 09:51:48 +0000 (09:51 +0000)]
Use "ifconfig -l" instead of "list_network_interfaces all" in
ifnet_rename() to support situations where rc.conf's $network_interfaces
variable is set to an explicit list of network interfaces (instead of
the default "auto").

Using "list_network_interfaces all" resulted in using
$network_interfaces for both interface _renaming_ and interface
_configuration_ which obviously cannot work either before (if the
new name is in $network_interfaces) or after (if the old name is in
$network_interfaces) renaming the interface.

19 years agofix typo: s/intefraces/interfaces/
rse [Sun, 5 Dec 2004 09:01:20 +0000 (09:01 +0000)]
fix typo: s/intefraces/interfaces/

19 years agoStart to add GIANT_REQUIRED; macros in places where giant is required
imp [Sun, 5 Dec 2004 07:55:30 +0000 (07:55 +0000)]
Start to add GIANT_REQUIRED; macros in places where giant is required
and that I've verified things seem to basically work.  I was able to
boot and hot plug usb devices.  Please let me know if this causes
problems for anybody.

The push down of giant has proceeded to the point that this will start
to matter more and more.

19 years agoSource changes to allow building a cross-debugger. Move solib.c and
marcel [Sun, 5 Dec 2004 06:59:01 +0000 (06:59 +0000)]
Source changes to allow building a cross-debugger. Move solib.c and
solib-svr4.c to the MD makefiles because they are native files for
alpha and sparc64, but target files for amd64, i386 and ia64.

Note that kgdb(1) does not yet build as a cross-debugger due to
libkvm.

19 years agoo Don't limit GPT as a rank 2 provider. Allow it to be connected
marcel [Sun, 5 Dec 2004 06:02:21 +0000 (06:02 +0000)]
o  Don't limit GPT as a rank 2 provider. Allow it to be connected
   anywhere in the DAG. This includes configurations that are not
   allowed by the EFI specification.
o  Reject a GPT partition table if it's not preceeded by a PMBR.
   There's no need to preserve the MBR partitioning anymore as GPT
   is mature and with the first bullet extending the applicability
   of GPT, it's better to be a bit more strict.

19 years agoNow as a full blown port.
obrien [Sun, 5 Dec 2004 04:16:36 +0000 (04:16 +0000)]
Now as a full blown port.

19 years agoFix previous commit. GDB_CROSS_DEBUGGER needs to be defined for all
marcel [Sun, 5 Dec 2004 04:08:22 +0000 (04:08 +0000)]
Fix previous commit. GDB_CROSS_DEBUGGER needs to be defined for all
subdirectories.

19 years agoGrab Giant around calls to DEVICE_SUSPEND/RESUME in acpi_SetSleepState().
njl [Sun, 5 Dec 2004 01:35:18 +0000 (01:35 +0000)]
Grab Giant around calls to DEVICE_SUSPEND/RESUME in acpi_SetSleepState().
If we are resuming non-MPSAFE drivers, they need Giant held for them.
This may fix some obscure suspend/resume problems.  It has fixed keyrate
setting problems that were triggered by cardbus (MPSAFE) changing the
ordering for syscons resume (non-MPSAFE).  Also, add some asserts that
Giant is held in our suspend/resume and shutdown methods.

Found by: iedowse
MFC after: 2 days

19 years agoAdd more frequently-used locale directories. This is in preparation
kris [Sat, 4 Dec 2004 23:30:36 +0000 (23:30 +0000)]
Add more frequently-used locale directories.  This is in preparation
for cleanup of pkg-plist files with respect to handling of the share/locale
subdirectories.

MFC after: 3 days

19 years agoDocument ACPI tunable hw.acpi.serialize_methods.
marks [Sat, 4 Dec 2004 23:26:46 +0000 (23:26 +0000)]
Document ACPI tunable hw.acpi.serialize_methods.
Also reorder tunables.

Approved by: njl
MFC after: 1 week

19 years agoReplace (inlined) pmap_pte() calls with smaller, faster code where
alc [Sat, 4 Dec 2004 22:02:31 +0000 (22:02 +0000)]
Replace (inlined) pmap_pte() calls with smaller, faster code where
possible, such as the inner loop of pmap_copy().

Remove two comments that apply to i386 but not amd64.

19 years agoWhen initializing device, set d_softc and d_no fields for all components,
pjd [Sat, 4 Dec 2004 21:20:59 +0000 (21:20 +0000)]
When initializing device, set d_softc and d_no fields for all components,
because we know it then and we need it when inserting a component which
wasn't destroyed while device was running.

Reported by: Michael Handler <handler@grendel.net>
MFC after: 1 week

19 years ago- Change license to standard 2 clause BSD. [1]
simon [Sat, 4 Dec 2004 19:01:20 +0000 (19:01 +0000)]
- Change license to standard 2 clause BSD. [1]
- Add a missing period.

Noticed by: ru
Approved by: Jorge Mario G. Mazo <jgutie11@eafit.edu.co> [1]

19 years agoRevert rev. 1.166 and remove sparc64/pci/ofw_pci_if.m from MFILES again,
marius [Sat, 4 Dec 2004 14:20:56 +0000 (14:20 +0000)]
Revert rev. 1.166 and remove sparc64/pci/ofw_pci_if.m from MFILES again,
sparc64/pci/ofw_pci.h is no longer required for compiling modules.

19 years agoCatch up with the new device name of sab(4). The entries for tty[a,b]
marius [Sat, 4 Dec 2004 14:03:45 +0000 (14:03 +0000)]
Catch up with the new device name of sab(4). The entries for tty[a,b]
can't be removed as ofw_console(4) and zs(4) use them so one has to
live with some complaints about non-existent devices at boot time and
remove the respective entries locally for now.

19 years agoRemove #if 0'ed rootfs mounting code.
phk [Sat, 4 Dec 2004 09:58:20 +0000 (09:58 +0000)]
Remove #if 0'ed rootfs mounting code.

19 years agoRemove embryonic rootfs mounting facility.
phk [Sat, 4 Dec 2004 09:57:38 +0000 (09:57 +0000)]
Remove embryonic rootfs mounting facility.

In the near future rootfs mounting will not require special handling
in the filesystems.

19 years agoReplace GNU tar with BSD tar.
obrien [Sat, 4 Dec 2004 08:24:36 +0000 (08:24 +0000)]
Replace GNU tar with BSD tar.

19 years agokmod.mk knows how to create empty opt_*.h files so let it deal with the
brooks [Fri, 3 Dec 2004 23:43:02 +0000 (23:43 +0000)]
kmod.mk knows how to create empty opt_*.h files so let it deal with the
NOINET6 case.

Reported by: ru

19 years agoImplement a function, mount_arg() for accumulating a list of mount parameters
phk [Fri, 3 Dec 2004 22:38:06 +0000 (22:38 +0000)]
Implement a function, mount_arg() for accumulating a list of mount parameters
to nmount.

Make kernel_mount() accept the output from mount_arg() and know how to
free the malloc'ed space.

Make kernel_vmount() use the new function.

19 years agoSort and wash #includes.
phk [Fri, 3 Dec 2004 21:29:25 +0000 (21:29 +0000)]
Sort and wash #includes.

19 years agoWhen omount() is called, check if the filesystem have a cmount method
phk [Fri, 3 Dec 2004 21:14:46 +0000 (21:14 +0000)]
When omount() is called, check if the filesystem have a cmount method
and if so call it.

The cmount method will gather and interpret omount() style arguments,
and issue a kern_[v]mount() call to execute the corresponding nmount
operation.

19 years agotypo in comment.
phk [Fri, 3 Dec 2004 20:36:55 +0000 (20:36 +0000)]
typo in comment.

19 years agoAdd vfs_cmount() method to vfs_ops, this is to convert old-style mount
phk [Fri, 3 Dec 2004 19:33:19 +0000 (19:33 +0000)]
Add vfs_cmount() method to vfs_ops, this is to convert old-style mount
args to nmount request.

19 years agoAdd early checks for MNT_ROOTFS since we need to allow it later on in
phk [Fri, 3 Dec 2004 19:25:44 +0000 (19:25 +0000)]
Add early checks for MNT_ROOTFS since we need to allow it later on in
the code path.

19 years agoRetire unused vfs_mount() function in the name of nmount migration.
phk [Fri, 3 Dec 2004 18:40:58 +0000 (18:40 +0000)]
Retire unused vfs_mount() function in the name of nmount migration.

19 years ago- Simplify pcn_probe() by moving vendor/device matching code to pcn_match().
mdodd [Fri, 3 Dec 2004 18:35:00 +0000 (18:35 +0000)]
- Simplify pcn_probe() by moving vendor/device matching code to pcn_match().
- Avoid LOR in pcn_probe() by removing useless mutex stuff.

19 years ago- Move chip ID code into separate function.
mdodd [Fri, 3 Dec 2004 18:21:30 +0000 (18:21 +0000)]
- Move chip ID code into separate function.
- Initialize sc->pcn_type during ATTACH as softc contents may not surivive
  from PROBE.
- Print out chip-id to assist with ongoing pcn(4) debugging efforts.

19 years agoDo not blindly pass linux filesystem specific mount data across.
phk [Fri, 3 Dec 2004 18:14:22 +0000 (18:14 +0000)]
Do not blindly pass linux filesystem specific mount data across.

19 years agoDon not call pp_down()/pp_up() form XX_tlf()/XX_tls() in non PPP mode
rik [Fri, 3 Dec 2004 16:57:15 +0000 (16:57 +0000)]
Don not call pp_down()/pp_up() form XX_tlf()/XX_tls() in non PPP mode
to privent running of PPP's state machine in non PPP mode.

MFC: after 3 days.

19 years agoAdditional register definitions.
mdodd [Fri, 3 Dec 2004 16:45:11 +0000 (16:45 +0000)]
Additional register definitions.

Obtained from:  NetBSD

19 years agoIntroduce vfs_byname_kld() which will try to load the filesystem
phk [Fri, 3 Dec 2004 16:11:01 +0000 (16:11 +0000)]
Introduce vfs_byname_kld() which will try to load the filesystem
as a module if possible.

Use it so we don't have linker magic in the middle of the already
complex mount code.

19 years agoFix description: the argument to setcontext(3) must have been previously
rse [Fri, 3 Dec 2004 14:10:04 +0000 (14:10 +0000)]
Fix description: the argument to setcontext(3) must have been previously
initialized "by a call to getcontext(3) or makecontext(3)" and not "by a
call to setcontext(3) or makecontext(3)".

MFC after: 3 days

19 years agoAdd a manual page for the kernel's EVENTHANDLER facility.
jkoshy [Fri, 3 Dec 2004 14:05:55 +0000 (14:05 +0000)]
Add a manual page for the kernel's EVENTHANDLER facility.

Reviewed by: ru

19 years agoRemove an extra space.
harti [Fri, 3 Dec 2004 13:03:16 +0000 (13:03 +0000)]
Remove an extra space.

Submitted by: ru

19 years agoFix breakage introduced on 64-bit platforms with my last commit. Need
harti [Fri, 3 Dec 2004 12:55:57 +0000 (12:55 +0000)]
Fix breakage introduced on 64-bit platforms with my last commit. Need
to change to size_t in a couple of other places too.

19 years agoMake NAMEI_DIAGNOSTIC compile again and add a stragic vprint()
phk [Fri, 3 Dec 2004 12:15:39 +0000 (12:15 +0000)]
Make NAMEI_DIAGNOSTIC compile again and add a stragic vprint()

19 years agoImprove vprint() a little bit: break long lines, reduce indent and tell
phk [Fri, 3 Dec 2004 12:09:34 +0000 (12:09 +0000)]
Improve vprint() a little bit:  break long lines, reduce indent and tell
if the VI_LOCK() is held.

19 years agoPlug a memory leak.
harti [Fri, 3 Dec 2004 12:07:03 +0000 (12:07 +0000)]
Plug a memory leak.

19 years agoPut macro arguments in paranthesis.
harti [Fri, 3 Dec 2004 12:02:14 +0000 (12:02 +0000)]
Put macro arguments in paranthesis.

Submitted by: johan

19 years agoMake sizes to be of type size_t and correct function arguments that
harti [Fri, 3 Dec 2004 11:59:30 +0000 (11:59 +0000)]
Make sizes to be of type size_t and correct function arguments that
should be Byte (as the numerous casts to Byte in the function calls show).

19 years agoAdd missing vop_bypass (returning EOPNOTSUPP).
phk [Fri, 3 Dec 2004 08:56:30 +0000 (08:56 +0000)]
Add missing vop_bypass (returning EOPNOTSUPP).

Tripped up: marks

19 years agoACPI is not on pc98 either.
njl [Fri, 3 Dec 2004 08:44:56 +0000 (08:44 +0000)]
ACPI is not on pc98 either.

Informed by: nyan

19 years agoStyle: fix indentation, protect macro with do { } while (0).
harti [Fri, 3 Dec 2004 08:43:07 +0000 (08:43 +0000)]
Style: fix indentation, protect macro with do { } while (0).

Checked with: diff on object file.

19 years agoNon-x86 platforms cannot use the ACPI includes. This should be fixed but
njl [Fri, 3 Dec 2004 08:13:08 +0000 (08:13 +0000)]
Non-x86 platforms cannot use the ACPI includes.  This should be fixed but
for now, only include the headers for i386, amd64, or ia64.

Pointed out by: grehan

19 years agoDescribe the .SHELL target.
harti [Fri, 3 Dec 2004 08:03:11 +0000 (08:03 +0000)]
Describe the .SHELL target.

Reviewed by: ru

19 years agoChange the algorithm that matches the builtin shells from the name keyword
harti [Fri, 3 Dec 2004 08:02:52 +0000 (08:02 +0000)]
Change the algorithm that matches the builtin shells from the name keyword
of the .SHELL target. Formerly it used to select the shell with the
longest common trailing substring, so that bash would select sh, but pocsh
would select csh. Now an exact match is required so that specifying bash
without also giving a path and the other keywords will give an error.

PR:
Submitted by:
Reviewed by: ru
Approved by:
Obtained from:
MFC after:

19 years agoEnable the relaxed behavior for op regions and other workarounds for
njl [Fri, 3 Dec 2004 08:01:09 +0000 (08:01 +0000)]
Enable the relaxed behavior for op regions and other workarounds for
non-standard BIOSen.  We used to implement this in local patches but
now that ACPI-CA has merged/re-implemented most of our fixes, they were
no longer needed and we just needed to turn this knob on.  Also, remove
an unnecessary cast.

Tested by: phk

19 years agoAdd myself to the committers' birthday calendar
dumbbell [Fri, 3 Dec 2004 01:41:55 +0000 (01:41 +0000)]
Add myself to the committers' birthday calendar

Reviewed by: mux

19 years agoInclude <sys/signalvar.h> for trapsignal().
cognet [Thu, 2 Dec 2004 23:31:48 +0000 (23:31 +0000)]
Include <sys/signalvar.h> for trapsignal().

19 years agoClarify the structure element size ordering.
dds [Thu, 2 Dec 2004 23:20:17 +0000 (23:20 +0000)]
Clarify the structure element size ordering.

Obtained from: OpenBSD style.9 1.38

19 years agoFix import conflicts from tzdata2004g.
wollman [Thu, 2 Dec 2004 23:01:25 +0000 (23:01 +0000)]
Fix import conflicts from tzdata2004g.

Obtained from: ftp://elsie.nci.nih.gov/pub/tzdata2004g.tar.gz

19 years agoMake the tests runnable on a read-only src. To do this you must make sure
harti [Thu, 2 Dec 2004 17:00:58 +0000 (17:00 +0000)]
Make the tests runnable on a read-only src. To do this you must make sure
that you create one of the object directories make knows (see make(1)).
This uses the -C flag, so add a test that checks that make actually accepts
-C. Also fix the test that selects csh via the .SHELL target to work for
tcsh users too.

This commit renames shell_test to shell_test.sh. There is no history
to preserve so go without a repo-copy.

Reviewed by: ru

19 years agoAm I smoking crack? Correct stupid, wrong ASSERT -> if conversion and make
mlaier [Thu, 2 Dec 2004 15:47:15 +0000 (15:47 +0000)]
Am I smoking crack? Correct stupid, wrong ASSERT -> if conversion and make
it do what I had in mind.

Noticed by: glebius
Pointyhat to: me, myself and mlaier

19 years agoo Do not dump core in -W if dumpdates was not readable and ddatev == NULL.
maxim [Thu, 2 Dec 2004 13:56:53 +0000 (13:56 +0000)]
o Do not dump core in -W if dumpdates was not readable and ddatev == NULL.

PR: bin/69977

o Remove unused ddates_in.

Obtained from: NetBSD
MFC after: 3 weeks

19 years agoo Add a missed "." .
maxim [Thu, 2 Dec 2004 13:13:27 +0000 (13:13 +0000)]
o Add a missed "." .

Reviewed by: ru
MFC after: 3 weeks

19 years agoo Terminate an endless loop sh -T goes into in dowait() around waitproc().
maxim [Thu, 2 Dec 2004 13:12:43 +0000 (13:12 +0000)]
o Terminate an endless loop sh -T goes into in dowait() around waitproc().

XXX from Tor: "The shell can also go into a similar loop if the child was
killed by signal 127, since the shell would believe the child to have
only stopped (WIFSTOPPED() macro returns nonzero value).  Disallowing
signals 127 and 128 will fix that problem."  See kern/19402 for details.

PR: bin/66242
Submitted by: tegge
Analysis and testcase by: demon
MFC after: 3 weeks

19 years agoDrop ffree() as a separate function and incorporate the only place used.
phk [Thu, 2 Dec 2004 12:17:27 +0000 (12:17 +0000)]
Drop ffree() as a separate function and incorporate the only place used.

19 years agoStyle polishing.
phk [Thu, 2 Dec 2004 11:56:13 +0000 (11:56 +0000)]
Style polishing.

Use grepable functions
Other minor nitpickings.

19 years agoRemove the de_devvp and stop VREF'ing it for every vnode we create.
phk [Thu, 2 Dec 2004 10:09:33 +0000 (10:09 +0000)]
Remove the de_devvp and stop VREF'ing it for every vnode we create.

19 years agoSpecifically use the 32-bit version of fuword/suword since that's what
obrien [Thu, 2 Dec 2004 09:38:34 +0000 (09:38 +0000)]
Specifically use the 32-bit version of fuword/suword since that's what
we really want vs. the size changing 'long' (i386 vs. AMD64).
This fixes the problem with DRM with Radeon's on AMD64.

Submitted by: Jung-uk Kim <jkim@niksun.com>

19 years agoTurn ACPI and PCI devices off or to a lower power state in suspend and
njl [Thu, 2 Dec 2004 08:07:12 +0000 (08:07 +0000)]
Turn ACPI and PCI devices off or to a lower power state in suspend and
back on again in resume.  Override the default of D3 with the value the
BIOS specifies in _SxD, if present.  Skip serial devices (PNP05xx) since
they seem to hang when set to D3 and may require special driver support.
Also, skip non-type 0 PCI devices (i.e., bridges) since our we don't yet
save/restore their config space and that seems to be necessary.

If this gives you trouble with suspend/resume, you can disable the new
ACPI and PCI power behavior separately with these tunables & sysctls:
    debug.acpi.do_powerstate
    hw.pci.do_powerstate

Approved by: imp (pci)
Tested by: acpi@ (numerous)

19 years agoAdd the ACPI_PWR_FOR_SLEEP method. It takes a device and outputs the
njl [Thu, 2 Dec 2004 08:04:57 +0000 (08:04 +0000)]
Add the ACPI_PWR_FOR_SLEEP method.  It takes a device and outputs the
appropriate power (Dx) state, if the BIOS suggests one.

MFC after: 3 weeks

19 years agoFor efficiency eliminate the call to pmap_pte() from pmap_protect()'s and
alc [Thu, 2 Dec 2004 04:06:40 +0000 (04:06 +0000)]
For efficiency eliminate the call to pmap_pte() from pmap_protect()'s and
pmap_remove()'s inner loop.  Instead, call pmap_pde_to_pte(), a new
function, prior to the inner loop.

Reviewed by: peter@, tegge@

19 years agoFor efficiency move the call to pmap_pte_quick() out of pmap_protect()'s
alc [Thu, 2 Dec 2004 03:29:17 +0000 (03:29 +0000)]
For efficiency move the call to pmap_pte_quick() out of pmap_protect()'s
and pmap_remove()'s inner loop.

Reviewed by: peter@, tegge@

19 years agoCatch up with AcpiOsSleep() interface change.
marks [Thu, 2 Dec 2004 00:25:35 +0000 (00:25 +0000)]
Catch up with AcpiOsSleep() interface change.
Catch up with some #define's renaming.
Implement AcpiOsGetTimer() as per ACPI 3.0.

Approved by: njl
MFC after: 1 week

19 years agoThis commit was generated by cvs2svn to compensate for changes in r138298,
marks [Thu, 2 Dec 2004 00:12:19 +0000 (00:12 +0000)]
This commit was generated by cvs2svn to compensate for changes in r138298,
which included commits to RCS files with non-trunk default branches.

19 years agoOops, remove unnecessary cast in original, out-commented code.
marks [Thu, 2 Dec 2004 00:12:19 +0000 (00:12 +0000)]
Oops, remove unnecessary cast in original, out-commented code.
This was a debug leftover.

MFC after: 1 week

19 years agoThis commit was generated by cvs2svn to compensate for changes in r138296,
marks [Thu, 2 Dec 2004 00:05:02 +0000 (00:05 +0000)]
This commit was generated by cvs2svn to compensate for changes in r138296,
which included commits to RCS files with non-trunk default branches.

19 years agoLocal change: Supporting code not yet available, use previous behavior
marks [Thu, 2 Dec 2004 00:05:02 +0000 (00:05 +0000)]
Local change: Supporting code not yet available, use previous behavior
instead for the time being. Intel should fix this.

Note that if this commit is correct, it is made on the vendor branch.
We expect the Intel folks to fix it, and we don't want to unnecessarily
take files off the vendor branch.

Approved by: njl
MFC after: 1 week

19 years agoLocal change: Remove warnings from vendor files.
marks [Wed, 1 Dec 2004 23:42:21 +0000 (23:42 +0000)]
Local change: Remove warnings from vendor files.

Approved by: njl
MFC after: 1 week

19 years agoLocal change: In the resume path, give up after waiting for a while
marks [Wed, 1 Dec 2004 23:40:48 +0000 (23:40 +0000)]
Local change:  In the resume path, give up after waiting for a while
for WAK_STS to be set.  Some BIOSs never set it.

Approved by: njl
MFC after: 1 week

19 years agoLocal change: Put various debugging options under ACPI_DISASSEMBLER.
marks [Wed, 1 Dec 2004 23:39:45 +0000 (23:39 +0000)]
Local change:  Put various debugging options under ACPI_DISASSEMBLER.

Approved by: njl
MFC after: 1 week

19 years agoUnchanged files that are off the vendor branch.
marks [Wed, 1 Dec 2004 23:34:39 +0000 (23:34 +0000)]
Unchanged files that are off the vendor branch.

Approved by: njl
MFC after: 1 week

19 years agoDo not leave build droppings in /usr/src for usr.sbin/pcvt/keycap and
peter [Wed, 1 Dec 2004 23:23:14 +0000 (23:23 +0000)]
Do not leave build droppings in /usr/src for usr.sbin/pcvt/keycap and
usr.bin/lex/lib for the 32 bit libraries on amd64.  Add an explicit
obj for these two directories that are built in for the "libraries" target.

19 years agoBack when VOP_* was introduced, we did not have new-style struct
phk [Wed, 1 Dec 2004 23:16:38 +0000 (23:16 +0000)]
Back when VOP_* was introduced, we did not have new-style struct
initializations but we did have lofty goals and big ideals.

Adjust to more contemporary circumstances and gain type checking.

Replace the entire vop_t frobbing thing with properly typed
structures.  The only casualty is that we can not add a new
VOP_ method with a loadable module.  History has not given
us reason to belive this would ever be feasible in the the
first place.

Eliminate in toto VOCALL(), vop_t, VNODEOP_SET() etc.

Give coda correct prototypes and function definitions for
all vop_()s.

Generate a bit more data from the vnode_if.src file:  a
struct vop_vector and protype typedefs for all vop methods.

Add a new vop_bypass() and make vop_default be a pointer
to another struct vop_vector.

Remove a lot of vfs_init since vop_vector is ready to use
from the compiler.

Cast various vop_mumble() to void * with uppercase name,
for instance VOP_PANIC, VOP_NULL etc.

Implement VCALL() by making vdesc_offset the offsetof() the
relevant function pointer in vop_vector.  This is disgusting
but since the code is generated by a script comparatively
safe.  The alternative for nullfs etc. would be much worse.

Fix up all vnode method vectors to remove casts so they
become typesafe.  (The bulk of this is generated by scripts)

19 years agoVendor import of Intel ACPI-CA 20041119
marks [Wed, 1 Dec 2004 23:14:10 +0000 (23:14 +0000)]
Vendor import of Intel ACPI-CA 20041119

19 years agoThis commit was generated by cvs2svn to compensate for changes in r138287,
marks [Wed, 1 Dec 2004 23:14:10 +0000 (23:14 +0000)]
This commit was generated by cvs2svn to compensate for changes in r138287,
which included commits to RCS files with non-trunk default branches.

19 years agoAdd nfs4 to list of net filesystems.
rees [Wed, 1 Dec 2004 22:05:50 +0000 (22:05 +0000)]
Add nfs4 to list of net filesystems.

Approved by: alfred

19 years agodon't confuse NFSMNT_ flags with MNT_ flags in statfs
rees [Wed, 1 Dec 2004 21:47:51 +0000 (21:47 +0000)]
don't confuse NFSMNT_ flags with MNT_ flags in statfs

Approved by: alfred