Implemented "nooption" and "nomakeoption" config(8) tokens.
Fixed memory leak in the "nodevice" option implementation. Use these instead of sed(1) in MD NOTES. Use a single makefile (sys/conf/makeLINT.mk) to generate LINT for all architectures. (Previous versions missed the LINT dependency on Makefile, and i386 version also missed the dependency on ${NOTES}.) Fixed bugs in the previous NOTES conversion using the "nodevice" token and sed(1): - i386 LINT lost "device pst". - pc98 LINT lost SC_*, MAXCONS and KBD_DISABLE_KEYMAP_LOAD options, and got needless DPT_* options. - Added nooptions PPC_DEBUG, PPC_PROBE_CHIPSET, KBD_INSTALL_CDEV to sparc64 LINT so that it has a chance to config(8). This basically returns us to where we were before.
This commit is contained in:
parent
3c67516766
commit
824018495d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=111582
@ -1,11 +1,3 @@
|
||||
# $FreeBSD$
|
||||
|
||||
all:
|
||||
@echo "make LINT only"
|
||||
|
||||
clean:
|
||||
rm -f LINT
|
||||
|
||||
NOTES= ../../conf/NOTES NOTES
|
||||
LINT: ${NOTES} ../../conf/makeLINT.sed
|
||||
cat ${NOTES} | sed -E -n -f ../../conf/makeLINT.sed > ${.TARGET}
|
||||
.include "${.CURDIR}/../../conf/makeLINT.mk"
|
||||
|
@ -1,11 +1,3 @@
|
||||
# $FreeBSD$
|
||||
|
||||
all:
|
||||
@echo "make LINT only"
|
||||
|
||||
clean:
|
||||
rm -f LINT
|
||||
|
||||
NOTES= ../../conf/NOTES NOTES
|
||||
LINT: ../../conf/makeLINT.sed
|
||||
cat ${NOTES} | sed -E -n -f ../../conf/makeLINT.sed > ${.TARGET}
|
||||
.include "${.CURDIR}/../../conf/makeLINT.mk"
|
||||
|
11
sys/conf/makeLINT.mk
Normal file
11
sys/conf/makeLINT.mk
Normal file
@ -0,0 +1,11 @@
|
||||
# $FreeBSD$
|
||||
|
||||
all:
|
||||
@echo "make LINT only"
|
||||
|
||||
clean:
|
||||
rm -f LINT
|
||||
|
||||
NOTES= ../../conf/NOTES NOTES
|
||||
LINT: ${NOTES} ../../conf/makeLINT.sed
|
||||
cat ${NOTES} | sed -E -n -f ../../conf/makeLINT.sed > ${.TARGET}
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/sed -E -n -f
|
||||
# $FreeBSD$
|
||||
|
||||
/^(machine|ident|device|nodevice|makeoptions|options|profile|cpu|option|maxusers)[[:space:]]/ {
|
||||
/^(machine|ident|device|nodevice|makeoptions|nomakeoption|options|option|nooption|profile|cpu|maxusers)[[:space:]]/ {
|
||||
s/[[:space:]]*#.*$//
|
||||
p
|
||||
}
|
||||
|
@ -1,11 +1,3 @@
|
||||
# $FreeBSD$
|
||||
|
||||
all:
|
||||
@echo "make LINT only"
|
||||
|
||||
clean:
|
||||
rm -f LINT
|
||||
|
||||
NOTES= ../../conf/NOTES NOTES
|
||||
LINT: ../../conf/makeLINT.sed
|
||||
cat ${NOTES} | sed -E -n -f ../../conf/makeLINT.sed > ${.TARGET}
|
||||
.include "${.CURDIR}/../../conf/makeLINT.mk"
|
||||
|
@ -557,6 +557,11 @@ device pca
|
||||
hint.pca.0.at="isa"
|
||||
hint.pca.0.port="0x040"
|
||||
|
||||
#
|
||||
# ATA raid adapters
|
||||
#
|
||||
device pst
|
||||
|
||||
#
|
||||
# SCSI host adapters:
|
||||
#
|
||||
|
@ -1,42 +1,3 @@
|
||||
# $FreeBSD$
|
||||
|
||||
all:
|
||||
@echo "make LINT only"
|
||||
|
||||
clean:
|
||||
rm -f LINT
|
||||
|
||||
NOTES= ../../conf/NOTES NOTES
|
||||
LINT: ${NOTES} ../../conf/makeLINT.sed
|
||||
cat ${NOTES} | sed -E -n -f ../../conf/makeLINT.sed \
|
||||
| sed -e /VGA_DEBUG/d \
|
||||
-e /SC_RENDER_DEBUG/d \
|
||||
-e /SC_DEBUG_LEVEL/d \
|
||||
-e /SC_NO_SUSPEND_VTYSWITCH/d \
|
||||
-e /SC_NO_SYSMOUSE/d \
|
||||
-e /SC_NO_HISTORY/d \
|
||||
-e /SC_NO_FONT_LOADING/d \
|
||||
-e /SC_NO_CUTPASTE/d \
|
||||
-e /SC_TWOBUTTON_MOUSE/d \
|
||||
-e /SC_CUT_SEPCHARS/d \
|
||||
-e /SC_CUT_SPACES2TABS/d \
|
||||
-e /SC_KERNEL_CONS_REV_ATTR/d \
|
||||
-e /SC_KERNEL_CONS_ATTR/d \
|
||||
-e /SC_NORM_REV_ATTR/d \
|
||||
-e /SC_NORM_ATTR/d \
|
||||
-e /SC_PIXEL_MODE/d \
|
||||
-e /SC_MOUSE_CHAR/d \
|
||||
-e /SC_HISTORY_SIZE/d \
|
||||
-e /SC_DISABLE_REBOOT/d \
|
||||
-e /SC_DISABLE_DDBKEY/d \
|
||||
-e /SC_DFLT_FONT/d \
|
||||
-e /SC_ALT_MOUSE_IMAGE/d \
|
||||
-e /MAXCONS/d \
|
||||
-e /VGA_WIDTH90/d \
|
||||
-e /VGA_SLOW_IOACCESS/d \
|
||||
-e /VGA_ALT_SEQACCESS/d \
|
||||
-e /PSM_RESETAFTERSUSPEND/d \
|
||||
-e /PSM_HOOKRESUME/d \
|
||||
-e /KBD_DISABLE_KEYMAP_LOAD/d \
|
||||
-e /ATKBD_DFLT_KEYMAP/d \
|
||||
> LINT
|
||||
.include "${.CURDIR}/../../conf/makeLINT.mk"
|
||||
|
@ -979,3 +979,25 @@ nodevice twe # 3ware ATA RAID
|
||||
nodevice cbb
|
||||
nodevice pccard
|
||||
nodevice cardbus
|
||||
|
||||
|
||||
#####################################################################
|
||||
# Options we don't want to deal with
|
||||
|
||||
nooption VGA_DEBUG
|
||||
nooption VGA_WIDTH90
|
||||
nooption VGA_SLOW_IOACCESS
|
||||
nooption VGA_ALT_SEQACCESS
|
||||
nooption PSM_RESETAFTERSUSPEND
|
||||
nooption PSM_HOOKRESUME
|
||||
nooption ATKBD_DFLT_KEYMAP
|
||||
nooption DPT_ALLOW_MEMIO
|
||||
nooption DPT_LOST_IRQ
|
||||
nooption DPT_RESET_HBA
|
||||
nooption DPT_TIMEOUT_FACTOR
|
||||
|
||||
|
||||
#####################################################################
|
||||
# Make options we don't want to deal with
|
||||
|
||||
nomakeoption ATKBD_DFLT_KEYMAP
|
||||
|
@ -1,43 +1,3 @@
|
||||
# $FreeBSD$
|
||||
|
||||
all:
|
||||
@echo "make LINT only"
|
||||
|
||||
clean:
|
||||
rm -f LINT
|
||||
|
||||
NOTES= ../../conf/NOTES NOTES
|
||||
LINT: ${NOTES} ../../conf/makeLINT.sed
|
||||
cat ${NOTES} | sed -E -n -f ../../conf/makeLINT.sed \
|
||||
| sed -e /VGA_DEBUG/d \
|
||||
-e /SC_RENDER_DEBUG/d \
|
||||
-e /SC_DEBUG_LEVEL/d \
|
||||
-e /SC_NO_SUSPEND_VTYSWITCH/d \
|
||||
-e /SC_NO_SYSMOUSE/d \
|
||||
-e /SC_NO_HISTORY/d \
|
||||
-e /SC_NO_FONT_LOADING/d \
|
||||
-e /SC_NO_CUTPASTE/d \
|
||||
-e /SC_TWOBUTTON_MOUSE/d \
|
||||
-e /SC_CUT_SEPCHARS/d \
|
||||
-e /SC_CUT_SPACES2TABS/d \
|
||||
-e /SC_KERNEL_CONS_REV_ATTR/d \
|
||||
-e /SC_KERNEL_CONS_ATTR/d \
|
||||
-e /SC_NORM_REV_ATTR/d \
|
||||
-e /SC_NORM_ATTR/d \
|
||||
-e /SC_PIXEL_MODE/d \
|
||||
-e /SC_MOUSE_CHAR/d \
|
||||
-e /SC_HISTORY_SIZE/d \
|
||||
-e /SC_DISABLE_REBOOT/d \
|
||||
-e /SC_DISABLE_DDBKEY/d \
|
||||
-e /SC_DFLT_FONT/d \
|
||||
-e /SC_ALT_MOUSE_IMAGE/d \
|
||||
-e /MAXCONS/d \
|
||||
-e /VGA_WIDTH90/d \
|
||||
-e /VGA_SLOW_IOACCESS/d \
|
||||
-e /VGA_ALT_SEQACCESS/d \
|
||||
-e /PSM_RESETAFTERSUSPEND/d \
|
||||
-e /PSM_HOOKRESUME/d \
|
||||
-e /KBD_DISABLE_KEYMAP_LOAD/d \
|
||||
-e /ATKBD_DFLT_KEYMAP/d \
|
||||
-e /EXT2FS/d \
|
||||
> ${.TARGET}
|
||||
.include "${.CURDIR}/../../conf/makeLINT.mk"
|
||||
|
@ -82,3 +82,49 @@ nodevice bt
|
||||
nodevice wds
|
||||
nodevice ep
|
||||
nodevice ex
|
||||
|
||||
|
||||
#####################################################################
|
||||
# Options we don't want to deal with
|
||||
|
||||
nooption VGA_DEBUG
|
||||
nooption SC_RENDER_DEBUG
|
||||
nooption SC_DEBUG_LEVEL
|
||||
nooption PPC_DEBUG
|
||||
nooption PPC_PROBE_CHIPSET
|
||||
nooption SC_NO_SUSPEND_VTYSWITCH
|
||||
nooption SC_NO_SYSMOUSE
|
||||
nooption SC_NO_HISTORY
|
||||
nooption SC_NO_FONT_LOADING
|
||||
nooption SC_NO_CUTPASTE
|
||||
nooption SC_TWOBUTTON_MOUSE
|
||||
nooption SC_CUT_SEPCHARS
|
||||
nooption SC_CUT_SPACES2TABS
|
||||
nooption SC_KERNEL_CONS_REV_ATTR
|
||||
nooption SC_KERNEL_CONS_ATTR
|
||||
nooption SC_NORM_REV_ATTR
|
||||
nooption SC_NORM_ATTR
|
||||
nooption SC_PIXEL_MODE
|
||||
nooption SC_MOUSE_CHAR
|
||||
nooption SC_HISTORY_SIZE
|
||||
nooption SC_DISABLE_REBOOT
|
||||
nooption SC_DISABLE_DDBKEY
|
||||
nooption SC_DFLT_FONT
|
||||
nooption SC_ALT_MOUSE_IMAGE
|
||||
nooption MAXCONS
|
||||
nooption VGA_WIDTH90
|
||||
nooption VGA_SLOW_IOACCESS
|
||||
nooption VGA_ALT_SEQACCESS
|
||||
nooption PSM_RESETAFTERSUSPEND
|
||||
nooption PSM_HOOKRESUME
|
||||
nooption KBD_INSTALL_CDEV
|
||||
nooption KBD_DISABLE_KEYMAP_LOAD
|
||||
nooption ATKBD_DFLT_KEYMAP
|
||||
nooption EXT2FS
|
||||
|
||||
|
||||
#####################################################################
|
||||
# Make options we don't want to deal with
|
||||
|
||||
nomakeoption SC_DFLT_FONT
|
||||
nomakeoption ATKBD_DFLT_KEYMAP
|
||||
|
@ -9,15 +9,17 @@
|
||||
%token CONFIG
|
||||
%token CPU
|
||||
%token DEVICE
|
||||
%token NODEVICE
|
||||
%token ENV
|
||||
%token EQUALS
|
||||
%token HINTS
|
||||
%token IDENT
|
||||
%token MAXUSERS
|
||||
%token NODEVICE
|
||||
%token PROFILE
|
||||
%token OPTIONS
|
||||
%token NOOPTION
|
||||
%token MAKEOPTIONS
|
||||
%token NOMAKEOPTION
|
||||
%token SEMICOLON
|
||||
%token INCLUDE
|
||||
|
||||
@ -136,8 +138,12 @@ Config_spec:
|
||||
} |
|
||||
OPTIONS Opt_list
|
||||
|
|
||||
NOOPTION Save_id
|
||||
= { rmopt(&opt, $2); } |
|
||||
MAKEOPTIONS Mkopt_list
|
||||
|
|
||||
NOMAKEOPTION Save_id
|
||||
= { rmopt(&mkopt, $2); } |
|
||||
IDENT ID
|
||||
= { ident = $2; } |
|
||||
System_spec
|
||||
@ -248,7 +254,10 @@ Device_spec:
|
||||
} |
|
||||
NODEVICE Dev
|
||||
= {
|
||||
rmopt(&opt, devopt($2));
|
||||
char *s = devopt($2);
|
||||
|
||||
rmopt(&opt, s);
|
||||
free(s);
|
||||
/* and the device part */
|
||||
rmdev($2);
|
||||
} ;
|
||||
|
@ -67,16 +67,18 @@ struct kt {
|
||||
{ "config", CONFIG },
|
||||
{ "cpu", CPU },
|
||||
{ "device", DEVICE },
|
||||
{ "nodevice", NODEVICE },
|
||||
{ "env", ENV },
|
||||
{ "hints", HINTS },
|
||||
{ "ident", IDENT },
|
||||
{ "machine", ARCH }, /* MACHINE is defined in /sys/param.h */
|
||||
{ "makeoptions", MAKEOPTIONS },
|
||||
{ "nomakeoption", NOMAKEOPTION },
|
||||
{ "maxusers", MAXUSERS },
|
||||
{ "nodevice", NODEVICE },
|
||||
{ "profile", PROFILE },
|
||||
{ "option", OPTIONS },
|
||||
{ "options", OPTIONS },
|
||||
{ "nooption", NOOPTION },
|
||||
{ "include", INCLUDE },
|
||||
{ 0, 0 },
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user