Commit Graph

109 Commits

Author SHA1 Message Date
apb b09e1b8e1d Let "MAKEDEV ptm" create the /dev/pts directory. Requested
in pkgsrc-users by Christian Biere.
2008-07-13 15:22:39 +00:00
hauke f5ede5dc2e Added driver for the Creative Systems Inc. Hurdler CPI parallel printer card.
Timecounter support for the Z8536 counters A + B is not complete, yet.

Reviewed by Martin Husemann.
2008-05-22 19:49:43 +00:00
martin 11a6dbe728 Convert TNF licenses to new 2 clause variant 2008-04-30 13:10:46 +00:00
apb af04b66a89 Remove an extraneous "%" from the end of a line. 2008-04-15 09:53:58 +00:00
apb 0a0e65b2a1 In the nooutput function, use {...} to ensure that shell messages
like "cmd: not found" are also redirected.

This should fix a problem reported by Chavdar Ivanov in which
the message "mtree: not found" appears during installation.
2008-04-15 09:52:41 +00:00
apb b0ec85766d * Fix the problem with pax complaining "file would overwrite itself" for
already-existing device nodes.  This is done by invoking pax with its
  current working directory set to an empty temporary directory.

* Add "-t mtree" command line option, to force MAKEDEV to use "mtree
  -e -U" to create device nodes.  Here are some timings from "MAKEDEV
  ${method} all" on an i386 system; each method was executed three
  times, first in an empty directory, then twice in an already-populated
  directory:

    -m mknod
	    4.56 real         1.58 user         1.68 sys
	    2.96 real         1.37 user         1.48 sys
	    2.95 real         1.43 user         1.44 sys
    -p pax
	    1.80 real         0.18 user         0.62 sys
	    2.35 real         0.25 user         0.80 sys
	    2.38 real         0.24 user         0.82 sys
    -t mtree
	    1.62 real         0.22 user         0.44 sys
	    0.23 real         0.29 user         0.04 sys
	    0.24 real         0.28 user         0.05 sys

* If no command line options force a choice, then prefer mtree, pax, or
  mknod, in that order of preference.

No objections in tech-userlevel to an earlier version of this change.
2008-04-09 20:19:15 +00:00
dyoung d3627477d7 Certain misguided people have complained, NetBSD only runs rare or
"retro" computers, but NetBSD also runs a growing number of rare
and retro add-on cards.  With this patch, NetBSD supports the IDEC
Supervision/16, a black&white image capture board for the 16-bit
ISA bus.  Approximate date of manufacture: 1991.  Total instances
known to be in use throughout the world: one.

Coming soon; isvctl(8), the utility program for capturing 8-bit,
512x480 images at speeds of up to 6 frames per second.
2008-04-02 01:34:36 +00:00
christos 5a9c754ab2 Make makedir code optional for all directories (fd and altq) are affected.
This is so that md code that tries to call makedev altq or fd does not fail
when the file exists. This was reported in port-powerpc, when building /dev.
2008-03-05 02:29:51 +00:00
ad 2ecdf58c2c Remove systrace. Ok core@. 2007-12-31 15:31:24 +00:00
riz ed16d9b321 Create drvctl as part of 'all'. 2007-12-17 04:29:50 +00:00
apb f90ed3540d s/07555/0755/ in permissions of /dev file system. Thanks to
Dieter Roelants for the report.
2007-12-16 16:09:27 +00:00
apb 802860abdb When MAKEDEV creates a memory file system, let it try mount_tmpfs(8)
before falling back to mount_mfs(8).  Also calculate required number
of inodes more accurately.

Discussed in tech-userlevel.
2007-12-15 21:33:13 +00:00
apb beae89cd6d In MAKEDEV.tmpl:
* Add a nooutput function to be used instead of redirecting to /dev/null,
  because /dev/null might not exist early in the boot sequence.  This
  should fix a bug in which the pax autodetection failed when used from
  init(8) with a read-only root file system without a /dev/null.
* Move most of the main program into a new makedev_main function,
  to allow reuse by MAKEDEV.local.

In MAKEDEV.local:
* Use the new makedev_main function defined in MAKEDEV.  This allows
  MAKEDEV.local to support all the options understood by MAKEDEV, instead
  of only a subset.  This should fix a bug in which the setup() function
  could try to use pax mode even though that was previously not supported.

