History log of /freebsd-10.0-release/sys/tools/
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
259065 07-Dec-2013 gjb

- Copy stable/10 (r259064) to releng/10.0 as part of the
10.0-RELEASE cycle.
- Update __FreeBSD_version [1]
- Set branch name to -RC1

[1] 10.0-CURRENT __FreeBSD_version value ended at '55', so
start releng/10.0 at '100' so the branch is started with
a value ending in zero.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


247116 21-Feb-2013 jhb

Further refine the handling of stop signals in the NFS client. The
changes in r246417 were incomplete as they did not add explicit calls to
sigdeferstop() around all the places that previously passed SBDRY to
_sleep(). In addition, nfs_getcacheblk() could trigger a write RPC from
getblk() resulting in sigdeferstop() recursing. Rather than manually
deferring stop signals in specific places, change the VFS_*() and VOP_*()
methods to defer stop signals for filesystems which request this behavior
via a new VFCF_SBDRY flag. Note that this has to be a VFC flag rather than
a MNTK flag so that it works properly with VFS_MOUNT() when the mount is
not yet fully constructed. For now, only the NFS clients are set this new
flag in VFS_SET().

A few other related changes:
- Add an assertion to ensure that TDF_SBDRY doesn't leak to userland.
- When a lookup request uses VOP_READLINK() to follow a symlink, mark
the request as being on behalf of the thread performing the lookup
(cnp_thread) rather than using a NULL thread pointer. This causes
NFS to properly handle signals during this VOP on an interruptible
mount.

PR: kern/176179
Reported by: Russell Cattelan (sigdeferstop() recursion)
Reviewed by: kib
MFC after: 1 month


244765 28-Dec-2012 gonzo

Fix build on ARM (and probably other platforms)


244445 19-Dec-2012 jeff

- Add new machine parsable KTR macros for timing events.
- Use this new format to automatically handle syscalls and VOPs. This
changes the earlier format but is still human readable.

Sponsored by: EMC / Isilon Storage Division


241394 10-Oct-2012 kevlo

Revert previous commit...

Pointyhat to: kevlo (myself)


241370 09-Oct-2012 kevlo

Prefer NULL over 0 for pointers


231975 21-Feb-2012 trociny

Make vnode_if.awk parse vnode operations with underscores, like VOP_FOO_BAR.

Reviewed by: kib
MFC after: 1 week


227385 09-Nov-2011 ed

Restore the comment that I removed by accident.

The comment still applies to this block of code.


227384 09-Nov-2011 ed

Simplify the code emitted by makeobjops.awk slightly.

Just place the default kobj_method inside the kobjop_desc structure.
There's no need to give these kobj_methods their own symbol. This shaves
off 10 KB of a GENERIC kernel binary.


227343 08-Nov-2011 ed

Make kobj_methods constant.

These structures hold no information that is modified during runtime. By
marking this constant, we see approximately 600 symbols become
read-only (amd64 GENERIC). While there, also mark the kobj_method
structures generated by makeobjops.awk static. They are only referenced
by the kobjop_desc structures within the same file.

Before:

$ ls -l kernel
-rwxr-xr-x 1 ed wheel 15937309 Nov 8 16:29 kernel*
$ size kernel
text data bss dec hex filename
12260854 1358468 2848832 16468154 fb48ba kernel
$ nm kernel | fgrep -c ' r '
8240

After:

$ ls -l kernel
-rwxr-xr-x 1 ed wheel 15922469 Nov 8 16:25 kernel*
$ size kernel
text data bss dec hex filename
12302869 1302660 2848704 16454233 fb1259 kernel
$ nm kernel | fgrep -c ' r '
8838


220227 31-Mar-2011 rstone

GNU awk does not output escaped newlines in multi-line printc statements. This
leads to compile errors when trying to compile firmware(9) stubs created with
gawk, as multiple #include statements end up on the same line. Replace the
multi-line printc statement that outputs all of the #includes with one printc
per #include. This allows modules compatible with firmware(9) to be cross-built
from a Linux machine without requiring the one true awk to be installed.

I've intentionally done the minimal set of changes necessary to make gawk
produce valid (but not pretty) C code, to reduce the churn and keep fw_stubs.awk
as readable as possible.

Approved by: emaste (mentor)
MFC after: 2 weeks


211616 22-Aug-2010 rpaulo

