Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/config More about attribute -> bus, and child config...
details: https://anonhg.NetBSD.org/src/rev/f7ab7ded886f
branches: trunk
changeset: 337290:f7ab7ded886f
user: uebayasi <uebayasi%NetBSD.org@localhost>
date: Fri Apr 10 03:30:09 2015 +0000
description:
More about attribute -> bus, and child configuration.
diffstat:
usr.bin/config/TODO | 23 +++++++++++++++++++++++
1 files changed, 23 insertions(+), 0 deletions(-)
diffs (33 lines):
diff -r aa752c8fb7ce -r f7ab7ded886f usr.bin/config/TODO
--- a/usr.bin/config/TODO Fri Apr 10 02:03:14 2015 +0000
+++ b/usr.bin/config/TODO Fri Apr 10 03:30:09 2015 +0000
@@ -44,6 +44,29 @@
defbus audiobus {}
attach audio at audiobus
+ Always provide xxxbusprint() (and xxxbussubmatch if multiple children).
+ Extend struct cfiattrdata like:
+
+ struct cfiattrdata {
+ const char *ci_name;
+ cfprint_t ci_print;
+ cfsubmatch_t ci_submatch;
+ int ci_loclen;
+ const struct cflocdesc ci_locdesc[];
+ };
+
+o Simplify child configuration API
+
+ With said struct cfiattrdata extension, config_found*() can omit
+ print/submatch args. If the found child is known (e.g., "pcibus" creating
+ "pci"):
+
+ config_found(self, "xxxbus");
+
+ If finding unknown children (e.g. "pci" finding pci devices):
+
+ config_find(self, "pci", locs, aux);
+
o Retire "attach foo at bar with foo_bar.c"
Most of these should be rewritten by defining a common interface attribute
Home |
Main Index |
Thread Index |
Old Index