In MAKEDEV.local man page:
* Update list of command line options.
* Don't explain all the options, just refer to MAKEDEV(8) man page.
* Remove BUGS section now that all MAKEDEV options are supported
  by MAKEDEV.local.
2007-12-15 17:28:09 +00:00
apb 280f9669d3 * Move duplicated code into a check_pax function, and improve the test
for whether pax is likely to be usable.
* Don't try to create an mfs with fewer than 10 inodes.
* Add a missing exit in an error case.
2007-12-11 11:51:19 +00:00
apb c1da1584c4 Pass "-pe" flag to pax, otherwise the devices get created with
permissions modified by the umask.
2007-12-11 10:02:24 +00:00
apb 6d3d3ebe02 * MAKEDEV's "-M -M" option was always intended for use only by init(8).
Improve the documentation around that.
* The "-p pax", "-m mknod", and "-s" (mtree specfile) options should
  always have been mutually exclusive.  Now enforce that.
* The "-f" option didn't ever work with pax or mtree mode; document that,
  and make it an error to try something that won't work.
* Make pax mode the default, if no other options prevent this, and if
  "pax -w -M" appears to be usable.
* Add missing options to a usage message.
2007-12-09 08:46:16 +00:00
apb 5e14203889 Update some comments and remove an unnecessary eval. No functional change. 2007-12-08 17:52:34 +00:00
apb 3bc3600ea3 Add a linecount shell function, and use it to count the lines in the
output from MAKEDEV.local.

Fixes PR 37498 from dlagner at rambler.ru, using an idea from David
Laight.  The while loop in the old code is executed in a subshell, so it
can't make persistent modifications to the parent shell's variables.
2007-12-08 17:31:12 +00:00
pooka b305014b90 add /dev/pud 2007-11-20 18:58:46 +00:00
pooka 005e676a62 Create /dev/putter and symlink /dev/puffs to it. 2007-11-13 13:14:25 +00:00
jmcneill a5bfefb1b0 Add support for /dev/padN devices 2007-11-11 17:54:47 +00:00
gdt 0930138fa6 Make cfs (for coda) as part of all, conforming to the documentation
which says that "all" means "all known devices".
2007-11-03 19:33:36 +00:00
ad 18af8ee9bd Add cpuctl(8). For now this is not much more than a toy for debugging and
benchmarking that allows taking CPUs online/offline.
2007-08-04 11:02:56 +00:00
martti 94f749229e Create /dev/bio 2007-05-16 13:06:03 +00:00
dyoung aa85121e03 Make './MAKEDEV local' work as expected, whether we are counting
the number of /dev nodes or not.
2007-03-21 23:07:00 +00:00
dyoung 46abb5c0e8 Remove whitespace from ends of lines. 2007-03-21 03:39:41 +00:00
apb 1f33f6e66f Test whether pax works; if not, fall back to mknod.
This is intended for use on install media that might not have pax.
2007-03-11 16:08:11 +00:00
apb f5b5e05c27 * Add "-p pax" flag, to create all device nodes at once using pax,
instead of one by one using mknod.  This is much faster (speed
  increases of up to 20 times have been observed, but 3 to 5 times is
  more common).
* One "-M" flag will create the mfs file system but not redirect output
  to a temporary console; "-M -M" will also redirect output.
* Change the way we accumulate options to pass to MAKEDEV.local.
2007-03-11 15:52:30 +00:00
dsl b1c0dd5ffc Replace hexprint with a version that is much faster for values > 15.
Since I managed to commit my alternate scheme for zeropad, delete
the commented out lines and replace the only other use.
I've not deleted the function itself though.
2007-03-09 19:16:47 +00:00
dsl 5c2f2286e3 Add a globally applied substitution pattern for the console major number.
Use it when creating a temporary node for the console.
MAKEDEV -M should now output what it is doing.
2007-03-09 13:57:54 +00:00
apb 68723a5b5f Remove MAKEDEV.subr. This removes the risk of third party scripts (or
human procedures) breaking because they assume it's enough to copy
MAKEDEV fom one place to another.

