Commit Graph

1553 Commits

Author SHA1 Message Date
jmcneill
fa30660c16 reserve char 200 for dtv 2011-07-09 14:47:27 +00:00
mrg
0514da4400 adb_kbd.c and adb_ms.c need -Wno-cast-qual due to sysctl const issue. 2011-07-07 08:47:22 +00:00
mrg
fc8b9ddc0c apply some -Wno-foo to 3 files that are non-trivial to solve, for GCC 4.5. 2011-07-04 13:00:19 +00:00
uch
9255b46fb4 7th Edition(V7) File System support. and NetBSD symbolic-link, socket, FIFO extension. see newfs_v7fs(8). 2011-06-27 11:52:22 +00:00
matt
65bd0920b3 Allow PAX_ASLR to be used by itself. 2011-06-23 23:42:43 +00:00
mrg
8f161cd6d3 remove all the code that supported HAVE_GCC=3. mostly from chuq. 2011-06-20 06:52:36 +00:00
matt
3a0f273eba If dbsym fails, not fail the command, remove the target too so that the
next invokation will try to remake it.
2011-06-17 21:19:42 +00:00
joerg
94dd60a9c3 Don't duplicate -Werror here, bsd.sys.mk already provides it 2011-05-30 03:12:43 +00:00
matt
2a1887ef27 Allow COM_TOLERANCE to be tweakable. If comspeed returns an invalid
rate, don't use that error value to set the speed.
2011-05-28 19:30:19 +00:00
joerg
a216da57a6 Default to -Wno-sign-compare -Wno-pointer-sign for clang.
Push -Wno-array-bounds down to the cases that depend on it.
Selectively disable warnings for 3rd party software or non-trivial
issues to be reviewed later to get clang -Werror to build most of the
tree.
2011-05-26 12:56:24 +00:00
drochner
4bd7f95161 -remove references to crypto/arc4/arc4.* -- the code isn't used
anywhere afaics
 (The confusion comes probably from use of arc4random() at various places,
  but this lives in libkern and doesn't share code with the former.)
-g/c non-implementation of arc4 encryption in swcrypto(4)
-remove special casing of ARC4 in crypto(4) -- the point is that it
 doesn't use an IV, and this fact is made explicit by the new "ivsize"
 property of xforms
2011-05-23 15:37:35 +00:00
joerg
d3630a7492 Reorder flag order to not depend on -Wextra being applied before
-Wno-sign-compare
2011-05-23 13:55:55 +00:00
mrg
45a8ff3bec move KERNHIST stuff much earlier, so drivers can depend upon it. 2011-05-23 06:50:17 +00:00
joerg
abe88b5ff5 Inherit SSP settings from bsd.sys.mk 2011-05-22 20:49:46 +00:00
joerg
188ae306aa Spell --fatal-warnings with two hyphens 2011-05-19 21:24:55 +00:00
joerg
eab53d10cd Add support for source specific AFLAGS and COPTS. 2011-05-17 07:16:02 +00:00
mrg
a852848eef fix the ordering and make UVMHIST enable KERNHIST automatically. 2011-05-17 05:32:31 +00:00
mrg
8169e46991 move and rename the uvm history code out of uvm_stat to "kernhist".
rename "UVMHIST" option to enable the uvm histories.

TODO:
- make UVMHIST properly depend upon KERNHIST
- enable dynamic registration of histories.  this is mostly just
  allocating something in a bitmap, and is only for viewing multiple
  histories in a merged form.


tested on amd64 and sparc64.
2011-05-17 04:18:05 +00:00
jakllsch
7124327c01 Make ${DBSYM} failure fatal. 2011-05-11 16:03:56 +00:00
drochner
9d083d2f9c add "camellia" crypto code, copied from FreeBSD 2011-05-05 17:38:35 +00:00
plunky
676a6668e7 correct comment 2011-04-30 19:21:09 +00:00
joerg
787e55aa29 Remove PECOFF/Win32 emulation. 2011-04-26 16:57:38 +00:00
joerg
e958063324 Remove IRIX emulation 2011-04-26 16:36:40 +00:00
joerg
5aca2679d7 Remove Darwin, MACH and Mach-O support. 2011-04-26 15:51:22 +00:00
rmind
fbc8beae75 Split off parts of vfs_subr.c into vfs_vnode.c and vfs_mount.c modules.
No functional change.  Discussed on tech-kern@.
2011-04-02 04:28:56 +00:00
dyoung
060522dec8 Hide the radix-trie implementation of the forwarding table so that we
will have an easier time replacing it with something different, even if
it is a second radix-trie implementation.

sys/net/route.c and sys/net/rtsock.c no longer operate directly on
radix_nodes or radix_node_heads.

Hopefully this will reduce the temptation to implement multipath or
source-based routing using grotty hacks to the grotty old radix-trie
code, too. :-)
2011-03-31 19:40:51 +00:00
tsutsui
73969d32cf Add usb_dma attribute for DMA capable USB host controllers
and specify that usb_dma attribute to dev/usb/usb_mem.c.