Add an extra comment to the SDT probes definition. This allows us to get
use '-' in probe names, matching the probe names in Solaris.[1]

Add userland SDT probes definitions to sys/sdt.h.

Sponsored by: The FreeBSD Foundation
Discussed with: rwaston [1]


208749 02-Jun-2010 raj

Flattened Device Tree helper scripts.

Reviewed by: imp
Sponsored by: The FreeBSD Foundation


198466 25-Oct-2009 rpaulo

Output a comment on top of each generated file explaining where it came
from.


198374 22-Oct-2009 emaste

Rename default to default_function, for compatibility with GNU awk.
(For cross-compiling out-of-tree kernel modules, for example.)


198277 20-Oct-2009 fjoe

Allow KMOD with hypens and dots.

MFC after: 1 week


195378 05-Jul-2009 ariff

- Increase dynamic range of filter coefficients from 28bit to 30bit.
This cause dramatic effect in overall precision and conversion quality
by pushing down most aliasing artifacts around -180 dB.

Spectrogram analysis/comparison:

http://people.freebsd.org/~ariff/z_comparison/z_28vs30/

- Guard against possible 64bit overflow during accumulation process by
slightly normalize and saturate sample and coefficient multiplication,
possible during extreme 32bit downsampling (eg. 380KHz -> 8KHz) with
custom preset that require more than ~7000 taps filter (which is
overkill).

- Add knobs through FEEDER_RATE_PRESETS to set dynamic range of filter
coefficients/accumulator and prefered polynomial interpolator:

COEFFICIENT_BIT:X
(where 1 <= X <= 30, default: 30)

ACCUMULATOR_BIT:X
(where 32 <= X <=64, default: 58)

INTERPOLATOR:I
(where I = ZOH, LINEAR, QUADRATIC, HERMITE, BSPLINE,
OPT32X, OPT16X, OPT8X, OPT4X, OPT2X)

Approved by: re (kib)


195283 02-Jul-2009 ariff

Slightly increase amount of bandwidth of resampling filter for
feeder_rate_quality=3. This have the benefit of reducing aliasing
artifacts due to alias masking.

Spectrogram analysis:

o Old preset (100:36:0.90)
http://people.freebsd.org/~ariff/z_comparison/z_q3_old.png

o New preset (100:36:0.92):
http://people.freebsd.org/~ariff/z_comparison/z_q3_new.png

Approved by: re (kib)


194233 15-Jun-2009 ariff

- Add a way to change filter oversampling factor through
FEEDER_RATE_PRESET "OVERSAMPLING_FACTOR:X .. .." where
X = log2(oversampling factor).

- Lower down default filter oversampling factor from 128
(log2 = 7) to 32 (log2 = 5), saving worth of 80 Kb.
The use of better polynomial interpolator will raise
its conversion quality/accuracy to match (or slightly
better) with previous settings.

- Bump driver version.


193889 10-Jun-2009 ariff

Move all sound related scripts to its own 'sound' subdir.

Suggested by: jmallett


193640 07-Jun-2009 ariff

Sound Mega-commit. Expect further cleanup until code freeze.

For a slightly thorough explaination, please refer to
[1] http://people.freebsd.org/~ariff/SOUND_4.TXT.html .

Summary of changes includes:

1 Volume Per-Channel (vpc). Provides private / standalone volume control
unique per-stream pcm channel without touching master volume / pcm.
Applications can directly use SNDCTL_DSP_[GET|SET][PLAY|REC]VOL, or for
backwards compatibility, SOUND_MIXER_PCM through the opened dsp device
instead of /dev/mixer. Special "bypass" mode is enabled through
/dev/mixer which will automatically detect if the adjustment is made
through /dev/mixer and forward its request to this private volume
controller. Changes to this volume object will not interfere with
other channels.

Requirements:
- SNDCTL_DSP_[GET|SET][PLAY|REC]_VOL are newer ioctls (OSSv4) which
require specific application modifications (preferred).
- No modifications required for using bypass mode, so applications
like mplayer or xmms should work out of the box.

Kernel hints:
- hint.pcm.%d.vpc (0 = disable vpc).

