diff options
author | peter <peter@FreeBSD.org> | 2000-06-17 20:10:55 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2000-06-17 20:10:55 +0000 |
commit | 61ad2eac9353a287b30eeb88e3267a7180ce7b8c (patch) | |
tree | 844d725855e8ec8b325a214fccd70c88f333abbc /sys/pc98 | |
parent | c953542e84761c80ca9074f2bd55cbc3772ce58b (diff) | |
download | FreeBSD-src-61ad2eac9353a287b30eeb88e3267a7180ce7b8c.zip FreeBSD-src-61ad2eac9353a287b30eeb88e3267a7180ce7b8c.tar.gz |
Deal with quoted arguments. This hack parser uses whitespace to delimit
fields, not lex/yacc grammar so it is not an exact match but should be
close enough for most cases.
Deal with 'port?', 'irq?' style specifications. These are parsed as
seperate values in lex/yacc in config(8) but tripped up this helper tool.
Diffstat (limited to 'sys/pc98')
-rw-r--r-- | sys/pc98/conf/gethints.pl | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/pc98/conf/gethints.pl b/sys/pc98/conf/gethints.pl index 1a90029..b385ed0 100644 --- a/sys/pc98/conf/gethints.pl +++ b/sys/pc98/conf/gethints.pl @@ -12,6 +12,7 @@ while (<>) { chop; s/#.*//; next unless /^device/; + s/"//g; ($dev, $nameunit, $at, $where, @rest) = split; next unless $at eq "at" && $where ne ""; $name = $nameunit; @@ -71,6 +72,10 @@ while (<>) { } next; } + if ($key eq "port?" || $key eq "drq?" || $key eq "irq?" || + $key eq "iomem?" || $key eq "iosiz?") { + next; + } if ($key eq "irq" || $key eq "drq" || $key eq "drive" || $key eq "iomem" || $key eq "iosiz" || $key eq "flags"|| $key eq "bus" || $key eq "target" || $key eq "unit") { |