Commit Graph

10 Commits

Author SHA1 Message Date
dholland f5d4142b2d Move locator lists to their own data structure. This can use more tidying;
it is not clear to me at the moment what the "string" and "num" values
pushed around in locator lists are supposed to actually mean.
2012-03-11 21:16:07 +00:00
dholland a551c5e8b7 Create a struct condexpr type to hold condition expressions, instead
of abusing struct nvlist to make trees.

(These are the a|b and a&b constructs.)
2012-03-11 08:21:53 +00:00
dholland bbe96a5ad8 Create a new type struct attrlist to manage lists of attributes,
instead of using struct nvlist.

(struct nvlist holds lists (or trees!) of semi-arbitrary stuff with no
structure and almost no type safety; it should go away.)
2012-03-11 07:32:41 +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 90ac64de16 Add a highly experimental pseudo-root feature to be used in conjuction
with the also-experimental ioconf keyword.  pseudo-root allows to
specify a root at any point in the device tree without having
attachments from the actual root.

For example, instead of having a config file like this:
mainbus0 at root
bus_a? at mainbus0
bus_b? at bus_a*
device7 at bus_b?

You can have one like this:
pseudo-root bus_b*
device7 at bus_b?

This will produce the relevant ioconf.c glue for device number 7
only instead of the whole 9 yards from root.  Perhaps needless to
say, this can be used to generate snippets of config glue for
modules and, let's not deny that my main motivation for doing this,
rump components.

This is part 2/3 of my modifications to config (the last part is
autogenerating source file lists and component Makefiles).

No strong objection from cube (after a little pressuring ;), but
like he said, the implementation will most likely need some more
tweaking and may not work correctly under all pseudo-root uses yet.
2010-03-08 10:19:14 +00:00
cube 42b52b8a61 Add 'no config <name>'. 2006-02-11 20:15:53 +00:00
cube 437f8925a6 Introduce versioning to config(1). This will allow us to provide a way to
error out in a bit more friendly way when the user is trying to use
config(1) on a too old or too recent source tree.

To achieve that, introduce the "version NUMBER" statement which can be use
about anywhere in the config files.  Also, use two defines, CONFIG_VERSION
(which is the actual version of binary), and CONFIG_MINVERSION, which is
the minimum version the binary supports.

Allowing a range of versions serves several purposes:  first it allows me
to introduce the versioning without requiring it to be used right away in
the kernel tree, which means it will be possible to introduce new features
of config(1) rather progressively in the future.  E.g., using 'no pci' in
a config file could only require the new version in that config file, so
that the rest remains compatible.

In the end, an actual bump of the main config system (i.e., in conf/files)
will only be required when e.g., ioconf.c semantics change.

(Mostly-)silently accepted on tech-kern.  Error messages turned into
correct and meaningful English thanks to Tracy and Perry.
2005-10-12 01:17:43 +00:00
cube 7aa6070d4e o Keep track of negated devices in deaddevitab
o  Rework do_kill_orphans() to use that information and mark explicitely
   orphaned devices (i.e., the ones whose missing ancestor has been
   negated)
o  Make a distinction between erroneous orphans and explicit orphans.
   Error out on the former, ignore the later (but print a warning when -v
   is used)

Yes, now config(1) will actually stop if you comment out a parent.  That
should help people still hoping adjustkernel is relevant these days :)
2005-10-01 23:30:37 +00:00
cube 7b7c582a4f Introduce two new statements:
no device at <attachment>

     <attachment> can take two forms:  either numbered/wildcarded, in which
     case only exactly matching instances will be removed, or plain (with
     no number or wildcard), in which case all matching instances will be
     removed.

     When <attachment> is a plain interface attribute, all instances using
     that attribute (either directly or through an explicit device) will be
     removed.

     E.g.:
             auich* at pci? dev ? function ?
             audio0 at audiobus?
             audio1 at auich?
             audio* at auich0

             no device at auich0     -> removes audio*
             no device at auich?     -> removes audio1
             no device at auich      -> removes audio1 _and_ audio*
             no device at audiobus?  -> removes audio0
             no device at audiobus   -> removes audio0, audio1 and audio*

  no <device>

     As in the previous case, <device> can either be numbered/starred, in
     which case all exactly matching instances are removed, or plain, in
     which case all instances of the device are removed.

    E.g.: (continuing previous example)

             no audio* -> removes 'audio* at auich0'
             no audio  -> removes all audio instances
2005-09-30 22:51:46 +00:00
thorpej 5ecc953bdb config and genassym are not sysadmin tools, they are development tools.
As such, they don't belong in /usr/sbin, but rather /usr/bin.  Move them
there.
2005-06-05 18:19:52 +00:00