Kernel sysctls:
- hw.snd.vpc_mixer_bypass (default: 1). Enable or disable /dev/mixer
bypass mode.
- hw.snd.vpc_autoreset (default: 1). By default, closing/opening
/dev/dsp will reset the volume back to 0 db gain/attenuation.
Setting this to 0 will preserve its settings across device
closing/opening.
- hw.snd.vpc_reset (default: 0). Panic/reset button to reset all
volume settings back to 0 db.
- hw.snd.vpc_0db (default: 45). 0 db relative to linear mixer value.

2 High quality fixed-point Bandlimited SINC sampling rate converter,
based on Julius O'Smith's Digital Audio Resampling -
http://ccrma.stanford.edu/~jos/resample/. It includes a filter design
script written in awk (the clumsiest joke I've ever written)
- 100% 32bit fixed-point, 64bit accumulator.
- Possibly among the fastest (if not fastest) of its kind.
- Resampling quality is tunable, either runtime or during kernel
compilation (FEEDER_RATE_PRESETS).
- Quality can be further customized during kernel compilation by
defining FEEDER_RATE_PRESETS in /etc/make.conf.

Kernel sysctls:
- hw.snd.feeder_rate_quality.
0 - Zero-order Hold (ZOH). Fastest, bad quality.
1 - Linear Interpolation (LINEAR). Slightly slower than ZOH,
better quality but still does not eliminate aliasing.
2 - (and above) - Sinc Interpolation(SINC). Best quality. SINC
quality always start from 2 and above.

Rough quality comparisons:
- http://people.freebsd.org/~ariff/z_comparison/

3 Bit-perfect mode. Bypasses all feeder/dsp effects. Pure sound will be
directly fed into the hardware.

4 Parametric (compile time) Software Equalizer (Bass/Treble mixer). Can
be customized by defining FEEDER_EQ_PRESETS in /etc/make.conf.

5 Transparent/Adaptive Virtual Channel. Now you don't have to disable
vchans in order to make digital format pass through. It also makes
vchans more dynamic by choosing a better format/rate among all the
concurrent streams, which means that dev.pcm.X.play.vchanformat/rate
becomes sort of optional.

6 Exclusive Stream, with special open() mode O_EXCL. This will "mute"
other concurrent vchan streams and only allow a single channel with
O_EXCL set to keep producing sound.

Other Changes:
* most feeder_* stuffs are compilable in userland. Let's not
speculate whether we should go all out for it (save that for
FreeBSD 16.0-RELEASE).
* kobj signature fixups, thanks to Andriy Gapon <avg@freebsd.org>
* pull out channel mixing logic out of vchan.c and create its own
feeder_mixer for world justice.
* various refactoring here and there, for good or bad.
* activation of few more OSSv4 ioctls() (see [1] above).
* opt_snd.h for possible compile time configuration:
(mostly for debugging purposes, don't try these at home)
SND_DEBUG
SND_DIAGNOSTIC
SND_FEEDER_MULTIFORMAT
SND_FEEDER_FULL_MULTIFORMAT
SND_FEEDER_RATE_HP
SND_PCM_64
SND_OLDSTEREO

Manual page updates are on the way.

Tested by: joel, Olivier SMEDTS <olivier at gid0 d org>, too many
unsung / unnamed heroes.


190518 29-Mar-2009 rwatson

Add SDT DTrace probes for VFS vnode operations in the vfs:vop
provider namespace. These are inserted dynamically into the
VOP_..._AP() functions created from vnode_if.src. Each VOP has
entry and return probes, as arg0 the primary vnode, arg1 the
vnode operation argument structure pointer, providing access to
IN and OUT arguments, and for return probes, arg2 the return
value.

MFC after: 1 month
Sponsored by: Google, Inc.


184598 03-Nov-2008 jhb

Remove some unused and broken code that attempted to not invoke locking
asserts on NULL vnode pointers. All the vnode assertion routines already
check for NULL vnode pointers.


175984 05-Feb-2008 raj

Introduce a standalone shell script for embedding MFS image.

This allows to fix a problem with ARM kernel.bin not having the MFS image
embedded: it is objcopied from the kernel.noheader temporary ELF file, which
was not subject to embedding the MFS image previously.

Reviewed by: imp
Approved by: cognet (mentor)


167814 22-Mar-2007 jkim

Catch up with ACPI-CA 20070320 import.


167165 02-Mar-2007 flz

- Add Intel firmwares for Intel PRO/Wireless LAN 2100/2200/2915 cards in a
uuencoded format along with their respective LICENSE files.
- Add new share/doc/legal directory to BSD.usr.dist mtree file. This is the
place we install LICENSE files for restricted firmwares.
- Teach firmware(9) and kmod.mk about licensed firmwares. Restricted firmwares
won't load properly unless legal.<name>.license_ack is set to 1, either
via kenv(1) or /boot/loader.conf.

Reviewed by: mlaier, sam
Permitted by: Intel (via Andrew Wilson)
MFC after: 1 month


167077 27-Feb-2007 flz

Fix obvious typo (use long name if short name isn't provided).

Reviewed by: sam
MFC after: 3 days


166756 15-Feb-2007 luigi

Cleanup and document the implementation of firmware(9) based on
a version that i posted earlier on the -current mailing list,
and subsequent feedback received.

The core of the change is just in sys/firmware.h and kern/subr_firmware.c,
while other files are just adaptation of the clients to the ABI change
(const-ification of some parameters and hiding of internal info,
so this is fully compatible at the binary level).

In detail:
- reduce the amount of information exported to clients in struct firmware,
and constify the pointer;

- internally, document and simplify the implementation of the various
functions, and make sure error conditions are dealt with properly.

The diffs are large, but the code is really straightforward now (i hope).

Note also that there is a subtle issue with the implementation of
firmware_register(): currently, as in the previous version, we just
store a reference to the 'imagename' argument, but we should rather
copy it because there is no guarantee that this is a static string.
I realised this while testing this code, but i prefer to fix it in
a later commit -- there is no regression with respect to the past.

Note, too, that the version in RELENG_6 has various bugs including
missing locks around the module release calls, mishandling of modules
loaded by /boot/loader, and so on, so an MFC is absolutely necessary
there. I was just postponing it until this cleanup to avoid doing
things twice.

MFC after: 1 week


159670 16-Jun-2006 jhb

Check for errors when registering and unregistering firmware modules. This
prevents the unfortunate situation whereby one might kldload a firmware
module by hand and later kldunload it while a driver still has an open
reference to it.

MFC after: 1 week
Glanced at by: iedowse


159083 30-May-2006 dds

- Add two checks for syntax errors
- Improve error reporting
- Remove redundant conditionals


159082 30-May-2006 dds

Assertion code specifications are introduced using special character
sequences that are distinct from comments. %% is used for argument
locks; %! for pre- and post-conditions.


158936 26-May-2006 dds

Update usage comment to match reality.


155055 30-Jan-2006 mlaier

Fix a leftover "iwi_boot" string.

Submitted by: gallatin


154974 29-Jan-2006 mlaier

firmware(9) is a subsystem to load binary data into the kernel via a
specially crafted module. There are several handrolled sollutions to this
problem in the tree already which will be replaced with this. They include
iwi(4), ipw(4), ispfw(4) and digi(4).

No objection from: arch
MFC after: 2 weeks
X-MFC after: some drivers have been converted


153400 14-Dec-2005 des

Eradicate caddr_t from the VFS API.


153397 14-Dec-2005 des

Nuke vnodeop_desc.vdesc_transports, which has been unused since the dawn
of time (or the inception of ncvs, whichever came last)


150524 24-Sep-2005 phk

Add convenience macros for bus_space usage that doesn't require specification
of bus tag+handle.

Instead of
bus_space_write_1(sc->tag, sc->handle, ...)
this macros offer
bus_write_1(sc->resource, ...)

The name+argument transformation is constant and the the macros are
generated (by hand) by the script in tools/bus_macro.sh.


147198 09-Jun-2005 ssouhlal

Allow EVFILT_VNODE events to work on every filesystem type, not just
UFS by:
- Making the pre and post hooks for the VOP functions work even when
DEBUG_VFS_LOCKS is not defined.
- Moving the KNOTE activations into the corresponding VOP hooks.
- Creating a MNTK_NOKNOTE flag for the mnt_kern_flag field of struct
mount that permits filesystems to disable the new behavior.
- Creating a default VOP_KQFILTER function: vfs_kqfilter()

My benchmarks have not revealed any performance degradation.

Reviewed by: jeff, bde
Approved by: rwatson, jmg (kqueue changes), grehan (mentor)


144907 11-Apr-2005 jeff

- Add the character "E" to the understood lock types. This means
the VOP requires an exclusive lock.

Sponsored by: Isilon Systems, Inc.


141515 08-Feb-2005 phk

Add VOP_FOO_APV() which takes a pointer to the vop_vector.

This allows stacked or partitioned filesystems to say "Continue
the normal resolution from here", for instace from FFS to UFS.

Use VNASSERT() instead of KASSERT().


140166 13-Jan-2005 phk

Get rid of the VDESC() macro while the pot is boiling anyway, it is
only used from generate files now, so we might as well generate the
right stuff from the start.


140165 13-Jan-2005 phk

Change the generated VOP_ macro implementations to improve type checking
and KASSERT coverage.

After this check there is only one "nasty" cast in this code but there
is a KASSERT to protect against the wrong argument structure behind
that cast.

Un-inlining the meat of VOP_FOO() saves 35kB of text segment on a typical
kernel with no change in performance.

We also now run the checking and tracing on VOP's which have been layered
by nullfs, umapfs, deadfs or unionfs.

Add new (non-inline) VOP_FOO_AP() functions which take a "struct
foo_args" argument and does everything the VOP_FOO() macros
used to do with checks and debugging code.

Add KASSERT to VOP_FOO_AP() check for argument type being
correct.

Slim down VOP_FOO() inline functions to just stuff arguments
into the struct foo_args and call VOP_FOO_AP().

Put function pointer to VOP_FOO_AP() into vop_foo_desc structure
and make VCALL() use it instead of the current offsetoff() hack.

Retire vcall() which implemented the offsetoff()

Make deadfs and unionfs use VOP_FOO_AP() calls instead of
VCALL(), we know which specific call we want already.

Remove unneeded arguments to VCALL() in nullfs and umapfs bypass
functions.

Remove unused vdesc_offset and VOFFSET().

Generally improve style/readability of the generated code.


139825 07-Jan-2005 imp

/* -> /*- for license, minor formatting changes


139518 31-Dec-2004 imp

dheader and hheader were the same function, really, so rename one of
them to header, kill the other and use both with a different arg...


139513 31-Dec-2004 imp

Use functions to make the program clearer.


139458 30-Dec-2004 imp

Allow -d and -h as command line flags. These are used to generate
only the .h or _data.h files respectively. Restructure code to allow
for this.


138789 13-Dec-2004 imp

Rather than casting through a (void *) to avoid the aliasing warning,
do things correctly from an aliasing perspective. Put the
vop_generic_args element as the first element for all the vop_*_args
and adjust the code to take the address of that instead of the
structure.

OK'd based on a vague description by: phk


138780 13-Dec-2004 imp

Cast from the specific vop_*_args to vop_generic_args via a (void *)
pointer to eliminate the hundreds of warnings that we have in tree at
the moment.

# Chances are good that all the struct vop_*_args should have, as its
# first element, the struct vop_generic_args, and when necessary to
# reference it, we just take its address rather than going through
# this double case.


138290 01-Dec-2004 phk

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)


138266 01-Dec-2004 phk

emit a "typedef vop_foo_t(struct vop_foo_args *);" which we can use
to prototype VOP functions with.


131987 11-Jul-2004 dfr

Pass doxygen doc comments through to the output.


131311 30-Jun-2004 njl

Complete quirk handling script by matching the in-kernel table format.
Use a union to properly assign values. Collapse some unnecessary variables
in the revision rules.


131037 24-Jun-2004 njl

Add a script to parse acpi_quirks into a header file that we can compile
into ACPI. Script written by Mark Santcroos with some edits from myself.

Submitted by: marks


129738 26-May-2004 imp

devlist2h.awk is too generic a name for what it does. It really
converts miidevs to a .h file, so rename to reflect that.

The usb and pccard versions have also been renamed and will be hooked
into the build system shortly (I've made the conversion in my p4
tree).


128302 16-Apr-2004 obrien

Correct $FreeBSD$ style.


127976 07-Apr-2004 imp

Remove advertising clause from University of California Regent's license,
per letter dated July 22, 1999.

Approved by: core


125504 05-Feb-2004 peter

Attempt to clean up the emu10k1-alsa.h stuff so that config doesn't
delete it each time its run and have it regenerated each time by make.
I used a quick hackish script rather than putting it in the files file
and used the before-depend rule to avoid the depend/no-depend hacks.


121134 16-Oct-2003 dfr

Changes for new SMP-safe kobj method dispatch algorithm.


116694 22-Jun-2003 truckman

Don't check the state of the vnode interlock if the specification says
that the lock should not be checked.

Skip the lock assertion checks for *vpp or any other pointer to a vnode
pointer if vpp (or equivalent) is NULL.


116614 20-Jun-2003 se

The assertions generated to test VFS locking never included checks
for vnodes reached through double indirection (i.e. **vpp). This
is worked-around by special-casing the identifier "vpp" (adding one
level of indirection).

The alternative fix mentioned in the PR had required substantial
changes to this script.

In case there are locking violations that had been hidden without
this patch, they may suddenly show up, now ...

This change does not affect code compiled without DEBUG_VFS_LOCKS.

PR: kern/46652


112735 28-Mar-2003 imp

MFp4:

Don't generate the data file.
Use 0xffffffff rather than -1 for sign safety as these fields are uint32_t.


109514 19-Jan-2003 obrien

Remove miidevs.h and generate it from miidevs at compile time.
The devlist2h.awk tool to do this has been repocopied to sys/tools/.


103986 26-Sep-2002 jeff

- Move ASSERT_VOP_*LOCK* functionality into functions in vfs_subr.c
- Make the VI asserts more orthogonal to the rest of the asserts by using a
new, common vfs_badlock() function and adding a 'str' arg.
- Adjust generated ASSERTS to match the new prototype.
- Adjust explicit ASSERTS to match the new prototype.


103833 23-Sep-2002 jeff

- Automatically generate and insert KTR points in all VOPs.


102210 21-Aug-2002 jeff

- Add two new debugging macros: ASSERT_VI_LOCKED and ASSERT_VI_UNLOCKED
- Use the new VI asserts in place of the old mtx_assert checks.
- Add the VI asserts to the automated lock checking in the VOP calls. The
interlock should not be held across vops with a few exceptions.
- Add the vop_(un)lock_{pre,post} functions to assert that interlock is held
when LK_INTERLOCK is set.


102164 20-Aug-2002 obrien

Use mv -f. Otherwise if you accidently build as root, and then as a user,
it keeps asking you if you want to overwrite it or not.

Submitted by: peter


100919 30-Jul-2002 jeff

- Add automatic post vop debug checks. These work in both the success and
failure cases.


99516 07-Jul-2002 jeff

- Use 'options DEBUG_VFS_LOCKS' instead of the DEBUG_ALL_VFS_LOCKS
environment variable to enable the lock verifiction code.


99482 06-Jul-2002 jeff

Add a new configuration directive that inserts calls to debugging functions
in the VOP inlines. This is intended to replace the simple locking
specifications for calls that have more complicated behavior such as rename and
lookup.

The syntax of the new entries is:
#! name pre/post function

If the function is marked 'pre' it is executed prior to calling the VOP and
takes a pointer to a struct vop_{name}_args as it's only parameter.

If the function is marked 'post' it is executed after the VOP call and takes
a pointer to a struct vop_{name}_args as it's first parameter and the integer
return value from the vop as the second paramter.


96008 04-May-2002 jeff

include systm.h in vnode_if.c so that panic is defined when we're doing
DEBUG_ALL_VFS_LOCKS.


95841 01-May-2002 obrien

Awk version of makeobjops.PL.
Note the invocation ordering is slightly different:
awk -f makeobjops.awk foo.m -ch

Submitted by: Oliver Fromme <olli@fromme.com>


93569 01-Apr-2002 joe

constify


91511 01-Mar-2002 obrien

Return vnode_if back to its AWK roots.
It became a Perl script in rev 1.20. This removes one more dependence
on perl for the kernel build.


88873 04-Jan-2002 silby

Throw the $FreeBSD$s back in, properly escaping them.


88872 04-Jan-2002 silby

Remove $FreeBSD$s from previous commit; perl thinks that they're
something to be interpreted. Urk.


88858 03-Jan-2002 silby

Solve vnode_if.pl's identity crisis; make sure that it refers to itself
as vnode_if.pl instead of vnode_if.sh.

PR: 33509
MFC after: 3 weeks


86271 11-Nov-2001 imp

Move from using PCCARD_ symbols gereated from this file to using PCMCIA_
symbols so that driver lists are easier to share and keep in sync.


83366 12-Sep-2001 julian

KSE Milestone 2
Note ALL MODULES MUST BE RECOMPILED
make the kernel aware that there are smaller units of scheduling than the
process. (but only allow one thread per process at this time).
This is functionally equivalent to teh previousl -current except
that there is a thread associated with each process.

Sorry john! (your next MFC will be a doosie!)

Reviewed by: peter@freebsd.org, dillon@freebsd.org

X-MFC after: ha ha ha ha


74688 23-Mar-2001 alfred

replace calls to non-existant bail() subroutine with calls to
the die() builtin function.


69663 06-Dec-2000 peter

Simplify this a bit so that it doesn't have to generate silly redundant
__P() prototypes when an ansi-style static inline is a prototype already.
Since vnode_if.[ch] are generated on the fly, there are no CVS diffs to
mess up.


62168 27-Jun-2000 alfred

remove crufty exec stuff, perl is in the base system
make it work with warnings on (there was some harmless use of uninitialized
variables)
make it work with 'use strict'

Approved by: peter


54499 12-Dec-1999 peter

Use a seperate -c and -h mode. The vnode_if.c file is compiled only into
the kernel while the vnode_if.h header is a bunch of inlines to call the
code that is in the kernel. Generating the .h file on the fly is kinda
bogus because it has to match the one compiled into the kernel.

IMHO we should have kern/vnode_if.c and sys/vnode_if.h committed in the
tree but that's another battle.


53383 18-Nov-1999 n_hibma

Add usbdevs and friends.


52506 26-Oct-1999 imp

Moderately hacked pccard code from newconfig. It is somewhat in
incomplete and likely has problem. The code was originally pcmcia,
but I renamed it to pccard and made it compile on FreeBSD -current. I
converted SIMPLEQ to STAILQ as well as a few sc->dev.xname ->
device_printf changes. This is a green port of fairly mature code.

I derived this work from the FreeBSD newconfig project
(http://www.jp.freebsd.org/newconfig). Any problems with it are
likely introduced by me.

Obtained from: newconfig project


51681 26-Sep-1999 eivind

Update this to be able to output ASSERT_VOP_(UN)LOCKED() based on the
lock specifications in kern/vnode_if.src. At present, this do not
distinguish between exclusive and shared locks, and the kernel is so full
of bugs in this area that running with auto-generation of assertions
enabled makes DEBUG_VFS_LOCKS totally useless for anybody that has used it
for anything prior to outputting automated assertions. Due to this, I made
vnode_if.sh only output locking assertions if you have the environment
variable DEBUG_ALL_VFS_LOCKS set to "YES". In order to actually use the
assertions, you need to also add "options DEBUG_VFS_LOCKS" to your kernel
config file.

Urged to commit by: phk


50481 28-Aug-1999 peter

$Id$ -> $FreeBSD$ (some mangled and/or hidden ones)


50477 28-Aug-1999 peter

$Id$ -> $FreeBSD$


50120 21-Aug-1999 wpaul

This commit adds support for the NetBSD MII abstraction layer and
MII-compliant PHY drivers. Many 10/100 ethernet NICs available today
either use an MII transceiver or have built-in transceivers that can
be programmed using an MII interface. It makes sense then to separate
this support out into common code instead of duplicating it in all
of the NIC drivers. The mii code also handles all of the media
detection, selection and reporting via the ifmedia interface.

This is basically the same code from NetBSD's /sys/dev/mii, except
it's been adapted to FreeBSD's bus architecture. The advantage to this
is that it automatically allows everything to be turned into a
loadable module. There are some common functions for use in drivers
once an miibus has been attached (mii_mediachg(), mii_pollstat(),
mii_tick()) as well as individual PHY drivers. There is also a
generic driver for all PHYs that aren't handled by a specific driver.
It's possible to do this because all 10/100 PHYs implement the same
general register set in addition to their vendor-specific register
sets, so for the most part you can use one driver for pretty much
any PHY. There are a couple of oddball exceptions though, hence
the need to have specific drivers.

There are two layers: the generic "miibus" layer and the PHY driver
layer. The drivers are child devices of "miibus" and the "miibus" is
a child of a given NIC driver. The "miibus" code and the PHY drivers
can actually be compiled and kldoaded as completely separate modules
or compiled together into one module. For the moment I'm using the
latter approach since the code is relatively small.

Currently there are only three PHY drivers here: the generic driver,
the built-in 3Com XL driver and the NS DP83840 driver. I'll be adding
others later as I convert various NIC drivers to use this code.

I realize that I'm cvs adding this stuff instead of importing it
onto a separate vendor branch, but in my opinion the import approach
doesn't really offer any significant advantage: I'm going to be
maintaining this stuff and writing my own PHY drivers one way or
the other.


47964 16-Jun-1999 mckusick

Add a vnode argument to VOP_BWRITE to get rid of the last vnode
operator special case. Delete special case code from vnode_if.sh,
vnode_if.src, umap_vnops.c, and null_vnops.c.


44328 28-Feb-1999 bde

Declare static __inline functions as __inline in their forward
declaration.

Fixed some comments.

Fixed a staticization botch.


41056 10-Nov-1998 peter

Make the vnode opv vector construction fully dynamic. Previously we
leaked memory on each unload and were limited to items referenced in
the kernel copy of vnode_if.c. Now a kernel module is free to create
it's own VOP_FOO() routines and the rest of the system will happily
deal with it, including passthrough layers like union/umap/etc.

Have VFS_SET() call a common vfs_modevent() handler rather than
inline duplicating the common code all over the place.

Have VNODEOP_SET() have the vnodeops removed at unload time (assuming a
module) so that the vop_t ** vector is reclaimed.

Slightly adjust the vop_t ** vectors so that calling slot 0 is a panic
rather than a page fault. This could happen if VOP_something() was called
without *any* handlers being present anywhere (including in vfs_default.c).
slot 1 becomes the default vector for the vnodeop table.

TODO: reclaim zones on unload (eg: nfs code)


37384 04-Jul-1998 julian

VOP_STRATEGY grows an (struct vnode *) argument
as the value in b_vp is often not really what you want.
(and needs to be frobbed). more cleanups will follow this.
Reviewed by: Bruce Evans <bde@freebsd.org>


31880 19-Dec-1997 bde

Use __inline instead of inline to prevent pedantic compiler warnings.


30813 28-Oct-1997 bde

Removed unused #includes.


29290 10-Sep-1997 phk

3 lines of code and updates to a number of comments.

Reviewed by: phk
Submitted by: Terry Lambert <tlambert@primenet.com>


22975 22-Feb-1997 peter

Back out part 1 of the MCFH that changed $Id$ to $FreeBSD$. We are not
ready for it yet.


21673 14-Jan-1997 jkh

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


12820 14-Dec-1995 phk

Another mega commit to staticize things.


12656 06-Dec-1995 bde

Don't #include vm stuff in vnode_if.[ch]. Enough vm stuff (a
single typedef) is now declared in <sys/types.h>.

This is the first of 4 commits that will remove some excessive
includes of vm*.h and user.h. The total speed improvement isn't
as large as I first thought. `make depend; make' for LINT only
improved from 2180 seconds to 2108 seconds user time.


11921 29-Oct-1995 phk

Second batch of cleanup changes.
This time mostly making a lot of things static and some unused
variables here and there.


10676 11-Sep-1995 bde

Generate prototypes for VOP functions. I decided to keep the old-style
definitions even though the functions are inline. If vnode_if.h was
compiled by a non-ANSI compiler, then `inline' would be defined away,
so vnode_if.h might compile correctly.


10551 04-Sep-1995 dyson

Added VOP_GETPAGES/VOP_PUTPAGES and also the "backwards" block count
for VOP_BMAP. Updated affected filesystems...


9842 01-Aug-1995 dg

Removed my special-case hack for VOP_LINK and fixed the problem with the
wrong vp's ops vector being used by changing the VOP_LINK's argument order.
The special-case hack doesn't go far enough and breaks the generic
bypass routine used in some non-leaf filesystems. Pointed out by Kirk
McKusick.


9430 07-Jul-1995 dg

The generated VCALL always uses the first vp which in the case of /link/
might not be handled by the same FS as the directory (e.g. special device
files)...so it must be special-cased. This bug is seen when doing
"ln /dev/console /dev/foo" or equivilent and first appeared after I fixed
the argument order of VOP_LINK. YUCK! There really needs to be a way of
specifying what vp to use in the VCALL; doing this could fix the strategy
and bwrite special-cases, too.


1817 02-Aug-1994 dg

Added $Id$


1541 24-May-1994 rgrimes

BSD 4.4 Lite Kernel Sources