commit-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

hurd-l4/laden Makefile.am ia32-shutdown.c laden...


From: Marcus Brinkmann
Subject: hurd-l4/laden Makefile.am ia32-shutdown.c laden...
Date: Sun, 07 Sep 2003 16:56:47 -0400

CVSROOT:        /cvsroot/hurd
Module name:    hurd-l4
Branch:         
Changes by:     Marcus Brinkmann <address@hidden>       03/09/07 16:56:46

Modified files:
        laden          : Makefile.am ia32-shutdown.c laden.c laden.h 
Added files:
        laden          : shutdown.c shutdown.h 

Log message:
        Make things even more modular.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/hurd/hurd-l4/laden/shutdown.c?rev=1.1
http://savannah.gnu.org/cgi-bin/viewcvs/hurd/hurd-l4/laden/shutdown.h?rev=1.1
http://savannah.gnu.org/cgi-bin/viewcvs/hurd/hurd-l4/laden/Makefile.am.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/hurd/hurd-l4/laden/ia32-shutdown.c.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/hurd/hurd-l4/laden/laden.c.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/hurd/hurd-l4/laden/laden.h.diff?tr1=1.3&tr2=1.4&r1=text&r2=text

Patches:
Index: hurd-l4/laden/Makefile.am
diff -u hurd-l4/laden/Makefile.am:1.2 hurd-l4/laden/Makefile.am:1.3
--- hurd-l4/laden/Makefile.am:1.2       Sun Sep  7 16:04:25 2003
+++ hurd-l4/laden/Makefile.am   Sun Sep  7 16:56:46 2003
@@ -20,16 +20,18 @@
 
 if ARCH_IA32
   ARCH_SOURCES = multiboot.h ia32-crt0.S ia32-cmain.c \
-    ia32-output.c ia32-shutdown.c output-vga.c
+    ia32-output.c output-vga.c ia32-shutdown.c
 endif
 
 noinst_PROGRAMS = laden
 
 laden_CFLAGS = -I$(srcdir) $(AM_CFLAGS)
 
-laden_SOURCES =  $(ARCH_SOURCES) elf.h laden.h string.h string.c \
-       output.h output.c output-none.c \
-       laden.c loader.c kip-fixup.c
+laden_SOURCES =  $(ARCH_SOURCES) string.h string.c             \
+       output.h output.c output-none.c                         \
+       shutdown.h shutdown.c                                   \
+       elf.h loader.c                                          \
+       laden.h laden.c kip-fixup.c
 
 /* FIXME: Make linkbase configurable.  */
 laden_LDFLAGS = -u_start -e_start -N -nostdlib -Ttext=0x180000
Index: hurd-l4/laden/ia32-shutdown.c
diff -u hurd-l4/laden/ia32-shutdown.c:1.1 hurd-l4/laden/ia32-shutdown.c:1.2
--- hurd-l4/laden/ia32-shutdown.c:1.1   Sat Jul 26 13:26:09 2003
+++ hurd-l4/laden/ia32-shutdown.c       Sun Sep  7 16:56:46 2003
@@ -20,7 +20,7 @@
 
 #include <sys/io.h>
 
-#include "laden.h"
+#include "shutdown.h"
 
 
 void
Index: hurd-l4/laden/laden.c
diff -u hurd-l4/laden/laden.c:1.2 hurd-l4/laden/laden.c:1.3
--- hurd-l4/laden/laden.c:1.2   Wed Sep  3 21:29:35 2003
+++ hurd-l4/laden/laden.c       Sun Sep  7 16:56:46 2003
@@ -41,34 +41,6 @@
 int debug;
 
 
-/* Reset the machine at failure, instead halting it.  */
-static int shutdown_reset;
-
-
-void
-shutdown (void)
-{
-  if (shutdown_reset)
-    {
-      /* FIXME: Sleep here for a couple of seconds.  */
-      reset ();
-    }
-  else
-    halt ();
-
-  /* Never reached.  */
-  if (shutdown_reset)
-    {
-      printf ("Unable to reset this machine.\n");
-      halt ();
-    }
-
-  printf ("Unable to halt this machine.\n");
-  while (1)
-    ;
-}
-
-
 static void
 parse_args (int argc, char *argv[])
 {
Index: hurd-l4/laden/laden.h
diff -u hurd-l4/laden/laden.h:1.3 hurd-l4/laden/laden.h:1.4
--- hurd-l4/laden/laden.h:1.3   Sun Sep  7 16:04:25 2003
+++ hurd-l4/laden/laden.h       Sun Sep  7 16:56:46 2003
@@ -21,6 +21,7 @@
 #include <l4.h>
 #include "string.h"
 #include "output.h"
+#include "shutdown.h"
 
 
 #define PROGRAM_NAME   "laden"
@@ -68,12 +69,6 @@
 /* Return a help text for this architecture.  */
 const char *help_arch (void);
 
-/* Reset the machine.  */
-void reset (void);
-
-/* Halt the machine.  */
-void halt (void);
-
 /* Load the system's memory descriptors into MEMDESC and return the
    number of memory descriptors loaded.  NR is the maximum number of
    descriptors to be loaded.  */
@@ -82,14 +77,10 @@
 
 /* The generic code defines these functions.  */
 
-/* End the program with a failure.  This can halt or reset the
-   system.  */
-void shutdown (void);
-
 /* Print an error message and fail.  */
 #define panic(...)                             \
   ({                                           \
-    printf ("laden: error: ");                 \
+    printf (PROGRAM_NAME ": error: ");         \
     printf (__VA_ARGS__);                      \
     putchar ('\n');                            \
     shutdown ();                               \




reply via email to

[Prev in Thread] Current Thread [Next in Thread]