Let MAKEDEV return after defining shell functions but before doing any
real work, if MAKEDEV_AS_LIBRARY is set.

Let MAKEDEV.local load MAKEDEV as a function library via
"MAKEDEV_AS_LIBRARY=1 . MAKEDEV".
2007-03-03 06:36:00 +00:00
dsl 7bb36ad737 Use the correct major number for the temporary console node 2007-03-02 22:44:16 +00:00
dsl 5c38fc826c Add code that can be used by init(1) to request MAKEDEV create a mfs
filesystem and then populate it.
Determine the actual number of inodes that will be needed and add 10%.
Use "mount_mfs -o union" to save us having to copy MADEDEV (in case
anyone wishes to see it.
2007-03-02 21:29:23 +00:00
apb f21f1a9ef9 If we are called as 'sh MAKEDEV ...', then we would previously have
tried to do '. MAKEDEV.subr'.  That doesn't work, we need to do
'. ./MAKEDEV.subr' in that case.
2007-03-01 20:48:26 +00:00
apb 2b64520a8c Avoid using dirname(1), which is not available in installation
ramdisk images.
2007-02-28 19:45:37 +00:00
apb 142606111b Provide a new MAKEDEV.subr file containing utility functions for
use by both MAKEDEV and MAKEDEV.local.  This allows MAKEDEV.local
to accept the same command line arguments as MAKEDEV.

The installed MAKEDEV.subr is generated from MAKEDEV.subr.tmpl.

Replace the licence on MAKEDEV.local with a NetBSD licence, since I
rewrote the entire file.

Reviewed by christos and agc
2007-02-26 20:44:03 +00:00
riz 3ba975dea2 Fix off-by-one error in the creation of dk(4) device nodes. 2007-02-07 03:01:13 +00:00
dyoung df51b53ccc Create /dev/cmos. 2007-02-06 21:27:43 +00:00
hubertf 6a5bb11672 Fix MAKEDEV on shark: Move ses(4) devices from MI code (MAKEDEV.tmpl) to
those platforms that actually have the driver.

See also:
http://mail-index.netbsd.org/tech-userlevel/2007/01/08/0001.html

Fixes PR 26511 properly.

OK'd by wrstuden@
2007-01-15 23:35:11 +00:00
pooka e56cecb8ea create /dev/puffs in 'all' 2007-01-09 15:34:15 +00:00
ad 7334cf17bb Enable /dev/io for COMPAT_FREEBSD. 2006-12-29 19:16:30 +00:00
dyoung 5eaf8c7227 Forward options -f, -m, -s to the MAKEDEV.local script, with the
help of some Bourne-shell magic from David Laight.
2006-12-10 08:14:32 +00:00
pooka c1b5a38fea add puffs device, but I didn't add it to MAKEDEV all on purpose
just quite yet, too experimental
2006-10-22 23:02:08 +00:00
manu 62e38c2a6a Restore twa as major 187, this time with the flag so that it does not get
used in kernels that do not include the driver.
2006-09-24 08:23:36 +00:00
manu 2a6884acfb Back out the twa device:
- if allocated in the MI range, it breaks the builds for ports that do
  not use it
- if allocated in the MD range, 3ware's tw_cli tool will break because it
  hardcodes the major
2006-09-24 03:46:30 +00:00
manu a2d5fc8a9e Add twa device 2006-09-23 22:24:51 +00:00
elad e23e9cfd2a PR/26511: Stephen Borrill: ses devices are not created with MAKEDEV all
Patch applied, thanks!
2006-09-23 20:23:09 +00:00
plunky 4f1cbddc12 update to bluetooth device attachment:
remove pseudo-device btdev(4) and inherent limitations

add bthub(4) which autoconfigures at bluetooth controllers as they
are enabled. bluetooth devices now attach here.

btdevctl(8) and its cache is updated to handle new semantics

etc/rc.d/btdevctl is updated to configure devices from a list
in /etc/bluetooth/btdevctl.conf
2006-09-10 15:45:55 +00:00
ad 44f6463cc4 Add /dev/lockstat. 2006-09-07 01:18:01 +00:00
martin 7699ba8851 Typo 2006-08-13 18:53:31 +00:00