From owner-acpi-jp@jp.freebsd.org  Wed Jun  7 00:42:26 2000
Received: (from daemon@localhost)
	by castle.jp.freebsd.org (8.9.3+3.2W/8.7.3) id AAA37720;
	Wed, 7 Jun 2000 00:42:26 +0900 (JST)
	(envelope-from owner-acpi-jp@jp.FreeBSD.org)
Received: from tasogare.imasy.or.jp (daemon@tasogare.imasy.or.jp [202.227.24.5])
	by castle.jp.freebsd.org (8.9.3+3.2W/8.7.3) with ESMTP id AAA37715
	for <acpi-jp@jp.freebsd.org>; Wed, 7 Jun 2000 00:42:23 +0900 (JST)
	(envelope-from iwasaki@jp.FreeBSD.org)
Received: from localhost (isdnb43.imasy.or.jp [202.227.24.171])
	by tasogare.imasy.or.jp (8.10.1+3.3W/3.7W-tasogare/smtpfeed 1.04) with ESMTP id e56FgJP98912
	for <acpi-jp@jp.freebsd.org>; Wed, 7 Jun 2000 00:42:19 +0900 (JST)
	(envelope-from iwasaki@jp.FreeBSD.org)
To: acpi-jp@jp.freebsd.org
X-Mailer: Mew version 1.94.1 on Emacs 19.34 / Mule 2.3 (SUETSUMUHANA)
Mime-Version: 1.0
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-Id: <20000607004216S.iwasaki@jp.FreeBSD.org>
Date: Wed, 07 Jun 2000 00:42:16 +0900
From: Mitsuru IWASAKI <iwasaki@jp.freebsd.org>
X-Dispatcher: imput version 20000228(IM140)
Lines: 137
Reply-To: acpi-jp@jp.freebsd.org
Precedence: list
X-Distribute: distribute version 2.1 (Alpha) patchlevel 24e+000315
X-Sequence: acpi-jp 389
Subject: [acpi-jp 389] style fix: amldb/amldb.c
Errors-To: owner-acpi-jp@jp.freebsd.org
Sender: owner-acpi-jp@jp.freebsd.org
X-Originator: iwasaki@jp.freebsd.org

Index: amldb/amldb.c
===================================================================
RCS file: /home/cvs/ACPI/usr.sbin/acpi/amldb/amldb.c,v
retrieving revision 1.3
diff -u -r1.3 amldb.c
--- amldb/amldb.c	2000/06/03 16:45:25	1.3
+++ amldb/amldb.c	2000/06/06 14:24:51
@@ -26,14 +26,9 @@
  *	$Id: amldb.c,v 1.3 2000/06/03 16:45:25 iwasaki Exp $
  */
 
-#include <assert.h>
-#include <err.h>
-#include <fcntl.h>
-#include <stdio.h>
-#include <string.h>
+#include <sys/param.h>
 #include <sys/mman.h>
 #include <sys/stat.h>
-#include <unistd.h>
 
 #include <i386/acpi/aml/aml_amlmem.h>
 #include <i386/acpi/aml/aml_common.h>
@@ -41,6 +36,13 @@
 #include <i386/acpi/aml/aml_parse.h>
 #include <i386/acpi/aml/aml_region.h>
 
+#include <assert.h>
+#include <err.h>
+#include <fcntl.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+
 #include "debug.h"
 
 int	regdump_enabled = 0;
@@ -52,8 +54,8 @@
 void
 acpi_init_namespace()
 {
-	struct aml_environ env;
-	struct aml_name *newname;
+	struct	aml_environ env;
+	struct	aml_name *newname;
 
 	new_aml_name_group(AML_NAME_GROUP_OS_DEFINED);
 	env.curname = get_rootname();
@@ -86,7 +88,6 @@
 		perror("mmap");
 		exit(-1);
 	}
-
 	acpi_init_namespace();
 
 	new_aml_name_group((int)code);
@@ -114,9 +115,8 @@
 	if (showtree_enabled == 1) {
 		showtree(env.curname, 0);
 	}
-
 	do {
-		acpi_dbgr(&env,&env);
+		acpi_dbgr(&env, &env);
 	} while (env.stat != aml_stat_panic);
 
 	aml_debug = 0;		/* debug print disabled */
@@ -124,7 +124,6 @@
 	if (regdump_enabled == 1) {
 		acpi_simulation_regdump("region.dmp");
 	}
-
 	while (name_group_list->id != AML_NAME_GROUP_ROOT) {
 		delete_aml_name_group(name_group_list);
 	}
@@ -132,15 +131,15 @@
 	if (memstat_enabled == 1) {
 		memman_statistics(aml_memman);
 	}
-
 	memman_freeall(aml_memman);
 
-	return 0;
+	return (0);
 }
 
 static void
 usage(const char *progname)
 {
+
 	printf("usage: %s [-d] [-s] [-t] [-h] dsdt_files...\n", progname);
 	exit(1);
 }
@@ -148,27 +147,25 @@
 int
 main(int argc, char *argv[])
 {
+	char	c, *progname;
 	int	i;
-	char	c, *progname = argv[0];
 
+	progname = argv[0];
 	while ((c = getopt(argc, argv, "dsth")) != -1) {
 		switch (c) {
 		case 'd':
 			regdump_enabled = 1;
 			break;
-
 		case 's':
 			memstat_enabled = 1;
 			break;
-
 		case 't':
 			showtree_enabled = 1;
 			break;
-
 		case 'h':
 		default:
 			usage(progname);
-			break;
+			/* NOTREACHED */
 		}
 	}
 	argc -= optind;
@@ -177,11 +174,9 @@
 	if (argc == 0) {
 		usage(progname);
 	}
-
 	for (i = 0; i < argc; i++) {
 		load_dsdt(argv[i]);
 	}
 
-	return 0;
+	return (0);
 }
-
