Commit Graph

1409 Commits

Author SHA1 Message Date
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