OpenBIOS
Threads by month
- ----- 2025 -----
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2003 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2002 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2001 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2000 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1999 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1998 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1997 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1996 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1995 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1994 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1993 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1992 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1991 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1990 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1989 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1988 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1987 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1986 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1985 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1984 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1983 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1982 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1981 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1980 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1979 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1978 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1977 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1976 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1975 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1974 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1973 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1972 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1971 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1970 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1969 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1968 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1967 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1966 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1965 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1964 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1963 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1962 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1961 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1960 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1959 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1958 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1957 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1956 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1955 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1954 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1953 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1952 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1951 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1950 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1949 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1948 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1947 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1946 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1945 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1944 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1943 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1942 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1941 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1940 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1939 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1938 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1937 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1936 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1935 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1934 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1933 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1932 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1931 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1930 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1929 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1928 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1927 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1926 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1925 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1924 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1923 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1922 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1921 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1920 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1919 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1918 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1917 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1916 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1915 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1914 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1913 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1912 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1911 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1910 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1909 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1908 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1907 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1906 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1905 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 1904 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
August 2009
- 14 participants
- 81 discussions
Author: blueswirl
Date: 2009-08-04 22:37:36 +0200 (Tue, 04 Aug 2009)
New Revision: 536
Modified:
trunk/openbios-devel/arch/sparc64/boot.h
trunk/openbios-devel/arch/sparc64/sys_info.c
Log:
Fix most Sparc64 warnings from Sparse
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Modified: trunk/openbios-devel/arch/sparc64/boot.h
===================================================================
--- trunk/openbios-devel/arch/sparc64/boot.h 2009-08-04 20:37:34 UTC (rev 535)
+++ trunk/openbios-devel/arch/sparc64/boot.h 2009-08-04 20:37:36 UTC (rev 536)
@@ -36,7 +36,7 @@
void boot(void);
// sys_info.c
-extern unsigned int qemu_mem_size;
+extern uint64_t qemu_mem_size;
// console.c
void ob_su_init(uint64_t base, uint64_t offset, int intr);
Modified: trunk/openbios-devel/arch/sparc64/sys_info.c
===================================================================
--- trunk/openbios-devel/arch/sparc64/sys_info.c 2009-08-04 20:37:34 UTC (rev 535)
+++ trunk/openbios-devel/arch/sparc64/sys_info.c 2009-08-04 20:37:36 UTC (rev 536)
@@ -3,6 +3,7 @@
#include "elf_boot.h"
#include "sys_info.h"
#include "context.h"
+#include "boot.h"
#define printf printk
#ifdef CONFIG_DEBUG_BOOT
1
0
Author: blueswirl
Date: 2009-08-04 22:37:34 +0200 (Tue, 04 Aug 2009)
New Revision: 535
Modified:
trunk/openbios-devel/arch/unix/unix.c
trunk/openbios-devel/libgcc/libgcc.h
Log:
Fix Unix target warnings from Sparse
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Modified: trunk/openbios-devel/arch/unix/unix.c
===================================================================
--- trunk/openbios-devel/arch/unix/unix.c 2009-08-04 20:37:32 UTC (rev 534)
+++ trunk/openbios-devel/arch/unix/unix.c 2009-08-04 20:37:34 UTC (rev 535)
@@ -52,13 +52,12 @@
/* local variables */
-ucell *latest, *state;
-ucell *memory;
+static ucell *memory;
-int diskemu;
+static int diskemu;
static int segfault = 0;
-int verbose = 0;
+static int verbose = 0;
#ifdef CONFIG_PPC
uint32_t isa_io_base;
@@ -477,7 +476,7 @@
sa.sa_sigaction = segv_handler;
sigemptyset(&sa.sa_mask);
sa.sa_flags = SA_SIGINFO | SA_NODEFER;
- sigaction(SIGSEGV, &sa, 0);
+ sigaction(SIGSEGV, &sa, NULL);
if (verbose)
printk("done.\n");
@@ -492,7 +491,7 @@
sa.sa_sigaction = int_handler;
sigemptyset(&sa.sa_mask);
sa.sa_flags = SA_SIGINFO | SA_NODEFER;
- sigaction(SIGINT, &sa, 0);
+ sigaction(SIGINT, &sa, NULL);
if (verbose)
printk("done.\n");
Modified: trunk/openbios-devel/libgcc/libgcc.h
===================================================================
--- trunk/openbios-devel/libgcc/libgcc.h 2009-08-04 20:37:32 UTC (rev 534)
+++ trunk/openbios-devel/libgcc/libgcc.h 2009-08-04 20:37:34 UTC (rev 535)
@@ -27,7 +27,7 @@
// Must be implemented outside:
void __divide_error(void);
-#ifdef __arch64__
+#if defined(__arch64__) || defined(__LP64__)
typedef int TItype __attribute__ ((mode (TI)));
__uint128_t __udivmodti4(__uint128_t num, __uint128_t den, __uint128_t *rem);
1
0
Author: blueswirl
Date: 2009-08-04 22:37:32 +0200 (Tue, 04 Aug 2009)
New Revision: 534
Modified:
trunk/openbios-devel/arch/x86/boot.h
trunk/openbios-devel/arch/x86/context.c
trunk/openbios-devel/arch/x86/elfload.c
trunk/openbios-devel/arch/x86/linux_load.c
trunk/openbios-devel/arch/x86/multiboot.c
Log:
Fix most x86 warnings from Sparse
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Modified: trunk/openbios-devel/arch/x86/boot.h
===================================================================
--- trunk/openbios-devel/arch/x86/boot.h 2009-08-02 18:20:53 UTC (rev 533)
+++ trunk/openbios-devel/arch/x86/boot.h 2009-08-04 20:37:32 UTC (rev 534)
@@ -6,9 +6,19 @@
* the copyright and warranty status of this work.
*/
+/* forthload.c */
int forth_load(struct sys_info *info, const char *filename, const char *cmdline);
+
+/* elfload.c */
int elf_load(struct sys_info *info, const char *filename, const char *cmdline);
+
+/* linux_load.c */
int linux_load(struct sys_info *info, const char *file, const char *cmdline);
+/* context.c */
+extern struct context *__context;
unsigned int start_elf(unsigned long entry_point, unsigned long param);
+
+/* boot.c */
+extern struct sys_info sys_info;
void boot(void);
Modified: trunk/openbios-devel/arch/x86/context.c
===================================================================
--- trunk/openbios-devel/arch/x86/context.c 2009-08-02 18:20:53 UTC (rev 533)
+++ trunk/openbios-devel/arch/x86/context.c 2009-08-04 20:37:32 UTC (rev 534)
@@ -26,7 +26,7 @@
* It is placed at the bottom of our stack, and loaded by assembly routine
* to start us up.
*/
-struct context main_ctx __attribute__((section (".initctx"))) = {
+static struct context main_ctx __attribute__((section (".initctx"))) = {
.gdt_base = (uint32_t) gdt,
.gdt_limit = GDT_LIMIT,
.cs = FLAT_CS,
Modified: trunk/openbios-devel/arch/x86/elfload.c
===================================================================
--- trunk/openbios-devel/arch/x86/elfload.c 2009-08-02 18:20:53 UTC (rev 533)
+++ trunk/openbios-devel/arch/x86/elfload.c 2009-08-04 20:37:32 UTC (rev 534)
@@ -30,7 +30,7 @@
if (alloc_size < nmemb || alloc_size < size) {
printk("calloc overflow: %u, %u\n", nmemb, size);
- return 0;
+ return NULL;
}
mem = malloc(alloc_size);
@@ -314,7 +314,7 @@
int retval = -1;
int image_retval;
- image_name = image_version = 0;
+ image_name = image_version = NULL;
if (!file_open(filename))
goto out;
Modified: trunk/openbios-devel/arch/x86/linux_load.c
===================================================================
--- trunk/openbios-devel/arch/x86/linux_load.c 2009-08-02 18:20:53 UTC (rev 533)
+++ trunk/openbios-devel/arch/x86/linux_load.c 2009-08-04 20:37:32 UTC (rev 534)
@@ -157,7 +157,7 @@
uint8_t reserved17[1792]; /* 0x900 - 0x1000 */
};
-uint64_t forced_memsize;
+static uint64_t forced_memsize;
/* Load the first part the file and check if it's Linux */
static uint32_t load_linux_header(struct linux_header *hdr)
@@ -294,14 +294,14 @@
int len;
int k_len;
int to_kern;
- char *initrd = 0;
+ char *initrd = NULL;
int toolong = 0;
forced_memsize = 0;
if (!orig_cmdline) {
*kern_cmdline = 0;
- return 0;
+ return NULL;
}
k_len = 0;
@@ -328,7 +328,7 @@
val = sep + 1;
len = end - val;
} else {
- val = 0;
+ val = NULL;
len = 0;
}
@@ -610,7 +610,7 @@
struct linux_header hdr;
struct linux_params *params;
uint32_t kern_addr, kern_size;
- char *initrd_file = 0;
+ char *initrd_file = NULL;
if (!file_open(file))
return -1;
Modified: trunk/openbios-devel/arch/x86/multiboot.c
===================================================================
--- trunk/openbios-devel/arch/x86/multiboot.c 2009-08-02 18:20:53 UTC (rev 533)
+++ trunk/openbios-devel/arch/x86/multiboot.c 2009-08-04 20:37:32 UTC (rev 534)
@@ -14,7 +14,8 @@
struct mbheader {
unsigned int magic, flags, checksum;
};
-const struct mbheader multiboot_header
+
+static const struct mbheader multiboot_header
__attribute__((section (".hdr"))) =
{
MULTIBOOT_HEADER_MAGIC,
1
0
Hi!
This patch series moves OF memory manager code to separate module. New OFMEM module is used by sparc64 and all ppc configurations.
Since ppc briq/mol/pearpc are not buildable for years I used local build hack to verify this change does not make those even worse.
Boot-tested on sparc64 and ppc/qemu.
Changes v0->v1:
- clean up ppc internal prototypes patch (whitespace)
- split ofmem migration patch to smaller ppc and sparc patches
Signed-off-by: igor.v.kovalenko(a)gmail.com
--
Kind regards,
Igor V. Kovalenko
3
14

r533 - in trunk/openbios-devel: . arch/ppc/briq arch/ppc/mol arch/ppc/pearpc arch/ppc/qemu arch/unix config/scripts include include/openbios kernel modules
by svn@openbios.org Aug. 2, 2009
by svn@openbios.org Aug. 2, 2009
Aug. 2, 2009
Author: blueswirl
Date: 2009-08-02 20:20:53 +0200 (Sun, 02 Aug 2009)
New Revision: 533
Added:
trunk/openbios-devel/VERSION
Modified:
trunk/openbios-devel/Makefile.target
trunk/openbios-devel/arch/ppc/briq/init.c
trunk/openbios-devel/arch/ppc/mol/init.c
trunk/openbios-devel/arch/ppc/pearpc/init.c
trunk/openbios-devel/arch/ppc/qemu/init.c
trunk/openbios-devel/arch/unix/unix.c
trunk/openbios-devel/config/scripts/switch-arch
trunk/openbios-devel/include/mconfig.h
trunk/openbios-devel/include/openbios/config.h
trunk/openbios-devel/kernel/bootstrap.c
trunk/openbios-devel/modules/elfnote.c
Log:
Improve version number handling
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Modified: trunk/openbios-devel/Makefile.target
===================================================================
--- trunk/openbios-devel/Makefile.target 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/Makefile.target 2009-08-02 18:20:53 UTC (rev 533)
@@ -38,8 +38,6 @@
all: versions dictionaries host-libraries target-libraries host-executables target-executables
-VERSION := "1.0"
-
versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
$(ODIR)/forth/version.fs:
@@ -51,8 +49,7 @@
$(ODIR)/target/include/openbios-version.h:
@DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
+ echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; ) \
> $(dir $(a))/openbios-version.h
info:
Added: trunk/openbios-devel/VERSION
===================================================================
--- trunk/openbios-devel/VERSION (rev 0)
+++ trunk/openbios-devel/VERSION 2009-08-02 18:20:53 UTC (rev 533)
@@ -0,0 +1 @@
+1.0
Modified: trunk/openbios-devel/arch/ppc/briq/init.c
===================================================================
--- trunk/openbios-devel/arch/ppc/briq/init.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/arch/ppc/briq/init.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -61,7 +61,8 @@
printk("\n");
printk("=============================================================\n");
- printk("OpenBIOS %s [%s]\n", OPENBIOS_RELEASE, OPENBIOS_BUILD_DATE );
+ printk(PROGRAM_NAME " " OPENBIOS_VERSION_STR " [%s]\n",
+ OPENBIOS_BUILD_DATE);
ofmem_init();
initialize_forth();
Modified: trunk/openbios-devel/arch/ppc/mol/init.c
===================================================================
--- trunk/openbios-devel/arch/ppc/mol/init.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/arch/ppc/mol/init.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -57,7 +57,8 @@
printk("\n");
printk("=============================================================\n");
- printk("OpenBIOS %s [%s]\n", OPENBIOS_RELEASE, OPENBIOS_BUILD_DATE );
+ printk(PROGRAM_NAME " " OPENBIOS_VERSION_STR " [%s]\n",
+ OPENBIOS_BUILD_DATE);
ofmem_init();
initialize_forth();
Modified: trunk/openbios-devel/arch/ppc/pearpc/init.c
===================================================================
--- trunk/openbios-devel/arch/ppc/pearpc/init.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/arch/ppc/pearpc/init.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -64,7 +64,8 @@
printk("\n");
printk("=============================================================\n");
- printk("OpenBIOS %s [%s]\n", OPENBIOS_RELEASE, OPENBIOS_BUILD_DATE );
+ printk(PROGRAM_NAME " " OPENBIOS_VERSION_STR " [%s]\n",
+ OPENBIOS_BUILD_DATE);
ofmem_init();
initialize_forth();
Modified: trunk/openbios-devel/arch/ppc/qemu/init.c
===================================================================
--- trunk/openbios-devel/arch/ppc/qemu/init.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/arch/ppc/qemu/init.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -461,7 +461,8 @@
printk("\n");
printk("=============================================================\n");
- printk("OpenBIOS %s [%s]\n", OPENBIOS_RELEASE, OPENBIOS_BUILD_DATE );
+ printk(PROGRAM_NAME " " OPENBIOS_VERSION_STR " [%s]\n",
+ OPENBIOS_BUILD_DATE);
fw_cfg_read(FW_CFG_SIGNATURE, buf, 4);
buf[4] = '\0';
Modified: trunk/openbios-devel/arch/unix/unix.c
===================================================================
--- trunk/openbios-devel/arch/unix/unix.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/arch/unix/unix.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -32,6 +32,7 @@
#include "openbios/stack.h"
#include "unix/plugins.h"
#include "openbios/bindings.h"
+#include "openbios-version.h"
#include "blk.h"
@@ -415,11 +416,12 @@
switch (c) {
case 'V':
- printk(BANNER "Version " VERSION "\n");
+ printk(BANNER "Version " OPENBIOS_VERSION_STR "\n");
return 0;
case 'h':
case '?':
- printk(BANNER "Version " VERSION "\n" USAGE, argv[0]);
+ printk(BANNER "Version " OPENBIOS_VERSION_STR "\n"
+ USAGE, argv[0]);
return 0;
case 'v':
verbose = 1;
Modified: trunk/openbios-devel/config/scripts/switch-arch
===================================================================
--- trunk/openbios-devel/config/scripts/switch-arch 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/config/scripts/switch-arch 2009-08-02 18:20:53 UTC (rev 533)
@@ -93,6 +93,8 @@
archname
fi
+VERSION=`head VERSION`
+
echo "Configuring OpenBIOS on $HOSTARCH for $*"
for RULES_ARCH in $*; do
ARCH=`echo $RULES_ARCH | sed s/cross-//g`
@@ -173,6 +175,7 @@
echo "AS_FLAGS=$AS_FLAGS" >> $ODIR/config.mak
echo "HOSTARCH?=$HOSTARCH" >> $ODIR/config.mak
echo "CROSSCFLAGS=$CROSSCFLAGS" >> $ODIR/config.mak
+ echo "VERSION=\"$VERSION\"" >> $ODIR/config.mak
ln -s $SRCDIR/config/xml/rules.xml $ODIR/rules.xml
ln -s $SRCDIR/config/examples/${RULES_ARCH}_config.xml $ODIR/config.xml
ln -s ../Makefile.target $ODIR/Makefile
Modified: trunk/openbios-devel/include/mconfig.h
===================================================================
--- trunk/openbios-devel/include/mconfig.h 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/include/mconfig.h 2009-08-02 18:20:53 UTC (rev 533)
@@ -41,9 +41,6 @@
/* Define to 1 if you have the <unistd.h> header file. */
#define HAVE_UNISTD_H 1
-/* Minor OpenBIOS version */
-#define MINOR_VERSION 0
-
/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT ""
@@ -59,15 +56,9 @@
/* Define to the version of this package. */
#define PACKAGE_VERSION ""
-/* Patchlevel */
-#define PATCH_LEVEL RC1
-
/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1
-/* Version */
-#define VERSION "1.0"
-
/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
`char[]'. */
#define YYTEXT_POINTER 1
Modified: trunk/openbios-devel/include/openbios/config.h
===================================================================
--- trunk/openbios-devel/include/openbios/config.h 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/include/openbios/config.h 2009-08-02 18:20:53 UTC (rev 533)
@@ -22,7 +22,6 @@
#include "asm/types.h"
#define PROGRAM_NAME "OpenBIOS"
-#define PROGRAM_VERSION VERSION
#ifndef BOOTSTRAP
Modified: trunk/openbios-devel/kernel/bootstrap.c
===================================================================
--- trunk/openbios-devel/kernel/bootstrap.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/kernel/bootstrap.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -27,6 +27,7 @@
#include "openbios/kernel.h"
#include "dict.h"
#include "cross.h"
+#include "openbios-version.h"
#define MEMORY_SIZE (1024*1024) /* 1M ram for hosted system */
@@ -992,11 +993,12 @@
switch (c) {
case 'V':
- printk("Version " VERSION "\n");
+ printk("Version " OPENBIOS_VERSION_STR "\n");
return 0;
case 'h':
case '?':
- printk("Version " VERSION "\n" USAGE, argv[0]);
+ printk("Version " OPENBIOS_VERSION_STR "\n" USAGE,
+ argv[0]);
return 0;
case 'v':
verbose = 1;
Modified: trunk/openbios-devel/modules/elfnote.c
===================================================================
--- trunk/openbios-devel/modules/elfnote.c 2009-08-02 16:59:05 UTC (rev 532)
+++ trunk/openbios-devel/modules/elfnote.c 2009-08-02 18:20:53 UTC (rev 533)
@@ -4,6 +4,7 @@
#include "sys_info.h"
#include "asm/io.h"
#include "ipchecksum.h"
+#include "openbios-version.h"
#define printf printk
#define debug printk
@@ -19,7 +20,7 @@
Elf_Nhdr hdr1;
char name1[sizeof(ELF_NOTE_BOOT)];
- char version[sizeof(PROGRAM_VERSION)];
+ char version[sizeof(OPENBIOS_VERSION_STR)];
Elf_Nhdr hdr2;
char name2[sizeof(ELF_NOTE_BOOT)];
@@ -39,11 +40,11 @@
.hdr1 = {
.n_namesz = sizeof(ELF_NOTE_BOOT),
- .n_descsz = sizeof(PROGRAM_VERSION),
+ .n_descsz = sizeof(OPENBIOS_VERSION_STR),
.n_type = EIN_PROGRAM_VERSION,
},
.name1 = ELF_NOTE_BOOT,
- .version = PROGRAM_VERSION,
+ .version = OPENBIOS_VERSION_STR,
.hdr2 = {
.n_namesz = sizeof(ELF_NOTE_BOOT),
@@ -81,7 +82,7 @@
.int EIN_PROGRAM_VERSION
1: .asciz "ELFBoot"
2: .align 4
-3: .asciz PROGRAM_VERSION
+3: .asciz OPENBIOS_VERSION_STR
4:
.align 4
1
0

r532 - in trunk/openbios-devel: . config/examples config/scripts config/xml
by svn@openbios.org Aug. 2, 2009
by svn@openbios.org Aug. 2, 2009
Aug. 2, 2009
Author: blueswirl
Date: 2009-08-02 18:59:05 +0200 (Sun, 02 Aug 2009)
New Revision: 532
Added:
trunk/openbios-devel/Makefile.target
trunk/openbios-devel/config/xml/rules.xml
Removed:
trunk/openbios-devel/config/examples/amd64_rules.xml
trunk/openbios-devel/config/examples/cross-ppc_rules.xml
trunk/openbios-devel/config/examples/cross-sparc32_rules.xml
trunk/openbios-devel/config/examples/cross-sparc64_rules.xml
trunk/openbios-devel/config/examples/cross-x86_rules.xml
trunk/openbios-devel/config/examples/ppc_rules.xml
trunk/openbios-devel/config/examples/sparc32_rules.xml
trunk/openbios-devel/config/examples/sparc64_rules.xml
trunk/openbios-devel/config/examples/x86_rules.xml
trunk/openbios-devel/config/scripts/archname
trunk/openbios-devel/config/scripts/crosscflags
Modified:
trunk/openbios-devel/Makefile
trunk/openbios-devel/config/scripts/switch-arch
Log:
Refactor the build rules
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Modified: trunk/openbios-devel/Makefile
===================================================================
--- trunk/openbios-devel/Makefile 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/Makefile 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,4 +1,3 @@
-HOSTARCH=$(shell config/scripts/archname)
ODIRS=$(wildcard obj-*)
TARGETS=$(subst obj-,,$(ODIRS))
@@ -9,13 +8,13 @@
echo; exit 1 )
info:
- @echo "Building OpenBIOS on $(HOSTARCH) for $(TARGETS)"
+ @echo "Building OpenBIOS for $(TARGETS)"
clean:
- @printf "Cleaning up..."
- @rm -rf $(ODIRS) forth.dict.core
- @find . -type f -name "*~" -exec rm \{\} \;
- @echo " ok"
+ @echo "Cleaning up..."
+ @for dir in $(ODIRS); do \
+ $(MAKE) -C $$dir clean; \
+ done
build:
@printf "Building..."
Added: trunk/openbios-devel/Makefile.target
===================================================================
--- trunk/openbios-devel/Makefile.target (rev 0)
+++ trunk/openbios-devel/Makefile.target 2009-08-02 16:59:05 UTC (rev 532)
@@ -0,0 +1,71 @@
+#
+# OpenBIOS Makefile
+# (C) 2004-2009 by the OpenBIOS team
+#
+
+include config.mak
+
+ODIR := .
+SRCDIR := ..
+HOSTCC := gcc
+
+HOSTCFLAGS+= -O2 -g -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
+HOSTCFLAGS+= -Wall -Wredundant-decls -Wshadow -Wpointer-arith
+HOSTCFLAGS+= -Wstrict-prototypes -Wmissing-declarations -Wundef -Wendif-labels
+HOSTCFLAGS+= -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
+HOSTCFLAGS+= -W
+HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
+
+CC := $(TARGET)gcc
+AS := $(TARGET)as
+AR := $(TARGET)ar
+LD := $(TARGET)ld
+NM := $(TARGET)nm
+STRIP := $(TARGET)strip
+RANLIB := $(TARGET)ranlib
+
+CFLAGS+= -Os -g -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS
+CFLAGS+= -Wall -Wredundant-decls -Wshadow -Wpointer-arith
+CFLAGS+= -Wstrict-prototypes -Wmissing-declarations -Wundef -Wendif-labels
+CFLAGS+= -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
+CFLAGS+= -Werror
+INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
+AS_FLAGS+= -g
+
+#
+# pre rules
+#
+
+all: versions dictionaries host-libraries target-libraries host-executables target-executables
+
+VERSION := "1.0"
+
+versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
+
+$(ODIR)/forth/version.fs:
+ @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
+ ( echo ": builddate \" $$DATE\" ; " ; \
+ echo ": version \" $(VERSION)\" ; " ; ) \
+ > $(dir $(a))/version.fs
+
+$(ODIR)/target/include/openbios-version.h:
+ @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
+ ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
+ echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
+ echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
+ > $(dir $(a))/openbios-version.h
+
+info:
+ @echo "Building OpenBIOS on $(HOSTARCH) for $(ARCH)"
+
+clean:
+ @printf "Cleaning up for $(ARCH)..."
+ @rm -rf forth.dict.core forthstrap *.dict openbios-*
+ @find . -type f -name "*~" -o -name '*.o' -o -name '*.a' -exec rm \{\} \;
+ @echo " ok"
+
+build-verbose: info build
+
+build: all
+
+include rules.mak
Deleted: trunk/openbios-devel/config/examples/amd64_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/amd64_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/amd64_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,86 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2005 by the OpenBIOS team
-#
-
-ARCH := amd64
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-CC := gcc
-AS := as
-AR := ar
-LD := ld
-NM := nm
-STRIP := strip
-RANLIB := ranlib
-INSTALL := install
-
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin -g
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/cross-ppc_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/cross-ppc_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/cross-ppc_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,104 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2005 by the OpenBIOS team
-#
-
-ARCH := ppc
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -Os -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-#
-# MOLPATH is needed if you want to build openbios-mol.elf
-#
-MOLPATH=$(HOME)/mol-0.9.71
-
-TARGET=powerpc-linux-gnu-
-CC := $(TARGET)gcc
-AS := $(TARGET)as
-AR := $(TARGET)ar
-LD := $(TARGET)ld
-NM := $(TARGET)nm
-STRIP := $(TARGET)strip
-RANLIB := $(TARGET)ranlib
-CFLAGS := -Os -Wall -msoft-float -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin-bcopy -fno-builtin-log2
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations -Werror
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-M4 := m4
-
-#
-# pre rules
-#
-
-all: mol versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-mol:
- @grep CONFIG_MOL $(ODIR)/forth/config.fs >/dev/null && ( \
- echo "Using MOL path $(MOLPATH)..."; \
- ln -s $(MOLPATH)/src/shared/osi_calls.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/shared/osi.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/shared/prom.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/boothelper_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/video_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/pseudofs_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/kbd_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/drivers/disk/include/scsi_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/drivers/disk/include/ablk_sh.h $(ODIR)/target/include/ ) || true
-
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; ranlib $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/cross-sparc32_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/cross-sparc32_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/cross-sparc32_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,87 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2006 by the OpenBIOS team
-#
-
-ARCH := sparc32
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-TARGET=sparc-elf-
-CC := $(TARGET)gcc
-AS := $(TARGET)as
-AR := $(TARGET)ar
-LD := $(TARGET)ld
-NM := $(TARGET)nm
-STRIP := $(TARGET)strip
-RANLIB := $(TARGET)ranlib
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin -g
-CFLAGS+= -Wa,-xarch=v8 -Wa,-32 -m32 -mcpu=supersparc
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes -Werror
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-AS_FLAGS := -Wa,-xarch=v8 -Wa,-32 -g
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/cross-sparc64_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/cross-sparc64_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/cross-sparc64_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,88 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2006 by the OpenBIOS team
-#
-
-ARCH := sparc64
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-TARGET=sparc64-elf-
-CC := $(TARGET)gcc
-AS := $(TARGET)as
-AR := $(TARGET)ar
-LD := $(TARGET)ld
-NM := $(TARGET)nm
-STRIP := $(TARGET)strip
-RANLIB := $(TARGET)ranlib
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -g
-CFLAGS+= -Wa,-xarch=v9b -Wa,-64 -m64 -mcpu=ultrasparc -mcmodel=medany
-CFLAGS+= -fno-builtin -nostdlib -ffreestanding
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes -Werror
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-AS_FLAGS := -Wa,-xarch=v9b -Wa,-64 -g
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/cross-x86_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/cross-x86_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/cross-x86_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,88 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2005 by the OpenBIOS team
-#
-
-ARCH := x86
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-#TARGET=i386-elf-
-TARGET=
-CC := $(TARGET)gcc
-AS := $(TARGET)as
-AR := $(TARGET)ar
-LD := $(TARGET)ld
-NM := $(TARGET)nm
-STRIP := $(TARGET)strip
-RANLIB := $(TARGET)ranlib
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin -g
-CFLAGS+= -m32
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-AS_FLAGS := -Wa,-32 -g
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/ppc_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/ppc_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/ppc_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,103 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2005 by the OpenBIOS team
-#
-
-ARCH := ppc
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -Os -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-#
-# MOLPATH is needed if you want to build openbios-mol.elf
-#
-MOLPATH=$(HOME)/mol-0.9.71
-
-CC := gcc
-AS := as
-AR := ar
-LD := ld
-NM := nm
-STRIP := strip
-RANLIB := ranlib
-CFLAGS := -Os -Wall -msoft-float -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin-bcopy -fno-builtin-log2
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes -Werror
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-M4 := m4
-
-#
-# pre rules
-#
-
-all: mol versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-mol:
- @grep CONFIG_MOL $(ODIR)/forth/config.fs >/dev/null && ( \
- echo "Using MOL path $(MOLPATH)..."; \
- ln -s $(MOLPATH)/src/shared/osi_calls.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/shared/osi.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/shared/prom.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/boothelper_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/video_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/pseudofs_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/include/kbd_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/drivers/disk/include/scsi_sh.h $(ODIR)/target/include/; \
- ln -s $(MOLPATH)/src/drivers/disk/include/ablk_sh.h $(ODIR)/target/include/ ) || true
-
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; ranlib $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/sparc32_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/sparc32_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/sparc32_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,92 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2006 by the OpenBIOS team
-#
-
-ARCH := sparc32
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-CC := gcc
-AS := as
-AR := ar
-LD := ld
-NM := nm
-STRIP := strip
-RANLIB := ranlib
-INSTALL := install
-
-ifeq ($(shell uname), Linux)
- LIBDL_LDFLAGS=-ldl
-endif
-
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin -g
-CFLAGS+= -Wa,-xarch=v8 -Wa,-32 -m32 -mcpu=supersparc
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes -Werror
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-AS_FLAGS := -Wa,-xarch=v8 -Wa,-32 -g
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/sparc64_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/sparc64_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/sparc64_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,93 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2006 by the OpenBIOS team
-#
-
-ARCH := sparc64
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wa,-xarch=v9 -Wa,-64 -m64 -mcpu=ultrasparc -mcmodel=medany
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-CC := gcc
-AS := as
-AR := ar
-LD := ld
-NM := nm
-STRIP := strip
-RANLIB := ranlib
-INSTALL := install
-
-ifeq ($(shell uname), Linux)
- LIBDL_LDFLAGS=-ldl
-endif
-
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin -g
-CFLAGS+= -Wa,-xarch=v9b -Wa,-64 -m64 -mcpu=ultrasparc -mcmodel=medany
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes -Werror
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-AS_FLAGS := -Wa,-xarch=v9b -Wa,-64 -g
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/examples/x86_rules.xml
===================================================================
--- trunk/openbios-devel/config/examples/x86_rules.xml 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/examples/x86_rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,90 +0,0 @@
-<rules>
-
-<pre><![CDATA[
-#
-# Autogenerated OpenBIOS Makefile
-# (C) 2004-2005 by the OpenBIOS team
-#
-
-ARCH := x86
-ODIR := .
-SRCDIR := ..
-HOSTCC := gcc
-HOSTARCH?=$(shell $(SRCDIR)/config/scripts/archname)
-CROSSCFLAGS=$(shell $(SRCDIR)/config/scripts/crosscflags $(HOSTARCH) $(ARCH))
-HOSTCFLAGS := -O2 -g -Wall -W -DFCOMPILER -DBOOTSTRAP $(CROSSCFLAGS)
-HOSTCFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-HOSTCFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-HOSTINCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-
-CC := gcc
-AR := ar
-NM := nm
-STRIP := strip
-RANLIB := ranlib
-INSTALL := install
-
-ifeq ($(shell uname), Linux)
- LIBDL_LDFLAGS=-ldl
-endif
-
-CFLAGS := -Os -Wall -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH -USWAP_ENDIANNESS -fno-builtin -g
-CFLAGS+= -m32
-CFLAGS+= -Wredundant-decls -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations
-CFLAGS+= -Wundef -Wendif-labels -Wstrict-aliasing -Wwrite-strings -Wmissing-prototypes
-INCLUDES := -I$(SRCDIR)/include -I$(SRCDIR)/kernel/include -I$(ODIR)/target/include
-AS_FLAGS := -Wa,-32 -g
-
-#
-# pre rules
-#
-
-all: versions dictionaries host-libraries target-libraries host-executables target-executables
-
-VERSION := "1.0"
-
-versions: $(ODIR)/target/include/openbios-version.h $(ODIR)/forth/version.fs
-
-$(ODIR)/forth/version.fs:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo ": builddate \" $$DATE\" ; " ; \
- echo ": version \" $(VERSION)\" ; " ; ) \
- > $(dir $(a))/version.fs
-
-$(ODIR)/target/include/openbios-version.h:
- @DATE="$(shell echo `LC_ALL=C TZ=UTC date +'%b %e %Y %H:%M'`)" ; \
- ( echo "#define OPENBIOS_BUILD_DATE \"$$DATE\"" ; \
- echo "#define OPENBIOS_VERSION_STR \"$(VERSION)\"" ; \
- echo "#define OPENBIOS_RELEASE \"$(VERSION)\"" ; ) \
- > $(dir $(a))/openbios-version.h
-]]></pre>
-
- <!-- host compiler build rules -->
-
-<rule target="host" entity="executable">
- $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
-</rule>
-
-<rule target="host" entity="object">
- $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="host" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
- <!-- target/cross compiler build rules -->
-
-<rule target="target" entity="executable">
- $(CC) $(CFLAGS) -o $@ $^
-</rule>
-
-<rule target="target" entity="object">
- $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
-</rule>
-
-<rule target="target" entity="library">
- $(AR) cru $@ $^; $(RANLIB) $@
-</rule>
-
-</rules>
Deleted: trunk/openbios-devel/config/scripts/archname
===================================================================
--- trunk/openbios-devel/config/scripts/archname 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/scripts/archname 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,17 +0,0 @@
-#!/bin/sh
-
-unset ARCH
-
-case "$1" in
- # ppc|powerpc) ARCH=ppc ;;
- # mpc107) ARCH=mpc107 ;;
- # osx|darwin) ARCH=osx ;;
- ppc|powerpc|mpc107|osx|darwin) ARCH=ppc ;;
-esac
-
-test "$ARCH" || ARCH=`uname -m | sed -e s/i.86/x86/ -e s/i86pc/x86/ \
- -e s/sun4u/sparc64/ -e s/sparc$/sparc32/ \
- -e s/arm.*/arm/ -e s/sa110/arm/ -e s/x86_64/amd64/ \
- -e "s/Power Macintosh/ppc/"`
-
-echo $ARCH
Deleted: trunk/openbios-devel/config/scripts/crosscflags
===================================================================
--- trunk/openbios-devel/config/scripts/crosscflags 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/scripts/crosscflags 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,60 +0,0 @@
-#!/bin/sh
-
-host=$1
-target=$2
-
-if test "$host" = "powerpc" -o "$host" = "ppc" \
- -o "$host" = "mips" -o "$host" = "s390" \
- -o "$host" = "sparc32" -o "$host" = "sparc64" \
- -o "$host" = "m68k" -o "$host" = "armv4b"; then
- hostbigendian="yes"
-else
- hostbigendian="no"
-fi
-
-# host long bits test
-if test "$host" = "sparc64" -o "$host" = "ia64" \
- -o "$host" = "amd64" -o "$host" = "x86_64" \
- -o "$host" = "alpha"; then
- hostlongbits="64"
-else
- hostlongbits="32"
-fi
-
-if test "$target" = "powerpc" -o "$target" = "ppc" \
- -o "$target" = "mips" -o "$target" = "s390" \
- -o "$target" = "sparc32" -o "$target" = "sparc64" \
- -o "$target" = "m68k" -o "$target" = "armv4b"; then
- targetbigendian="yes"
-else
- targetbigendian="no"
-fi
-
-# target long bits test
-if test "$target" = "sparc64" -o "$target" = "ia64" \
- -o "$target" = "amd64" -o "target" = "x86_64" \
- -o "$target" = "alpha"; then
- targetlongbits="64"
-else
- targetlongbits="32"
-fi
-
-if test "$targetbigendian" = "$hostbigendian"; then
- cflags="-USWAP_ENDIANNESS"
-else
- cflags="-DSWAP_ENDIANNESS"
-fi
-
-if test "$targetlongbits" = "$hostlongbits"; then
- cflags="$cflags -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH"
-elif test "$targetlongbits" -lt "$hostlongbits"; then
- cflags="$cflags -DNATIVE_BITWIDTH_SMALLER_THAN_HOST_BITWIDTH"
-else
- cflags="$cflags -DNATIVE_BITWIDTH_LARGER_THAN_HOST_BITWIDTH"
-fi
-
-if test "$host" = "x86" -a "$targetlongbits" = "64"; then
- cflags="$cflags -DNEED_FAKE_INT128_T"
-fi
-
-echo "$cflags"
Modified: trunk/openbios-devel/config/scripts/switch-arch
===================================================================
--- trunk/openbios-devel/config/scripts/switch-arch 2009-08-02 12:41:31 UTC (rev 531)
+++ trunk/openbios-devel/config/scripts/switch-arch 2009-08-02 16:59:05 UTC (rev 532)
@@ -1,5 +1,10 @@
#!/bin/sh
+#
+# MOLPATH is needed if you want to build openbios-mol.elf
+#
+MOLPATH=$HOME/mol-0.9.71
+
if [ x"$1" = x ]; then
printf "Usage:\n $0 [arch-config]...\n"
printf "arch-config values supported for native builds:\n"
@@ -9,19 +14,121 @@
exit 0
fi
+crosscflags()
+{
+ local host=$1
+ local target=$2
+
+ if test "$host" = "powerpc" -o "$host" = "ppc" \
+ -o "$host" = "mips" -o "$host" = "s390" \
+ -o "$host" = "sparc32" -o "$host" = "sparc64" \
+ -o "$host" = "m68k" -o "$host" = "armv4b"; then
+ hostbigendian="yes"
+ else
+ hostbigendian="no"
+ fi
+
+# host long bits test
+ if test "$host" = "sparc64" -o "$host" = "ia64" \
+ -o "$host" = "amd64" -o "$host" = "x86_64" \
+ -o "$host" = "alpha"; then
+ hostlongbits="64"
+ else
+ hostlongbits="32"
+ fi
+
+ if test "$target" = "powerpc" -o "$target" = "ppc" \
+ -o "$target" = "mips" -o "$target" = "s390" \
+ -o "$target" = "sparc32" -o "$target" = "sparc64" \
+ -o "$target" = "m68k" -o "$target" = "armv4b"; then
+ targetbigendian="yes"
+ else
+ targetbigendian="no"
+ fi
+
+# target long bits test
+ if test "$target" = "sparc64" -o "$target" = "ia64" \
+ -o "$target" = "amd64" -o "target" = "x86_64" \
+ -o "$target" = "alpha"; then
+ targetlongbits="64"
+ else
+ targetlongbits="32"
+ fi
+
+ if test "$targetbigendian" = "$hostbigendian"; then
+ cflags="-USWAP_ENDIANNESS"
+ else
+ cflags="-DSWAP_ENDIANNESS"
+ fi
+
+ if test "$targetlongbits" = "$hostlongbits"; then
+ cflags="$cflags -DNATIVE_BITWIDTH_EQUALS_HOST_BITWIDTH"
+ elif test "$targetlongbits" -lt "$hostlongbits"; then
+ cflags="$cflags -DNATIVE_BITWIDTH_SMALLER_THAN_HOST_BITWIDTH"
+ else
+ cflags="$cflags -DNATIVE_BITWIDTH_LARGER_THAN_HOST_BITWIDTH"
+ fi
+
+ if test "$host" = "x86" -a "$targetlongbits" = "64"; then
+ cflags="$cflags -DNEED_FAKE_INT128_T"
+ fi
+
+ CROSSCFLAGS=$cflags
+}
+
+archname()
+{
+ HOSTARCH=`uname -m | sed -e s/i.86/x86/ -e s/i86pc/x86/ \
+ -e s/sun4u/sparc64/ -e s/sparc$/sparc32/ \
+ -e s/arm.*/arm/ -e s/sa110/arm/ -e s/x86_64/amd64/ \
+ -e "s/Power Macintosh/ppc/"`
+}
+
# This is needed because viewvc messes with the permissions of executables:
chmod 755 utils/dist/debian/rules
chmod 755 config/scripts/switch-arch
-chmod 755 config/scripts/archname
chmod 755 config/scripts/reldir
-chmod 755 config/scripts/crosscflags
+
if test "x$HOSTARCH" = "x"; then
- HOSTARCH=`config/scripts/archname`
+ archname
fi
echo "Configuring OpenBIOS on $HOSTARCH for $*"
for RULES_ARCH in $*; do
- ARCH=`cat config/examples/${RULES_ARCH}_rules.xml |grep "^ARCH" |cut -d\= -f2|tr -d \ `
+ ARCH=`echo $RULES_ARCH | sed s/cross-//g`
+ case $ARCH in
+ amd64)
+ TARGET="x86_64-linux-gnu-"
+ CFLAGS="-fno-builtin"
+ ;;
+
+ ppc)
+ TARGET="powerpc-linux-gnu-"
+ CFLAGS="-msoft-float -fno-builtin-bcopy -fno-builtin-log2"
+ ;;
+
+ sparc32)
+ TARGET="sparc-elf-"
+ CFLAGS="-Wa,-xarch=v8 -Wa,-32 -m32 -mcpu=supersparc -fno-builtin"
+ AS_FLAGS="-Wa,-xarch=v8 -Wa,-32"
+ ;;
+
+ sparc64)
+ TARGET="sparc64-elf-"
+ CFLAGS="-Wa,-xarch=v9b -Wa,-64 -m64 -mcpu=ultrasparc -mcmodel=medany -fno-builtin"
+ AS_FLAGS="-Wa,-xarch=v9b -Wa,-64"
+ ;;
+
+ x86)
+ TARGET="i486-linux-gnu-"
+ CFLAGS="-fno-builtin -m32"
+ AS_FLAGS="-Wa,-32"
+ ;;
+ esac
+ if test "$ARCH" = "$RULES_ARCH"; then
+ TARGET=""
+ fi
+ crosscflags $HOSTARCH $ARCH
OBJDIR=obj-$ARCH
printf "Initializing build tree $OBJDIR..."
rm -rf "$OBJDIR"
@@ -60,15 +167,35 @@
ODIR=.
printf "Creating target Makefile..."
- ln -s $SRCDIR/config/examples/${RULES_ARCH}_rules.xml $ODIR/rules.xml
+ echo "ARCH=$ARCH" > $ODIR/config.mak
+ echo "TARGET=$TARGET" >> $ODIR/config.mak
+ echo "CFLAGS=$CFLAGS" >> $ODIR/config.mak
+ echo "AS_FLAGS=$AS_FLAGS" >> $ODIR/config.mak
+ echo "HOSTARCH?=$HOSTARCH" >> $ODIR/config.mak
+ echo "CROSSCFLAGS=$CROSSCFLAGS" >> $ODIR/config.mak
+ ln -s $SRCDIR/config/xml/rules.xml $ODIR/rules.xml
ln -s $SRCDIR/config/examples/${RULES_ARCH}_config.xml $ODIR/config.xml
+ ln -s ../Makefile.target $ODIR/Makefile
xsltproc $SRCDIR/config/xml/xinclude.xsl $SRCDIR/build.xml > $ODIR/build-full.xml
- xsltproc $SRCDIR/config/xml/makefile.xsl $ODIR/build-full.xml > $ODIR/Makefile
+ xsltproc $SRCDIR/config/xml/makefile.xsl $ODIR/build-full.xml > $ODIR/rules.mak
echo "ok."
printf "Creating config files..."
xsltproc $SRCDIR/config/xml/config-c.xsl $SRCDIR/config/examples/${RULES_ARCH}_config.xml > $ODIR/host/include/autoconf.h
xsltproc $SRCDIR/config/xml/config-c.xsl $SRCDIR/config/examples/${RULES_ARCH}_config.xml > $ODIR/target/include/autoconf.h
xsltproc $SRCDIR/config/xml/config-forth.xsl $SRCDIR/config/examples/${RULES_ARCH}_config.xml > $ODIR/forth/config.fs
echo "ok."
+
+ grep CONFIG_MOL $ODIR/forth/config.fs >/dev/null && ( \
+ echo "Using MOL path $MOLPATH..."; \
+ ln -s $MOLPATH/src/shared/osi_calls.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/shared/osi.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/shared/prom.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/include/boothelper_sh.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/include/video_sh.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/include/pseudofs_sh.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/include/kbd_sh.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/drivers/disk/include/scsi_sh.h $ODIR/target/include/; \
+ ln -s $MOLPATH/src/drivers/disk/include/ablk_sh.h $ODIR/target/include/ ) || true
+
cd $SRCDIR
done
Added: trunk/openbios-devel/config/xml/rules.xml
===================================================================
--- trunk/openbios-devel/config/xml/rules.xml (rev 0)
+++ trunk/openbios-devel/config/xml/rules.xml 2009-08-02 16:59:05 UTC (rev 532)
@@ -0,0 +1,23 @@
+<rules>
+ <!-- host compiler build rules -->
+<rule target="host" entity="executable">
+ $(HOSTCC) $(HOSTCFLAGS) -o $@ $^
+</rule>
+<rule target="host" entity="object">
+ $(HOSTCC) $(HOSTCFLAGS) $(HOSTINCLUDES) -c -o $@ $^
+</rule>
+<rule target="host" entity="library">
+ $(AR) cru $@ $^; $(RANLIB) $@
+</rule>
+
+ <!-- target/cross compiler build rules -->
+<rule target="target" entity="executable">
+ $(CC) $(CFLAGS) -o $@ $^
+</rule>
+<rule target="target" entity="object">
+ $(CC) $$EXTRACFLAGS $(CFLAGS) $(INCLUDES) -c -o $@ $^
+</rule>
+<rule target="target" entity="library">
+ $(AR) cru $@ $^; $(RANLIB) $@
+</rule>
+</rules>
1
0
Author: blueswirl
Date: 2009-08-02 14:41:31 +0200 (Sun, 02 Aug 2009)
New Revision: 531
Modified:
trunk/openbios-devel/config/scripts/crosscflags
Log:
Make crosscflags executable
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Property changes on: trunk/openbios-devel/config/scripts/crosscflags
___________________________________________________________________
Added: svn:executable
+ *
1
0
Author: blueswirl
Date: 2009-08-02 14:37:02 +0200 (Sun, 02 Aug 2009)
New Revision: 530
Added:
trunk/openbios-devel/.gitignore
Log:
Add a .gitignore file
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Added: trunk/openbios-devel/.gitignore
===================================================================
--- trunk/openbios-devel/.gitignore (rev 0)
+++ trunk/openbios-devel/.gitignore 2009-08-02 12:37:02 UTC (rev 530)
@@ -0,0 +1 @@
+obj-*
1
0
Author: blueswirl
Date: 2009-08-02 14:28:24 +0200 (Sun, 02 Aug 2009)
New Revision: 529
Modified:
trunk/openbios-devel/modules/sun-parts.c
Log:
Fix compile when CONFIG_DEBUG_SUN_PARTS is defined
Signed-off-by: Blue Swirl <blauwirbel(a)gmail.com>
Modified: trunk/openbios-devel/modules/sun-parts.c
===================================================================
--- trunk/openbios-devel/modules/sun-parts.c 2009-08-02 11:08:01 UTC (rev 528)
+++ trunk/openbios-devel/modules/sun-parts.c 2009-08-02 12:28:24 UTC (rev 529)
@@ -146,7 +146,8 @@
di->size_hi = size >> BITS;
di->size_lo = size & (ucell) -1;
di->type = __be32_to_cpu(p->infos[parnum].id);
- DPRINTF("Found Sun partition table, offs %lld size %lld\n", offs, size);
+ DPRINTF("Found Sun partition table, offs %lld size %lld\n",
+ (llong)offs, (llong)size);
RET( -1 );
}
1
0