usb_mem.c uses bus_dma(9) for DMA memory allocation,
but non-DMA capable USB host controllers like slhci(4)
doesn't need them at all, and some ports don't bother to
prepare MD bus_dma(9) implementation (yet).

Discussed on current-users
 http://mail-index.NetBSD.org/current-users/2011/03/13/msg015995.html
and usb_dma attribute is suggested by bouyer@.
Tested by kiyohara@ on mmeye with slhci at pcmcia.
2011-03-20 17:54:02 +00:00
bouyer
063f96f3c2 merge the bouyer-quota2 branch. This adds a new on-disk format
to store disk quota usage and limits, integrated with ffs
metadata. Usage is checked by fsck_ffs (no more quotacheck)
and is covered by the WAPBL journal. Enabled with kernel
option QUOTA2 (added where QUOTA was enabled in kernel config files),
turned on with tunefs(8) on a per-filesystem
basis. mount_mfs(8) can also turn quotas on.

See http://mail-index.netbsd.org/tech-kern/2011/02/19/msg010025.html
for details.
2011-03-06 17:08:10 +00:00
ahoka
2b6ee22130 Import the Flash and NAND subsytem code contributed by the University
of Szeged, Hungary.

The commit includes:
 - Flash layer, which gives a common API to access flash devices
 - NAND controller subsystem for the flash layer
 - An example OMAP driver which is used on BeagleBoard or alike ARM boards
2011-02-26 18:07:13 +00:00
jmcneill
6a0ee33bc0 add VirtualBox DRM driver 2011-02-20 15:40:21 +00:00
matt
7cefbb6066 Default PCU_UNIT_COUNT to 0. If 0, don't compile the contents of subr_pcu.c
and don't include the pcu related members into struct lwp.
2011-02-19 20:19:54 +00:00
rmind
617a3e62e4 Compile subr_pcu.c under option PCU. 2011-02-18 22:49:03 +00:00
matt
d6c7c66ed9 If generating a gdb kernel and using dbsym, insert the symbols into it.
(This is useful when using the .gdb with an emulator so that ddb in the
emulator will have symbols).
2011-02-17 18:47:13 +00:00
rmind
bc16d8a440 Add PCU (Per-CPU Unit) - an interface to manage synchronization of any
per CPU context tied with an LWP.  Main use - lazy FPU handling on SMP.

Requested by matt@, will be used on mips64.  Note: implementation will
be improved to use IPIs before adopting on x86.  OK ad@.
2011-02-17 18:32:29 +00:00
macallan
5c83b0f64d use the bus independent stuff from ic/ct65550* and leave only the PCI specific
bits in pci/chipsfb.c
2011-02-09 21:21:32 +00:00
jmcneill
4ed3c0a866 add a public domain image decoder 2011-02-06 23:13:04 +00:00
joerg
3c550524b5 Drop bootprog_maker (formerly enabled by -M) and bootprog_date (formerly
disabled by -D) from the output of newvers_stand.sh.  Change -D to the
inverted logic, so that it adds the date to bootprog_rev in ().

Change all platforms accordingly. -D is added if MKREPRO is not yes and
wasn't present before. Platforms that didn't use -D don't depend on
MKREPRO now either.
2011-01-22 19:19:14 +00:00
jmcneill
bc2a81f763 unreserve kmixer 2011-01-20 19:10:02 +00:00
jmcneill
1dc6287662 reserve a major number for kmixer 2011-01-05 22:35:08 +00:00
matt
802fd8b955 If using a kernel ldscript, make sure it's added to the list of kernel
dependencies.
2011-01-04 01:52:30 +00:00
matt
d24d5902b3 Kernels modules are c99 (gnu99) just like the kernel.
Add(move) -std=gnu99 to CPPFLAGS (from COPTS).
2011-01-02 19:24:47 +00:00
uwe
cfaf20150d Revert previous. Add 2011 to the list in old format.
Let board@ decide if it's ok to switch to the range format.
2011-01-01 01:36:10 +00:00
rmind
304c5ab65d Welcome to 2011! Happy New Year!
Do not forget to update copyright notices when you add new code.
2011-01-01 00:29:23 +00:00
hannken
afdfce8e3b Remove unused count from pseudo-device md. 2010-11-23 11:13:52 +00:00
uebayasi
9150ddda9b Reserve an MI major for coming flash(4).
hpcmips defines one in MD majors, but it's not listed in
etc/etc.hpcmips/MAKEDEV.conf, so I assume actual files are never
created in users' filesystems.

