summaryrefslogtreecommitdiffstats
path: root/usr.sbin/config/mkioconf.c
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1998-10-16 15:00:18 +0000
committerbde <bde@FreeBSD.org>1998-10-16 15:00:18 +0000
commit607edc8d5f6ba86346dd9512dfc5ad978509d72c (patch)
tree175715104f54c84c49a6e6b025d24090b687fc4e /usr.sbin/config/mkioconf.c
parentf77a3ee2fecffc4029aecf38ccc4376572147000 (diff)
downloadFreeBSD-src-607edc8d5f6ba86346dd9512dfc5ad978509d72c.zip
FreeBSD-src-607edc8d5f6ba86346dd9512dfc5ad978509d72c.tar.gz
Don't generate unused file ioconf.h.
Didn't bump CONFIGVERS, since ioconf.h was already unused when CONFIGVERS was last bumped (although essentially the same (CAM) commit batch that bumped CONFIGVERS also added bogus includes of ioconf.h).
Diffstat (limited to 'usr.sbin/config/mkioconf.c')
-rw-r--r--usr.sbin/config/mkioconf.c45
1 files changed, 6 insertions, 39 deletions
diff --git a/usr.sbin/config/mkioconf.c b/usr.sbin/config/mkioconf.c
index ea29c2a..e435c39 100644
--- a/usr.sbin/config/mkioconf.c
+++ b/usr.sbin/config/mkioconf.c
@@ -36,7 +36,7 @@
static char sccsid[] = "@(#)mkioconf.c 8.2 (Berkeley) 1/21/94";
#endif
static const char rcsid[] =
- "$Id: mkioconf.c,v 1.41 1998/09/15 10:29:32 gibbs Exp $";
+ "$Id: mkioconf.c,v 1.42 1998/09/16 09:34:07 dfr Exp $";
#endif /* not lint */
#include <err.h>
@@ -52,7 +52,7 @@ char *intv();
char *wnum();
void pseudo_ioconf();
void comp_config __P((FILE *));
-void scbus_devtab __P((FILE *, FILE *, int *));
+void scbus_devtab __P((FILE *, int *));
void isa_devtab __P((FILE *, char *, int *));
void isa_biotab __P((FILE *, char *));
void i386_ioconf __P((void));
@@ -616,7 +616,7 @@ i386_ioconf()
{
register struct device *dp, *mp;
int dev_id;
- FILE *fp, *fp1;
+ FILE *fp;
static char *old_d_name;
int count;
@@ -629,19 +629,8 @@ i386_ioconf()
fprintf(fp, " */\n");
fprintf(fp, "\n");
fprintf(fp, "#include <sys/param.h>\n");
- fprintf(fp, "#include \"ioconf.h\"\n");
fprintf(fp, "\n");
fprintf(fp, "#define C (caddr_t)\n");
- fp1 = fopen(path("ioconf.h.new"), "w");
- if (fp1 == 0)
- err(1, "%s", path("ioconf.h.new"));
- fprintf(fp1, "/*\n");
- fprintf(fp1, " * Extern declarations for I/O configuration.\n");
- fprintf(fp1, " * DO NOT EDIT-- this file is automatically generated.\n");
- fprintf(fp1, " */\n");
- fprintf(fp1, "\n");
- fprintf(fp1, "#ifndef IOCONF_H\n");
- fprintf(fp1, "#define\tIOCONF_H\n");
/*
* First print the isa initialization structures
*/
@@ -694,7 +683,7 @@ i386_ioconf()
isa_devtab(fp, "null", &dev_id);
}
if (seen_scbus)
- scbus_devtab(fp, fp1, &dev_id);
+ scbus_devtab(fp, &dev_id);
fprintf(fp, "\n");
fprintf(fp, "/*\n");
@@ -712,14 +701,8 @@ i386_ioconf()
fprintf(fp, "\n");
fprintf(fp, "int devtab_count = %d;\n", count);
- /* XXX David did this differently!!! */
- /* pseudo_ioconf(fp); */
(void) fclose(fp);
- fprintf(fp1, "\n");
- fprintf(fp1, "#endif /* IOCONF_H */\n");
- (void) fclose(fp1);
moveifchanged(path("ioconf.c.new"), path("ioconf.c"));
- moveifchanged(path("ioconf.h.new"), path("ioconf.h"));
}
void
@@ -822,9 +805,8 @@ static void id_put(fp, unit, s)
* lost and should be put back in.
*/
void
-scbus_devtab(fp, fp1, dev_idp)
+scbus_devtab(fp, dev_idp)
FILE *fp;
- FILE *fp1;
int *dev_idp;
{
register struct device *dp, *mp;
@@ -1245,7 +1227,6 @@ alpha_ioconf()
{
register struct device *dp, *mp;
FILE *fp;
- FILE *fp1;
int dev_id = 10;
int count;
@@ -1254,21 +1235,10 @@ alpha_ioconf()
err(1, "%s", path("ioconf.c"));
fprintf(fp, "#include <sys/types.h>\n");
fprintf(fp, "#include <sys/time.h>\n");
- fprintf(fp, "#include <ioconf.h>\n\n");
fprintf(fp, "#include <sys/queue.h>\n\n");
fprintf(fp, "#include <sys/bus_private.h>\n");
fprintf(fp, "#include <isa/isareg.h>\n\n");
fprintf(fp, "#define C (char *)\n\n");
- fp1 = fopen(path("ioconf.h.new"), "w");
- if (fp1 == 0)
- err(1, "%s", path("ioconf.h.new"));
- fprintf(fp1, "/*\n");
- fprintf(fp1, " * Extern declarations for I/O configuration.\n");
- fprintf(fp1, " * DO NOT EDIT-- this file is automatically generated.\n");
- fprintf(fp1, " */\n");
- fprintf(fp1, "\n");
- fprintf(fp1, "#ifndef IOCONF_H\n");
- fprintf(fp1, "#define\tIOCONF_H\n");
for (dp = dtab; dp != 0; dp = dp->d_next) {
if (dp->d_type != CONTROLLER && dp->d_type != MASTER
@@ -1291,13 +1261,10 @@ alpha_ioconf()
fprintf(fp, "int devtab_count = %d;\n", count);
if (seen_scbus)
- scbus_devtab(fp, fp1, &dev_id);
+ scbus_devtab(fp, &dev_id);
(void) fclose(fp);
- fprintf(fp1, "#endif\n");
- (void) fclose(fp1);
moveifchanged(path("ioconf.c.new"), path("ioconf.c"));
- moveifchanged(path("ioconf.h.new"), path("ioconf.h"));
}
#endif
OpenPOWER on IntegriCloud