DragonFly BSD

CVS log for src/sys/conf/files

[BACK] Up to [DragonFly] / src / sys / conf

Request diff between arbitrary revisions


Keyword substitution: kv
Default branch: MAIN


Revision 1.234: download - view: text, markup, annotated - select for diffs
Mon Nov 17 11:55:19 2008 UTC (5 years, 11 months ago) by swildner
Branches: MAIN
CVS tags: HEAD
Diff to: previous 1.233: preferred, unified
Changes since revision 1.233: +12 -0 lines
Make ath(4) compilable into the kernel and add it to LINT.

Adapted-from: FreeBSD

Revision 1.233: download - view: text, markup, annotated - select for diffs
Thu Aug 28 09:25:42 2008 UTC (6 years, 1 month ago) by hasso
Branches: MAIN
Diff to: previous 1.232: preferred, unified
Changes since revision 1.232: +1 -0 lines
Add acpi_video(4) - a driver for ACPI video extensions.

Obtained-from: FreeBSD with modifications

Revision 1.232: download - view: text, markup, annotated - select for diffs
Thu Aug 28 07:10:04 2008 UTC (6 years, 1 month ago) by hasso
Branches: MAIN
Diff to: previous 1.231: preferred, unified
Changes since revision 1.231: +1 -0 lines
Add ACPI support module for IBM/Lenovo Thinkpad laptops. Work in progress,
but already usable for most of Thinkpads.

Obtained-from: FreeBSD with modifications

Revision 1.231: download - view: text, markup, annotated - select for diffs
Thu Aug 28 06:16:32 2008 UTC (6 years, 1 month ago) by hasso
Branches: MAIN
Diff to: previous 1.230: preferred, unified
Changes since revision 1.230: +2 -0 lines
Move acpi_toshiba.c, it's not pc32 specific.

Revision 1.230: download - view: text, markup, annotated - select for diffs
Wed Aug 27 16:35:19 2008 UTC (6 years, 1 month ago) by hasso
Branches: MAIN
Diff to: previous 1.229: preferred, unified
Changes since revision 1.229: +1 -0 lines
Add some methods to ACPI to handle embedded controllers and device matching.

Obtained-from: FreeBSD

Revision 1.229: download - view: text, markup, annotated - select for diffs
Mon Jul 28 15:07:28 2008 UTC (6 years, 2 months ago) by sephe
Branches: MAIN
Diff to: previous 1.228: preferred, unified
Changes since revision 1.228: +1 -0 lines
Dispatch ipfw control to netisr0.  To avoid possible dangling netmsg handler,
create ip_fw2_glue.c, which will be built if inet is built.  IPFW_LOADED is
checked again after netmsg's handler is running, since ipfw unload netmsg may
be processed before this ipfw control netmsg.

Revision 1.228: download - view: text, markup, annotated - select for diffs
Mon Jul 28 01:21:39 2008 UTC (6 years, 2 months ago) by swildner
Branches: MAIN
Diff to: previous 1.227: preferred, unified
Changes since revision 1.227: +0 -2 lines
Remove some old driver remains.

Revision 1.227: download - view: text, markup, annotated - select for diffs
Sat Jul 26 14:26:30 2008 UTC (6 years, 3 months ago) by sephe
Branches: MAIN
CVS tags: DragonFly_Preview
Diff to: previous 1.226: preferred, unified
Changes since revision 1.226: +1 -0 lines
Add jme(4)

Revision 1.226: download - view: text, markup, annotated - select for diffs
Sat Jul 26 07:15:11 2008 UTC (6 years, 3 months ago) by sephe
Branches: MAIN
Diff to: previous 1.225: preferred, unified
Changes since revision 1.225: +2 -0 lines
Move em(4) from MD conf/files to MI conf/files

Revision 1.225: download - view: text, markup, annotated - select for diffs
Tue Jul 22 11:37:14 2008 UTC (6 years, 3 months ago) by sephe
Branches: MAIN
Diff to: previous 1.224: preferred, unified
Changes since revision 1.224: +1 -0 lines
Add jmphy.c

Revision 1.223.2.1: download - view: text, markup, annotated - select for diffs
Thu Jul 17 10:18:06 2008 UTC (6 years, 3 months ago) by swildner
Branches: DragonFly_RELEASE_2_0
CVS tags: DragonFly_RELEASE_2_0_Slip
Diff to: previous 1.223: preferred, unified; next MAIN 1.224: preferred, unified
Changes since revision 1.223: +1 -1 lines
MFC: Enable building of hammer.ko.

Revision 1.224: download - view: text, markup, annotated - select for diffs
Thu Jul 17 00:16:14 2008 UTC (6 years, 3 months ago) by swildner
Branches: MAIN
Diff to: previous 1.223: preferred, unified
Changes since revision 1.223: +1 -1 lines
Make HAMMER build and work as a module and extend hammer(5)'s SYNOPSIS
accordingly.

Revision 1.223: download - view: text, markup, annotated - select for diffs
Sat Jul 12 02:47:38 2008 UTC (6 years, 3 months ago) by dillon
Branches: MAIN
Branch point for: DragonFly_RELEASE_2_0
Diff to: previous 1.222: preferred, unified
Changes since revision 1.222: +1 -0 lines
HAMMER 61D/Many: Mirroring features

* Split PFS ioctls into their own source file.

* Add additional PFS/mirroring directives:  pfs-upgrade, pfs-downgrade, and
  finish implementing pfs-destroy.  (Yes, that means you can change the
  master/slave mode for a PFS now).

* Consolidate some of the B-Tree deletion code.

* Fix another sync_lock deadlock.

Revision 1.222: download - view: text, markup, annotated - select for diffs
Mon Jul 7 22:02:09 2008 UTC (6 years, 3 months ago) by nant
Branches: MAIN
Diff to: previous 1.221: preferred, unified
Changes since revision 1.221: +4 -0 lines
Introduce experimental MPLS over ethernet support. Add 'options MPLS'
to the kernel config file to enable it. This modification increases
the footprint of each route in the FIB by 12 bytes, used to hold up
to 3 label operations per route.

Hints-from: Ayame, NiSTswitch implementations.
Reviewed-by: dillon@, sephe@, hsu@, hasso@.

Revision 1.221: download - view: text, markup, annotated - select for diffs
Sat Jun 28 17:59:46 2008 UTC (6 years, 3 months ago) by dillon
Branches: MAIN
Diff to: previous 1.220: preferred, unified
Changes since revision 1.220: +1 -0 lines
Replace the bwillwrite() subsystem to make it more fair to processes.

* Add new API functions, bwillread(), bwillwrite(), bwillinode() which
  the kernel calls when it intends to read, write, or make inode
  modifications.

* Redo the backend.  Add bd_heatup() and bd_wait().  bd_heatup() heats up
  the buf_daemon, starting it flushing before we hit any blocking conditions
  (similar to the previous algorith).

* The new bwill*() blocking functions no longer introduce escalating delays
  to keep the number of dirty buffers under control.  Instead it takes a page
  from HAMMER and estimates the load caused by the caller, then waits for a
  specific number of dirty buffers to complete their write I/O's before
  returning.  If the buffers can be retired quickly these functions will
  return more quickly.

Revision 1.220: download - view: text, markup, annotated - select for diffs
Fri Jun 27 14:02:14 2008 UTC (6 years, 3 months ago) by swildner
Branches: MAIN
Diff to: previous 1.219: preferred, unified
Changes since revision 1.219: +1 -1 lines
Fix a typo so that old netgraph builds again.