Prompted By:	pooka
2010-10-27 14:08:08 +00:00
ahoka
f6f08ea895 add dme (dm9000 ethernet) 2010-09-08 22:55:54 +00:00
rmind
2e6f2099c6 Import NPF - a packet filter. Some features:
- Designed to be fully MP-safe and highly efficient.

- Tables/IP sets (hash or red-black tree) for high performance lookups.

- Stateful filtering and Network Address Port Translation (NAPT).
  Framework for application level gateways (ALGs).

- Packet inspection engine called n-code processor - inspired by BPF -
  supporting generic RISC-like and specific CISC-like instructions for
  common patterns (e.g. IPv4 address matching).  See npf_ncode(9) manual.

- Convenient userland utility npfctl(8) with npf.conf(8).

NOTE: This is not yet a fully capable alternative to PF or IPFilter.
Further work (support for binat/rdr, return-rst/return-icmp, common ALGs,
state saving/restoring, logging, etc) is in progress.

Thanks a lot to Matt Thomas for various useful comments and code review.
Aye by: board@
2010-08-22 18:56:18 +00:00
pgoyette
4a743ad47d Define a set of new kernel locking primitives to implement the recursive
kernconfig_mutex.  Update module subsystem to use this mutex rather than
its own internal (non-recursive) mutex.  Make module_autoload() do its
own locking to be consistent with the rest of the module_xxx() calls.
Update module(9) man page appropriately.

As discussed on tech-kern over the last few weeks.