r528 - in trunk/openbios-devel: arch/sparc32 arch/sparc64 config/examples
by svn@openbios.org Aug. 2, 2009
by svn@openbios.org Aug. 2, 2009
Aug. 2, 2009
Author: blueswirl
Date: 2009-08-02 13:08:01 +0200 (Sun, 02 Aug 2009)
New Revision: 528
Modified:
trunk/openbios-devel/arch/sparc32/lib.c
trunk/openbios-devel/arch/sparc64/lib.c
trunk/openbios-devel/arch/sparc64/ofmem_sparc64.c
trunk/openbios-devel/arch/sparc64/ofmem_sparc64.h
trunk/openbios-devel/config/examples/cross-sparc64_config.xml
Log:
switch sparc64 to ofmem module implementation (Igor Kovalenko)
Modified: trunk/openbios-devel/arch/sparc32/lib.c
===================================================================
--- trunk/openbios-devel/arch/sparc32/lib.c 2009-08-02 11:07:13 UTC (rev 527)
+++ trunk/openbios-devel/arch/sparc32/lib.c 2009-08-02 11:08:01 UTC (rev 528)
@@ -68,25 +68,6 @@
struct linux_mlist_v0 *ptmap;
struct linux_mlist_v0 *ptavail;
-typedef struct alloc_desc {
- struct alloc_desc *next;
- int size; /* size (including) this struct */
-} alloc_desc_t;
-
-typedef struct mem_range {
- struct mem_range *next;
- ulong start;
- ulong size;
-} range_t;
-
-typedef struct trans {
- struct trans *next;
- ulong virt; /* chain is sorted by virt */
- ulong size;
- ulong phys;
- int mode;
-} translation_t;
-
static struct {
char *next_malloc;
int left;
Modified: trunk/openbios-devel/arch/sparc64/lib.c
===================================================================
--- trunk/openbios-devel/arch/sparc64/lib.c 2009-08-02 11:07:13 UTC (rev 527)
+++ trunk/openbios-devel/arch/sparc64/lib.c 2009-08-02 11:08:01 UTC (rev 528)
@@ -298,11 +298,19 @@
}
}
-void ofmem_unmap_pages(ucell virt, ucell size)
+void ofmem_arch_unmap_pages(ucell virt, ucell size)
{
unmap_pages(virt, size);
}
+void ofmem_arch_early_map_pages(ucell phys, ucell virt, ucell size, ucell mode)
+{
+ if (mode & SPITFIRE_TTE_LOCKED) {
+ // install locked tlb entries now
+ ofmem_map_pages(phys, virt, size, mode);
+ }
+}
+
/*
3.6.5 unmap
( virt size -- )
@@ -332,14 +340,8 @@
virt = POP();
}
- printk("claim virt=" FMT_ucellx " size=" FMT_ucellx " align=" FMT_ucellx
- "\n",
- virt, size, align);
-
virt = ofmem_claim_virt(virt, size, align);
- printk("claimed virt=" FMT_ucellx "\n", virt);
-
PUSH(virt);
}
@@ -354,9 +356,8 @@
size = POP();
virt = POP();
- printk("release virt=" FMT_ucellx " size=" FMT_ucellx "\n", virt, size);
- ofmem_release(virt, size);
+ ofmem_release_virt(virt, size);
}
/* ( phys size align --- base ) */
@@ -373,14 +374,8 @@
phys |= POP();
}
- printk("mem_claim phys=" FMT_ucellx " size=" FMT_ucellx
- " align=" FMT_ucellx "\n",
- phys, size, align);
-
phys = ofmem_claim_phys(phys, size, align);
- printk("ofmem_claim_phys result phys=" FMT_ucellx "\n", phys);
-
ofmem_map(phys, phys, size, -1);
PUSH(phys >> 32);
@@ -395,9 +390,8 @@
size = POP();
phys = POP();
- printk("release virt=" FMT_ucellx " size=" FMT_ucellx "\n", phys, size);
- ofmem_release(phys, size);
+ ofmem_release_phys(phys, size);
}
DECLARE_NODE(memory, INSTALL_OPEN, 0, "/memory");
Modified: trunk/openbios-devel/arch/sparc64/ofmem_sparc64.c
===================================================================
--- trunk/openbios-devel/arch/sparc64/ofmem_sparc64.c 2009-08-02 11:07:13 UTC (rev 527)
+++ trunk/openbios-devel/arch/sparc64/ofmem_sparc64.c 2009-08-02 11:08:01 UTC (rev 528)
@@ -18,11 +18,6 @@
#include "ofmem_sparc64.h"
#include "spitfire.h"
-static inline uint64_t ALIGN_SIZE(uint64_t x, uint64_t a)
-{
- return (x + a - 1) & ~(a-1);
-}
-
#define OF_MALLOC_BASE ((char*)OFMEM + ALIGN_SIZE(sizeof(ofmem_t), 8))
#define MEMSIZE ((128 + 256 + 512) * 1024)
@@ -36,199 +31,41 @@
translation_t **g_ofmem_translations = &s_ofmem_data.ofmem.trans;
-ulong get_ram_size( void )
+static ucell get_heap_top( void )
{
- ofmem_t *ofmem = OFMEM;
- return ofmem->ramsize;
+ return (ucell)TOP_OF_RAM;
}
-static phandle_t s_phandle_memory = 0;
-static phandle_t s_phandle_mmu = 0;
-
-static void ofmem_update_mmu_translations( void )
+static inline size_t ALIGN_SIZE(size_t x, size_t a)
{
- ofmem_t *ofmem = OFMEM;
- translation_t *t;
- int ncells;
- ucell *props;
-
- if (s_phandle_mmu == 0)
- return;
-
- for( t = ofmem->trans, ncells = 0; t ; t=t->next, ncells++ ) {
- }
-
- props = malloc(ncells * sizeof(ucell) * 3);
-
- if (props == NULL)
- return;
-
- for( t = ofmem->trans, ncells = 0 ; t ; t=t->next ) {
- props[ncells++] = t->virt;
- props[ncells++] = t->size;
- props[ncells++] = t->mode;
- }
-
- set_property(s_phandle_mmu, "translations",
- (char*)props, ncells * sizeof(props[0]));
-
- free(props);
+ return (x + a - 1) & ~(a-1);
}
-static void ofmem_update_memory_available( phandle_t ph, range_t *range,
- u64 top_address )
+ofmem_t* ofmem_arch_get_private(void)
{
- range_t *r;
- int ncells;
- ucell *props;
-
- ucell start, size;
-
- if (s_phandle_memory == 0)
- return;
-
- /* count phys_range list entries */
- for( r = range, ncells = 0; r ; r=r->next, ncells++ ) {
- }
-
- /* inverse of phys_range list could take 2 more cells for the tail */
- props = malloc((ncells+1) * sizeof(ucell) * 2);
-
- if (props == NULL) {
- /* out of memory! */
- return;
- }
-
- start = 0;
- ncells = 0;
-
- for (r = range; r; r=r->next) {
- if (r->start >= top_address) {
- break;
- }
-
- size = r->start - start;
- if (size) {
- props[ncells++] = start;
- props[ncells++] = size;
- }
- start = r->start + r->size;
- }
-
- /* tail */
- if (start < top_address) {
- props[ncells++] = start;
- props[ncells++] = top_address - start;
- }
-
- set_property(ph, "available",
- (char*)props, ncells * sizeof(props[0]));
-
- free(props);
+ return OFMEM;
}
-static void ofmem_update_translations( void )
+void* ofmem_arch_get_malloc_base(void)
{
- ofmem_t *ofmem = OFMEM;
-
- ofmem_update_memory_available(s_phandle_memory,
- ofmem->phys_range, ofmem->ramsize);
- ofmem_update_memory_available(s_phandle_mmu,
- ofmem->virt_range, -1ULL);
- ofmem_update_mmu_translations();
+ return OF_MALLOC_BASE;
}
-/************************************************************************/
-/* OF private allocations */
-/************************************************************************/
-
-void* ofmem_malloc( size_t size )
+ucell ofmem_arch_get_heap_top(void)
{
- ofmem_t *ofmem = OFMEM;
- alloc_desc_t *d, **pp;
- char *ret;
-
- if( !size )
- return NULL;
-
- if( !ofmem->next_malloc )
- ofmem->next_malloc = (char*)OF_MALLOC_BASE;
-
- /* assuming sizeof(alloc_desc_t) is multiple of 8 */
- size = ALIGN_SIZE(size + sizeof(alloc_desc_t), 8);
-
- /* look in the freelist */
- for( pp=&ofmem->mfree; *pp && (**pp).size < size; pp = &(**pp).next ) {
- }
-
- /* waste at most 4K by taking an entry from the freelist */
- if( *pp && (**pp).size < size + 0x1000 ) {
- ret = (char*)*pp + sizeof(alloc_desc_t);
- memset( ret, 0, (**pp).size - sizeof(alloc_desc_t) );
- *pp = (**pp).next;
- return ret;
- }
-
- if( ofmem->next_malloc + size >= TOP_OF_RAM ) {
- printk("out of malloc memory (%x)!\n", size );
- return NULL;
- }
-
- d = (alloc_desc_t*) ofmem->next_malloc;
- ofmem->next_malloc += size;
-
- d->next = NULL;
- d->size = size;
-
- ret = (char*)d + sizeof(alloc_desc_t);
- memset( ret, 0, size - sizeof(alloc_desc_t) );
-
- return ret;
+ return get_heap_top();
}
-void ofmem_free( void *ptr )
+ucell ofmem_arch_get_virt_top(void)
{
- ofmem_t *ofmem = OFMEM;
- alloc_desc_t **pp, *d;
-
- /* it is legal to free NULL pointers (size zero allocations) */
- if( !ptr )
- return;
-
- d = (alloc_desc_t*)((char *)ptr - sizeof(alloc_desc_t));
- d->next = ofmem->mfree;
-
- /* insert in the (sorted) freelist */
- for( pp=&ofmem->mfree; *pp && (**pp).size < d->size ; pp = &(**pp).next ) {
- }
-
- d->next = *pp;
- *pp = d;
+ return (ucell)TOP_OF_RAM;
}
-void* ofmem_realloc( void *ptr, size_t size )
-{
- alloc_desc_t *d = (alloc_desc_t*)((char *)ptr - sizeof(alloc_desc_t));
- char *p;
-
- if( !ptr )
- return malloc( size );
- if( !size ) {
- free( ptr );
- return NULL;
- }
- p = malloc( size );
- memcpy( p, ptr, MIN(d->size - sizeof(alloc_desc_t),size) );
- free( ptr );
- return p;
-}
-
-
/************************************************************************/
/* misc */
/************************************************************************/
-static inline ucell def_memmode( ucell phys )
+ucell ofmem_arch_default_translation_mode( ucell phys )
{
/* Writable, cacheable */
/* not privileged and not locked */
@@ -236,399 +73,9 @@
}
-/************************************************************************/
-/* client interface */
-/************************************************************************/
-static int is_free( ucell ea, ucell size, range_t *r )
-{
- if( size == 0 )
- return 1;
- for( ; r ; r=r->next ) {
- if( r->start + r->size - 1 >= ea && r->start <= ea )
- return 0;
- if( r->start >= ea && r->start <= ea + size - 1 )
- return 0;
- }
- return 1;
-}
-static void add_entry_( ucell ea, ucell size, range_t **r )
-{
- range_t *nr;
-
- for( ; *r && (**r).start < ea; r=&(**r).next ) {
- }
-
- nr = (range_t*)malloc( sizeof(range_t) );
- nr->next = *r;
- nr->start = ea;
- nr->size = size;
- *r = nr;
-}
-
-static int add_entry( ucell ea, ucell size, range_t **r )
-{
- if( !is_free( ea, size, *r ) ) {
- printk("add_entry: range not free!\n");
- return -1;
- }
- add_entry_( ea, size, r );
- return 0;
-}
-
-static ucell find_area( ucell align, ucell size, range_t *r,
- ucell min, ucell max, int reverse )
-{
- ucell base = min;
- range_t *r2;
-
- if( (align & (align-1)) ) {
- printk("bad alignment " FMT_ucell "\n", align);
- align = 0x1000;
- }
- if( !align )
- align = 0x1000;
-
- base = reverse ? max - size : min;
- r2 = reverse ? NULL : r;
-
- for( ;; ) {
- if( !reverse ) {
- base = (base + align - 1) & ~(align-1);
- if( base < min )
- base = min;
- if( base + size - 1 >= max -1 )
- break;
- } else {
- if( base > max - size )
- base = max - size;
- base -= base & (align-1);
- }
- if( is_free( base, size, r ) )
- return base;
-
- if( !reverse ) {
- if( !r2 )
- break;
- base = r2->start + r2->size;
- r2 = r2->next;
- } else {
- range_t *rp;
-
- for( rp=r; rp && rp->next != r2 ; rp=rp->next ) {
- }
-
- r2 = rp;
- if( !r2 )
- break;
- base = r2->start - size;
- }
- }
- return (ucell)-1;
-}
-
-static ucell ofmem_claim_phys_( ucell phys, ucell size, ucell align,
- ucell min, ucell max, int reverse )
-{
- ofmem_t *ofmem = OFMEM;
- if( !align ) {
- if( !is_free( phys, size, ofmem->phys_range ) ) {
- printk("Non-free physical memory claimed!\n");
- return -1;
- }
- add_entry( phys, size, &ofmem->phys_range );
- return phys;
- }
- phys = find_area( align, size, ofmem->phys_range, min, max, reverse );
- if( phys == (ucell)-1 ) {
- printk("ofmem->claim_phys - out of space\n");
- return -1;
- }
- add_entry( phys, size, &ofmem->phys_range );
-
- ofmem_update_translations();
-
- return phys;
-}
-
-/* if align != 0, phys is ignored. Returns -1 on error */
-ucell ofmem_claim_phys( ucell phys, ucell size, ucell align )
-{
- /* printk("+ ofmem_claim phys %08lx %lx %ld\n", phys, size, align ); */
- return ofmem_claim_phys_( phys, size, align, 0, get_ram_size(), 0 );
-}
-
-static ucell ofmem_claim_virt_( ucell virt, ucell size, ucell align,
- ucell min, ucell max, int reverse )
-{
- ofmem_t *ofmem = OFMEM;
- if( !align ) {
- if( !is_free( virt, size, ofmem->virt_range ) ) {
- printk("Non-free physical memory claimed!\n");
- return -1;
- }
- add_entry( virt, size, &ofmem->virt_range );
- return virt;
- }
-
- virt = find_area( align, size, ofmem->virt_range, min, max, reverse );
- if( virt == -1UL ) {
- printk("ofmem_claim_virt - out of space\n");
- return -1UL;
- }
- add_entry( virt, size, &ofmem->virt_range );
- return virt;
-}
-
-ucell ofmem_claim_virt( ucell virt, ucell size, ucell align )
-{
- /* printk("+ ofmem_claim virt %08lx %lx %ld\n", virt, size, align ); */
- return ofmem_claim_virt_( virt, size, align, get_ram_size(), (ucell)TOP_OF_RAM, 0 );
-}
-
-
-/* allocate both physical and virtual space and add a translation */
-ucell ofmem_claim( ucell addr, ucell size, ucell align )
-{
- ofmem_t *ofmem = OFMEM;
- ucell virt, phys;
- ucell offs = addr & 0xfff;
-
- /* printk("+ ofmem_claim %08lx %lx %ld\n", addr, size, align ); */
- virt = phys = 0;
- if( !align ) {
- if( is_free(addr, size, ofmem->virt_range) &&
- is_free(addr, size, ofmem->phys_range) ) {
- ofmem_claim_phys_( addr, size, 0, 0, 0, 0 );
- ofmem_claim_virt_( addr, size, 0, 0, 0, 0 );
- virt = phys = addr;
- } else {
- /* printk("**** ofmem_claim failure ***!\n"); */
- return -1;
- }
- } else {
- if( align < 0x1000 )
- align = 0x1000;
- phys = ofmem_claim_phys_( addr, size, align, 0, get_ram_size(), 1 /* reverse */ );
- virt = ofmem_claim_virt_( addr, size, align, 0, get_ram_size(), 1 /* reverse */ );
- if( phys == (ucell)-1 || virt == (ucell)-1 ) {
- printk("ofmem_claim failed\n");
- return -1;
- }
- /* printk("...phys = %08lX, virt = %08lX, size = %08lX\n", phys, virt, size ); */
- }
-
- /* align */
- if( phys & 0xfff ) {
- size += (phys & 0xfff);
- virt -= (phys & 0xfff);
- phys &= ~0xfff;
- }
- if( size & 0xfff )
- size = (size + 0xfff) & ~0xfff;
-
- /* printk("...free memory found... phys: %08lX, virt: %08lX, size %lX\n", phys, virt, size ); */
- ofmem_map( phys, virt, size, -1 );
- return virt + offs;
-}
-
-
/************************************************************************/
-/* keep track of ea -> phys translations */
-/************************************************************************/
-
-static void split_trans( ucell virt )
-{
- ofmem_t *ofmem = OFMEM;
- translation_t *t, *t2;
-
- for( t=ofmem->trans; t; t=t->next ) {
- if( virt > t->virt && virt < t->virt + t->size-1 ) {
- t2 = (translation_t*)malloc( sizeof(translation_t) );
- t2->virt = virt;
- t2->size = t->size - (virt - t->virt);
- t->size = virt - t->virt;
- t2->phys = t->phys + t->size;
- t2->mode = t->mode;
- t2->next = t->next;
- t->next = t2;
- }
- }
-}
-
-static int map_page_range( ucell phys, ucell virt, ucell size, ucell mode )
-{
- ofmem_t *ofmem = OFMEM;
- translation_t *t, **tt;
-
- OFMEM_TRACE("map_page_range " FMT_ucellx
- " -> " FMT_ucellx " " FMT_ucellx " mode " FMT_ucellx "\n",
- virt, phys, size, mode );
-
- split_trans( virt );
- split_trans( virt + size );
-
- /* detect remappings */
- for( t=ofmem->trans; t; ) {
- if( virt == t->virt || (virt < t->virt && virt + size > t->virt )) {
- if( t->phys + virt - t->virt != phys ) {
- OFMEM_TRACE("mapping altered virt=" FMT_ucellx ")\n", t->virt );
- } else if( t->mode != mode ){
- OFMEM_TRACE("mapping mode altered virt=" FMT_ucellx
- " old mode=" FMT_ucellx " new mode=" FMT_ucellx "\n",
- t->virt, t->mode, mode);
- }
-
- for( tt=&ofmem->trans; *tt != t ; tt=&(**tt).next ) {
- }
-
- *tt = t->next;
-
- /* really unmap these pages */
- ofmem_unmap_pages(t->virt, t->size);
-
- free((char*)t);
-
- t=ofmem->trans;
- continue;
- }
- t=t->next;
- }
-
- /* add mapping */
- for( tt=&ofmem->trans; *tt && (**tt).virt < virt ; tt=&(**tt).next ) {
- }
-
- t = (translation_t*)malloc( sizeof(translation_t) );
- t->virt = virt;
- t->phys = phys;
- t->size = size;
- t->mode = mode;
- t->next = *tt;
- *tt = t;
-
- ofmem_update_translations();
-
- return 0;
-}
-
-static int unmap_page_range( ucell virt, ucell size )
-{
- ofmem_t *ofmem = OFMEM;
- translation_t **plink;
-
- /* make sure there is exactly one matching translation entry */
-
- split_trans( virt );
- split_trans( virt + size );
-
- /* find and unlink entries in range */
- plink = &ofmem->trans;
-
- while (*plink && (*plink)->virt < virt+size) {
- translation_t **plinkentry = plink;
- translation_t *t = *plink;
-
- /* move ahead */
- plink = &t->next;
-
- if (t->virt >= virt && t->virt + t->size <= virt+size) {
-
- /* unlink entry */
- *plinkentry = t->next;
-
- printk("unmap_page_range found " FMT_ucellx
- " -> " FMT_ucellx " " FMT_ucellx " mode " FMT_ucellx "\n",
- t->virt, t->phys, t->size, t->mode );
-
- // really map these pages
- ofmem_unmap_pages(t->virt, t->size);
-
- free((char*)t);
- }
- }
-
- ofmem_update_translations();
-
- return 0;
-}
-
-int ofmem_map( ucell phys, ucell virt, ucell size, ucell mode )
-{
- /* printk("+ofmem_map: %08lX --> %08lX (size %08lX, mode 0x%02X)\n",
- virt, phys, size, mode ); */
-
- if( (phys & 0xfff) || (virt & 0xfff) || (size & 0xfff) ) {
- /* printk("ofmem_map: Bad parameters (%08lX %08lX %08lX)\n",
- phys, virt, size ); */
- phys &= ~0xfff;
- virt &= ~0xfff;
- size = (size + 0xfff) & ~0xfff;
- }
-
- if (mode==-1) {
- mode = def_memmode(phys);
- }
-
- // install translations
- map_page_range(phys, virt, size, mode);
-
- if (mode & SPITFIRE_TTE_LOCKED) {
- // install locked tlb entries now
- ofmem_map_pages(phys, virt, size, mode);
- }
-
- return 0;
-}
-
-int ofmem_unmap( ucell virt, ucell size )
-{
- OFMEM_TRACE("ofmem_unmap " FMT_ucellx " " FMT_ucellx "\n",
- virt, size );
-
- if( (virt & 0xfff) || (size & 0xfff) ) {
- /* printk("ofmem_unmap: Bad parameters (%08lX %08lX)\n",
- virt, size ); */
- virt &= ~0xfff;
- size = (size + 0xfff) & ~0xfff;
- }
-
- /* remove translations and unmap pages */
- unmap_page_range(virt, size);
-
- return 0;
-}
-
-/* virtual -> physical. */
-ucell ofmem_translate( ucell virt, ucell *mode )
-{
- ofmem_t *ofmem = OFMEM;
- translation_t *t;
-
- for( t=ofmem->trans; t && t->virt <= virt ; t=t->next ) {
- ucell offs;
- if( t->virt + t->size - 1 < virt )
- continue;
- offs = virt - t->virt;
- *mode = t->mode;
- return t->phys + offs;
- }
-
- /*printk("ofmem_translate: no translation defined (%08lx)\n", virt);*/
- /*print_trans();*/
- return -1UL;
-}
-
-/* release memory allocated by ofmem_claim */
-void ofmem_release( ucell virt, ucell size )
-{
- printk("ofmem_release unimplemented (" FMT_ucellx ", " FMT_ucellx ")\n",
- virt, size );
-}
-
-
-/************************************************************************/
/* init / cleanup */
/************************************************************************/
@@ -636,12 +83,12 @@
static int remap_page_range( ucell phys, ucell virt, ucell size, ucell mode )
{
- map_page_range(phys, virt, size, mode);
+ ofmem_map_page_range(phys, virt, size, mode);
if (!(mode & SPITFIRE_TTE_LOCKED)) {
OFMEM_TRACE("remap_page_range clearing translation " FMT_ucellx
" -> " FMT_ucellx " " FMT_ucellx " mode " FMT_ucellx "\n",
virt, phys, size, mode );
- ofmem_unmap_pages(virt, size);
+ ofmem_arch_unmap_pages(virt, size);
}
return 0;
}
@@ -655,10 +102,3 @@
ofmem_walk_boot_map(remap_page_range);
}
-void ofmem_register( phandle_t ph_memory, phandle_t ph_mmu )
-{
- s_phandle_memory = ph_memory;
- s_phandle_mmu = ph_mmu;
-
- ofmem_update_translations();
-}
Modified: trunk/openbios-devel/arch/sparc64/ofmem_sparc64.h
===================================================================
--- trunk/openbios-devel/arch/sparc64/ofmem_sparc64.h 2009-08-02 11:07:13 UTC (rev 527)
+++ trunk/openbios-devel/arch/sparc64/ofmem_sparc64.h 2009-08-02 11:08:01 UTC (rev 528)
@@ -16,54 +16,13 @@
#include "ofmem.h"
-extern void* ofmem_malloc( size_t size );
-extern void ofmem_free( void *ptr );
-extern void* ofmem_realloc( void *ptr, size_t size );
-
-extern int ofmem_unmap(ucell virt, ucell size);
-
-ulong get_ram_size( void );
-ulong get_ram_top( void );
-ulong get_ram_bottom( void );
-extern void ofmem_register( phandle_t ph_memory, phandle_t ph_mmu );
extern void ofmem_map_pages(ucell phys, ucell virt, ucell size, ucell mode);
-extern void ofmem_unmap_pages(ucell virt, ucell size);
typedef int (*translation_entry_cb)(ucell phys, ucell virt,
ucell size, ucell mode);
extern void ofmem_walk_boot_map(translation_entry_cb cb);
-typedef struct alloc_desc {
- struct alloc_desc *next;
- ucell size; /* size (including) this struct */
-} alloc_desc_t;
-
-typedef struct mem_range {
- struct mem_range *next;
- ucell start;
- ucell size;
-} range_t;
-
-typedef struct trans {
- struct trans *next;
- ucell virt; /* chain is sorted by virt */
- ucell size;
- ucell phys;
- ucell mode;
-} translation_t;
-
-typedef struct {
- uint64_t ramsize;
- char *next_malloc;
- alloc_desc_t *mfree; /* list of free malloc blocks */
-
- range_t *phys_range;
- range_t *virt_range;
-
- translation_t *trans; /* this is really a translation_t */
-} ofmem_t;
-
extern translation_t **g_ofmem_translations;
#endif /* _H_OFMEM_SPARC64 */
Modified: trunk/openbios-devel/config/examples/cross-sparc64_config.xml
===================================================================
--- trunk/openbios-devel/config/examples/cross-sparc64_config.xml 2009-08-02 11:07:13 UTC (rev 527)
+++ trunk/openbios-devel/config/examples/cross-sparc64_config.xml 2009-08-02 11:08:01 UTC (rev 528)
@@ -38,6 +38,8 @@
<option name="CONFIG_DEBLOCKER" type="boolean" value="true"/>
<option name="CONFIG_FONT_8X8" type="boolean" value="true"/>
<option name="CONFIG_FONT_8X16" type="boolean" value="false"/>
+ <option name="CONFIG_OFMEM" type="boolean" value="true"/>
+ <option name="CONFIG_OFMEM_MALLOC_ALIGN" type="integer" value="8"/>
<!-- Filesystem Configuration -->
<option name="CONFIG_DISK_LABEL" type="boolean" value="true"/>
1
0