Revision 1.219: download - view: text, markup, annotated - select for diffs
Thu Jun 26 23:24:11 2008 UTC (6 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.218: preferred, unified
Changes since revision 1.218: +111 -8 lines
Add files and options lines for NETGRAPH7

Revision 1.218: download - view: text, markup, annotated - select for diffs
Thu Jun 26 04:06:21 2008 UTC (6 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.217: preferred, unified
Changes since revision 1.217: +1 -0 lines
HAMMER 59A/Many: Mirroring related work (and one bug fix).

* BUG FIX: Fix a bug in directory hashkey generation.  The iterator could
  sometimes conflict with a key already on-disk and interfere with a pending
  deletion.  The chance of this occuring was miniscule but not 0.  Now fixed.

  The fix also revamps the directory iterator code, moving it all to one
  place and removing it from two other places.

* PRUNING CHANGE: The pruning code no longer shifts the create_tid and
  delete_tid of adjacent records to fill gaps.  This means that historical
  queries must either use snapshot softlinks or use a fine-grained
  transaction id greater then the most recent snapshot softlink.

  fine-grained historical access still works up to the first snapshot
  softlink.

* Clean up the cursor code responsible for acquiring the parent node.

* Add the core mirror ioctl read/write infrastructure.  This work is still
  in progress.

  - ioctl commands
  - pseudofs enhancements, including st_dev munging.
  - mount options
  - transaction id and object id conflictless allocation
  - initial mirror_tid recursion up the B-Tree (not finished)
  - B-Tree mirror scan optimizations to skip sub-hierarchies that do not
    need to be scanned (requires mirror_tid recursion to be 100% working).

Revision 1.217: download - view: text, markup, annotated - select for diffs
Tue Jun 10 05:06:18 2008 UTC (6 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.216: preferred, unified
Changes since revision 1.216: +14 -14 lines
HAMMER 53E/Many: Performance tuning

* Change the code which waits for reclaims to drain to be more inline with
  the new bwillwrite().  Impose a dynamic delay instead of blocking outright.

* Move the hammer_inode_waitreclaims() call from hammer_vop_open() to
  hammer_get_inode(), and only call it when we would otherwise have to
  create a new inode.

* Sort HAMMER's file list in conf/files.

Revision 1.216: download - view: text, markup, annotated - select for diffs
Mon May 12 21:17:15 2008 UTC (6 years, 5 months ago) by dillon
Branches: MAIN
Diff to: previous 1.215: preferred, unified
Changes since revision 1.215: +1 -0 lines
HAMMER 43/Many: Remove records from the media format, plus other stuff

* Get rid of hammer_record_ondisk.  As HAMMER has evolved the need for
  a separate record structure has devolved into trivialities.  Originally
  the idea was to have B-Tree nodes referencing records and data.  The
  B-Tree elements were originally intended to be throw-away and the on-media
  records were originally intended to be the official representation of
  the data and contained additional meta-information such as the obj_id
  of a directory entry and a few additional fields related to the inode.

  But once the UNDO code went in and it became obvious that the B-Tree needed
  to be tracked (undo-wise) along with everything else, the need for an
  official representation of the record as a separate media structure
  essentially disappeared.

  Move the directory-record meta-data into the directory-entry data and move
  the inode-record meta-data into the inode-record data.  As a single
  exception move the atime field to the B-Tree element itself (it replaces
  what used to be the record offset), in order to continue to allow atime
  updates to occur without requiring record rewrites.  With these changes
  records are no longer needed at all, so remove the on-media record structure
  and all the related code.

* The removal of the on-media record structure also greatly improves
  performance.

* B-Tree elements are now the official on-media record.

* Fix a race in the extraction of the root of the B-Tree.

* Clean up the in-memory record handling API.  Instead of having to
  construct B-Tree leaf elements we can simply embed one in the in-memory
  record structure (struct hammer_record), and in the inode.

Revision 1.215: download - view: text, markup, annotated - select for diffs
Wed Apr 23 21:06:19 2008 UTC (6 years, 6 months ago) by thomas
Branches: MAIN
Diff to: previous 1.214: preferred, unified
Changes since revision 1.214: +1 -0 lines
Add hammer_flusher.c, to make kernels with options HAMMER build.

Revision 1.214: download - view: text, markup, annotated - select for diffs
Wed Apr 23 08:57:10 2008 UTC (6 years, 6 months ago) by hasso
Branches: MAIN
Diff to: previous 1.213: preferred, unified
Changes since revision 1.213: +2 -0 lines
Add a driver for Omnikey CardMan 4040 smartcard reader - cmx(4).

Obtained-from: FreeBSD

Revision 1.213: download - view: text, markup, annotated - select for diffs
Sun Apr 6 18:58:12 2008 UTC (6 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.212: preferred, unified
Changes since revision 1.212: +1 -0 lines
Add fairq to altq.  Fairq is a fair queueing algorithm with bandwidth
prioritization and a bandwidth delimiter (hogs) to allow low bandwidth
buckets to jump the round robin.  This fairq algorithm is currently unweighted
but traffic can still be classified with the global priority model.  For
each queue traffic is normally round robined by taking a packet from each
bucket in turn.

This feature is primarily intended for edge routers and egress points with
bandwidth constrictions.

* Hogs feature allows low bandwidth buckets to burst.  Low bandwidth can
  mean, e.g. an interactive shell or even simply ack traffic, without
  the need to explicitly classify it.  Bandwidth is managed on a per-bucket
  basis.

* Prioritization feature allows minimum guaranteed bandwidths based on
  service classifications. e.g. VOIP, web, mail, PtP, etc.

* Weighted fairq not implemented (beyond using classification into priority
  queues), but the circular bucket design makes it a fairly easy task if
  someone wants to do it.

* Add ALTQ_MBUF_STATE_HASHED and generate a hash of the connection state
  in the mbuf header for any packet that you have set 'keep state' for
  in pf.  This is done in PF and is needed by fairq to bucketize
  'connections'.

* Add the fairq implementation and a new ALTQ_FAIRQ kernel build option.

* Simple example included below.

ports="{ 25, 80 }"
altq on vke0 fairq bandwidth 500Kb queue { normal, bulk }
queue bulk priority 1 bandwidth 100Kb \
        fairq(buckets 64, hogs 25Kb) qlimit 50
queue normal priority 2 bandwidth 400Kb \
        fairq(buckets 64, hogs 25Kb, default) qlimit 50

pass out on vke0 inet proto tcp from any to any \
        keep state queue normal
pass out on vke0 inet proto tcp from any to any port $ports \
        keep state queue bulk

Revision 1.212: download - view: text, markup, annotated - select for diffs
Sat Apr 5 18:12:28 2008 UTC (6 years, 6 months ago) by hasso
Branches: MAIN
Diff to: previous 1.211: preferred, unified
Changes since revision 1.211: +48 -16 lines
DRM update to git snapshot from 2008-01-04.

Revision 1.211: download - view: text, markup, annotated - select for diffs
Sat Mar 22 21:24:44 2008 UTC (6 years, 7 months ago) by dillon
Branches: MAIN
Diff to: previous 1.210: preferred, unified
Changes since revision 1.210: +1 -0 lines
Fix collision in conf/files, add hammer_signal.c.

Revision 1.210: download - view: text, markup, annotated - select for diffs
Sat Mar 22 09:45:44 2008 UTC (6 years, 7 months ago) by sephe
Branches: MAIN
Diff to: previous 1.209: preferred, unified
Changes since revision 1.209: +0 -1 lines
Remove ipw(4) from LINT building and module building

Revision 1.209: download - view: text, markup, annotated - select for diffs
Tue Mar 18 05:19:14 2008 UTC (6 years, 7 months ago) by dillon
Branches: MAIN
Diff to: previous 1.208: preferred, unified
Changes since revision 1.208: +2 -0 lines
HAMMER 32/many: Record holes, initial undo API, initial reblocking code

* Add code to record recent 'holes' created by the blockmap allocator
  due to the requirement that data blocks not cross a 16K hammer buffer
  boundary, in order to try to fill in the gaps with smaller chunks of data
  when possible.

  Currently a hole is not added for blockmap frees.  It is questionable
  whether it is a good idea to do it for frees or not, because it can
  interfere with the reblock code's attempt to completely free a big block.

* Add a reblocking ioctl which scans the B-Tree and reblocks leaf nodes,
  records, and data in partially empty big blocks to try to free up
  the entire big block.  Incomplete (needs to reblock internal B-Tree nodes
  and doesn't yet, needs a low-free-space mode which focuses on freeing
  a single large block).

* Add the API infrastructure required to implement the undo records,
  and implement the initial undo code (sans ordering requirements for
  writes).  Incomplete.

Revision 1.208: download - view: text, markup, annotated - select for diffs
Mon Mar 10 10:47:57 2008 UTC (6 years, 7 months ago) by sephe
Branches: MAIN
Diff to: previous 1.207: preferred, unified
Changes since revision 1.207: +1 -0 lines
- Embed ether vlan tag in mbuf packet header.  Add an mbuf flag to mark that
  this field is valid.
- Hide ifvlan after the above change; drivers support hardware vlan tagging
  only need to check ether_vlantag in mbuf packet header.
- Convert all drivers that support hardware vlan tagging to use vlan tag field
  in mbug packet header.

Obtained-from: FreeBSD

Change the vlan/parent serializer releasing/holding sequences into mbuf
dispatching.  There are several reasons to do so:
- Avoid excessive vlan interface serializer releasing/holding
- Touching parent interface if_snd without holding parent's serializer is
  unsafe
- vlan's parent may disappear or be changed after vlan's serializer is released

# This dispatching could be further optimized by packing all mbufs into one
# netmsg using m_nextpkt to:
# - Amortize netmsg sending cost
# - Reduce the time that parent interface spends on serializer releasing/holding

Revision 1.207: download - view: text, markup, annotated - select for diffs
Sun Mar 9 09:56:02 2008 UTC (6 years, 7 months ago) by sephe
Branches: MAIN
Diff to: previous 1.206: preferred, unified
Changes since revision 1.206: +2 -0 lines
- Add an entry for iwl(4)
- Add iwl(4) in LINT

Revision 1.206: download - view: text, markup, annotated - select for diffs
Thu Feb 28 18:39:20 2008 UTC (6 years, 7 months ago) by swildner
Branches: MAIN
Diff to: previous 1.205: preferred, unified
Changes since revision 1.205: +1 -0 lines
Add an experimental driver for NICs using Silan Microelectronics' SC92301
chip, some of which seem to be known as Rsltek [sic] 8139D. This is a port
of Silan's own FreeBSD 4.7 driver which was written by one 'gaoyonghong'.

It's up to the point where it works with the "Noganet KN-8139D" product,
but it still gives occasional errors/warnings on the console. Also, some
areas need to be brought more up to date.

Therefore, the if_sln.ko module is built, but the driver is not yet in
GENERIC.

Tested-by: Damian Vicino <dvicino@dc.uba.ar>

Revision 1.205: download - view: text, markup, annotated - select for diffs
Mon Feb 11 19:57:30 2008 UTC (6 years, 8 months ago) by swildner
Branches: MAIN
CVS tags: DragonFly_RELEASE_1_12_Slip, DragonFly_RELEASE_1_12
Diff to: previous 1.204: preferred, unified
Changes since revision 1.204: +1 -1 lines
Clean up remains of the umsm(4) -> ugensa(4) renaming.

Revision 1.204: download - view: text, markup, annotated - select for diffs
Sun Feb 10 09:50:59 2008 UTC (6 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.203: preferred, unified
Changes since revision 1.203: +2 -1 lines
HAMMER 28/many: Implement zoned blockmap

* Implement a zoned blockmap.  Separate B-Tree nodes, records, small blocks
  of data, and large blocks of data into their own zones.  Use 8MB large
  blocks, 32-byte blockmap entry structures, and two layers to support
  59 bits (512 petabytes).

* Create a temporary freeblock allocator so the blockmap can be tested.
  It just allocates sequentially and asserts when it hits the end of the
  volume.   This will be replaced with a real freeblock allocator soon.

* Clean up some of the mess I created from the temporary fifo mechanism
  that had been put in-place to test the major rewiring in 27.

* Adjust newfs_hammer.  The 'hammer' utility has not yet been adjusted
  (it can't decode blockmaps yet but will soon).

Revision 1.203: download - view: text, markup, annotated - select for diffs
Fri Feb 8 08:30:55 2008 UTC (6 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.202: preferred, unified
Changes since revision 1.202: +0 -1 lines
HAMMER 27/many: Major surgery - change allocation model

After getting stuck on the recovery code and highly unoptimal write
performance issues, remove the super-cluster/cluster and radix tree bitmap
infrastructure and replace it with a circular FIFO.

* Nothing is localized yet with this major surgery commit, which means
  radix nodes, hammer records, file data, and undo fifo elements are
  all being written to a single fifo.  These elements will soon get their
  own abstracted fifos (and in particular, the undo elements will get a
  fixed-sized circular fifo and be considered temporary data).

* No sequence numbers or transaction spaces are generated yet.

* Create a 'hammer_off_t' type (64 bits).  This type reserves 4 bits for
  a zone.  Zones which encode volume numbers reserve another 8 bits,
  giving us a 52 bit byte offset able to represent up to 4096 TB per
  volume.  Zones which do not encode volume numbers have 60 bits available
  for an abstracted offset, resulting in a maximum filesystem size of
  2^60 bytes (1 MTB).  Up to 15 zones can be encoded.

  As of this commit only 2 zones are implemented to wrap up existing
  functionality.

* Adjust the B-Tree to use full 64 bit hammer offsets.  Have one global B-Tree
  for the entire filesystem.  The tree is no longer per-cluster.

* Scrap the recovery and spike code.  Scrap the cluster and super-cluster
  code.  Scrap those portions of the B-Tree code that dealt with spikes.
  Scrap those portions of the IO subsystem that dealt with marking a
  cluster open or closed.

* Expand the hammer_modify_*() functions to include a data range and add
  UNDO record generation.  Do not implement buffer ordering dependancies
  yet (ordering issues are going change radically with the FIFO model).

Revision 1.202: download - view: text, markup, annotated - select for diffs
Mon Feb 4 08:33:14 2008 UTC (6 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.201: preferred, unified
Changes since revision 1.201: +1 -0 lines
HAMMER 25/many: Add an ioctl API for HAMMER.

* Add HAMMERIOC_PRUNE - a command which will scan a range of inode numbers
  and prune them according to the supplied list.   This is a preliminary
  implementation.

* Add HAMMERIOC_GETHISTORY - a command which scans the history for a
  particular file or a particular file offset within a file and displays
  it.

Revision 1.201: download - view: text, markup, annotated - select for diffs
Fri Feb 1 13:18:49 2008 UTC (6 years, 8 months ago) by sephe
Branches: MAIN
Diff to: previous 1.200: preferred, unified
Changes since revision 1.200: +0 -8 lines
Nuke following outdated drivers
ray(4):	FH only wireless NIC driver
awi(4):	802.11 (read: not even 802.11b) and FH wireless NIC driver
gx(4):	replaced by em(4) and unmaintained for quite a long time

Revision 1.200: download - view: text, markup, annotated - select for diffs
Mon Jan 21 02:27:37 2008 UTC (6 years, 9 months ago) by pavalos
Branches: MAIN
Diff to: previous 1.199: preferred, unified
Changes since revision 1.199: +0 -2 lines
Sync mly(4) with FreeBSD.

Obtained-from: FreeBSD

Revision 1.199: download - view: text, markup, annotated - select for diffs
Fri Jan 18 19:06:29 2008 UTC (6 years, 9 months ago) by dillon
Branches: MAIN
Diff to: previous 1.198: preferred, unified
Changes since revision 1.198: +1 -0 lines
Add hammer_recover.c for kernel builds w/ HAMMER.

Revision 1.198: download - view: text, markup, annotated - select for diffs
Fri Jan 11 11:59:40 2008 UTC (6 years, 9 months ago) by sephe
Branches: MAIN
Diff to: previous 1.197: preferred, unified
Changes since revision 1.197: +1 -0 lines
- Split if_clone.c out of if.c, license in if.c is attached to if_clone.c
- Split if_clone.h out of if.h and if_var.h, license of if_var.h is attached
  to if_clone.h
- Staticize some variables and function in if_clone.c
- if_clonereq is the only userland visible structure related to this commit;
  it is kept in if.h for now, so userland application won't be aware of this
  commit.  It will be moved to net/if_clone.h

No functional changes.

# if_clone.c is subjected to change to support clone creation with
# additional parameters.

Revision 1.197: download - view: text, markup, annotated - select for diffs
Sat Dec 29 13:40:28 2007 UTC (6 years, 9 months ago) by swildner
Branches: MAIN
Diff to: previous 1.196: preferred, unified
Changes since revision 1.196: +0 -1 lines
Remove the xrpu driver as FreeBSD did ~1 month ago.

Revision 1.196: download - view: text, markup, annotated - select for diffs
Wed Dec 26 14:02:36 2007 UTC (6 years, 10 months ago) by sephe
Branches: MAIN
Diff to: previous 1.195: preferred, unified
Changes since revision 1.195: +1 -0 lines
Import msk(4) which supports Marvell Yukon II based NICs (both gigE and fastE)

Obtained-from: FreeBSD (yongari@FreeBSD.org)
Tested-by: me, swildner@, Ferruccio Zamuner <nonsolosoft@diff.org>

# Hardware vlan tagging, hardware checksum offload and jumbo frame support
# are still missing as of this commit.

Revision 1.195: download - view: text, markup, annotated - select for diffs
Mon Nov 19 00:53:38 2007 UTC (6 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.194: preferred, unified
Changes since revision 1.194: +1 -0 lines
HAMMER 3/many - more core infrastructure.

* Add an in-memory B-Tree node abstraction
* Add an in-memory record abstraction.
* Put the B-Tree cursor code in its own source file.
* Fill in more of the VOP code.

* Do a major clean-up of all in-memory structures and some on-disk
  structures.  All the major in-memory structures now use similarly
  named functions.

* Move inter-cluster link from a B-Tree leaf node to a B-Tree internal
  node, giving us a left and right boundary to play with.  This simplifies
  the algorithms by quite a bit.
* Allow the B-Tree to be unbalanced by moving the sub-type from the B-Tree
  node header to the B-Tree element structure.

* Revamp the I/O infrastructure, in particular allow B-Tree nodes to be
  held passively.
* Implement a flexible B-Tree node cache.  References into the B-Tree can
  be cached by inodes.  If the related buffer is flushed by the system, the
  related cache pointers will be cleared.

Revision 1.194: download - view: text, markup, annotated - select for diffs
Sun Nov 18 17:53:01 2007 UTC (6 years, 11 months ago) by pavalos
Branches: MAIN
Diff to: previous 1.193: preferred, unified
Changes since revision 1.193: +1 -0 lines
Rewrite of the CAM error recovery code.

Some of the major changes include:

	- The SCSI error handling portion of cam_periph_error() has
	  been broken out into a number of subfunctions to better
	  modularize the code that handles the hierarchy of SCSI errors.
	  As a result, the code is now much easier to read.

	- String handling and error printing has been significantly
	  revamped.  We now use sbufs to do string formatting instead
	  of using printfs (for the kernel) and snprintf/strncat (for
	  userland) as before.

	  There is a new catchall error printing routine,
	  cam_error_print() and its string-based counterpart,
	  cam_error_string() that allow the kernel and userland
	  applications to pass in a CCB and have errors printed out
	  properly, whether or not they're SCSI errors.  Among other
	  things, this helped eliminate a fair amount of duplicate code
	  in camcontrol.

	  We now print out more information than before, including
	  the CAM status and SCSI status and the error recovery action
	  taken to remedy the problem.

Obtained-from: FreeBSD

Revision 1.193: download - view: text, markup, annotated - select for diffs
Fri Nov 16 02:45:44 2007 UTC (6 years, 11 months ago) by sephe
Branches: MAIN
Diff to: previous 1.192: preferred, unified
Changes since revision 1.192: +1 -0 lines
CPU localize dummynet(4) step 1/2

       CPU ip_dn_cpu                             CPU n1
+--------------------------+            +---------------------+
|          netisr          |            |                     |
|            |             |            |                     |
|            +<---------------dn_descX----[ip_fw_dn_io_ptr()] |
|            |             |            |                     |
| [ip_dn_io_ptr(dn_descX)] |            |                     |
|            |             |            |                     |
|            |             |            |                     |
|            |             |            |                     |
| [transmit_event() begin  |            |                     |
|            +----------------dn_descY------>[ip_output()]    |
|            :             |            |                     |
|            :             |            |                     |
|            :             |            +---------------------+
|            :             |
|            :             |
|            :             |                     CPU n2
|            :             |            +---------------------+
|            :             |            |                     |
|            +----------------dn_descZ------>[ip_input()]     |
|            :             |            |                     |
|  transmit_event() end]   |            +---------------------+
|            |             |
+--------------------------+

NOTE: transmit_event() is triggered by dummynet systimer on CPU ip_dn_cpu


- Add flow id field, which is packet filter independent, in dummynet
  descriptor, so that we can record the flow id realted information on the
  originator's stack.  In this way, dummynet descriptor and its associated
  mbuf could be dispatched to different thread for further processing.
- Add packet filter private data and private data unreference function
  pointer in dummynet descriptor.
- All of the dummynet descriptor is allocated and filled by packet filter
  (only ipfw(4) currently), so things like route entry reference is updated
  on the CPU to which it belongs.
- All packets are dispatched to netisr on CPU ip_dn_cpu to be queued on the
  target flow queue.  Netisr on CPU ip_dn_cpu is also where various dummynet
  events got processed.
- DUMMYNET_LOADED is not checked before dispatching a packet; it is checked
  in netisr before the packet is handed to dummynet.  This paves the way for
  step 2/2.
- ip_{output,input}/ether_{demux,output_frame} is no longer called directly
  in dummynet, they are called after packet dispatched back to the originator
  CPU, so that ip_input() will be called on the same CPU (as determined by
  ip_mport()) and things like route entry reference will be updated on the
  CPU to which it belongs.
- If the packet is to be dispatched back to ip_output(), the recorded route
  entry is checked to make sure that it is still up.
- Dummynet discriptor and its associated mbuf is freed on their originator CPU.
- Reference count the ipfw(4) rule if it is going to be associated with a
  dummynet descriptor, so we would not have a dangling rule pointer if the
  rule was deleted when the dummynet descriptor was in transit state.
  Suggested-by: dillon@
- If ipfw(4) is compiled and loaded as module, reference count the ipfw(4)
  module usage, if a rule is associated with a dummynet descriptor.
- Add net/dummynet/ip_dummynet_glue.c, which contains various netisr dispatch
  function.  This file will be compiled into kernel if 'options INET' is set,
  so that we will not have a dangling function pointer in transitting dummynet
  descriptor.
- Add DUMMYNET_MBUF_TAGGED mbuf fw_flag, which may be used later.
- Nuke dummynet's dependency on ipfw(4).

Revision 1.192: download - view: text, markup, annotated - select for diffs
Sat Nov 10 19:02:04 2007 UTC (6 years, 11 months ago) by swildner
Branches: MAIN
Diff to: previous 1.191: preferred, unified
Changes since revision 1.191: +1 -1 lines
Some aac(4) cleanup:

* Activate aac_debug.c. Fix AAC_DEBUG and add it to LINT.

* Staticise stuff which is used only locally.

* Remove unused functions.

* Constify an argument of aac_print_fib().

Revision 1.191: download - view: text, markup, annotated - select for diffs
Fri Nov 9 18:36:20 2007 UTC (6 years, 11 months ago) by hasso
Branches: MAIN
Diff to: previous 1.190: preferred, unified
Changes since revision 1.190: +1 -0 lines
Fix LINT build.

Reported-by: swildner

Revision 1.190: download - view: text, markup, annotated - select for diffs
Wed Nov 7 09:07:44 2007 UTC (6 years, 11 months ago) by hasso
Branches: MAIN
Diff to: previous 1.189: preferred, unified
Changes since revision 1.189: +1 -0 lines
Add uchcom(4) - the driver for WinChipHead CH341/CH340 chips.

Obtained-from: NetBSD

Revision 1.189: download - view: text, markup, annotated - select for diffs
Wed Nov 7 08:57:17 2007 UTC (6 years, 11 months ago) by hasso
Branches: MAIN
Diff to: previous 1.188: preferred, unified
Changes since revision 1.188: +1 -0 lines
Add moscom(4) - the driver for MosChip Semiconductor MCS7703 USB to
serial chips.

Obtained-from: OpenBSD

Revision 1.188: download - view: text, markup, annotated - select for diffs
Wed Nov 7 00:43:21 2007 UTC (6 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.187: preferred, unified
Changes since revision 1.187: +4 -0 lines
HAMMER part 2/many.

* Implement most of the I/O infrastructure and internal HAMMER tracking
  structures for volumes, super-clusters, clusters, and buffers.

* Flesh out the B-Tree code and add an iterator.

* Implement a good chunk of the vnops, but no modifying operations yet.

* Implement passive filesystem buffer tracking which allows a struct buf
  to remain associated with internal HAMMER data structures and also
  provides a reverse path whereby the filesystem buffer cache drives
  garbage collection of internal HAMMER data structures.  Use the augmented
  bio_ops to facilitate this.

* Skeleton for transactions, spikes, and object allocation & management.

Revision 1.187: download - view: text, markup, annotated - select for diffs
Fri Nov 2 19:54:16 2007 UTC (6 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.186: preferred, unified
Changes since revision 1.186: +1 -0 lines
Break-out the standard UNIX uid/gid tests for VOP_ACCESS into a helper file.
The code was basically taken from UFS and the helper file retains the
appropriate copyright.  This way HAMMER can call the procedure without us
needing to add the University copyright to HAMMER sources.

Revision 1.186: download - view: text, markup, annotated - select for diffs
Thu Nov 1 22:05:23 2007 UTC (6 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.185: preferred, unified
Changes since revision 1.185: +7 -0 lines
Add a HAMMER kernel build option, add a VFS type for HAMMER, add a file
type for key-access (database) files.

Revision 1.185: download - view: text, markup, annotated - select for diffs
Fri Oct 12 14:12:42 2007 UTC (7 years ago) by sephe
Branches: MAIN
Diff to: previous 1.184: preferred, unified
Changes since revision 1.184: +2 -0 lines
Add et(4), which supports Agere ET1310 based Ethernet chips (PCIe only)

  This chips supports two RX rings, one is currently used for packets
  whose size are smaller than 110 bytes, the other one is used for the
  rest packets sizes.

  Its RX interrupt moderation is quite similar to what bge(4) does:
  Two control variables, one is used to control how many packet should be
  received the other is used to control RX interrupt delay, RX interrupt
  moderation is achieved through the interaction of these two variables.

  Its TX interrupt moderation is more straightforward than RX's ;), you
  can tell hardware which TX segment should trigger interrupt.  It also
  has a hardware timer, which is set to 1Hz currently to prevent
  if_watchdog() from (mis)firing.

  I didn't figure out how to add polling(4) support for this chip, its
  RX state ring simply stops working if interrupts are disabled.  However,
  its hardware timer may be used to mimic polling(4) support.

  The missing features of the driver as of this commit:
  - Hardware checksum
  - Hardware vlan tagging
  - Jumbo buffer support
  Hopefully, they will be added later.

Add TruePHY (will any vendors name their PHY as FalsePHY one day?) support
into miibus(4) for Agere ET1011C PHY, which is used by et(4).  The data
sheet says model is 1 for ET1011C, while my testing card's model is 4; it
may be just a variant.

Revision 1.184: download - view: text, markup, annotated - select for diffs
Tue Oct 2 13:37:38 2007 UTC (7 years ago) by hasso
Branches: MAIN
Diff to: previous 1.183: preferred, unified
Changes since revision 1.183: +3 -0 lines
lm(4) and it(4) drivers for hardware sensors used in many motherboards. Ported
from OpenBSD to FreeBSD by Constantine A. Murenin <mureninc at gmail.com>.

Obtained-from: OpenBSD via FreeBSD GSoC 2007 project

Revision 1.183: download - view: text, markup, annotated - select for diffs
Tue Oct 2 13:16:42 2007 UTC (7 years ago) by hasso
Branches: MAIN
Diff to: previous 1.182: preferred, unified
Changes since revision 1.182: +1 -0 lines
Coretemp(4) driver for Intel Core on-die digital thermal sensor with patch
from Constantine A. Murenin <mureninc at gmail.com> to make it use
hw.sensors framework.

Obtained-from: FreeBSD with modifications from Constantine A. Murenin

Revision 1.182: download - view: text, markup, annotated - select for diffs
Tue Oct 2 12:57:00 2007 UTC (7 years ago) by hasso
Branches: MAIN
Diff to: previous 1.181: preferred, unified
Changes since revision 1.181: +1 -0 lines
Hardware sensors framework originally developed in OpenBSD and ported to
FreeBSD by Constantine A. Murenin <mureninc at gmail.com>.

Obtained-from: OpenBSD via FreeBSD GSoC 2007 project

Revision 1.181: download - view: text, markup, annotated - select for diffs
Wed Sep 12 08:31:43 2007 UTC (7 years, 1 month ago) by hasso
Branches: MAIN
Diff to: previous 1.180: preferred, unified
Changes since revision 1.180: +2 -0 lines
Update the agp(4) code to the latest one from FreeBSD HEAD. This brings in
a lot of newer hardware support.

Obtained-from: FreeBSD

Revision 1.180: download - view: text, markup, annotated - select for diffs
Sun Sep 2 13:27:23 2007 UTC (7 years, 1 month ago) by sephe
Branches: MAIN
Diff to: previous 1.179: preferred, unified
Changes since revision 1.179: +1 -2 lines
Switch ipfw from ipfw1 to ipfw2.

Approved-by: dillon@
Submitted-by: Gary Allan <dragonfly@gallan.plus.com> (w/ modification)

Revision 1.179: download - view: text, markup, annotated - select for diffs
Fri Aug 31 11:26:44 2007 UTC (7 years, 1 month ago) by swildner
Branches: MAIN
Diff to: previous 1.178: preferred, unified
Changes since revision 1.178: +0 -6 lines
GC even more remains of the recent old driver removal.

Revision 1.178: download - view: text, markup, annotated - select for diffs
Wed Aug 29 15:42:05 2007 UTC (7 years, 1 month ago) by swildner
Branches: MAIN
Diff to: previous 1.177: preferred, unified
Changes since revision 1.177: +0 -1 lines
Fix LINT: Remove cm(4) and fla(4) remains.

Revision 1.177: download - view: text, markup, annotated - select for diffs
Mon Aug 27 16:15:41 2007 UTC (7 years, 2 months ago) by hasso
Branches: MAIN
Diff to: previous 1.176: preferred, unified
Changes since revision 1.176: +0 -1 lines
Nuke FDDI support.

Revision 1.176: download - view: text, markup, annotated - select for diffs
Mon Aug 27 14:55:59 2007 UTC (7 years, 2 months ago) by hasso
Branches: MAIN
Diff to: previous 1.175: preferred, unified
Changes since revision 1.175: +0 -1 lines
Nuke token ring support. This also means one blob less in DragonFly.

Revision 1.175: download - view: text, markup, annotated - select for diffs
Mon Aug 27 13:15:13 2007 UTC (7 years, 2 months ago) by hasso
Branches: MAIN
Diff to: previous 1.174: preferred, unified
Changes since revision 1.174: +0 -1 lines
Nuke ARCnet support.

Revision 1.174: download - view: text, markup, annotated - select for diffs
Thu Aug 16 20:38:33 2007 UTC (7 years, 2 months ago) by hasso
Branches: MAIN
Diff to: previous 1.173: preferred, unified
Changes since revision 1.173: +1 -0 lines
Add umsm(4) driver for EVDO and UMTS modems with Qualcomm MSM chipsets.

Obtained-from: OpenBSD

Revision 1.173: download - view: text, markup, annotated - select for diffs
Thu Aug 16 20:03:52 2007 UTC (7 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.172: preferred, unified
Changes since revision 1.172: +2 -0 lines
Bring CARP into the tree.  CARP = Common Address Redundancy Protocol, which
allows an IP address to hot switch to backup machine(s) when the master goes
offline.

Submitted-by:	Baptiste Ritter <baptiste.ritter@ulp.u-strasbg.fr>,
		Jonathan, and Nicolas
Testing-by:	Thomas Nikolajsen, Gergo Szakal
Obtained-from:	OpenBSD, NetBSD, and FreeBSD

Revision 1.172: download - view: text, markup, annotated - select for diffs
Wed Aug 15 14:34:02 2007 UTC (7 years, 2 months ago) by swildner
Branches: MAIN
Diff to: previous 1.171: preferred, unified
Changes since revision 1.171: +1 -1 lines
Fix uslcom path.

Revision 1.171: download - view: text, markup, annotated - select for diffs
Tue Aug 14 22:28:11 2007 UTC (7 years, 2 months ago) by hasso
Branches: MAIN
Diff to: previous 1.170: preferred, unified
Changes since revision 1.170: +1 -0 lines
Add uark(4) driver which supports Arkmicro Technologies ARK3116 chip found
in some USB to serial adapters.

Obtained-from: OpenBSD

Revision 1.170: download - view: text, markup, annotated - select for diffs
Tue Aug 14 08:53:58 2007 UTC (7 years, 2 months ago) by hasso
Branches: MAIN
Diff to: previous 1.169: preferred, unified
Changes since revision 1.169: +1 -0 lines
Add uslcom(4) driver which provides support for USB devices based on
Silicon Laboratories CP120x USB-UART bridges.

Obtained-from: OpenBSD

Revision 1.169: download - view: text, markup, annotated - select for diffs
Mon Aug 13 17:49:14 2007 UTC (7 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.168: preferred, unified
Changes since revision 1.168: +4 -0 lines
Part 1/many USERFS support.  Bring in the initial userfs infrastructure.
Add syslink-based mount support.  Most of the VOPs are still just dummy
wrappers with this commit.  USERFS is not yet linked into the build.

Revision 1.168: download - view: text, markup, annotated - select for diffs
Thu Aug 2 23:44:48 2007 UTC (7 years, 2 months ago) by pavalos
Branches: MAIN
Diff to: previous 1.167: preferred, unified
Changes since revision 1.167: +2 -2 lines
Add an ISA attachment to the aic7xxx driver to handle 284X controllers.

This was sleeping in my tree and was somehow forgotten earlier.

Revision 1.166.2.1: download - view: text, markup, annotated - select for diffs
Tue Jul 31 22:40:49 2007 UTC (7 years, 2 months ago) by dillon
Branches: DragonFly_RELEASE_1_10
CVS tags: DragonFly_RELEASE_1_10_Slip
Diff to: previous 1.166: preferred, unified; next MAIN 1.167: preferred, unified
Changes since revision 1.166: +1 -0 lines
Synchronize all changes made in HEAD to date with the 1.10 release branch.

* usbdevs update
* header file fixes
* vinum root
* vinum device I/O fixes
* MD fixes
* New PCI ids for netif rum and ural
* New USB uplcom ids
* linux exec memory leak
* devclass ordering fixes (sound devices)
* rate-limited kprintf support (filesystem full console spams)
* msdosfs fixes
* Manual page work

Revision 1.167: download - view: text, markup, annotated - select for diffs
Mon Jul 30 08:02:36 2007 UTC (7 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.166: preferred, unified
Changes since revision 1.166: +1 -0 lines
Add infrastructure to locate a disk device by name by scanning the disk
list.  Note: This doesn't work with the 'vn' device yet but it does work
with ccd.

Add a VFS with a dummy mount which is capable of synthesizing vnodes for
devices.

Add infrastructure that allows easy opening and closing of a device-backed
vnode.

Revision 1.166: download - view: text, markup, annotated - select for diffs
Thu Jul 5 12:08:53 2007 UTC (7 years, 3 months ago) by sephe
Branches: MAIN
Branch point for: DragonFly_RELEASE_1_10
Diff to: previous 1.165: preferred, unified
Changes since revision 1.165: +2 -1 lines
Update cardbus/pccard support.

The original patch was done by joerg@; I seemed to "maintain"
it for quite a long time :P

Obtained-from: FreeBSD
Tested-by: many (intermittently tho)

Revision 1.165: download - view: text, markup, annotated - select for diffs
Tue Jun 26 19:30:46 2007 UTC (7 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.164: preferred, unified
Changes since revision 1.164: +3 -3 lines
Repo-copy numerous files from sys/emulation/posix4 to sys/sys and sys/kern
and adjust the build to suit.  posix scheduling is here to stay.

Submitted-by: Joe Talbott <josepht@cstone.net>

Revision 1.164: download - view: text, markup, annotated - select for diffs
Mon Jun 18 05:13:32 2007 UTC (7 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.163: preferred, unified
Changes since revision 1.163: +2 -0 lines
Move all the code related to handling the current 32 bit disklabel
to subr_disklabel32.c.  Move the header file from sys/disklabel.h to
sys/disklabel32.h.  Rename all the related structures and constants
and retire 'struct disklabel'.

Redo the sys/disklabel.h header file to implement a generic disklabel
abstraction.  Modify kern/subr_diskslice.c to use this abstraction, with
some shims for the ops dispatch at the moment which will be cleaned up later.

Adjust all auxillary code that directly accesses 32 bit disklabels to use
the new structure and constant names.

Remove the snoop-adjust code.  The kernel would snoop reads and writes to
the disklabel area via the raw slice device (e.g. ad0s1) and convert the
disklabel from the in-core format to the on-disk format and vise-versa.
The reads and writes made by disklabel -r and the kernel's own internal
readdisklabel and writedisklabel code used the snooping.

Rearrange the kernel's internal code to manually convert the disklabel when
reading and writing.  Rearrange the /sbin/disklabel program to do the same
when the -r option is used.  Have the disklabel program also check which
DragonFly OS it is running under so it can be run on older systems.  Note
that the disklabel binary prior to these changes will NOT operate on the
disklabel properly if running on a NEW kernel.

Introduce skeleton files for 64 bit disklabel support.

Revision 1.163: download - view: text, markup, annotated - select for diffs
Sun Jun 17 20:33:14 2007 UTC (7 years, 4 months ago) by swildner
Branches: MAIN
Diff to: previous 1.162: preferred, unified
Changes since revision 1.162: +1 -0 lines
* Add a missing KMODDEP to ng_eiface and hook it into the build. [*]

* Add a ng_eiface(4) manual page from FreeBSD-4 [*] and add a reference
  to it in netgraph(4).

* Add a NETGRAPH_EIFACE kernel config option.

* Sync libnetgraph with our node types.


[*] Submitted-by: Nuno-Antunes <nuno.antunes@gmail.com>

Revision 1.162: download - view: text, markup, annotated - select for diffs
Sat Jun 16 19:48:04 2007 UTC (7 years, 4 months ago) by hasso
Branches: MAIN
Diff to: previous 1.161: preferred, unified
Changes since revision 1.161: +3 -0 lines
Bring in the latest sound changes from RELENG_6.

Obtained-from: FreeBSD

Revision 1.161: download - view: text, markup, annotated - select for diffs
Sat Jun 16 18:55:28 2007 UTC (7 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.160: preferred, unified
Changes since revision 1.160: +1 -0 lines
Import the kernel GPT and UUID header files from FreeBSD, and bring in
kern_uuid.c from FreeBSD.

Revision 1.160: download - view: text, markup, annotated - select for diffs
Sat May 26 08:50:49 2007 UTC (7 years, 5 months ago) by sephe
Branches: MAIN
Diff to: previous 1.159: preferred, unified
Changes since revision 1.159: +1 -0 lines
Add support for Broadcom NetXtreme II GigE.  Jumbo buffer support
is missing currently, which will be added later.

Thank David Christensen <davidch@broadcom.com> for sending us two
sample NICs.
Thank dillon@ for providing a blazing fast machine and environment
to test the driver.
Also thank Walter <wa1ter@myrealbox.com> very much, who contacted
Broadcom for me :)

Obtained-from: FreeBSD (w/ modification)

Revision 1.159: download - view: text, markup, annotated - select for diffs
Sun Apr 29 01:29:30 2007 UTC (7 years, 5 months ago) by dillon
Branches: MAIN
Diff to: previous 1.158: preferred, unified
Changes since revision 1.158: +1 -0 lines
Implement SYSREF - structural reference counting, allocation, and sysid
management subsystem.

* Structural reference count management, including creation and termination
  sequencing (e.g. where the structure might be temporarily referenced
  during termination).

* Allocation.  It uses an objcache backend for optimal allocation,
  deallocation, and memory recovery.

* Sysid assignment and red-black tree indexing.  It does this in the
  objcache CTOR and DTOR so it costs us absolutely nothing in the
  resource allocation / deallocation critical path.  sysids will be
  reused unless they are externally accessed.

Revision 1.158: download - view: text, markup, annotated - select for diffs
Thu Apr 26 02:10:57 2007 UTC (7 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.157: preferred, unified
Changes since revision 1.157: +2 -1 lines

Move syslink_desc to sys/syslink_rpc.h so kernel code does not need
to #include sys/syslink.h.  Add a kernel config option 'SYSLINK' to build
with kern_syslink.c, so it can be worked on (read: broken) without
interfering with other developer's kernel builds.  Add a shims file for
the syslink() system call for kernels not built with kern_syslink.c.  The
shims file can be used generally for this purpose.

Revision 1.157: download - view: text, markup, annotated - select for diffs
Sun Apr 22 01:13:08 2007 UTC (7 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.156: preferred, unified
Changes since revision 1.156: +1 -0 lines
Give the sockbuf structure its own header file and supporting source file.
Move all sockbuf-specific functions from kern/uipc_socket2.c into the new
kern/uipc_sockbuf.c and move all the sockbuf-specific structures from
sys/socketvar.h to sys/sockbuf.h.

Change the sockbuf structure to only contain those fields required to
properly management a chain of mbufs.  Create a signalsockbuf structure
to hold the remaining fields (e.g. selinfo, mbmax, etc).

Change the so_rcv and so_snd structures in the struct socket from
a sockbuf to a signalsockbuf.

Remove the recently added sorecv_direct structure which was being used
to provide a direct mbuf path to consumers for socket I/O.  Use the newly
revamped sockbuf base structure instead.  This gives mbuf consumers
direct access to the sockbuf API functions for use outside of a struct
socket.  This will also allow new API functions to be added to the sockbuf
interface to ease the job of parsing data out of chained mbufs.

Revision 1.156: download - view: text, markup, annotated - select for diffs
Mon Apr 9 17:09:56 2007 UTC (7 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.155: preferred, unified
Changes since revision 1.155: +1 -0 lines
Add subr_alist.c.  This is a bitmap allocator that works very similarly to
subr_blist.c (swap allocator), but with added considerations.

1. All allocations must be in powers of 2.
2. All allocations will be aligned to the allocation size.
3. No allocation size limit (blist was limited to 32 blocks per allocation)

Like the blist allocator, the alist is arranged in a linear array suitable
for direct mapping onto a storage medium.  A dataspace of 2^31-1 blocks may
be represented.  Approximately 3 bits of kernel memory is used per block.

This allocator will be used by HAMMER and ANVIL (filesystem and filesystem
storage manager), and by syslink route nodes to chop out individual addresses
and subnets.  We may also use this allocator to improve the allocation of
physical memory.

Revision 1.155: download - view: text, markup, annotated - select for diffs
Sat Apr 7 21:07:21 2007 UTC (7 years, 6 months ago) by swildner
Branches: MAIN
Diff to: previous 1.154: preferred, unified
Changes since revision 1.154: +0 -2 lines
Remove the hostcache code which has been inactive since 1998.

Revision 1.154: download - view: text, markup, annotated - select for diffs
Mon Apr 2 14:25:38 2007 UTC (7 years, 6 months ago) by sephe
Branches: MAIN
Diff to: previous 1.153: preferred, unified
Changes since revision 1.153: +0 -1 lines
Nuke old TX rate control algorithm coming with ral(4).

Revision 1.153: download - view: text, markup, annotated - select for diffs
Sun Apr 1 13:59:41 2007 UTC (7 years, 6 months ago) by sephe
Branches: MAIN
Diff to: previous 1.152: preferred, unified
Changes since revision 1.152: +1 -0 lines
- Define 802.11 modulation types as 'enum ieee80211_modtype'.
- Expose ieee80211_rate2modtype() for pubic use.
- Add definition for DIFS, slot time and contention window.
- Add addition field in TX rate control state structure, so drivers can
  give hints to TX rate control algorithms about their capabilities.
- Add Sample TX rate control support:
  http://www.pdos.lcs.mit.edu/papers/jbicket-ms.pdf
  It is factored out and adapted from the one in ath(4).
- In ieee80211_ratectl.h, expose only IEEE80211_RATECTL_{ONOE,AMRR,SAMPLE}
  for user space program.
- Teach ifconfig(8) to show and set Sample TX rate control algorithm.
- Fix a node leakage on rt2560_tx_mgt() error handling path.
- Support Onoe and Sample TX rate control algorithm in 2560 part of
  ral(4), and use Sample TX rate control algorithm as the default TX
  rate control algorithm. [*]
- Make ral(4) depend on wlan_ratectl_{onoe,sample}.
- Hook Sample TX rate control algorithm into GENERIC and LINT.

# [*]
# If Sample TX rate control algorithm is used, I get almost 100~200%
# UDP_STREAM netperf TX performance boost than the original TX rate
# control algorithm in open/noisy enviroments, and +200~500Kbits/s
# UDP_STREAM netperf TX performance boost under good conditions.

Revision 1.152: download - view: text, markup, annotated - select for diffs
Sun Feb 11 01:51:28 2007 UTC (7 years, 8 months ago) by swildner
Branches: MAIN
Diff to: previous 1.151: preferred, unified
Changes since revision 1.151: +0 -1 lines
Remove ancient SimOS support.

Revision 1.151: download - view: text, markup, annotated - select for diffs
Thu Feb 1 10:33:25 2007 UTC (7 years, 8 months ago) by corecode
Branches: MAIN
Diff to: previous 1.150: preferred, unified
Changes since revision 1.150: +1 -0 lines
Change kinfo_proc interface between kernel and userland.

Before, we were embedding a struct proc (among others) into struct
kinfo_proc.  Every time we change implementation details in the kernel,
userland has to be adapted (recompiled).  In preparation for the coming
LWP changes this interface has been reworked.  Now kinfo_proc is a
structure which does not depend on other structures on the kernel which
are subject to change.  Instead, the routines fill_kinfo_proc and
fill_kinfo_lwp copy all values which are of interest between the kernel
structure and the stable kinfo_proc structure.

Furthermore, this change adds infrastructure to export LWP-specific data.
If userland requests LWP data, it sets the flag KERN_PROC_FLAG_LWP in the
sysctl oid.  This leads to multiple kinfo_procs being exported.  If not
set, the first LWP will used.  This is like FreeBSD do it, and it seems
easy and simple.  Note that userland was not yet adjusted to actually
request LWPs and aggregate this information if necessary.  Besides, the
kernel does not yet have more than one LWP per process anyways.

This introduces a new file, kern/kern_kinfo.c, which is shared between
kernel and libkvm.  This was done to avoid and remove code duplication.
Now kvm_getprocs constructs a complete struct proc, including pointers,
and then calls fill_kinfo_proc to do its job.

In-collaboration-with: Thomas E. Spanjaard <tgen@netphreax.net>

Revision 1.150: download - view: text, markup, annotated - select for diffs
Wed Jan 17 17:31:19 2007 UTC (7 years, 9 months ago) by y0netan1
Branches: MAIN
CVS tags: DragonFly_RELEASE_1_8_Slip, DragonFly_RELEASE_1_8
Diff to: previous 1.149: preferred, unified
Changes since revision 1.149: +9 -4 lines
Update ACPI build wrappers to use new ACPI-CA code.
* many fixes in ACPI-CA code (see changes.txt for detail)

* enable interpreter slack code
  relaxed checking on AML code to get fewer warnings

* use OS implementation of spinlock and cache object:
  OSL cache code by:
	  Jeffrey Hsu <hsu@dragonflybsd.org>
  Fix to semaphore and locking code:
	  Simon 'corecode' Schubert <corecode@fs.ei.tum.de>

* added a few debugging knobs(on make command line):
  ACPI_DEBUG_LOCKS=yes to activate debugging code for AcpiOs*Lock()
  ACPI_DEBUG_MEMMAP=yes to activate debugging code for AcpiOs*MapMemory()

Revision 1.149: download - view: text, markup, annotated - select for diffs
Mon Jan 8 01:38:02 2007 UTC (7 years, 9 months ago) by swildner
Branches: MAIN
Diff to: previous 1.148: preferred, unified
Changes since revision 1.148: +1 -3 lines
* Sync with FreeBSD-RELENG_6.

* Add some devices to LINT.

* Do some cleanup in sys/conf/files.

OK-by: corecode

Revision 1.148: download - view: text, markup, annotated - select for diffs
Thu Jan 4 21:47:00 2007 UTC (7 years, 9 months ago) by corecode
Branches: MAIN
Diff to: previous 1.147: preferred, unified
Changes since revision 1.147: +52 -72 lines
Say hello to a sound system update from FreeBSD.  This includes the long
awaited Intel High Definition Audio (HDA) a.k.a. Azalia support.

The generic sound support module has been renamed to sound.ko and the
"everything included" module is called snd_driver.ko now.  Apart from
that, everything should continue working as normal, just better.

Revision 1.147: download - view: text, markup, annotated - select for diffs
Sun Dec 17 20:07:27 2006 UTC (7 years, 10 months ago) by dillon
Branches: MAIN
Diff to: previous 1.146: preferred, unified
Changes since revision 1.146: +1 -0 lines
Repo copy machine/pc32/i386/mem.c to kern/kern_memio.c and separate out
the (few) machine-dependant parts.  This file primarily controls access
to /dev/zero, /dev/null, /dev/random, and kernel memory, and does not belong
in a machine-dependant directory.

Revision 1.146: download - view: text, markup, annotated - select for diffs
Thu Dec 14 16:20:22 2006 UTC (7 years, 10 months ago) by swildner
Branches: MAIN
Diff to: previous 1.145: preferred, unified
Changes since revision 1.145: +1 -0 lines
Make umct compilable into the kernel and add it to LINT.

Revision 1.145: download - view: text, markup, annotated - select for diffs
Sun Dec 10 04:59:38 2006 UTC (7 years, 10 months ago) by sephe
Branches: MAIN
Diff to: previous 1.144: preferred, unified
Changes since revision 1.144: +2 -0 lines
- Hook rum(4) and ural(4) into GENERIC and LINT
- Hook rum(4) and ural(4) into module building
- Enable wlan_ratectl_onoe in GENERIC.  It is required by rum(4) and ural(4)
- Add a commented-out entry in GENERIC for wlan_ratectl_amrr
- Enable rtw(4) in GENERIC again

Revision 1.144: download - view: text, markup, annotated - select for diffs
Mon Dec 4 14:40:36 2006 UTC (7 years, 10 months ago) by tgen
Branches: MAIN
Diff to: previous 1.143: preferred, unified
Changes since revision 1.143: +16 -0 lines
Initial import of the port of the new(er) FreeBSD ATA code.

Note this code has not yet been hooked into the build as such, unless you (unwisely) specify the devices in your kernel config according to sys/conf/files. The modules are also excluded from the module build due to not having a SUBDIR entry in sys/dev/disk/Makefile. The PCI code isn't yet operation pending a patch for sys/bus/pci/pci.c I will send to kernel@ shortly. It short-circuits lazy resource allocation for PCI ATA controllers in legacy mode (i.e. on legacy ISA ATA addresses, which are not configured in the PCI BARs).

The userland utility used to control nata ('natacontrol') and documentation will follow later. Also, be aware only nata, natapci, natadisk and natapicd have seen testing on real hardware so far. nataraid, natausb and natacam are probably not compilable yet, I need to clean those up.

Revision 1.143: download - view: text, markup, annotated - select for diffs
Thu Nov 16 13:43:55 2006 UTC (7 years, 11 months ago) by sephe
Branches: MAIN
Diff to: previous 1.142: preferred, unified
Changes since revision 1.142: +2 -0 lines
- Add stge(4) for Sundance/Tamarack TC9021 Gigabit Ethernet chip.
  It supports following cards:
    o  Antares Microsystems Gigabit Ethernet
    o  ASUS NX1101 Gigabit Ethernet
    o  D-Link DGE-550T Gigabit Ethernet
    o  IC Plus IP1000A Gigabit Ethernet
    o  Sundance ST-2021 Gigabit Ethernet
    o  Sundance ST-2023 Gigabit Ethernet
    o  Sundance TC9021 Gigabit Ethernet
    o  Tamarack TC9021 Gigabit Ethernet
- Add PHY module for IC Plus IP1000A integrated PHY, which may be used
  by some on-board stge(4)
- Hook stge(4) into GENERIC and LINT

Obtained-from: FreeBSD (yongari@freebsd.org)

Revision 1.131.2.1: download - view: text, markup, annotated - select for diffs
Sun Sep 17 15:39:41 2006 UTC (8 years, 1 month ago) by joerg
Branches: DragonFly_RELEASE_1_6
CVS tags: DragonFly_RELEASE_1_6_Slip
Diff to: previous 1.131: preferred, unified; next MAIN 1.132: preferred, unified
Changes since revision 1.131: +0 -1 lines
MFC 1.142:
null_subr.c doesn't exist anymore.

Revision 1.142: download - view: text, markup, annotated - select for diffs
Sun Sep 17 15:37:48 2006 UTC (8 years, 1 month ago) by joerg
Branches: MAIN
Diff to: previous 1.141: preferred, unified
Changes since revision 1.141: +0 -1 lines
nullfs_subr doesn't exist anymore.

Revision 1.141: download - view: text, markup, annotated - select for diffs
Tue Sep 5 16:18:58 2006 UTC (8 years, 1 month ago) by dillon
Branches: MAIN
Diff to: previous 1.140: preferred, unified
Changes since revision 1.140: +1 -0 lines
Move the code that eats certain PNP IDs into a ISA bus-specific file.

Revision 1.140: download - view: text, markup, annotated - select for diffs
Sun Sep 3 17:11:47 2006 UTC (8 years, 1 month ago) by dillon
Branches: MAIN
Diff to: previous 1.139: preferred, unified
Changes since revision 1.139: +1 -0 lines
Add skeleton procedures for the vmspace_*() series of system calls which
will be used by virtual kernels to implement processes.

Revision 1.139: download - view: text, markup, annotated - select for diffs
Sun Sep 3 07:37:58 2006 UTC (8 years, 1 month ago) by sephe
Branches: MAIN
Diff to: previous 1.138: preferred, unified
Changes since revision 1.138: +5 -0 lines
- Port rtw(4) from NetBSD, which supports various RealTek 8180 chip based
  wireless NIC.
- Put NetBSD 802.11 duration related structures and functions in rtw.c and
  rtwvar.h, and rename them to rtw_xxxx.
- Fix various ieee80211_node leakages in TX path.
- Use spare RX DMA map to recover from bus_dmamap_load_mbuf() failure.
- Utilize TX rate control algorithm framework in our 802.11 layer, support
  Onoe TX rate control algorithm.
- Hook rtw(4) into module building.
- Hook rtw(4) into GENERIC and LINT.

Thank David Young and many other people for their work on this driver.

Tested with a Linksys WPC11 ver.4

Revision 1.138: download - view: text, markup, annotated - select for diffs
Fri Sep 1 15:12:11 2006 UTC (8 years, 1 month ago) by sephe
Branches: MAIN
Diff to: previous 1.137: preferred, unified
Changes since revision 1.137: +4 -0 lines
Implement a generic TX rate control algorithm framework in 802.11 layer.
It is highly modulized so TX rate control algorithms can be added with ease.
Only limited interfaces are exported for driver to use, so most of the WiFi
drivers can be converted without too much trouble.  It does not affect WiFi
drivers which are unaware of the new framework yet.  Also, the new framework
allows TX rate control algorithm to be changed without touching the 802.11
state machine or reinitializing WiFi devices.

Two TX rate control algorithms are factored out from ath(4) driver:
1) Onoe TX rate control algorithm, which is suitable for almost any kinds of
   WiFi NIC driver, especially for 11b devices. (*)
2) AMRR TX rate control algorithm, which should _only_ be used by the WiFi NIC
   which supports multi-rate retry.  More information of this TX rate control
   algorithm is available at:
   http://www-sop.inria.fr/rapports/sophia/RR-5208.html

In order to use the framework, individual WiFi driver needs to do following:
1) Tell the framework, which TX rate control algorithms it supports and which
   one to be used as the default, by setting up ieee80211com.ic_ratectl.
2) Call ieee80211_ratectl_newstate() in driver's own newstate() function.
3) When set up hardware TX descriptors, which normally contain TX rate related
   fields, instead of accessing ieee80211_node.ni_txrate directly, call
   ieee80211_ratectl_findrate() to get a rate set from the framework.
4) When TX completes, feed TX state (e.g. failure, number of retries) to the
   framework by calling ieee80211_ratectl_tx_complete().

Teach ifconfig(8) to print and set the TX rate control algorithm.


# (*) There is no formal paper for this algorithm, but following two papers
#     have brief introduction of this TX rate control algorithm:
#     http://www-sop.inria.fr/rapports/sophia/RR-5208.html
#     http://www.pdos.lcs.mit.edu/papers/jbicket-ms.pdf

Revision 1.137: download - view: text, markup, annotated - select for diffs
Sun Aug 27 03:41:46 2006 UTC (8 years, 2 months ago) by sephe
Branches: MAIN
Diff to: previous 1.136: preferred, unified
Changes since revision 1.136: +1 -0 lines
Add an entry for nfe(4)

Revision 1.136: download - view: text, markup, annotated - select for diffs
Wed Aug 23 06:45:38 2006 UTC (8 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.135: preferred, unified
Changes since revision 1.135: +1 -0 lines
Bring in the initial cut of the Cache Coherency Management System module.
Add a sysctl kern.ccms_enable for testing.  CCMS operations are disabled by
default.

The comment below describes the whole enchillada.  Only basic locking has
been implemented in this commit.

CCMS is a duel-purpose cache management layer based around offset ranges.

#1 - Threads on the local machine can obtain shared, exclusive, and modifying
     range locks.  These work kinda like lockf locks and the kernel will use
     them to enforce UNIX I/O atomicy rules.

#2 - The BUF/BIO/VM system can manage the cache coherency state for offset
     ranges.  That is, Modified/Exclusive/Shared/Invalid (and two more
     advanced states).

     These cache states to not represent the state of data we have cached.
     Instead they represent the best case state of data we are allowed
     to cache within the range.

     The cache state for a single machine (i.e. no cluster), for every
     CCMS data set, would simply be 'Exclusive' or 'Modified' for the
     entire 64 bit offset range.

The way this works in general is that the locking layer is used to enforce
UNIX I/O atomicy rules locally and to generally control access on the local
machine.  The cache coherency layer would maintain the cache state for
the object's entire offset range.  The local locking layer would be used
to prevent demotion of the underlying cache state, and modifications to the
cache state might have the side effect of communicating with other machines
in the cluster.

Take a typical write().  The offset range in the file would first be locked,
then the underlying cache coherency state would be upgraded to Modified.
If the underlying cache state is not compatible with the desired cache
state then communication might occur with other nodes in the cluster in
order to gain exclusive access to the cache elements in question so they
can be upgraded to the desired state.  Once upgraded, the range lock
prevents downgrading until the operation completes.  This of course can
result in a deadlock between machines and deadlocks would have to be dealt
with.

Likewise, if a remote machine needs to upgrade its representation of
the cache state for a particular file it might have to communicate with
us in order to downgrade our cache state.  If a remote machine
needs an offset range to be Shared then we have to downgrade our
cache state for that range to Shared or Invalid.  This might have side
effects on us such as causing any dirty buffers or VM pages to be flushed
to disk.  If the remote machine needs to upgrade its cache state to
Exclusive then we have to downgrade ours to Invalid, resulting in a
flush and discard of the related buffers and VM pages.

Both range locks and range-based cache state is stored using a common
structure called a CST, in a red-black tree.  All operations are
approximately N*LOG(N).  CCMS uses a far superior algorithm to the one
that the POSIX locking code (lockf) has to use.

It is important to note that layer #2 cache state is fairly persistent
while layer #1 locks tend to be ephermal.  To prevent too much
fragmentation of the data space the cache state for adjacent elements
may have to be actively merged (either upgraded or downgraded to match).
The buffer cache and VM page caches are naturally fragmentory, but we
really do not want the CCMS representation to be too fragmented.  This
also gives us the opportunity to predispose our CCMS cache state so
I/O operations done on the local machine are not likely to require
communication with other hosts in the cluster.  The cache state as
stored in CCMS is a superset of the actual buffers and VM pages cached
on the local machine.

Revision 1.135: download - view: text, markup, annotated - select for diffs
Thu Aug 17 22:07:33 2006 UTC (8 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.134: preferred, unified
Changes since revision 1.134: +0 -7 lines
Remove the coda fs.  It hasn't worked in a long time.

Revision 1.134: download - view: text, markup, annotated - select for diffs
Sun Aug 6 18:56:42 2006 UTC (8 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.133: preferred, unified
Changes since revision 1.133: +1 -0 lines
Add structures and skeleton code for a new system call called syslink()
which will support the kernel syslink API.  This is the link protocol that
will be used for user<->kernel (e.g. user VFS) and kernel<->kernel (cluster)
communications.

Syslink-based protocols will be used for DEV, VFS, CCMS, and other
cluster-related operations.

Revision 1.133: download - view: text, markup, annotated - select for diffs
Sun Aug 6 10:32:23 2006 UTC (8 years, 2 months ago) by sephe
Branches: MAIN
Diff to: previous 1.132: preferred, unified
Changes since revision 1.132: +0 -1 lines
Sync MII support with NetBSD/OpenBSD:
- Standard conforming GMII support:
  1) replace mii_media_add() with mii_phy_add_media().
  2) ukphy has generic GMII support now, thus retire nvphy.
- Factor common code of PHY modules out into mii_physubr.c, noticably
  mii_phy_{set_media, tick, update}().
  In order to support this refactoring:
  1) mii_softc.{mii_reset,mii_status} funtion pointers are added, which are
     used to reset PHY modules and get PHY modules' status.
  2) mii_softc.mii_anegticks is added, which is used by PHY modules to tell
     mii_phy_tick(), how often auto-negociation should happen.  Two commonly
     used values are defined as MII_ANEGTICKS and MII_ANEGTICKS_GIGE.
     mii_softc.mii_anegticks is set to MII_ANEGTICKS by default.
- Add mii_softc.mii_media_status and rename mii_softc.mii_active to
  mii_softc.mii_media_active.  Now changes in either one of them will cause
  MIIBUS_STATCHG() being involked.
- For PHY modules that utilize mii_phy_add_media(), ifmedia_entry.ifm_data
  no longer stores value of BMCR.  It stores an index of mii_media_table[],
  which stores BMCR, ANAR and GTCR.
- Replace slightly different PHY modules detach routines with ukphy_detach().
- Use OUI and MODEL id array + mii_phy_match() in PHY modules probe routines,
  instead of original large `if, else if' or `switch' code segment.
- Support more OUIs and MODELs in individual PHY module.
- Make the usage of `mii' and `sc' stack variable more consistent.  `mii'
  refers to miibus softc, while `sc' refers to PHY module softc.
- Nuke no longer used functions' definition and declaration.
- Regen miidevs.h

Following PHY modules were tested:
acphy(dc), brgphy(bge), e1000phy(nv,sk), exphy(xl), inphy(fxp), rgephy(re),
rlphy(rl), ruephy(rue), ukphy(nv,vr,...)

MII generic code is mainly synced with NetBSD.
Individual PHY modules are mainly synced with OpenBSD.

Tested-by: swildner, corecode

Revision 1.132: download - view: text, markup, annotated - select for diffs
Fri Jul 28 02:17:34 2006 UTC (8 years, 3 months ago) by dillon
Branches: MAIN
Diff to: previous 1.131: preferred, unified
Changes since revision 1.131: +0 -1 lines
MASSIVE reorganization of the device operations vector.  Change cdevsw
to dev_ops.  dev_ops is a syslink-compatible operations vector structure
similar to the vop_ops structure used by vnodes.

Remove a huge number of instances where a thread pointer is still being
passed as an argument to various device ops and other related routines.
The device OPEN and IOCTL calls now take a ucred instead of a thread pointer,
and the CLOSE call no longer takes a thread pointer.

Revision 1.131: download - view: text, markup, annotated - select for diffs
Fri Jul 7 14:16:29 2006 UTC (8 years, 3 months ago) by sephe
Branches: MAIN
Branch point for: DragonFly_RELEASE_1_6
Diff to: previous 1.130: preferred, unified
Changes since revision 1.130: +5 -3 lines
- Replace lnc(4) driver with NetBSD's le(4), which gives us better performance,
  especially for VMWare users.
- Sync lnc(4) manpage.

Submitted-by: Bill Marquette <bill.marquette@gmail.com>
Manpage-reviewed-and-adjusted-by: swildner

Revision 1.130: download - view: text, markup, annotated - select for diffs
Sun Jun 25 11:02:37 2006 UTC (8 years, 4 months ago) by corecode
Branches: MAIN
Diff to: previous 1.129: preferred, unified
Changes since revision 1.129: +0 -1 lines
Remove OLDBRIDGE

Revision 1.129: download - view: text, markup, annotated - select for diffs
Sun Jun 18 01:33:29 2006 UTC (8 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.128: preferred, unified
Changes since revision 1.128: +1 -1 lines
Replace the random number generator with an IBAA generator for /dev/random
and a L15 generator for /dev/urandom.

Submitted-by: Robin J Carey
Modified-from-original: Syntax adjusted to DragonFly kernel norms, and I
	integrated the original code into the DragonFly kernel random number
	generator API.  Also added a TSC-based seed on top of nanouptime.

Revision 1.128: download - view: text, markup, annotated - select for diffs
Wed Jun 7 03:02:07 2006 UTC (8 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.127: preferred, unified
Changes since revision 1.127: +0 -1 lines
Remove the asynchronous system call interface sendsys/waitsys.  It was an
idea before its time.

Revision 1.127: download - view: text, markup, annotated - select for diffs
Sun Jun 4 21:09:45 2006 UTC (8 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.126: preferred, unified
Changes since revision 1.126: +0 -1 lines
Remove LWKT reader-writer locks (kern/lwkt_rwlock.c).  Remove lwkt_wait
queues (only RW locks used them).  Convert remaining uses of RW locks to
LOCKMGR locks.

In recent months lockmgr locks have been simplified to the point where we
no longer need a lighter-weight fully blocking lock.  The removal also
simplifies lwkt_schedule() in that it no longer needs a special case to
deal with wait lists.

Revision 1.126: download - view: text, markup, annotated - select for diffs
Mon May 29 03:57:16 2006 UTC (8 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.125: preferred, unified
Changes since revision 1.125: +1 -0 lines
Further isolate the user process scheduler data by moving more variables
from the globaldata structure to the scheduler module(s).

Make the user process scheduler MP safe.  Make the LWKT 'pull thread'
(to a different cpu) feature MP safe.  Streamline the user process
scheduler API.

Do a near complete rewrite of the BSD4 scheduler.  Remote reschedules
(reschedules to other cpus), cpu pickup of queued processes, and locality
of reference handling should make the new BSD4 scheduler a lot more
responsive.

Add a demonstration user process scheduler called 'dummy'
(kern/usched_dummy.c).  Add a kenv variable 'kern.user_scheduler' that
can be set to the desired scheduler on boot (i.e. 'bsd4' or 'dummy').

NOTE: Until more of the system is taken out from under the MP lock,
these changes actually slow things down slightly.  Buildworlds are
about ~2.7% slower.

Revision 1.125: download - view: text, markup, annotated - select for diffs
Tue May 23 20:35:07 2006 UTC (8 years, 5 months ago) by dillon
Branches: MAIN
Diff to: previous 1.124: preferred, unified
Changes since revision 1.124: +1 -0 lines
Move all the resource limit handling code into a new file, kern/kern_plimit.c.
Add spinlocks for access, and mark getrlimit and setrlimit as being MPSAFE.

Document how LWPs will have to be handled - basically we will have to unshare
the resource structure once we start allowing multiple LWPs per process, but
we can otherwise leave it in the proc structure.

Revision 1.124: download - view: text, markup, annotated - select for diffs
Mon May 22 06:26:29 2006 UTC (8 years, 5 months ago) by swildner
Branches: MAIN
Diff to: previous 1.123: preferred, unified
Changes since revision 1.123: +0 -1 lines
Mop up remains of the ibcs2/streams/svr4 removal:

* Remove streams(4) and svr4(4) manual pages.

* Add associated modules and their manual pages to the list of files
  to be removed upon 'make upgrade'.

* Remove IBCS2 and SPX_HACK options.

* Change M_ZOMBIE definition back to static.

* Fix miscellaneous references & comments.

Revision 1.123: download - view: text, markup, annotated - select for diffs
Sat May 20 09:13:09 2006 UTC (8 years, 5 months ago) by sephe
Branches: MAIN
Diff to: previous 1.122: preferred, unified
Changes since revision 1.122: +4 -0 lines
- Add ral(4) for Ralink RT2500/RT2501/RT2600 chip based wireless NIC
- Add ral(4) to GENERIC and LINT
- Add man page for ral(4)
  Reviewed-by: swildner

Thank Damien Bergamini for his work on this driver

For RT2500:
- Fix a ieee80211_node leakage
- Due to the inter-dependency nature of DONE/(ENCRYPT|DECRYPT) intr, reap desc
  rings twice if one of them comes.  This change gives me ~17.6% TX performance
  boost on my ASUS WL-107G (WPA is used here):
  Original way of TX/RX intr processing
  ------------------------------------------------------------
  Client connecting to sephe-test, TCP port 5001
  TCP window size: 32.5 KByte (default)
  ------------------------------------------------------------
  [  3] local 192.168.2.14 port 1063 connected with 192.168.2.254 port 5001
  [  3]  0.0- 5.0 sec  10.2 MBytes  17.1 Mbits/sec
  [  3]  5.0-10.0 sec  9.95 MBytes  16.7 Mbits/sec
  [  3] 10.0-15.0 sec  9.67 MBytes  16.2 Mbits/sec
  [  3] 15.0-20.0 sec  10.1 MBytes  17.0 Mbits/sec
  [  3] 20.0-25.0 sec  10.2 MBytes  17.1 Mbits/sec
  [  3] 25.0-30.0 sec  10.0 MBytes  16.8 Mbits/sec
  [  3] 30.0-35.0 sec  9.91 MBytes  16.6 Mbits/sec
  [  3] 35.0-40.0 sec  10.3 MBytes  17.2 Mbits/sec
  [  3] 40.0-45.0 sec  9.87 MBytes  16.6 Mbits/sec
  [  3] 45.0-50.0 sec  9.94 MBytes  16.7 Mbits/sec
  [  3] 50.0-55.0 sec  10.2 MBytes  17.2 Mbits/sec
  [  3] 55.0-60.0 sec  9.73 MBytes  16.3 Mbits/sec
  [  3]  0.0-60.0 sec    120 MBytes  16.8 Mbits/sec

  Adapted way of TX/RX intr processing
  ------------------------------------------------------------
  Client connecting to sephe-test, TCP port 5001
  TCP window size: 32.5 KByte (default)
  ------------------------------------------------------------
  [  3] local 192.168.2.14 port 1062 connected with 192.168.2.254 port 5001
  [  3]  0.0- 5.0 sec  11.8 MBytes  19.8 Mbits/sec
  [  3]  5.0-10.0 sec  11.5 MBytes  19.4 Mbits/sec
  [  3] 10.0-15.0 sec  11.1 MBytes  18.7 Mbits/sec
  [  3] 15.0-20.0 sec  12.0 MBytes  20.1 Mbits/sec
  [  3] 20.0-25.0 sec  12.6 MBytes  21.2 Mbits/sec
  [  3] 25.0-30.0 sec  11.7 MBytes  19.6 Mbits/sec
  [  3] 30.0-35.0 sec  12.3 MBytes  20.7 Mbits/sec
  [  3] 35.0-40.0 sec  11.9 MBytes  19.9 Mbits/sec
  [  3] 40.0-45.0 sec  11.9 MBytes  19.9 Mbits/sec
  [  3] 45.0-50.0 sec  12.2 MBytes  20.4 Mbits/sec
  [  3] 50.0-55.0 sec  12.1 MBytes  20.2 Mbits/sec
  [  3] 55.0-60.0 sec  12.3 MBytes  20.7 Mbits/sec
  [  3]  0.0-60.0 sec    143 MBytes  20.0 Mbits/sec

Obtained-from: FreeBSD

Revision 1.122: download - view: text, markup, annotated - select for diffs
Sat May 20 07:15:17 2006 UTC (8 years, 5 months ago) by sephe
Branches: MAIN
Diff to: previous 1.121: preferred, unified
Changes since revision 1.121: +2 -0 lines
- Add ciphy for PHY modules produced by Cicada Semiconductor
- Add vge(4) for VIA VT612x GigE, which may have ciphy as its PHY module
- Add vge(4) into GENERIC and LINT
- Add man page for vge(4)

Thank Bill Paul for his work on this driver.
Thank Sascha Wildner for preparing the man page.

Obtained-from: FreeBSD
Tested-by: herrgard <herrgard@gmail.com>

NOTE:
Although polling(4) is claimed to be supported by this driver, but it does not
work that well with vge(4) (extremely slow, ~7000ms for ping, as reported by
herrgard).

Revision 1.121: download - view: text, markup, annotated - select for diffs
Thu May 18 13:51:45 2006 UTC (8 years, 5 months ago) by sephe
Branches: MAIN
Diff to: previous 1.120: preferred, unified
Changes since revision 1.120: +14 -7 lines
Sync 802.11 support with FreeBSD6:
    "it includes completed 802.11g, WPA, 802.11i, 802.1x, WME/WMM, AP-side
     power-save, crypto plugin framework, authenticator plugin framework,
     and access control plugin frameowrk."

Reoriganize the layout of netproto/802_11: put generic 802.11 layer, crypto
modules, authentication module and access control module into their own
directories.  Header files are still in their original place.

Nuke all of the mutexing in generic 802.11, reorganize ieee80211_node table
scanning a little bit.

Rename FreeBSD's m_append() to ieee80211_mbuf_append(), rename FreeBSD's
m_unshare() to ieee80211_mbuf_clone() and put them into
netproto/802_11/wlan/ieee80211_dragonly.c
They are not generic enough for public using, at least for now.
Pointed-out-by: hsu

Expose ieee80211_add_{ssid, xrates, rates}() which are used by acx(4)

Keep using opencrypto's AES implmentation for 802.11 CCMP crypto module


Sync ifconfig(8)'s 802.11 support with FreeBSD6


Update acx(4) and ndis(4) for the new 802.11 support

Sync iwi(4), ipw(4), wi(4) and ray(4) with FreeBSD6

For iwi(4):
- Fix ieee80211_node leakage
- Use a bitmap instead of FreeBSD's "unit number alloctor" to allocate IBSS node


Add generic 802.11 layer and crypto modules into GENERIC and LINT,
authentication module and access module are only added to LINT

Unhook awi(4) from GENERIC and LINT temporarily, since as of this commit it
is broken :(  It will be fixed sometime later.


Thank Sam Leffler and many other people for their work on 802.11 support.

Thank Andrew Atrens and Adrian Michael Nida for submitting the patch.

Thank all the people that helped testing 802.11 patches for this commit


Based-on-Patch-Submitted-by:
  Andrew Atrens <atrens@nortelnetworks.com>
  Adrian Michael Nida <nida@musc.edu>

Tested-by:
  Thomas Schlesinger <schlesinger@netcologne.de>
  Johannes Hofmann <Johannes.Hofmann@gmx.de>
  Andrew Thompson <andrew@hijacked.us>
  Erik Wikström <erik-wikstrom@telia.com>

Revision 1.120: download - view: text, markup, annotated - select for diffs
Fri May 12 22:07:21 2006 UTC (8 years, 5 months ago) by dillon
Branches: MAIN
Diff to: previous 1.119: preferred, unified
Changes since revision 1.119: +0 -3 lines
UMAPFS has been disabled (and non-working) for a long time.  Scrap it
entirely.

Revision 1.119: download - view: text, markup, annotated - select for diffs
Mon May 8 18:45:50 2006 UTC (8 years, 5 months ago) by dillon
Branches: MAIN
Diff to: previous 1.118: preferred, unified
Changes since revision 1.118: +1 -0 lines
Split kern/vfs_journal.c.  Leave the low level journal support code in
kern/vfs_journal.c and move all the mount-based journaling code and
journaling VNOPS to kern/vfs_jops.c.  This is in preparation for utilizing
the core journaling protocol for userland VFS support.

Revision 1.118: download - view: text, markup, annotated - select for diffs
Tue Apr 4 17:34:23 2006 UTC (8 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.117: preferred, unified
Changes since revision 1.117: +7 -4 lines
Transplant all the UFS ops that EXT2 used to call into the EXT2 tree and
reconnect it to the build.  Recent BUF/BIO work made most of the UFS tree
incompatible with EXT2FS.

Reported-by: Csaba Henk <csaba.henk@creo.hu>

Revision 1.117: download - view: text, markup, annotated - select for diffs
Sat Apr 1 10:06:39 2006 UTC (8 years, 6 months ago) by swildner
Branches: MAIN
Diff to: previous 1.116: preferred, unified
Changes since revision 1.116: +0 -4 lines
Remove owi(4) (old wi) driver and adjust related bits.

It's been replaced by the more generic wi(4) driver since Sep 5, 2004.

Revision 1.116: download - view: text, markup, annotated - select for diffs
Sat Apr 1 02:55:36 2006 UTC (8 years, 6 months ago) by sephe
Branches: MAIN
Diff to: previous 1.115: preferred, unified
Changes since revision 1.115: +4 -0 lines
- Import driver[acx(4)] for TI acx100/acx111 based WiFi NIC.
- Import user space utility[acxcontrol(8)] to load firmware and show driver
  statistics.
- Add acx(4) and acxcontrol(8) man pages.
- Build acx(4) as module only, since it needs firmware to work.
- Add an entry for acx(4) in LINT.


This driver is known to work with following hardware:
D-Link DWL-520+
D-Link DWL-650+
D-Link DWL-G520+
D-Link DWL-G650+

Although both infrastructured mode and adhoc mode are supported, it may not
work well in adhoc mode.  PBCC based rate, 22Mbits/s, is not supported yet.


acxcontrl(8) and man pages are written by Sascha Wildner.  He also kindly
helped debugging and testing the driver.  Thank you, Sascha!

The meaning and layout of hardware registers are based on the reverse
engineering work done by people at acx100.sourceforge.net
Thank them for their great work!

This driver is initially based on acx100 developed by people at wlan.kewl.org
Thank them for their nice work.

Revision 1.115: download - view: text, markup, annotated - select for diffs
Mon Mar 27 16:18:30 2006 UTC (8 years, 7 months ago) by dillon
Branches: MAIN
Diff to: previous 1.114: preferred, unified
Changes since revision 1.114: +1 -1 lines
Remove NQNFS support.  The mechanisms are too crude to co-exist with
upcoming cache coherency management work and the original implementation
hacked up the NFS code pretty severely.

Move nqnfs_clientd() out of nfs_nqlease.c to a new file, nfs_kerb.c,
and rename it nfs_clientd().

Revision 1.88.2.1: download - view: text, markup, annotated - select for diffs
Fri Mar 10 00:27:50 2006 UTC (8 years, 7 months ago) by corecode
Branches: DragonFly_RELEASE_1_2
Diff to: previous 1.88: preferred, unified; next MAIN 1.89: preferred, unified
Changes since revision 1.88: +6 -6 lines
MFC commit from long ago:

  Build aicasm as a host tool

This allows us to compile 1.2-Release on 1.4+ again.

Revision 1.113.2.1: download - view: text, markup, annotated - select for diffs
Tue Dec 27 07:11:40 2005 UTC (8 years, 10 months ago) by dillon
Branches: DragonFly_RELEASE_1_4
CVS tags: DragonFly_RELEASE_1_4_Slip
Diff to: previous 1.113: preferred, unified; next MAIN 1.114: preferred, unified
Changes since revision 1.113: +1 -0 lines
MFC - add rgephy to the build.

Revision 1.114: download - view: text, markup, annotated - select for diffs
Mon Dec 26 13:39:50 2005 UTC (8 years, 10 months ago) by sephe
Branches: MAIN
Diff to: previous 1.113: preferred, unified
Changes since revision 1.113: +1 -0 lines
hook rgephy

Revision 1.113: download - view: text, markup, annotated - select for diffs
Wed Dec 21 16:37:15 2005 UTC (8 years, 10 months ago) by corecode
Branches: MAIN
Branch point for: DragonFly_RELEASE_1_4
Diff to: previous 1.112: preferred, unified
Changes since revision 1.112: +2 -0 lines
Bring in if_bridge from Open-/Net-/FreeBSD

Based-on-patch-by: Andrew Atrens
Reviewed-and-locking-corrected-by: dillon and sephe

Revision 1.112: download - view: text, markup, annotated - select for diffs
Mon Dec 19 00:07:02 2005 UTC (8 years, 10 months ago) by corecode
Branches: MAIN
Diff to: previous 1.111: preferred, unified
Changes since revision 1.111: +1 -1 lines
Adjust sources to accomodate for repo copy of our bridging code

sys/net/bridge was copied to sys/net/oldbridge

Revision 1.111: download - view: text, markup, annotated - select for diffs
Wed Nov 16 02:24:26 2005 UTC (8 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.110: preferred, unified
Changes since revision 1.110: +1 -0 lines
Continue work on our pluggable scheduler abstraction.  Implement a system
call to set the scheduler for the current process (and future children),
and add an abstraction for scheduler registration.

Submitted-by: Sergey Glushchenko <deen@smz.com.ua>

Revision 1.110: download - view: text, markup, annotated - select for diffs
Wed Nov 2 18:41:50 2005 UTC (8 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.109: preferred, unified
Changes since revision 1.109: +1 -0 lines
ICU/APIC cleanup part 5/many.

Start migrating the ICU and APIC interrupt interfaces to a new machine
level interrupt ABI.  This ABI will eventually be tied into the BUS
architecture.

Move INTRDIS/INTREN to the new API: machintr_intrdis(irq) and
machintr_intren(irq).

Get rid of ithread_unmask().  Have the interrupt thread code call
machintr_intrdis(irq) directly.

Revision 1.109: download - view: text, markup, annotated - select for diffs
Mon Oct 24 16:45:10 2005 UTC (9 years ago) by dillon
Branches: MAIN
Diff to: previous 1.108: preferred, unified
Changes since revision 1.108: +1 -0 lines
Add an mii_flags field to the attach arguments, to make it easier to create
custom MII drivers without having to duplicate all of the generic
attach/detach code.

Add a simplified custom driver for nvidia/marvell which simply sets the
flag which allows the generic mii code to probe for GiGE.

Revision 1.108: download - view: text, markup, annotated - select for diffs
Sun Sep 25 16:05:36 2005 UTC (9 years, 1 month ago) by swildner
Branches: MAIN
Diff to: previous 1.107: preferred, unified
Changes since revision 1.107: +1 -0 lines
Add iwi (fixes building of LINT).

Revision 1.107: download - view: text, markup, annotated - select for diffs
Tue Sep 20 11:48:23 2005 UTC (9 years, 1 month ago) by asmodai
Branches: MAIN
Diff to: previous 1.106: preferred, unified
Changes since revision 1.106: +1 -0 lines
Actually hook up ipw.

Forgotten since 2005-03-06.

Revision 1.106: download - view: text, markup, annotated - select for diffs
Mon Sep 19 02:53:27 2005 UTC (9 years, 1 month ago) by sephe
Branches: MAIN
Diff to: previous 1.105: preferred, unified
Changes since revision 1.105: +2 -0 lines
Port rue(4) from FreeBSD:
dev/usb/if_rue.c	rev 1.14, 1.20
dev/usb/if_ruereg.h	rev 1.3
dev/mii/ruephy.c	rev 1.1.4.1
dev/mii/ruephyreg.h	rev 1.1.4.1
modules/rue/Makefile	rev 1.2

This driver supports:
RealTek RTL8150 based USB ethernet devices
- Melco LUA-KTX
- GREEN HOUSE GH-USB100B
- Billionton ThumbLAN USBKR2-100B

Changes to FreeBSD version:
- use hw.rue as sysctl node instead of hw.usb.rue
- cleanup rue_attach() code path
- RUE_{LOCK, UNLOCK}() ==> crit_{enter, exit}()
- get rid of qdat
- nuke rue_softc.{rue_info, rue_unit}
- use callout_*()
- use m_getcl() instead of MGETHDR() and MCLGET()

Thanks Shunsuke Akiyama <akiyama@FreeBSD.org> and others for rue(4)

Lack of rue(4) in our base was first noticed by swilder,
thanks him for his reminding

Approved-by: dillon
Tested-by: me (with a Billionton ThumbLAN USBKR2-100B)

Revision 1.105: download - view: text, markup, annotated - select for diffs
Sun Sep 4 01:28:57 2005 UTC (9 years, 1 month ago) by dillon
Branches: MAIN
Diff to: previous 1.104: preferred, unified
Changes since revision 1.104: +2 -1 lines
Give the kernel a native NFS mount rpc capability for mounting NFS roots by
splitting off the mount rpc code from the BOOTP code.  The loader is no
longer required to pass the nfs root mount file handle to the kernel.

Pure tftp-based loaders with no knowledge of NFS can now pass a NFS root
mount path to the kernel without having to pass a resolved NFS file handle.
This change allows kernels booted from tftp loaders to have an NFS root
without having to specify BOOTP (which sometimes doesn't work properly when
done from both the loader and from the kernel).

Revision 1.104: download - view: text, markup, annotated - select for diffs
Sun Aug 28 15:27:05 2005 UTC (9 years, 1 month ago) by hsu
Branches: MAIN
Diff to: previous 1.103: preferred, unified
Changes since revision 1.103: +1 -0 lines
A machine-independent spinlock implementation.  It has the advantages of
  1.  being written in C except for the most low-level atomic swap primitive,
        which is universally supported on current processor architectures
  2.  having a very small inlined memory footprint for spin_lock(),
        with the slow-path defered to a subroutine call
  3.  only requiring a bus-locked operation for lock acquisition,
         and not requiring a bus-locked operation for lock release
  4.  doing a non-bus-locked check first in the spin loop to
        reduce bus contention
  5.  doing exponential backoff in the uncommon contested case, which
        Sun has found to reduce bus contention by a factor of 5 or more

Reviewed by:	Matt Dillon

Revision 1.103: download - view: text, markup, annotated - select for diffs
Sat Aug 27 20:23:05 2005 UTC (9 years, 2 months ago) by joerg
Branches: MAIN
Diff to: previous 1.102: preferred, unified
Changes since revision 1.102: +1 -0 lines
Make struct dirent contain a full 64bit inode. Allow more than 255 byte
filenames by increasing d_namlen to 16bit. Remove UFS specific macros
from sys/dirent.h, programs which really need them should include
vfs/ufs/dir.h. MAXNAMLEN should not be used, but replaced by NAME_MAX.

To keep the impact for older BSD code small, d_ino and d_fileno are kept
in the old meaning when __BSD_VISIBLE is defined, otherwise the POSIX
version d_ino is used. This will be changed later to always define only
d_ino and make d_fileno a compatiblity macro for __BSD_VISIBLE.

d_name is left with hard-coded 256 byte space, this will be changed at
some point in the future and doesn't affect the ABI. Programs should
correctly allocate space themselve, since the maximum directory entry
length can be > 256 byte.

For allocating dirents (e.g. for readdir_r), _DIRENT_RECLEN and
_DIRENT_DIRSIZ should be used. NetBSD has choosen the same names.
Revamp the compatibility code to always use a local kernel buffer and
write out the entries. This will be changed later by passing down the
output function to vop_readdir, elimininating the redundant copy.

Change NFS and CD9660 to use to use vop_write_dirent, for CD9660 ensure
that the buffers are big enough by prepending char arrays of the right
size.

Tested-by & discussed-with: dillon

Revision 1.102: download - view: text, markup, annotated - select for diffs
Tue Aug 16 10:31:35 2005 UTC (9 years, 2 months ago) by y0netan1
Branches: MAIN
Diff to: previous 1.101: preferred, unified
Changes since revision 1.101: +154 -141 lines
Get rid of 4.x-derived acpi code:
- move most part of /sys/dev/acpica5/Makefile.inc into /sys/conf/acpi.mk
- rename SYSACPICA_DIR, OSACPI_DIR to ACPICA_DIR and ACPI_MI_DIR,
  make them relative to $S (or $SYSDIR) so as they can be shared between
  kernel and modules builds
- remove 4.x ACPI lines from, and add acpica5 lines to, /sys/conf/files*
- make LINT to use `device acpi' instead of older `device acpica'
- adjust ACPI driver build wrapper and ACPI tools to use /sys/conf/acpi.mk

Revision 1.101: download - view: text, markup, annotated - select for diffs
Wed Aug 3 23:33:52 2005 UTC (9 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.100: preferred, unified
Changes since revision 1.100: +1 -1 lines
Add a new system config directive called "nonoptional" which specifies
files based on options which MUST be specified in the kernel config.

Make the option to maintain compatibility with DragonFly 1.2 (and older
1.3 kernels) non-optional.

Older versions of config will not recognize the new option and generate
a reasonable error, rather then blindly compile a kernel without 1.2
support, hopefully prompting people to recompile their config
program rather then post a bug report.

Revision 1.100: download - view: text, markup, annotated - select for diffs
Tue Aug 2 13:03:54 2005 UTC (9 years, 2 months ago) by joerg
Branches: MAIN
Diff to: previous 1.99: preferred, unified
Changes since revision 1.99: +1 -0 lines
Make nlink_t 32bit and ino_t 64bit. Implement the old syscall numbers
for *stat by wrapping the new syscalls and truncation of the values.
Add a hack for boot2 to keep ino_t 32bit, otherwise we would have to
link the 64bit math code in and that would most likely overflow boot2.
Bump libc major to annotate changed ABI and work around a problem with
strip during installworld. strip is dynamically linked and doesn't play
well with the new libc otherwise.

Support for 64bit inode numbers is still incomplete, because the dirent
limited to 32bit. The checks for nlink_t have to be redone too.

Revision 1.99: download - view: text, markup, annotated - select for diffs
Sat Jul 23 07:33:43 2005 UTC (9 years, 3 months ago) by dillon
Branches: MAIN
Diff to: previous 1.98: preferred, unified
Changes since revision 1.98: +1 -1 lines
Do not compile the kernel with the stack protector.  I've decided to tolerate
the stack protector as a default for user programs, but not for the kernel.
The stack protector has known bugs and I frankly believe that it is far more
likely that we would hit one of its bugs verses it actually finding a
stack overflow in the kernel.

Revision 1.98: download - view: text, markup, annotated - select for diffs
Fri Jul 15 17:54:47 2005 UTC (9 years, 3 months ago) by eirikn
Branches: MAIN
Diff to: previous 1.97: preferred, unified
Changes since revision 1.97: +13 -0 lines
Tie SCTP into the kernel, this includes adding a new syscall (sctp_peeloff).

Obtained from: KAME

Revision 1.97: download - view: text, markup, annotated - select for diffs
Wed Jul 13 17:31:05 2005 UTC (9 years, 3 months ago) by joerg
Branches: MAIN
Diff to: previous 1.96: preferred, unified
Changes since revision 1.96: +2 -1 lines
Move PCCARD attachment into separate file. Use the NEWCARD helper
functions for accessing the CIS instead of doing it manually.

Submitted-by: Sepherosa Ziehau <sepherosa@gmail.com>
Obtained-from: FreeBSD

Revision 1.96: download - view: text, markup, annotated - select for diffs
Sat Jul 9 21:58:10 2005 UTC (9 years, 3 months ago) by swildner
Branches: MAIN
Diff to: previous 1.95: preferred, unified
Changes since revision 1.95: +1 -1 lines
Fix typo: netgarph -> netgraph.

Revision 1.95: download - view: text, markup, annotated - select for diffs
Sat Jun 25 20:03:33 2005 UTC (9 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.94: preferred, unified
Changes since revision 1.94: +1 -1 lines
Associate a userland scheduler control structure with every process and
call userland scheduling functions through that structure.  Note that the
proc structure already had a field reserved for this purpose so it actually
doesn't change size.

The child of a fork() inherits the parent's userland scheduler control
structure pointer.

Move uio_yield() to a scheduler-independant file, and do some minor
cleanups of already #ifdef'd out code.

Repo-Rename usched_4bsd.c to usched_bsd4.c, so the file matches the function
prefixes I want to use.

Believe it or not, this should not represent any operational code changes
other then changing some previously direct function calls into indirect
calls through the new p_usched field in the process structure.

Revision 1.94: download - view: text, markup, annotated - select for diffs
Sat Jun 25 19:12:27 2005 UTC (9 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.93: preferred, unified
Changes since revision 1.93: +1 -1 lines
Repo-copy kern_switch.c to usched_4bsd.c, remove kern_switch.c, and point
the kernel build at usched_4bsd.c in preparation for creating a switchable
userland scheduling API.

Revision 1.93: download - view: text, markup, annotated - select for diffs
Sat Jun 11 09:03:48 2005 UTC (9 years, 4 months ago) by swildner
Branches: MAIN
Diff to: previous 1.92: preferred, unified
Changes since revision 1.92: +0 -4 lines
Dispose of support for IBM's Micro Channel architecture (MCA).

Revision 1.92: download - view: text, markup, annotated - select for diffs
Tue Jun 7 19:07:11 2005 UTC (9 years, 4 months ago) by hsu
Branches: MAIN
Diff to: previous 1.91: preferred, unified
Changes since revision 1.91: +1 -0 lines
Generic cache of pre-initialized objects.  It uses per-cpu caches
for MP-safety, was designed to be NUMA-aware, and works on top of
any storage allocator.  The object cache is largely inspired by the
object cache portion of Sun's slab allocator.

Revision 1.91: download - view: text, markup, annotated - select for diffs
Wed Jun 1 20:19:43 2005 UTC (9 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.90: preferred, unified
Changes since revision 1.90: +1 -0 lines
More cleanups, add the API implementation to select the system clock.

Revision 1.90: download - view: text, markup, annotated - select for diffs
Tue May 24 20:58:55 2005 UTC (9 years, 5 months ago) by dillon
Branches: MAIN
Diff to: previous 1.89: preferred, unified
Changes since revision 1.89: +1 -0 lines
Get rid of bus_{disable,enable}_intr(), it wasn't generic enough for
our needs.

Implement some generic atomic.h functions to aid in the implementation of
a low level mutex.

Implement a generic low level sleep-mutex serializer, kern/lwkt_serialize.c.
The serializer is designed to be a replacement for SPL calls but may also
be used for other very low level work (e.g. lockmgr interlocks).

Add a serializer argument to BUS_SETUP_INTR().  When non-NULL, the interrupt
handler will no longer be protected by an SPL so e.g. spl*() will no
longer protect against that device's interrupts.

The IF queueing and dequeueing mechanisms may no longer depend on outside
SPL state because network driver interrupt handlers are no longer required to
enter splnet().  Use critical sections for the moment.  The IFQ and
IFF_OACTIVE interactions are not yet MP safe.

Revision 1.89: download - view: text, markup, annotated - select for diffs
Thu Apr 21 14:43:58 2005 UTC (9 years, 6 months ago) by joerg
Branches: MAIN
Diff to: previous 1.88: preferred, unified
Changes since revision 1.88: +6 -6 lines
Build aicasm as host program, not via world's compiler.

Revision 1.88: download - view: text, markup, annotated - select for diffs
Sat Apr 2 20:00:40 2005 UTC (9 years, 6 months ago) by joerg
Branches: MAIN
CVS tags: DragonFly_Stable, DragonFly_RELEASE_1_2_Slip
Branch point for: DragonFly_RELEASE_1_2
Diff to: previous 1.87: preferred, unified
Changes since revision 1.87: +55 -29 lines
Split pcm into the generic framework (pcm) and the sound cards (snd).
Add support for choosing single devices by the same name as the corresponding
module.

E.g. device snd_ich gives the AC97 support, device "snd_sb8" gives the
SoundBlaster 8 support.

Revision 1.87: download - view: text, markup, annotated - select for diffs
Sat Mar 19 14:54:50 2005 UTC (9 years, 7 months ago) by joerg
Branches: MAIN
Diff to: previous 1.86: preferred, unified
Changes since revision 1.86: +1 -0 lines
Generic firmware support. Currently implemented is loading from
/etc/firmware, support kernel builtin images and kernel modules
will follow later.

Written-by: Johannes Hofmann and Joerg Sonnenberger

Revision 1.86: download - view: text, markup, annotated - select for diffs
Fri Feb 11 22:25:56 2005 UTC (9 years, 8 months ago) by joerg
Branches: MAIN
Diff to: previous 1.85: preferred, unified
Changes since revision 1.85: +7 -0 lines
Import ALTQ support from KAME. This is based on the FreeBSD 4 snapshot.
This includes neither the ALTQ3 compat code nor the !DragonFly defines.
The macros have been replaced with inline functions in net/ifq_var.h.

This also renames pkthdr.pf_flags as it is intended as general flag bit.
Currently supported are ppp(4), sppp(4), tun(4) and wi(4), more drivers
are coming later.

Reviewed-by: corecode, dillon, hsu
Comments-from: hmp

Revision 1.85: download - view: text, markup, annotated - select for diffs
Mon Jan 31 23:44:34 2005 UTC (9 years, 8 months ago) by joerg
Branches: MAIN
Diff to: previous 1.84: preferred, unified
Changes since revision 1.84: +0 -2 lines
Remove GPLed fpemulation, old rp, old awe and pcic.
dgb is still in, until the persons having the hardware decide that
digi(4) works for them.

Correct spelling of deprecation.

Revision 1.84: download - view: text, markup, annotated - select for diffs
Fri Jan 14 03:25:31 2005 UTC (9 years, 9 months ago) by dillon
Branches: MAIN
Diff to: previous 1.83: preferred, unified
Changes since revision 1.83: +1 -0 lines
Add missing kern_umtx.c to sys/conf/files.

Noticed-by: David Rhodus

Revision 1.83: download - view: text, markup, annotated - select for diffs
Mon Jan 10 19:37:23 2005 UTC (9 years, 9 months ago) by joerg
Branches: MAIN
Diff to: previous 1.82: preferred, unified
Changes since revision 1.82: +0 -1 lines
Remove wx(4). It's been superseded by em(4).

Revision 1.82: download - view: text, markup, annotated - select for diffs
Fri Dec 17 00:18:03 2004 UTC (9 years, 10 months ago) by dillon
Branches: MAIN
Diff to: previous 1.81: preferred, unified
Changes since revision 1.81: +2 -0 lines
VFS messaging/interfacing work stage 10/99:

Start adding the journaling, range locking, and (very slightly) cache
coherency infrastructure.  Continue cleaning up the VOP operations vector.

Expand on past commits that gave each mount structure its own set of VOP
operations vectors by adding additional vector sets for journaling or
cache coherency operations.  Remove the vv_jops and vv_cops fields
from the vnode operations vector in favor of placing those vop_ops directly
in the mount structure.  Reorganize the VOP calls as a double-indirect
and add a field to the mount structure which represents the current
vnode operations set (which will change when e.g. journaling is turned on
or off).  This creates the infrastructure necessary to allow us to stack
a generic journaling implementation on top of a filesystem.

Introduce a hard range-locking API for vnodes.   This API will be used by
high level system/vfs calls in order to handle atomicy guarentees.  It is
a prerequisit for: (1) being able to break I/O's up into smaller pieces
for the vm_page list/direct-to-DMA-without-mapping goal, (2) to support
the parallel write operations on a vnode goal, (3) to support the clustered
(remote) cache coherency goal, and (4) to support massive parallelism in
dispatching operations for the upcoming threaded VFS work.

This commit represents only infrastructure and skeleton/API work.

Revision 1.81: download - view: text, markup, annotated - select for diffs
Wed Nov 24 22:51:01 2004 UTC (9 years, 11 months ago) by joerg
Branches: MAIN
Diff to: previous 1.80: preferred, unified
Changes since revision 1.80: +1 -0 lines
Add the basic of libkcore. Switch pstat to use kcore/kinfo backing,
defaulting to kcore for now.

Revision 1.80: download - view: text, markup, annotated - select for diffs
Tue Nov 23 06:31:59 2004 UTC (9 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.79: preferred, unified
Changes since revision 1.79: +1 -0 lines
There is enough demand for Kip Macy's checkpointing code to warrent
permanent integration into the kernel.  Add a fixed system call,
sys_checkpoint(2), to support the checkpt(1) utility as well as user
programs which want to install their own signal handler (SIGCKPT).

Revision 1.79: download - view: text, markup, annotated - select for diffs
Sun Nov 14 00:49:07 2004 UTC (9 years, 11 months ago) by hsu
Branches: MAIN
Diff to: previous 1.78: preferred, unified
Changes since revision 1.78: +1 -0 lines
Implement SACK.

Revision 1.78: download - view: text, markup, annotated - select for diffs
Mon Oct 25 13:53:26 2004 UTC (10 years ago) by simokawa
Branches: MAIN
Diff to: previous 1.77: preferred, unified
Changes since revision 1.77: +1 -0 lines
Sync with FreeBSD-current:
- Split dcons core and OS dependent part.
- Use dcons buffer passed by loader(8).
- Invalidate dcons buffer on shutdown.

Revision 1.77: download - view: text, markup, annotated - select for diffs
Tue Oct 12 19:20:26 2004 UTC (10 years ago) by dillon
Branches: MAIN
Diff to: previous 1.76: preferred, unified
Changes since revision 1.76: +3 -0 lines
VFS messaging/interfacing work stage 8/99: Major reworking of the vnode
interlock and other miscellanious things.  This patch also fixes FS
corruption due to prior vfs work in head.  In particular, prior to this
patch the namecache locking could introduce blocking conditions that
confuse the old vnode deactivation and reclamation code paths.  With
this patch there appear to be no serious problems even after two days
of continuous testing.

* VX lock all VOP_CLOSE operations.
* Fix two NFS issues.  There was an incorrect assertion (found by
  David Rhodus), and the nfs_rename() code was not properly
  purging the target file from the cache, resulting in Stale file
  handle errors during, e.g. a buildworld with an NFS-mounted /usr/obj.
* Fix a TTY session issue.  Programs which open("/dev/tty" ,...) and
  then run the TIOCNOTTY ioctl were causing the system to lose track
  of the open count, preventing the tty from properly detaching.
  This is actually a very old BSD bug, but it came out of the woodwork
  in DragonFly because I am now attempting to track device opens
  explicitly.
* Gets rid of the vnode interlock.  The lockmgr interlock remains.
* Introduced VX locks, which are mandatory vp->v_lock based locks.
* Rewrites the locking semantics for deactivation and reclamation.
  (A ref'd VX lock'd vnode is now required for vgone(), VOP_INACTIVE,
  and VOP_RECLAIM).  New guarentees emplaced with regard to vnode
  ripouts.
* Recodes the mountlist scanning routines to close timing races.
* Recodes getnewvnode to close timing races (it now returns a
  VX locked and refd vnode rather then a refd but unlocked vnode).
* Recodes VOP_REVOKE- a locked vnode is now mandatory.
* Recodes all VFS inode hash routines to close timing holes.
* Removes cache_leaf_test() - vnodes representing intermediate
  directories are now held so the leaf test should no longer be
  necessary.
* Splits the over-large vfs_subr.c into three additional source
  files, broken down by major function (locking, mount related,
  filesystem syncer).

* Changes splvm() protection to a critical-section in a number of
  places (bleedover from another patch set which is also about to be
  committed).

Known issues not yet resolved:

* Possible vnode/namecache deadlocks.
* While most filesystems now use vp->v_lock, I haven't done a final
  pass to make vp->v_lock mandatory and to clean up the few remaining
  inode based locks (nwfs I think and other obscure filesystems).
* NullFS gets confused when you hit a mount point in the underlying
  filesystem.
* Only UFS and NFS have been well tested
* NFS is not properly timing out namecache entries, causing changes made
  on the server to not be properly detected on the client if the client
  already has a negative-cache hit for the filename in question.

Testing-by: David Rhodus <sdrhodus@gmail.com>,
	    Peter Kadau <peter.kadau@tuebingen.mpg.de>,
	    walt <wa1ter@myrealbox.com>,
	    others

Revision 1.76: download - view: text, markup, annotated - select for diffs
Tue Sep 28 00:25:25 2004 UTC (10 years ago) by dillon
Branches: MAIN
CVS tags: DragonFly_Snap29Sep2004
Diff to: previous 1.75: preferred, unified
Changes since revision 1.75: +1 -0 lines
VFS messaging/interfacing work stage 6/99.  Populate and maintain the
namecache pointers previously attached to struct filedesc, giving the new
lookup code a base from which to work.

Implement the new lookup API (it is not yet being used by anything) and
augment the namecache API to handle the new functions, in particular
adding cache_setvp() to resolve an unresolved namecache entry into a
positive or negative hit and set various flags.  Note that we do not yet
cache symlink data but we could very easily.

The new API is greatly simplified.  Basically nlookups need only returned
a locked namecache pointer (guarenteeing namespace atomicy).  Related
vnodes are not locked.  Both the leaf and governing directory vnodes can
be extracted from the returned namecache pointer.  namecache pointers may
also represent negative hits, which means that their namespace locking
feature serves to reserve a filename that has not yet been created (e.g.
open+create, rename).

The kernel is still using the old API as of this commit.  This commit is
primarily introducing the management infrastructure required to actually
start writing code to use the new API.

VOP_RESOLVE() has been added, along with a default function which falls back
to VOP_LOOKUP()/VOP_CACHEDLOOKUP().  This VOP function is not yet being used
as of this commit.  This VOP will be responsible for taking an unresolved
but locked namecache structure (hence the namespace is locked), and actually
does the directory lookup.  But unlike the far more complex
VOP_LOOKUP()/VOP_CACHEDLOOKUP() API the VOP_RESOLVE() API only needs to
attach a vnode (or NULL if the entry does not exist) to the passed-in
namecache structure.  It is likely that timeouts, e.g. for NFS, will also
be attached via this API.

This commit does not implement any of the cache-coherency infrastructure
but keeps this future requirement in mind in its design.

Revision 1.75: download - view: text, markup, annotated - select for diffs
Thu Sep 23 06:52:05 2004 UTC (10 years, 1 month ago) by simokawa
Branches: MAIN
Diff to: previous 1.74: preferred, unified
Changes since revision 1.74: +2 -0 lines
Hooks to build dcons(4)/dcons_crom(4).

Revision 1.74: download - view: text, markup, annotated - select for diffs
Mon Sep 20 20:38:17 2004 UTC (10 years, 1 month ago) by eirikn
Branches: MAIN
Diff to: previous 1.73: preferred, unified
Changes since revision 1.73: +1 -0 lines
Add KTR, a facility that logs kernel events to help debugging. You can access
the logged information with ddb. If KTR_VERBOSE is defined a string will also be
printed with printf() to your console.

See ktr(4) and ktr(9) for information on how to use KTR.

Obtained from: FreeBSD

Revision 1.73: download - view: text, markup, annotated - select for diffs
Sun Sep 19 22:32:47 2004 UTC (10 years, 1 month ago) by joerg
Branches: MAIN
Diff to: previous 1.72: preferred, unified
Changes since revision 1.72: +9 -0 lines
Kernel part of PF

Ported-by:
- Max Layer (original patch set, FreeBSD PF maintainer)
- Devon O'Dell, Simon 'corecode' Schubert (integration and DragonFly specific
   changes)

In contrast to FreeBSD and OpenBSD, use direct flags in pkthdr instead of
m_tags. This reduces allocation and processing overhead.

Keep the IP header in Host Byte Order like the rest of the tree assumes.

Module support has a memory leak for vm_zones when unloading pf.ko.

Revision 1.72: download - view: text, markup, annotated - select for diffs
Mon Sep 6 13:52:24 2004 UTC (10 years, 1 month ago) by joerg
Branches: MAIN
CVS tags: DragonFly_Snap13Sep2004
Diff to: previous 1.71: preferred, unified
Changes since revision 1.71: +0 -1 lines
Import the new wi(4) driver based on the generic 802.11 layer.

Obtained-from: FreeBSD

Revision 1.71: download - view: text, markup, annotated - select for diffs
Sun Sep 5 13:34:56 2004 UTC (10 years, 1 month ago) by joerg
Branches: MAIN
Diff to: previous 1.70: preferred, unified
Changes since revision 1.70: +4 -0 lines
Save current version of wi(4) as owi before switching to generic 802.11
version.

Small modifications to allow kernels with both devices included.

if_owi.c: copy of if_wi.c, 1.15
if_owi_pccard.c: copy of if_wi_pccard.c, 1.5
if_owi_pci.c: copy of if_wi_pci.c, 1.4
if_wireg.h: copy of if_wireg.h, 1.3
if_wivar.h: copy of if_wivar.h, 1.4
owi_hostap.c: copy of wi_hostap.c, 1.9
wi_hostap.h: copy of wi_hostap.h, 1.2

Revision 1.70: download - view: text, markup, annotated - select for diffs
Fri Aug 13 17:51:05 2004 UTC (10 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.69: preferred, unified
Changes since revision 1.69: +1 -0 lines
VFS messaging/interfacing work stage 1/99.  This stage replaces the old
dynamic VFS descriptor and inlined wrapper mess with a fixed structure
and fixed procedural wrappers.  Most of the work is straightforward except
for vfs_init, which was basically rewritten (and greatly simplified).

It is my intention to make the vop_*() call wrappers eventually handle
range locking and cache coherency issues as well as implementing the
direct call -> messaging interface layer.  The call wrappers will also
API translation as we shift the APIs over to new, more powerful mechanisms
in order to allow the work to be incrementally committed.

This is the first stage of what is likely to be a huge number of stages
to modernize the VFS subsystem.

Revision 1.69: download - view: text, markup, annotated - select for diffs
Tue Aug 3 07:16:14 2004 UTC (10 years, 2 months ago) by joerg
Branches: MAIN
Diff to: previous 1.68: preferred, unified
Changes since revision 1.68: +1 -0 lines
Add re(4) to GENERIC.

Revision 1.68: download - view: text, markup, annotated - select for diffs
Mon Jul 26 16:30:16 2004 UTC (10 years, 3 months ago) by joerg
Branches: MAIN
Diff to: previous 1.67: preferred, unified
Changes since revision 1.67: +7 -0 lines
Import generic 802.11 layer.

Choose netproto/802_11 instead of net80211 as source location.

Use token API instead mutexing. The locking heavenly depends on atomic
Operations and needs additional work.

Use POSIX int types.

Add dev/wi/if_wavelan_ieee.h as netproto/802_11/if_wavelan_ieee.h, since
this is used by all wireless interfaces and beside the variable and constant
naming mostly wi(4) indepedent.

Obtained-from: FreeBSD

Revision 1.67: download - view: text, markup, annotated - select for diffs
Fri Jul 23 11:54:14 2004 UTC (10 years, 3 months ago) by joerg
Branches: MAIN
Diff to: previous 1.66: preferred, unified
Changes since revision 1.66: +1 -0 lines
Add RC4 to the crypto module / device. This will be used by the generic
802.11 layer.

Revision 1.66: download - view: text, markup, annotated - select for diffs
Thu Jul 8 15:50:19 2004 UTC (10 years, 3 months ago) by dillon
Branches: MAIN
CVS tags: DragonFly_1_0_REL, DragonFly_1_0A_REL
Diff to: previous 1.65: preferred, unified
Changes since revision 1.65: +1 -1 lines
ugenbuf is associated with the 'ugen' device, not the 'ugenbuf' device.

Reported-by: "GeekGod" <GeekGod@GeekGod.com>

Revision 1.65: download - view: text, markup, annotated - select for diffs
Thu Jul 8 03:53:52 2004 UTC (10 years, 3 months ago) by dillon
Branches: MAIN
Diff to: previous 1.64: preferred, unified
Changes since revision 1.64: +1 -0 lines
Julian Elischer posted an interesting proof-of-concept to freebsd-current
regarding UGEN's use of a 1K stack buffer for bulk IO issues.  The small
block size resulted in unnecessarily slow performance with certain devices.

Implement a fix along the lines described.  Create a simple ugen buffer
allocator abstraction and a one-entry cache to avoid unnecessary malloc/free
sequences.  Allow the block size to be set with a sysctl and default it
to 16K.

Not much uses UGEN.  Camera software, mainly.  The change appears to
slightly improve s10sh transfer performance from my Canon 10D.

Revision 1.64: download - view: text, markup, annotated - select for diffs
Thu Jun 24 08:15:11 2004 UTC (10 years, 4 months ago) by dillon
Branches: MAIN
CVS tags: DragonFly_1_0_RC1
Diff to: previous 1.63: preferred, unified
Changes since revision 1.63: +1 -1 lines
Get rid of the PFIL_HOOKS option, integrate pfil in the system permanently.
(previously the packet filters couldn't even be kldload'd without PFIL_HOOKS).

Revision 1.63: download - view: text, markup, annotated - select for diffs
Sat Jun 5 19:57:40 2004 UTC (10 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.62: preferred, unified
Changes since revision 1.62: +1 -0 lines
Add the MSFBUF API.  MSFBUFs are like SFBUFs but they manage ephermal
multi-page mappings instead of single-page mappings.  MSFBUFs have the
same caching and page invalidation optimizations that SFBUFs have and are
considered to be SMP-friendly.

Whereas XIO manages pure page lists, MSFBUFs manage KVA mappings of pure
page lists.

This initial commit just gets the basic API operational.  The roadmap for
future work includes things like better interactions with third-party XIOs,
mapping user buffers into the kernel (extending the xio_init_ubuf() API into
the MSFBUF API), and allowing higher level subsystems to pass previously
released MSFBUFs as a hint to speed-up regeneration.  We also need to come
up with a way to overload additional sets of MSFBUFs representing smaller
chunks of memory on top of the same KVA space in order to efficiently use
our KVA reservation when dealing with subsystems like the buffer cache.

MSFBUFs will eventually replace the KVA management in the BUF/BIO, PIPE,
and other subsystems which create fake linear mappings with pbufs.  The
general idea for BUF/BIO will be to use XIO and MSFBUFs to avoid KVA
mapping file data through the nominal I/O path.  XIO will be the primary I/O
buffer mechanism while MSFBUFs will be used when things like UFS decide they
need a temporary mapping.

This is a collaborative work between Hiten Pandya <hmp@leaf.dragonflybsd.org>
and Matthew Dillon <dillon@backplane.com>.

Revision 1.62: download - view: text, markup, annotated - select for diffs
Fri Jun 4 20:35:35 2004 UTC (10 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.61: preferred, unified
Changes since revision 1.61: +1 -0 lines
async syscall work: The async syscall code got dated by recent LWKT
changes, set mp_abort_port and clear MSGF_DONE as appropriate.

If a system call returns EASYNC, record the message in p->p_sysmsgq so we
can run them down in exit1().

In exit1(), run down any asynch system calls that are still running.  Note
that this commit does not implement abort support (yet).

Get rid of lwkt_port->mp_refs, it was not being used and it is likely never
going to be used (reference counting LWKT is hazzardous anyway since it
doesn't really fit the access model).

Add lwkt_checkmsg() to support some of the rearranged async syscall code.

Revision 1.61: download - view: text, markup, annotated - select for diffs
Sat May 15 17:54:12 2004 UTC (10 years, 5 months ago) by joerg
Branches: MAIN
Diff to: previous 1.60: preferred, unified
Changes since revision 1.60: +4 -3 lines
Update bktr(4) to FreeBSD current's version. This most importantly
includes a new msp driver based on the Linux Brooktree driver.

Add support for Terratec TValue submitted by Patrick Mauritz
<oxygene@studentenbude.ath.cx>.

The ioctl headers are moved into the MI dev/ tree, symlinks for
compatibiliy are added in a separate commit.

Revision 1.60: download - view: text, markup, annotated - select for diffs
Sat Apr 17 03:57:22 2004 UTC (10 years, 6 months ago) by drhodus
Branches: MAIN
Diff to: previous 1.59: preferred, unified
Changes since revision 1.59: +5 -0 lines
Add in kernel config file options that were
forgotten on last commit.

Revision 1.59: download - view: text, markup, annotated - select for diffs
Wed Mar 31 19:29:26 2004 UTC (10 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.58: preferred, unified
Changes since revision 1.58: +0 -1 lines
Trash the vmspace_copy() hacks that CAPS was previously using.  No other
subsystem uses these hacks and the new XIO mechanism is far, far superior.

Revision 1.58: download - view: text, markup, annotated - select for diffs
Wed Mar 31 19:24:28 2004 UTC (10 years, 6 months ago) by dillon
Branches: MAIN
Diff to: previous 1.57: preferred, unified
Changes since revision 1.57: +1 -0 lines
Hook XIO up to the kernel build.

Revision 1.57: download - view: text, markup, annotated - select for diffs
Thu Mar 18 18:47:39 2004 UTC (10 years, 7 months ago) by dillon
Branches: MAIN
Diff to: previous 1.56: preferred, unified
Changes since revision 1.56: +3 -3 lines
Adjust the Makefile's to move the iconv files to libiconv, and add it to
the module build.

Revision 1.56: download - view: text, markup, annotated - select for diffs
Fri Mar 12 22:38:14 2004 UTC (10 years, 7 months ago) by joerg
Branches: MAIN
Diff to: previous 1.55: preferred, unified
Changes since revision 1.55: +3 -0 lines
Merge the kernel part of UDF support from FreeBSD 5.

This doesn't include the iconv hocks and makes use of M_WAITOK everywhere.

Revision 1.55: download - view: text, markup, annotated - select for diffs
Sat Mar 6 01:58:54 2004 UTC (10 years, 7 months ago) by hsu
Branches: MAIN
Diff to: previous 1.54: preferred, unified
Changes since revision 1.54: +1 -0 lines
Dispatch upper-half protocol request handling.

Revision 1.54: download - view: text, markup, annotated - select for diffs
Fri Feb 27 11:56:12 2004 UTC (10 years, 7 months ago) by joerg
Branches: MAIN
Diff to: previous 1.53: preferred, unified
Changes since revision 1.53: +1 -0 lines
Add bfe(4) support from FreeBSD.
Initial code submitted by Peter Avalos <pavalos@theshell.com>.

Changes to the FreeBSD version:
- make the code consistent w.r.t. style(9)
- remove some unused entries from bfe_softc
- use the PCI IDs from pcidevs.h
- use BUS_DMA_WAITOK since the allocation is done in bfe_attach before
  the interrupt is registered and sleeping is therefore safe
- fix some warnings in the code about signed/unsigned comparisions

Revision 1.53: download - view: text, markup, annotated - select for diffs
Tue Feb 24 15:21:25 2004 UTC (10 years, 8 months ago) by joerg
Branches: MAIN
Diff to: previous 1.52: preferred, unified
Changes since revision 1.52: +2 -0 lines
Split off the PCI-PCI bridge and the PCI-ISA bridge code from
pcisupport.c. This moves just code around and is non-functional.

Revision 1.52: download - view: text, markup, annotated - select for diffs
Sat Feb 21 06:37:06 2004 UTC (10 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.51: preferred, unified
Changes since revision 1.51: +1 -1 lines
Synchronize a bunch of things from FreeBSD-5 in preparation for the new
ACPICA driver support.

* Bring in a lot of new bus and pci DEV_METHODs from FreeBSD-5
* split apic.h into apicreg.h and apicio.h
* rename INTR_TYPE_FAST -> INTR_FAST and move the #define
* rename INTR_TYPE_EXCL -> INTR_EXCL and move the #define
* rename some PCIR_ registers and add additional macros from FreeBSD-5
* note: new pcib bus call, host_pcib_get_busno() imported.
* kern/subr_power.c no longer optional.

Other changes:

* machine/smp.h machine smp/smptests.h can now be #included unconditionally,
  and some APIC_IO vs SMP separation has been done as well.
* gd_acpi_id and gd_apic_id added to machine/globaldata.h prep for new
  ACPI code.

Despite all the changes, the generated code should be virtually the same.
These were mostly additions which the pre-existing code does not (yet) use.

Revision 1.51: download - view: text, markup, annotated - select for diffs
Thu Feb 19 15:05:26 2004 UTC (10 years, 8 months ago) by joerg
Branches: MAIN
Diff to: previous 1.50: preferred, unified
Changes since revision 1.50: +0 -1 lines
Remove duplicate line for if_ray

Revision 1.50: download - view: text, markup, annotated - select for diffs
Wed Feb 18 15:41:56 2004 UTC (10 years, 8 months ago) by drhodus
Branches: MAIN
Diff to: previous 1.49: preferred, unified
Changes since revision 1.49: +0 -1 lines
*	Remove ufs_disksubr.c from kernel build files.

Revision 1.49: download - view: text, markup, annotated - select for diffs
Sun Feb 15 02:14:40 2004 UTC (10 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.48: preferred, unified
Changes since revision 1.48: +1 -0 lines
Split the IPIQ messaging out of lwkt_thread.c and move it to its own file,
lwkt_ipiq.c.

Add a MI synchronous cpu rendezvous API lwkt_cpusync_*().  This API allows the
kernel to synchronize an operation across any number of cpus.  Multiple cpus
can initiate synchronization operations simultaniously without creating a
deadlock.  The API utilizes the IPI messaging core and guarentees that
other synchronization and IPI messaging operations will continue to work
during any given synchronization op.  The API is a spin-blocking API, meaning
that it will not switch threads and can be used by mainline code, interrupts,
and other sensitive code.

This API is intended to replace smp_rendezvous(), Xcpustop, and other
hardwired IPI ops.  It will also be used to fix our TLB shootdown code.

As of this commit the API has not yet been connected to anything and has
been tested only a little.

Revision 1.48: download - view: text, markup, annotated - select for diffs
Sat Feb 14 21:12:38 2004 UTC (10 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.47: preferred, unified
Changes since revision 1.47: +1 -0 lines
Move <machine/in_cksum.h> to <sys/in_cksum.h>.  This file is now platform
independant.  If we want to add extreme machine specialization later on
then sys/in_cksum.h will #include machine/in_cksum.h.

Move i386/i386/in_cksum.c to netinet/in_cksum.c.  Note that netinet/in_cksum.c
already existed but was not used by the build system at all.  The move
overwrites it.  The new in_cksum.c is a portable, complete rewrite which
references core assembly (procedure call) to do 32-bit-aligned work.  See
also i386/i386/in_cksum2.s.

Revision 1.47: download - view: text, markup, annotated - select for diffs
Fri Feb 13 21:15:12 2004 UTC (10 years, 8 months ago) by joerg
Branches: MAIN
Diff to: previous 1.46: preferred, unified
Changes since revision 1.46: +2 -0 lines
Sync if_ed with FreeBSD current

Revision 1.46: download - view: text, markup, annotated - select for diffs
Tue Feb 10 07:55:46 2004 UTC (10 years, 8 months ago) by joerg
Branches: MAIN
Diff to: previous 1.45: preferred, unified
Changes since revision 1.45: +27 -30 lines
Initial backport of NEWCARD from FreeBSD 5.

The included version is from end of November 2002 with the exception of
bus/pccard/pccarddevs which is from November 2003.

Thanks to Warner Losh and the other folks for NEWCARD.

Revision 1.45: download - view: text, markup, annotated - select for diffs
Mon Feb 9 21:13:17 2004 UTC (10 years, 8 months ago) by dillon
Branches: MAIN
Diff to: previous 1.44: preferred, unified
Changes since revision 1.44: +1 -0 lines
Split the lwkt_token code out of lwkt_thread.c.  Give it its own file.
No operational changes.

Revision 1.44: download - view: text, markup, annotated - select for diffs
Fri Jan 30 13:23:55 2004 UTC (10 years, 8 months ago) by drhodus
Branches: MAIN
Diff to: previous 1.43: preferred, unified
Changes since revision 1.43: +1 -0 lines
*	Add kern_systimer.c to the kernel build process.

Revision 1.43: download - view: text, markup, annotated - select for diffs
Tue Jan 20 18:41:47 2004 UTC (10 years, 9 months ago) by dillon
Branches: MAIN
Diff to: previous 1.42: preferred, unified
Changes since revision 1.42: +1 -0 lines
Resident executable support stage 1/4: Add kernel bits and syscall support
for in-kernel caching of vmspace structures.  The main purpose of this
feature is to make it possible to run dynamically linked programs as fast
as if they were statically linked, by vmspace_fork()ing their vmspace and
saving the copy in the kernel, then using that whenever the program is
exec'd.

Revision 1.42: download - view: text, markup, annotated - select for diffs
Sun Jan 18 12:29:46 2004 UTC (10 years, 9 months ago) by dillon
Branches: MAIN
Diff to: previous 1.41: preferred, unified
Changes since revision 1.41: +2 -1 lines
CAPS IPC library stage 1/3: The core CAPS IPC code, providing system calls
to create and connect to named rendezvous points.  The CAPS interface
implements a many-to-1 (client:server) capability and is totally self
contained.  The messaging is designed to support single and multi-threading,
synchronous or asynchronous (as of this commit: polling and synchronous only).

Message data is 100% opaque and so while the intention is to integrate it into
a userland LWKT messaging subsystem, the actual system calls do not depend
on any LWKT structures.

Since these system calls are experiemental and may contain root holes,
they must be enabled via the sysctl kern.caps_enabled.

Revision 1.41: download - view: text, markup, annotated - select for diffs
Thu Jan 15 18:22:22 2004 UTC (10 years, 9 months ago) by joerg
Branches: MAIN
Diff to: previous 1.40: preferred, unified
Changes since revision 1.40: +1 -0 lines
Add pcib_if.m

Revision 1.40: download - view: text, markup, annotated - select for diffs
Thu Jan 15 15:41:23 2004 UTC (10 years, 9 months ago) by drhodus
Branches: MAIN
Diff to: previous 1.39: preferred, unified
Changes since revision 1.39: +5 -0 lines

*	Add in support for the IBM ServeRAID controller.

Port done and sent in by:
	TONETANI Tomokazu <ghwt+dragonfly-kernel@les.ath.cx>

Revision 1.39: download - view: text, markup, annotated - select for diffs
Wed Jan 7 18:13:19 2004 UTC (10 years, 9 months ago) by joerg
Branches: MAIN
Diff to: previous 1.38: preferred, unified
Changes since revision 1.38: +1 -1 lines
Move the FreeBSD 2.2 and 3.x PCI compatibility code into pci_compat.c and let it
depend on COMPAT_OLDPCI. Adjust LINT to accordingly.

Revision 1.38: download - view: text, markup, annotated - select for diffs
Tue Jan 6 00:56:49 2004 UTC (10 years, 9 months ago) by dillon
Branches: MAIN
Diff to: previous 1.37: preferred, unified
Changes since revision 1.37: +1 -0 lines
Import the libkern/fnmatch code from FreeBSD-5.

Submitted-by: Max Laier <max@love2party.net>

Revision 1.37: download - view: text, markup, annotated - select for diffs
Tue Dec 30 01:01:38 2003 UTC (10 years, 9 months ago) by dillon
Branches: MAIN
Diff to: previous 1.36: preferred, unified
Changes since revision 1.36: +8 -2 lines
Bring in the entire FreeBSD-5 USB infrastructure.  As of this commit my
USB camera, Hard Drive, Mouse, and Sony memory key all work and I can even
unplug and replug them in without crashing the port.

Not all drivers and subsystems compile as of this commit, but the ones that
do not are very close.

Revision 1.36: download - view: text, markup, annotated - select for diffs
Wed Dec 10 23:48:07 2003 UTC (10 years, 10 months ago) by hsu
Branches: MAIN
Diff to: previous 1.35: preferred, unified
Changes since revision 1.35: +1 -0 lines
Pull the sf_buf routines and structures out into its own files in
anticipation of wider future use.

Requested and reviewed by:	dillon

Revision 1.35: download - view: text, markup, annotated - select for diffs
Wed Dec 10 22:27:26 2003 UTC (10 years, 10 months ago) by dillon
Branches: MAIN
Diff to: previous 1.34: preferred, unified
Changes since revision 1.34: +1 -0 lines
Add -fstack-protector support for the kernel.

    http://www.trl.ibm.com/projects/security/ssp/

Submitted-by: Ryan Dooley <dooleyr@missouri.edu>

Revision 1.34: download - view: text, markup, annotated - select for diffs
Wed Dec 10 00:29:23 2003 UTC (10 years, 10 months ago) by dillon
Branches: MAIN
Diff to: previous 1.33: preferred, unified
Changes since revision 1.33: +2 -0 lines
Add strlcpy and strlcat to libkern

Revision 1.33: download - view: text, markup, annotated - select for diffs
Sun Dec 7 19:23:36 2003 UTC (10 years, 10 months ago) by dillon
Branches: MAIN
Diff to: previous 1.32: preferred, unified
Changes since revision 1.32: +3 -1 lines
PCI compat cleanup, part 1.  This brings in the LNC and VX drivers
from FreeBSD-5.  They are not the newest versions, just new enough to
use newbus, not the PCI compat code.

Submitted-by: Joerg Sonnenberger <joerg@britannica.bec.de>

Revision 1.32: download - view: text, markup, annotated - select for diffs
Tue Dec 2 08:00:22 2003 UTC (10 years, 10 months ago) by asmodai
Branches: MAIN
Diff to: previous 1.31: preferred, unified
Changes since revision 1.31: +1 -0 lines
Add PFIL_HOOKS functionality.  This allows us to plug in many firewalling
architectures by using/having generic hooks in the networking code.

Revision 1.31: download - view: text, markup, annotated - select for diffs
Sun Nov 30 20:13:51 2003 UTC (10 years, 10 months ago) by dillon
Branches: MAIN
Diff to: previous 1.30: preferred, unified
Changes since revision 1.30: +1 -0 lines
Add the MPIPE subsystem.  This subsystem is used for 'pipelining' fixed-size
allocations.  Pipelining is used to avoid lack-of-resource deadlocks by
still allowing resource allocations to 'block' by guarenteeing that an
already in-progress operation will soon free memory that will be immediately
used to satisfy the blocked resource.

Adjust the ATAold code to use the new mechanism and remove the code that
tried to back-off into PIO mode when resources were lacking.

Revision 1.30: download - view: text, markup, annotated - select for diffs
Fri Nov 21 05:29:05 2003 UTC (10 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.29: preferred, unified
Changes since revision 1.29: +1 -0 lines
Implement an upcall mechanism to support userland LWKT.  This mechanism will
allow multiple processes sharing the same VM space (aka clone/threading)
to send each other what are basically IPIs.

Two new system calls have been added, upc_register() and upc_control().
Documentation is forthcoming.  The upcalls are nicely abstracted and a
program can register as many as it wants up to the kernel limit (which
is 32 at the moment).

The upcalls will be used for passing asynch data from kernel to userland,
such as asynch syscall message replies, for thread preemption timing,
software interrupts, IPIs between virtual cpus (e.g. between the processes
that are sharing the single VM space).

Revision 1.29: download - view: text, markup, annotated - select for diffs
Sun Nov 16 10:32:46 2003 UTC (10 years, 11 months ago) by asmodai
Branches: MAIN
Diff to: previous 1.28: preferred, unified
Changes since revision 1.28: +24 -287 lines
Rework the logic in the kernel config files.
Remove all build magic for the module interface methods from the 'files'
file and move it to the Makefile where it belongs.

Based on:	Makefile.i386 1.181 and files 1.348
Tested with:	LINT

Revision 1.28: download - view: text, markup, annotated - select for diffs
Fri Nov 14 20:54:06 2003 UTC (10 years, 11 months ago) by daver
Branches: MAIN
Diff to: previous 1.27: preferred, unified
Changes since revision 1.27: +1 -0 lines
Split mmap().

Move ovadvise(), ogetpagesize() and ommap() to new file 43bsd/43bsd_vm.c.

http://gomerbud.com/daver/patches/dragonfly/syscall-separation-15.diff

Revision 1.27: download - view: text, markup, annotated - select for diffs
Fri Nov 14 01:53:54 2003 UTC (10 years, 11 months ago) by daver
Branches: MAIN
Diff to: previous 1.26: preferred, unified
Changes since revision 1.26: +1 -0 lines

Move ogethostname(), osethostname(), ogethostid(), osethostid(), and
oquota() to the 43bsd emulation subtree.

Change o{get,set}hostname() to use kernel_sysctl() instead of
userland_sysctl().

Revision 1.26: download - view: text, markup, annotated - select for diffs
Sat Nov 8 07:57:40 2003 UTC (10 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.25: preferred, unified
Changes since revision 1.25: +1 -0 lines
Network threading stage 1/3: netisrs are already software interrupts,
which means they alraedy run in their own thread.  This commit creates
multiple supporting threads for netisrs rather then just one and code
has been added to begin routing packets to particular threads based on
their content.  Eventually this will lead to us being able to isolate and
serialize PCBs in particular threads.  The tail end of the ip_input path's
protocol dispatch, the UIPC (user entry) code, and listen socket have not
been covered yet and still need to be serialized.

A new debugging sysctl, net.inet.ip.mthread_enable, has been added.  It
defaults to 1.  If you set this sysctl 0 netisr processing will revert to
the prior single-threaded behavior.

Submitted-by: Jeffrey Hsu <hsu@FreeBSD.org>
Additional-work-by: dillon

Revision 1.25: download - view: text, markup, annotated - select for diffs
Wed Nov 5 23:26:15 2003 UTC (10 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.24: preferred, unified
Changes since revision 1.24: +1 -0 lines
Variant symlink support stage 1/2: Implement support for storing and retrieving
system-specific, user-specific, and process-specific variables.

Revision 1.24: download - view: text, markup, annotated - select for diffs
Tue Nov 4 20:30:53 2003 UTC (10 years, 11 months ago) by dillon
Branches: MAIN
Diff to: previous 1.23: preferred, unified
Changes since revision 1.23: +2 -0 lines
add cmpdi2 and ucmpdi2 to conf/files to fix LINT build.

Revision 1.23: download - view: text, markup, annotated - select for diffs
Mon Nov 3 15:57:33 2003 UTC (10 years, 11 months ago) by daver
Branches: MAIN
Diff to: previous 1.22: preferred, unified
Changes since revision 1.22: +2 -0 lines
Split wait4(), setrlimit(), getrlimit(), statfs(), fstatfs(), chdir(),
open(), mknod(), link(), symlink(), unlink(), lseek(), access(), stat(),
lstat(), readlink(), chmod(), chown(), lchown(), utimes(), lutimes(),
futimes(), truncate(), rename(), mkdir(), rmdir(), getdirentries(),
getdents().

Trash the 4.3BSD numeric filesystem type support in mount().

Move ocreat(), olseek(), otruncate(), ostat(), olstat(), owait(),
ogetrlimit(), and osetrlimit() to the 43bsd subtree and reimplement
using split syscalls.  Move ogetdirentries() to the subtree without
change because it is such a mess.

Convince linux_waitpid(), linux_wait(), linux_setrlimit(),
linux_old_getrlimit(), and linux_getrlimit() to use split syscalls.

The file kern/vfs_syscalls.c is now completely free of COMPAT_43 code.
I believe that execve() is the only pending split before I can tackle
stackgap usage in the linux emulator's CHECKALT{EXIST,CREAT}() macros.

Revision 1.22: download - view: text, markup, annotated - select for diffs
Fri Oct 31 21:49:23 2003 UTC (10 years, 11 months ago) by asmodai
Branches: MAIN
Diff to: previous 1.21: preferred, unified
Changes since revision 1.21: +1 -0 lines
Add nForce AGP support, taken from FreeBSD with some minor changes to get
it to work with DragonFly.

Revision 1.21: download - view: text, markup, annotated - select for diffs
Fri Oct 24 14:10:45 2003 UTC (11 years ago) by daver
Branches: MAIN
Diff to: previous 1.20: preferred, unified
Changes since revision 1.20: +1 -0 lines
Remove the FreeBSD 3.x signal code.  This includes osendsig(),
osigreturn() and a couple of structures that these syscalls depended
on.

Split the sigaction(), sigprocmask(), sigpending(), sigsuspend(),
sigaltstack() and kill() syscalls.

Move the 4.3BSD signal syscalls osigvec(), osigblock(), osigsetmask(),
osigstack() and okillpg() to the 43bsd subtree.  I'm not too sure
if these will even work with the FreeBSD-4 signal trampoline code,
but they do compile and link.

Implement linux_signal(), linux_rt_sigaction(), linux_sigprocmask(),
linux_rt_sigprocmask(), linux_sigpending(), linux_kill(),
linux_sigaction(), linux_sigsuspend(), linux_rt_sigsuspend(),
linux_pause(), and linux_sigaltstack() with the new in-kernel syscalls.
This patch kills 7 stackgap allocations in the Linuxolator.

Revision 1.20: download - view: text, markup, annotated - select for diffs
Tue Oct 21 01:05:09 2003 UTC (11 years ago) by daver
Branches: MAIN
Diff to: previous 1.19: preferred, unified
Changes since revision 1.19: +2 -0 lines
Create the kern_fstat() and kern_ftruncate() in-kernel syscalls.

Implement fstat(), nfstat() and ftruncate() using the in-kernel syscalls.

Move ofstat() and oftruncate() to the 43bsd emulation tree and implement
with in-kernel syscalls.

Create the linux_ftruncate() syscall in the linux emulation layer.  This
replaces a direct use of oftruncate() in the linux syscall map.  Rewrite
linux_newfstat() and linux_fstat64() with the in-kernel syscalls.

Revision 1.19: download - view: text, markup, annotated - select for diffs
Sun Oct 19 00:23:20 2003 UTC (11 years ago) by dillon
Branches: MAIN
Diff to: previous 1.18: preferred, unified
Changes since revision 1.18: +0 -1 lines
Entirely remove the old kernel malloc and kmem_map code.  The slab allocator
is now mandatory.  Also remove the related conf options, USE_KMEM_MAP and
NO_SLAB_ALLOCATOR.

Revision 1.18: download - view: text, markup, annotated - select for diffs
Wed Oct 15 16:48:03 2003 UTC (11 years ago) by hmp
Branches: MAIN
Diff to: previous 1.17: preferred, unified
Changes since revision 1.17: +1 -0 lines
Second contigmalloc() cleanup:

	* Move the contigmalloc/vm_contig_pg API into its own
	  file, vm_contig.c.

	* Give contigmalloc1() a more sensible to reflect its
	  purpose, contigmalloc_map().

Revision 1.17: download - view: text, markup, annotated - select for diffs
Mon Oct 13 18:01:23 2003 UTC (11 years ago) by dillon
Branches: MAIN
Diff to: previous 1.16: preferred, unified
Changes since revision 1.16: +1 -0 lines
Augment falloc() to support thread-only file pointers (with no integer file
descriptor or process).

Add new generic 'easy to use' fp_*() kernel functions which operate on file
pointers.  This will greatly ease in-kernel functions which must open,
perform I/O, and close files.

Adopted from: other kernel sources and Kip Macy's checkpoint code.

Revision 1.16: download - view: text, markup, annotated - select for diffs
Wed Sep 24 04:39:46 2003 UTC (11 years, 1 month ago) by drhodus
Branches: MAIN
Diff to: previous 1.15: preferred, unified
Changes since revision 1.15: +2 -1 lines

	Looks like we can't have comments on the same
	lines that are being parsed.

Revision 1.15: download - view: text, markup, annotated - select for diffs
Wed Sep 24 03:32:15 2003 UTC (11 years, 1 month ago) by drhodus
Branches: MAIN
Diff to: previous 1.14: preferred, unified
Changes since revision 1.14: +146 -0 lines


*  Intel ACPI 20030228 distribution with local DragonFly changes.

*  OSPM ACPI driver.  Note that this driver does not include
   support for PCI interrupt routing or enumeration of ISA bridges or
   Host to PCI bridges.  While functional on some machines, this driver
   should be considered experimental and should be tested prior to being
   deployed in a production environment.


Original work done by John Baldwin
  Sponsored by:   The Weather Channel

Revision 1.14: download - view: text, markup, annotated - select for diffs
Mon Sep 15 23:38:12 2003 UTC (11 years, 1 month ago) by hsu
Branches: MAIN
Diff to: previous 1.13: preferred, unified
Changes since revision 1.13: +0 -1 lines
Centralize if queue handling.

Original patch against FreeBSD submitted by Jonathan Lemon.
Reviewed by Matt Dillon.

Revision 1.13: download - view: text, markup, annotated - select for diffs
Fri Sep 12 00:43:30 2003 UTC (11 years, 1 month ago) by daver
Branches: MAIN
Diff to: previous 1.12: preferred, unified
Changes since revision 1.12: +1 -1 lines
Create an emulation/43bsd directory and move the recently modified
compatibility syscalls there. Any future work on the COMPAT_43 code
should be split from the rest of the kernel and moved here.

Everything in the kernel that explicity uses the osockaddr structure
has been modified to include "emulation/43bsd/43bsd_socket.h".

There was one case where struct osockaddr was used in userland,
talk/talkd.  This commit has a temporary fix for talk/talkd.

Revision 1.12: download - view: text, markup, annotated - select for diffs
Sat Sep 6 21:51:11 2003 UTC (11 years, 1 month ago) by drhodus
Branches: MAIN
Diff to: previous 1.11: preferred, unified
Changes since revision 1.11: +1 -0 lines

Inital cleanup work to make NETNS compile again
before someone tries to remove it. 8-)
Also fix a few small bugs and try to make
the code do the right thing.

Revision 1.11: download - view: text, markup, annotated - select for diffs
Wed Aug 27 01:43:05 2003 UTC (11 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.10: preferred, unified
Changes since revision 1.10: +1 -0 lines
SLAB ALLOCATOR Stage 1.  This brings in a slab allocator written from scratch
by your's truely.  A detailed explanation of the allocator is included but
first, other changes:

* Instead of having vm_map_entry_insert*() and friends allocate the
  vm_map_entry structures a new mechanism has been emplaced where by
  the vm_map_entry structures are reserved at a higher level, then
  expected to exist in the free pool in deep vm_map code.  This preliminary
  implementation may eventually turn into something more sophisticated that
  includes things like pmap entries and so forth.  The idea is to convert
  what should be low level routines (VM object and map manipulation)
  back into low level routines.

* vm_map_entry structure are now per-cpu cached, which is integrated into
  the the reservation model above.

* The zalloc 'kmapentzone' has been removed.  We now only have 'mapentzone'.

* There were race conditions between vm_map_findspace() and actually
  entering the map_entry with vm_map_insert().  These have been closed
  through the vm_map_entry reservation model described above.

* Two new kernel config options now work.  NO_KMEM_MAP has been fleshed out
  a bit more and a number of deadlocks related to having only the kernel_map
  now have been fixed.  The USE_SLAB_ALLOCATOR option will cause the kernel
  to compile-in the slab allocator instead of the original malloc allocator.
  If you specify USE_SLAB_ALLOCATOR you must also specify NO_KMEM_MAP.

* vm_poff_t and vm_paddr_t integer types have been added.  These are meant
  to represent physical addresses and offsets (physical memory might be
  larger then virtual memory, for example Intel PAE).  They are not heavily
  used yet but the intention is to separate physical representation from
  virtual representation.

			    SLAB ALLOCATOR FEATURES

The slab allocator breaks allocations up into approximately 80 zones based
on their size.  Each zone has a chunk size (alignment).  For example, all
allocations in the 1-8 byte range will allocate in chunks of 8 bytes.  Each
size zone is backed by one or more blocks of memory.  The size of these
blocks is fixed at ZoneSize, which is calculated at boot time to be between
32K and 128K.  The use of a fixed block size allows us to locate the zone
header given a memory pointer with a simple masking operation.

The slab allocator operates on a per-cpu basis.  The cpu that allocates a
zone block owns it.  free() checks the cpu that owns the zone holding the
memory pointer being freed and forwards the request to the appropriate cpu
through an asynchronous IPI.  This request is not currently optimized but it
can theoretically be heavily optimized ('queued') to the point where the
overhead becomes inconsequential.  As of this commit the malloc_type
information is not MP safe, but the core slab allocation and deallocation
algorithms, non-inclusive the having to allocate the backing block,
*ARE* MP safe.  The core code requires no mutexes or locks, only a critical
section.

Each zone contains N allocations of a fixed chunk size.  For example, a
128K zone can hold approximately 16000 or so 8 byte allocations.  The zone
is initially zero'd and new allocations are simply allocated linearly out
of the zone.  When a chunk is freed it is entered into a linked list and
the next allocation request will reuse it.  The slab allocator heavily
optimizes M_ZERO operations at both the page level and the chunk level.

The slab allocator maintains various undocumented malloc quirks such as
ensuring that small power-of-2 allocations are aligned to their size,
and malloc(0) requests are also allowed and return a non-NULL result.
kern_tty.c depends heavily on the power-of-2 alignment feature and ahc
depends on the malloc(0) feature.  Eventually we may remove the malloc(0)
feature.

			    PROBLEMS AS OF THIS COMMIT

NOTE!  This commit may destabilize the kernel a bit.  There are issues
with the ISA DMA area ('bounce' buffer allocation) due to the large backing
block size used by the slab allocator and there are probably some deadlock
issues do to the removal of kmem_map that have not yet been resolved.

Revision 1.10: download - view: text, markup, annotated - select for diffs
Thu Aug 7 21:16:48 2003 UTC (11 years, 2 months ago) by dillon
Branches: MAIN
Diff to: previous 1.9: preferred, unified
Changes since revision 1.9: +1010 -1011 lines
kernel tree reorganization stage 1: Major cvs repository work (not logged as
commits) plus a major reworking of the #include's to accomodate the
relocations.

    * CVS repository files manually moved.  Old directories left intact
      and empty (temporary).

    * Reorganize all filesystems into vfs/, most devices into dev/,
      sub-divide devices by function.

    * Begin to move device-specific architecture files to the device
      subdirs rather then throwing them all into, e.g. i386/include

    * Reorganize files related to system busses, placing the related code
      in a new bus/ directory.  Also move cam to bus/cam though this may
      not have been the best idea in retrospect.

    * Reorganize emulation code and place it in a new emulation/ directory.

    * Remove the -I- compiler option in order to allow #include file
      localization, rename all config generated X.h files to use_X.h to
      clean up the conflicts.

    * Remove /usr/src/include (or /usr/include) dependancies during the
      kernel build, beyond what is normally needed to compile helper
      programs.

    * Make config create 'machine' softlinks for architecture specific
      directories outside of the standard <arch>/include.

    * Bump the config rev.

    WARNING! after this commit /usr/include and /usr/src/sys/compile/*
    should be regenerated from scratch.

Revision 1.9: download - view: text, markup, annotated - select for diffs
Sun Aug 3 12:29:05 2003 UTC (11 years, 2 months ago) by hmp
Branches: MAIN
Diff to: previous 1.8: preferred, unified
Changes since revision 1.8: +1 -0 lines
Move the backtrace() function from kern_subr.c to  kern_debug.c.

All debugging related kernel functions, and syscalls should
be added into this file.

Discussed with:	Matt (about kern_debug.c)

Revision 1.8: download - view: text, markup, annotated - select for diffs
Tue Jul 22 17:03:26 2003 UTC (11 years, 3 months ago) by dillon
Branches: MAIN
Diff to: previous 1.7: preferred, unified
Changes since revision 1.7: +1 -0 lines
DEV messaging stage 2/4: In this stage all DEV commands are now being
funneled through the message port for action by the port's beginmsg function.
CONSOLE and DISK device shims replace the port with their own and then
forward to the original.  FB (Frame Buffer) shims supposedly do the same
thing but I haven't been able to test it.   I don't expect instability
in mainline code but there might be easy-to-fix, and some drivers still need
to be converted.  See primarily: kern/kern_device.c (new dev_*() functions and
inherits cdevsw code from kern/kern_conf.c), sys/device.h, and kern/subr_disk.c
for the high points.

In this stage all DEV messages are still acted upon synchronously in the
context of the caller.  We cannot create a separate handler thread until
the copyin's (primarily in ioctl functions) are made thread-aware.

Note that the messaging shims are going to look rather messy in these early
days but as more subsystems are converted over we will begin to use
pre-initialized messages and message forwarding to avoid having to constantly
rebuild messages prior to use.

Note that DEV itself is a mess oweing to its 4.x roots and will be cleaned
up in subsequent passes.  e.g. the way sub-devices inherit the main device's
cdevsw was always a bad hack and it still is, and several functions
(mmap, kqfilter, psize, poll) return results rather then error codes, which
will be fixed since now we have a message to store the result in :-)

Revision 1.7: download - view: text, markup, annotated - select for diffs
Sun Jul 20 01:37:19 2003 UTC (11 years, 3 months ago) by dillon
Branches: MAIN
Diff to: previous 1.6: preferred, unified
Changes since revision 1.6: +2 -1 lines
This is the initial implmentation of the LWKT messaging infrastructure.
Messages are sent to message ports and typically replied to a message port
embedded in the originating thread's thread structure (td_msgport).
The port functions match up and optimization client sync/asynch requests
verses target synch/asynch responses.

In this initial implementation a port must be owned by a particular thread,
and we use *asynch* IPI messaging to forward queueing and dequeueing operations
to the correct cpu.  Most of the IPI overhead will be absorbed by the fact
that these same IPIs also tend to schedule the threads in question, which on
the correct cpu (which is the one it will be on) costs nothing.

Message ports have in-context dispatch functions for initiating, aborting,
and replying to a message which can be overriden and will queue by default.

This code compiles but is as yet unreferenced, and almost certainly needs more
work.

Revision 1.6: download - view: text, markup, annotated - select for diffs
Sun Jun 29 03:28:41 2003 UTC (11 years, 3 months ago) by dillon
Branches: MAIN
CVS tags: PRE_MP
Diff to: previous 1.5: preferred, unified
Changes since revision 1.5: +2 -1 lines
threaded interrupts 1: Rewrite the ICU interrupt code, splz, and doreti code.
The APIC code hasn't been done yet.   Consolidate many interrupt thread
related functions into MI code, especially software interrupts.  All normal
interrupts and software interrupts are now threaded, and I'm almost ready
to deal with interrupt-thread-only preemption.  At the moment I run
interrupt threads in a critical section and probably will continue to do
so until I can make them MP safe.

Revision 1.5: download - view: text, markup, annotated - select for diffs
Sat Jun 21 17:31:05 2003 UTC (11 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.4: preferred, unified
Changes since revision 1.4: +2 -1 lines
Add kern/lwkt_rwlock.c -- reader/writer locks.  Clean up the process exit &
reaping interlock code to allow context switches to occur.  Clean up and
make operational the lwkt_block/signaling code.

Revision 1.4: download - view: text, markup, annotated - select for diffs
Sat Jun 21 07:54:53 2003 UTC (11 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.3: preferred, unified
Changes since revision 1.3: +2 -2 lines
thread stage 8: add crit_enter(), per-thread cpl handling, fix deferred
interrupt handling for critical sections, add some basic passive token code,
and blocking/signaling code.   Add structural definitions for additional
LWKT mechanisms.

Remove asleep/await.  Add generation number based xsleep/xwakeup.

Note that when exiting the last crit_exit() we run splz() to catch up
on blocked interrupts.  There is also some #if 0'd code that will cause
a thread switch to occur 'at odd times'... primarily wakeup()->
lwkt_schedule()->critical_section->switch.  This will be usefulf or testing
purposes down the line.

The passive token code is mostly disabled at the moment.  It's primary use
will be under SMP and its primary advantage is very low overhead on UP and,
if used properly, should also have good characteristics under SMP.

Revision 1.3: download - view: text, markup, annotated - select for diffs
Fri Jun 20 02:09:47 2003 UTC (11 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.2: preferred, unified
Changes since revision 1.2: +2 -1 lines
thread stage 7: Implement basic LWKTs, use a straight round-robin model for
the moment.  Also continue consolidating the globaldata structure so both UP
and SMP use it with more commonality.  Temporarily match user processes up
with scheduled LWKTs on a 1:1 basis.  Eventually user processes will have
LWKTs, but they will not all be scheduled 1:1 with the user process's
runnability.

With this commit work can potentially start to fan out, but I'm not ready
to announce yet.

Revision 1.2: download - view: text, markup, annotated - select for diffs
Tue Jun 17 04:28:19 2003 UTC (11 years, 4 months ago) by dillon
Branches: MAIN
Diff to: previous 1.1: preferred, unified
Changes since revision 1.1: +1 -0 lines
Add the DragonFly cvs id and perform general cleanups on cvs/rcs/sccs ids.  Most
ids have been removed from !lint sections and moved into comment sections.

Revision 1.1: download - view: text, markup, annotated - select for diffs
Tue Jun 17 02:53:55 2003 UTC (11 years, 4 months ago) by dillon
Branches: MAIN
CVS tags: FREEBSD_4_FORK
import from FreeBSD RELENG_4 1.340.2.137

Diff request

This form allows you to request diffs between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.

Log view options