Welcome to NetBSD 5.99.39 !
2010-08-21 13:17:31 +00:00
chs
8594179a40 COMPAT_LINUX32 requires COMPAT_LINUX. 2010-07-07 01:09:39 +00:00
kefren
25133d6d8f Fix build for MPLS import: add options MPLS, changed pseudo-device mpls
to pseudo-device ifmpls
2010-06-26 15:17:56 +00:00
kefren
826653c190 Add MPLS support, proposed on tech-net@ a couple of days ago
Welcome to 5.99.33
2010-06-26 14:24:27 +00:00
pooka
3da3ab250b For the simple cases, augment device-major with information on how
a driver expects /dev/node -> minor mappings to go and include that
information in devsw_conv.
(no, I didn't plow through all the MD majors files)
2010-04-30 20:47:17 +00:00
pooka
a6795f6ae1 compress whitespace. no functional change. 2010-04-30 20:28:13 +00:00
pooka
3767a7069c needs-count for fss is unused => needs-remove 2010-04-16 13:44:49 +00:00
pooka
59611015f4 Steal a static major number for rumpblk. 2010-04-14 16:05:23 +00:00
pooka
7ea24651a7 Move routines related to syscall establishment from kern_subr.c and
kern_stub.c to kern_syscall.c.
2010-04-14 14:46:59 +00:00
pooka
290fe400e0 Separate lwp specificdata data structure management from lwp cpu/vm
management.

No functional change.

(specificdata routines went from kern_lwp.c to subr_lwp_specificdata.c)
2010-04-12 22:15:31 +00:00
nonaka
38ac2371ac Added PCA9564 I2C Controller driver. 2010-04-09 10:09:49 +00:00
pgoyette
d41a3cef46 Split spdmem driver into a bus attachment and a common back-end
probe and ROM decode, to follow similar changes made in OpenBSD:

        http://article.gmane.org/gmane.os.openbsd.cvs/94948
        http://article.gmane.org/gmane.os.openbsd.cvs/94956

There exists at least one alternative attachment (for SGI IP35
systems; see http://article.gmane.org/gmane.os.openbsd.cvs/94947),
and there could be more in the future.

Thanks to Christoph Egger for pointing out the OpenBSD activity.
2010-03-24 00:31:41 +00:00
christos
724aa20200 rename DEBUG_ASLR -> PAX_ASLR_DEBUG 2010-03-15 20:35:19 +00:00
darran
ce440a888f DTrace: only build in kernel CTF support if DTrace support is enabled
(i.e. options KDTRACE_HOOKS).
2010-03-13 08:33:26 +00:00
darran
38c72d335c DTrace: Add support for CTF sections in the netbsd elf image, load these
at boot.
Add a ksyms_mod_foreach() function to iterate a callback function over the
set of elf symbols for a specific module (netbsd included).
Add kern_ctf.c and mod_ctf_get() to allow the retrieval and decompression
of CTF sections for a specific module.
2010-03-12 21:43:10 +00:00
plunky
c269ebf72f use a MI major number for uhso(4) driver
(requested by mrg)
2010-03-06 23:45:38 +00:00
njoly
3a3fc358b3 Use 'a && b && ...' contructs for running multiple commands on a single line
in Makefiles, to properly detect/report failures.
2010-03-05 23:06:49 +00:00
tsutsui
8f7c20ed4f Put several fixes to ne(4) driver for better 8 bit mode support,
especially on RTL8019AS which is also used for non-ISA local bus of
embedded controllers and some m68k machines like atari and x68k.

 * move RTL8019 probe and attach code from each bus attachment
   to MI ne2000_detect() and ne2000_attach()
 * change a method for backend and attachment to specify 8 bit mode
   to use a new sc->sc_quirk member, instead of sc->sc_dmawidth
 * handle more NE2000 8 bit mode specific settings, including
   bus_space(9) access width and available size of buffer memory
 * add a function to detect NE2000 8 bit mode
   (disabled by default, but enalbed by options NE2000_DETECT_8BIT
    to avoid possible regression on various ISA clones)
 * fix ipkdb attachment accordingly (untested)

Tested on two NE2000 ISA variants (RTL8019AS and another clone named UL0001)
in both 8 bit and 16 bit mode on i386. "Looks good" from nonaka@.

See my post on tech-kern for details:
http://mail-index.NetBSD.org/tech-kern/2010/02/26/msg007423.html
2010-03-03 13:39:57 +00:00
uebayasi
9cbe93a0cc Define i4b files in netisdn/files.i4b. 2010-03-02 13:27:27 +00:00
darran
6a9056a926 DTrace: Add an SDT (Statically Defined Tracing) provider framework, and
implement most of the proc provider.  Adds proc:::create, exec,
exec_success, exec_faillure, signal_send, signal_discard, signal_handle,
lwp_create, lwp_start, lwp_exit.
2010-03-01 21:10:13 +00:00
darran
0311cbad04 DTrace: remove kern_dtrace.c, no longer used 2010-02-23 22:21:25 +00:00
darran
37422f86b0 Added a defflag option for KDTRACE_HOOKS and included opt_dtrace.h in the
relevant files. (Per Quentin Garnier - thanks!).
2010-02-21 07:01:57 +00:00
darran
7fe76dd45f Add the DTrace kernel hooks file to the kernel build. 2010-02-21 04:00:47 +00:00
joerg
d621e29eca Remove separate mb_map. The nmbclusters is computed at boot time based
on the amount of physical memory and limited by NMBCLUSTERS if present.
Architectures without direct mapping also limit it based on the kmem_map
size, which is used as backing store. On i386 and ARM, the maximum KVA
used for mbuf clusters is limited to 64MB by default.

The old default limits and limits based on GATEWAY have been removed.
key_registered_sb_max is hard-wired to a value derived from 2048
clusters.
2010-02-08 19:02:25 +00:00
pooka
0f9bb09e12 Device accessors are only marginally related to autoconf, so put them
into subr_device.c instead of having them in subr_autoconf.c.

Since none of the copyrights in subr_autoconf.c really match the
history of device accessors, I took the liberty of slapping (c)
2006 TNF onto subr_device.c.
2010-01-31 15:10:11 +00:00
pooka
04b824ef52 Place *hook implementations in kern_hook.c instead of them floating
around in the kern_subr.c gruel.  Arrrrr.
2010-01-31 01:38:48 +00:00
pooka
92394bf5f3 Trade 200-something bytes for the death of an ifdef. 2010-01-30 23:19:55 +00:00
pooka
6e52e33956 ipfilter depends on bpf_filter, not bpfilter (since the year 2000). 2010-01-24 14:25:57 +00:00
pooka
10fe49d72c Redefine bpf linkage through an always present op vector, i.e.
#if NBPFILTER is no longer required in the client.  This change
doesn't yet add support for loading bpf as a module, since drivers
can register before bpf is attached.  However, callers of bpf can
now be modularized.

Dynamically loadable bpf could probably be done fairly easily with
coordination from the stub driver and the real driver by registering
attachments in the stub before the real driver is loaded and doing
a handoff.  ... and I'm not going to ponder the depths of unload
here.

Tested with i386/MONOLITHIC, modified MONOLITHIC without bpf and rump.
2010-01-19 22:06:18 +00:00
pooka
9c403c2e0c Specify bpf_filter attribute only when the device uses the filter engine. 2010-01-19 16:24:44 +00:00
dyoung
1b379d7ac4 Make cgd(4) into a detachable pseudo-device. Thanks, Jan Danielsson,
for the patches!

I've lightly tested the basics: create cgd0 on vnd0d, initialize with
zeros, newfs /dev/cgd0a, mount, copy files on, unmount, drvctl -d
cgd0.  Works fine.  I also shutdown with a cgd0 configured: detached as
expected.
2010-01-12 21:08:08 +00:00
snj
4619d47274 Remove ad clause on a UCB license. 2010-01-10 23:55:03 +00:00
jnemeth
590b8b7018 Welcome to 2010.
Don't forget to update copyright notices when you add new code.
2009-12-31 23:59:02 +00:00
pooka
25da823f47 * support passing ident on the command line
* rename -i to -n since it's less confusing when coupled with the above
2009-12-16 21:25:03 +00:00
pooka
ffd78a62ec Make it possible to leave out .note.netbsd.ident with command line flag -i. 2009-12-16 20:54:49 +00:00
pooka
70d4493c77 Remove the portalfs kernel file system driver. Replace mount_portal(8)
with a version based on puffs.  User functionality remains the same.
2009-12-05 20:11:01 +00:00
pooka
bbc50ef41d Due to the schizophrenic nature of kobj (mem + vfs source),
split the module in twain to subj_kobj.c (master + mem) and
subr_kobj_vfs.c (vfs).
2009-11-27 17:54:11 +00:00
kiyohara
6e701b77b2 Add attribute mii to smsh(4). 2009-11-25 08:52:38 +00:00
rmind
dbd9b86792 Remove some unecessary includes sys/user.h header. 2009-11-23 02:13:44 +00:00
pooka
a8ed404de6 * make it possible to include kern_module in a kernel without vfs
support, i.e. move vfs functionality to a separate module
  (kern_module_vfs.c)
* make module proplist size an MI constant (now 8k) instead of PAGE_SIZE
* change some error values to something else than the karmic EINVAL
2009-11-18 17:40:45 +00:00
dsl
c0ed6b9587 Fix borkeage 2009-11-15 18:41:08 +00:00
dsl
b6abfac44f Get patch part of version from comment. 2009-11-15 14:40:18 +00:00
dsl
3f7c0ec34d Use shell builtins instead of awk and sed.
Avoids problems with awk processing floating point numbers when LC_NUMERIC
give a decimal point of ','.
Fixes PR/42321
2009-11-15 13:39:00 +00:00
snj
b839469ef3 igsfb needs videomode. 2009-11-12 18:37:10 +00:00
tron
34ce7b691c "cgd.c" doesn't use variable size stack allocations anymore. 2009-11-10 20:24:50 +00:00
pooka
fcc20a4ba1 Split uiomove() and high-level copy routines out of the crowded
kern_subr and into their own cozy home in subr_copy.
2009-11-04 16:54:00 +00:00
pooka
83685e650c Heave-ho mutex/rwlock object routines into separate modules -- they
don't have anything to do with the lock internals.
2009-11-04 13:29:45 +00:00
dyoung
fe26b18dc7 Alphabetize. 2009-11-03 00:24:05 +00:00
apb
2fbd897fba Describe new -n option in a comment; improve description of -m option. 2009-10-29 06:33:27 +00:00
joerg
f92e474cf5 Add -n option to print major and minor version, e.g. 5.99 on -current. 2009-10-26 15:32:38 +00:00
rmind
40cf6f3659 Remove uarea swap-out functionality:
- Addresses the issue described in PR/38828.
- Some simplification in threading and sleepq subsystems.
- Eliminates pmap_collect() and, as a side note, allows pmap optimisations.
- Eliminates XS_CTL_DATA_ONSTACK in scsipi code.
- Avoids few scans on LWP list and thus potentially long holds of proc_lock.
- Cuts ~1.5k lines of code.  Reduces amd64 kernel size by ~4k.
- Removes __SWAP_BROKEN cases.

Tested on x86, mips, acorn32 (thanks <mpumford>) and partly tested on
acorn26 (thanks to <bjh21>).

Discussed on <tech-kern>, reviewed by <ad>.
2009-10-21 21:11:57 +00:00
pooka
68f37adaa6 Give humanize_number & format_bytes their own spots in the sun and move
from kern_subr to subr_humanize.
2009-10-02 15:48:41 +00:00
jmcneill
6c62f91733 Initial import of an SD/MMC driver for the Winbond W83L518D (and probably
W83L519D) Integrated Media Reader with PNP bus attachment glue.
2009-09-30 20:44:49 +00:00
jakllsch
37ed71241b Marvell has two "l"s, but not two "e"s.
(Also, Melllvar has three "l"s, but that's not really relevant here.)
2009-09-26 19:05:07 +00:00
jakllsch
a34f7e7b8b As, siisata attaches not just at pci, but for a while now, also at cardbus,
move siisata core driver config to the propper config file.
2009-09-26 19:01:04 +00:00
pooka
41c00db98c Chop init_sysctl into base nodes (init_sysctl_base.c) and the
kitchen sink (init_sysctl.c).  Further surgery may be needed down
the line.
2009-09-16 15:03:56 +00:00
sborrill
b88195cfa1 hdaudio(4) is a standards-compliant driver for Intel High Definition Audio.
It will replace azalia(4) after testing.

To use, comment out azalia in your kernel configuration and uncomment the
hdaudio and hdafg lines so it reads:

# Intel High Definition Audio
hdaudio*	at pci? dev ? function ?
hdafg*		at hdaudiobus?

You should also:
cd /dev
sh MAKEDEV audio
2009-09-06 17:25:55 +00:00
pooka
f926eb58c3 Remove autoconf dependency on vfs and dk:
opendisk() -> kern/subr_disk_open.c
config_handle_wedges -> dev/dkwedge/dk.c
2009-09-06 16:18:55 +00:00
mbalmer
3ab4ce4739 Add support for multi-position electro-mechanical keylocks. An example
driver, gpiolock(4), is provided as an example how to interface real hardware.
A new securemodel, securemodel_keylock, is provided to show how this can
be used to tie keylocks to overall system security.  This is experimental
code.  The diff has been on tech-kern for several weeks.

Reviewed by many, kauth(9) integration reviewed by Elad Efrat; approved by
tonnerre@ and tron@.  Thanks to everyone who provided feedback.
2009-08-14 21:17:21 +00:00
simonb
570522d1c8 Tab police. 2009-08-10 11:46:42 +00:00
matt
0dee8e59c9 Add [default] option to make UAREAs swappable. Disabling the option makes
them unswappable and therefore allocatable using KSEG/BAT/etc.
2009-08-09 21:58:03 +00:00
kiyohara
5bb9b7a6ef Support SMSC LAN9118 Family Ethernet interfaces device driver.
It tested on GUMSTIX only.
2009-08-09 06:40:09 +00:00
kiyohara
ce1343fcd9 Support Marvell Hercules-I/II SATA Controllers. 2009-07-27 12:34:12 +00:00
reinoud
69a586f230 Import read-only part of the NiLFS (v2) implementation for NetBSD. It has been
tested with a DEBUG+DIAGNOSTIC+LOCKDEBUG kernel. To summerise NiLFS, i'll
repeat my posting to tech-kern here:

NiLFS stands for New implementation of Logging File System; LFS done
right they claim :) It is at version 2 now and is being developed by NTT, the
Japanese telecom company and recently put into the linux source tree. See
http://www.nilfs.org. The on-disc format is not completely frozen and i expect
at least one minor revision to come in time.

The benefits of NiLFS are build-in fine-grained checkpointing, persistent
snapshots, multiple mounts and very large file and media support. Every
checkpoint can be transformed into a snapshot and v.v. It is said to perform
very well on flash media since it is not overwriting pieces apart from a
incidental update of the superblock, but that might change. It is accompanied
by a cleaner to clean up the segments and recover lost space.

My work is not a port of the linux code; its a new implementation. Porting the
code would be more work since its very linux oriented and never written to be
ported outside linux. The goal is to be fully interchangable. The code is non
intrusive to other parts of the kernel. It is also very light-weight.

The current state of the code is read-only access to both clean and dirty
NiLFS partitions. On mounting a dirty partition it rolls forward the log to
the last checkpoint. Full read-write support is however planned!

Just as the linux code, mount_nilfs allows for the `head' to be mounted
read/write and allows multiple read-only snapshots/checkpoint mounts next to
it.

By allowing the RW mount at a different snapshot for read-write it should be
possible eventually to revert back to a previous state; i.e. try to upgrade a
system and being able to revert to the exact state prior to the upgrade.

Compared to other FS's its pretty light-weight, suitable for embedded use and
on flash media. The read-only code is currently 17kb object code on
NetBSD/i386. I doubt the read-write code will surpass the 50 or 60. Compared
this to FFS being 156kb, UDF being 84 kb and NFS being 130kb. Run-time memory
usage is most likely not very different from other uses though maybe a bit
higher than FFS.
2009-07-18 16:31:41 +00:00
mrg
c7c2933c33 make external drm the default. 2009-06-21 20:15:26 +00:00
jakllsch
da65bf0f42 ahcisata now uses the common FIS code, register this dependency. 2009-06-17 04:02:59 +00:00
jakllsch
e5e3060059 ahcisata(4) and siisata(4) use similar SATA FIS functions, share them. 2009-06-17 03:07:51 +00:00
wiz
cf1c67ea5b <space> -> <tab> consistency. 2009-05-21 19:27:38 +00:00
cube
2a75637a75 Nothing has used config_time.h since 1/8/2008. 2009-05-13 18:06:26 +00:00
cube
0f7746f7cc Bump required config(1) version after files.drm changes [hi mrg!]. 2009-05-06 02:52:13 +00:00
elad
414eb0a314 Move dovfsusermount to secmodel_bsd44, where it really belongs.
The secmodel code now creates the same knob in two places: both under the
secmodel itself, as well as the widely known location.

Mailing list references:

    http://mail-index.netbsd.org/source-changes/2009/05/02/msg220641.html
    http://mail-index.netbsd.org/tech-kern/2009/05/03/msg005015.html
2009-05-03 21:25:44 +00:00
pooka
fb42667d02 Move dovfsusermount from vfs_syscalls.c to param.c: secmodel bsd44
depends on it and we can't isolate it in vfs.
(no, it doesn't really belong in param.c, but I couldn't figure out
a better place for it)
2009-05-02 14:13:28 +00:00
nonaka
e0297d1ead Added SD/MMC support from OpenBSD.
tested on i386, amd64 at current-users ML by pgoyette@.
tested on zaurus by myself.
2009-04-21 03:00:29 +00:00
perry
92ec9dc66a Add a MKREPRO variable (defaults to "no") that invokes newvers.sh with
the -r flag if it is set to "yes", resulting in a reproducible kernel build.
2009-03-30 16:34:19 +00:00
perry
b30c3a7aac Add a -r option that produces a version string without the time or kernel
build number in it. This will be used for reproducible builds.
2009-03-30 16:29:55 +00:00
pooka
e77db3f765 fix cscope target
Philip Paeps, PR kern/41012
2009-03-20 09:13:06 +00:00
jmcneill
143d119885 Add 'alternative memory' disk device driver. 2009-03-12 00:15:07 +00:00
joerg
f5b0fec0e0 Remove SHMMAXPGS from all kernel configs. Dynamically compute the
initial limit as 1/4 of the physical memory. Ensure the limit is at
least 1024 pages, the old default on most platforms.
2009-03-06 20:31:46 +00:00
ad
59fcf21389 PR kern/26878 FFSv2 + softdep = livelock (no free ram)
PR kern/16942 panic with softdep and quotas
PR kern/19565 panic: softdep_write_inodeblock: indirect pointer #1 mismatch
PR kern/26274 softdep panic: allocdirect_merge: ...
PR kern/26374 Long delay before non-root users can write to softdep partitions
PR kern/28621 1.6.x "vp != NULL" panic in ffs_softdep.c:4653 while unmounting a softdep (+quota) filesystem
PR kern/29513 FFS+Softdep panic with unfsck-able file-corruption
PR kern/31544 The ffs softdep code appears to fail to write dirty bits to disk
PR kern/31981 stopping scsi disk can cause panic (softdep)
PR kern/32116 kernel panic in softdep (assertion failure)
PR kern/32532 softdep_trackbufs deadlock
PR kern/37191 softdep: locking against myself
PR kern/40474 Kernel panic after remounting raid root with softdep

Retire softdep, pass 2. As discussed and later formally announced on the
mailing lists.
2009-02-22 20:28:05 +00:00
yamt
e951b81082 don't embed localized timestamps into kernels/bootblocks. 2009-02-20 13:41:27 +00:00
cube
ec543a2ce5 Convert the recently introduced awk command to retrieve the value of the
option MODULAR to using %MODULAR%.  While it is now possible to only
request the new version in the affected Makefiles, it is made mandatory for
everybody because I just fixed a bug in config(1) that would not make it
fail in the case of a syntax error in the Makefile template.
2009-02-15 01:58:01 +00:00
apb
0cc72e51ac Use "defopt MODULAR" in sys/conf/files, and #include "opt_modular.h"
in all kernel sources that use the MODULAR option.
Proposed in tech-kern on 18 Jan 2009.
2009-02-13 22:41:00 +00:00
christos
160a37667a Unbreak ssp kernels. The issue here that when the ssp_init() call was deferred,
it caused the return from the enclosing function to break, as well as the
ssp return on i386. To fix both issues, split configure in two pieces
the one before calling ssp_init and the one after, and move the ssp_init()
call back in main. Put ssp_init() in its own file, and compile this new file
with -fno-stack-protector. Tested on amd64.
XXX: If we want to have ssp kernels working on 5.0, this change needs to
be pulled up.
2009-02-12 18:24:18 +00:00
jym
92ae85d18e Changes to MEMORY_RBFLAGS option:
- renamed to MEMORY_DISK_RBFLAGS to better fit the rest of the
MEMORY_DISK options(4)
- change default value to RB_AUTOBOOT instead of RB_SINGLE, and adapt
the config(5) files accordingly
- document this option inside options(4)

See also http://mail-index.netbsd.org/tech-kern/2008/12/25/msg003924.html

Reviewed by abs@ in private mail.
2009-02-06 18:50:26 +00:00
christos
f0adb7fbbb compat_linux needs at least netbsd_16 for sigcontext. 2009-01-18 23:29:33 +00:00
hans
7ff8bbb1b3 Not every grep knows -q. Ok by apb. 2009-01-18 13:53:03 +00:00
he
c2e5f48d9e After the recent time_t and associated changes, COMPAT_ULTRIX now
depends on COMPAT_50.  Make it so.
2009-01-18 13:25:39 +00:00
christos
00a0ee995f fix COMPAT dependency. 2009-01-11 15:55:55 +00:00
christos
461a86f9bd merge christos-time_t 2009-01-11 02:45:45 +00:00
macallan
71a6e25dc4 Last bit of the bwi driver
From Urban Boquist
2009-01-09 19:58:17 +00:00
pooka
167269d42c Include kernel printf routines in rump instead of relying on the
magic libc symbol.  This also allows to bid farewell to subr_prf2.c
and merge the contents back to subr_prf.c.  The host kernel bridging
is now done via rumpuser_putchar().
2009-01-02 02:54:13 +00:00
salo
e47eff8181 MUHAHAHA, FIRST POST!!!!111!1!!ONE!!1
(also, "welcome to 2009 and don't forget to update copyright notices
        when you add new code" and all that stuff)
2009-01-01 00:00:01 +00:00
martin
a1ad1cee58 require newer config(1) for the rootfs changes. 2008-12-21 11:40:48 +00:00
haad
c9d0c62a0c Merge the haad-dm branch to -current. This branch adds LVM functionality to
the base NetBSD system. It uses Linux LVM2 tools and our BSD licensed
device-mapper driver.

The device-mapper driver can be used to create virtual block devices which
maps virtual blocks to real with target mapping called target. Currently
these targets are available a linear, zero, error and a snapshot (this is
work in progress and doesn't work yet).

The lvm2tools adds lvm and dmsetup binary to based system, where the lvm
tool is used to manage and administer whole LVM and the dmestup is used to
communicate iwith device-mapper kernel driver. With these tools also
a libdevmapper library is instaled to the base system.

Building of tools and driver is currently disable and can be enabled with
MKLVM=yes in mk.conf. I will add sets lists and rc.d script soon.

Oked by agc@ and cube@.
2008-12-19 15:24:03 +00:00
alc
1c52cf4c6b Import config(9) file and register HAL's files in the build machinery. 2008-12-11 05:42:18 +00:00
ad
3c9eb3fb0f zfs needs block devices too, for zvol. 2008-12-05 13:06:50 +00:00
ad
92ce8c6a3d Make the emulations, exec formats, coredump, NFS, and the NFS server
into modules. By and large this commit:

- shuffles header files and ifdefs
- splits code out where necessary to be modular
- adds module glue for each of the components
- adds/replaces hooks for things that can be installed at runtime
2008-11-19 18:35:57 +00:00
pooka
9e46e516a7 Move fd_closeexec() and fd_checkstd() from kern_descrip to their
own file, subr_exec_fd.c (they're used only by exec).

After this change, the kernel source modules are in a partitioned
enough state to allow building a system without vfs at all.
2008-11-18 13:01:41 +00:00
pooka
48d146fba6 cwd is logically a vfs concept, so take it out from the bosom of
kern_descrip and into vfs_cwd.  No functional change.
2008-11-18 11:36:58 +00:00
ad
d3d0b437b0 - Conditionalise POSIX aio and mqueue, but include them by default.
- Add a COMPAT_NETBSD attribute. Emit if any compat options are used.
2008-11-14 23:28:30 +00:00
matt
b0aa811639 Sort the kernel objects. 2008-11-13 06:48:38 +00:00
ad
0b7375c9af Allow the POSIX semaphore code to be loaded as a module. 2008-11-12 14:32:34 +00:00
ad
0efea177e3 Remove LKMs and switch to the module framework, pass 1.
Proposed on tech-kern@.
2008-11-12 12:35:50 +00:00