]> git.ozlabs.org Git - yaboot.git/blobdiff - second/prom.c
Pretend to allocate/deallocate memory correctly
[yaboot.git] / second / prom.c
index c89182ca83b5b98f31368d9bb750fb37089b9572..25811ea30d146fb30aadff54c2acd0876c780021 100644 (file)
@@ -1,25 +1,27 @@
 /*
-    Routines for talking to the Open Firmware PROM on
-    Power Macintosh computers.
-    Copyright (C) 1999 Benjamin Herrenschmidt
-    Copyright (C) 1999 Marius Vollmer
-    Copyright (C) 1996 Paul Mackerras.
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
-
+ *  prom.c - Routines for talking to the Open Firmware PROM
+ *
+ *  Copyright (C) 2001, 2002 Ethan Benson
+ *
+ *  Copyright (C) 1999 Benjamin Herrenschmidt
+ *
+ *  Copyright (C) 1999 Marius Vollmer
+ *
+ *  Copyright (C) 1996 Paul Mackerras.
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
  */
 
 #include "prom.h"
@@ -551,7 +553,9 @@ prom_claim (void *virt, unsigned int size, unsigned int align)
 void
 prom_release(void *virt, unsigned int size)
 {
-//  call_prom ("release", 2, 1, virt, size);
+     call_prom ("release", 2, 0, virt, size);
+#if 0 /* this is bullshit, newworld OF RELEASE method works fine. */
+
      /* release in not enough, it needs also an unmap call. This bit of forth
       * code inspired from Darwin's bootloader but could be replaced by direct
       * calls to the MMU package if needed
@@ -568,6 +572,7 @@ prom_release(void *virt, unsigned int size)
                "\" release\" ^mem "                    // Then free the physical pages
                ,size, virt 
          );
+#endif /* bullshit */
 }
 
 void