OpenBIOS
Threads by month
- ----- 2026 -----
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- 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
October 2010
- 14 participants
- 92 discussions
[commit] r927 - in trunk/openbios-devel/config: examples scripts
by repository service Oct. 30, 2010
by repository service Oct. 30, 2010
Oct. 30, 2010
Author: afaerber
Date: Sat Oct 30 17:17:37 2010
New Revision: 927
URL: http://tracker.coreboot.org/trac/openbios/changeset/927
Log:
switch-arch: Prepare ppc64 support
Detect ppc64 as Big Endian and 64-bit.
Reuse arch/ppc/ wherever possible.
v3:
* Split off int128_t fix.
* Rebase to HEAD, add support for qemu-ppc64 target.
* Rename $INCLUDEARCH to $BASEARCH and initialize it earlier.
* Set both CONFIG_$BASEARCH and CONFIG_$ARCH if they differ.
* Use -fno-builtin.
* Add ppc64 config, copied from ppc.
v2:
* Use powerpc64 prefix.
* Disable fake int128_t for everything but sparc64.
Signed-off-by: Andreas Färber <andreas.faerber(a)web.de>
Added:
trunk/openbios-devel/config/examples/ppc64_config.xml
- copied unchanged from r926, trunk/openbios-devel/config/examples/ppc_config.xml
Modified:
trunk/openbios-devel/config/scripts/switch-arch
Copied: trunk/openbios-devel/config/examples/ppc64_config.xml (from r926, trunk/openbios-devel/config/examples/ppc_config.xml)
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ trunk/openbios-devel/config/examples/ppc64_config.xml Sat Oct 30 17:17:37 2010 (r927, copy of r926, trunk/openbios-devel/config/examples/ppc_config.xml)
@@ -0,0 +1,77 @@
+ <!-- Kernel Debugging -->
+ <option name="CONFIG_DEBUG" type="boolean" value="true"/>
+ <option name="CONFIG_DEBUG_BOOT" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_DSTACK" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_RSTACK" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_DICTIONARY" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_INTERNAL" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_INTERPRETER" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_CONSOLE" type="boolean" value="true"/>
+ <option name="CONFIG_DEBUG_CONSOLE_SERIAL" type="boolean" value="true"/>
+ <option name="CONFIG_SERIAL_PORT" type="integer" value="0"/>
+ <option name="CONFIG_SERIAL_SPEED" type="integer" value="115200"/>
+ <option name="CONFIG_DEBUG_CONSOLE_VGA" type="boolean" value="true"/>
+ <option name="CONFIG_DEBUG_OFMEM" type="boolean" value="false"/>
+
+
+ <!-- Module Configuration -->
+ <option name="CONFIG_CMDLINE" type="boolean" value="true"/>
+ <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="4"/>
+ <option name="CONFIG_VGA_WIDTH" type="integer" value="800"/>
+ <option name="CONFIG_VGA_HEIGHT" type="integer" value="600"/>
+ <option name="CONFIG_VGA_DEPTH" type="integer" value="8"/>
+ <option name="CONFIG_LOADER_AOUT" type="boolean" value="false"/>
+ <option name="CONFIG_LOADER_BOOTINFO" type="boolean" value="true"/>
+ <option name="CONFIG_LOADER_ELF" type="boolean" value="true"/>
+ <option name="CONFIG_LOADER_FCODE" type="boolean" value="false"/>
+ <option name="CONFIG_LOADER_FORTH" type="boolean" value="false"/>
+ <option name="CONFIG_LOADER_XCOFF" type="boolean" value="true"/>
+
+ <!-- Filesystem Configuration -->
+ <option name="CONFIG_DISK_LABEL" type="boolean" value="true"/>
+ <option name="CONFIG_PART_SUPPORT" type="boolean" value="true"/>
+ <option name="CONFIG_MAC_PARTS" type="boolean" value="true"/>
+ <option name="CONFIG_DEBUG_MAC_PARTS" type="boolean" value="false"/>
+ <option name="CONFIG_PC_PARTS" type="boolean" value="true"/>
+ <option name="CONFIG_HFS" type="boolean" value="true"/>
+ <option name="CONFIG_HFSP" type="boolean" value="true"/>
+ <option name="CONFIG_ISO9660" type="boolean" value="true"/>
+ <option name="CONFIG_EXT2" type="boolean" value="true"/>
+ <option name="CONFIG_GRUBFS" type="boolean" value="true"/>
+ <option name="CONFIG_FSYS_EXT2FS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_FAT" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_JFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_MINIX" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_REISERFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_XFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_UFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_ISO9660" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_FFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_VSTAFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_NTFS" type="boolean" value="false"/>
+ <option name="CONFIG_FSYS_AFFS" type="boolean" value="false"/>
+ <option name="CONFIG_DEBUG_FS" type="boolean" value="false"/>
+
+ <!-- Miscellaneous -->
+ <option name="CONFIG_LINUXBIOS" type="boolean" value="false"/>
+ <option name="CONFIG_RTAS" type="boolean" value="false"/>
+
+ <!-- Drivers -->
+ <option name="CONFIG_DRIVER_PCI" type="boolean" value="true"/>
+ <option name="CONFIG_DEBUG_PCI" type="boolean" value="false"/>
+ <option name="CONFIG_DRIVER_IDE" type="boolean" value="true"/>
+ <option name="CONFIG_IDE_NUM_CHANNELS" type="integer" value="2"/>
+ <option name="CONFIG_IDE_FIRST_UNIT" type="integer" value="1"/>
+ <option name="CONFIG_IDE_DEV_NAME" type="string" value="ata-%d"/>
+ <option name="CONFIG_IDE_DEV_TYPE" type="string" value="ata"/>
+ <option name="CONFIG_DEBUG_IDE" type="boolean" value="false"/>
+ <option name="CONFIG_DRIVER_ADB" type="boolean" value="true"/>
+ <option name="CONFIG_DRIVER_VGA" type="boolean" value="true"/>
+ <option name="CONFIG_DRIVER_MACIO" type="boolean" value="true"/>
+ <option name="CONFIG_DRIVER_ESCC" type="boolean" value="true"/>
+ <option name="CONFIG_DRIVER_FW_CFG" type="boolean" value="true"/>
+ <option name="CONFIG_FW_CFG_ADDR" type="integer" value="0xf0000510"/>
Modified: trunk/openbios-devel/config/scripts/switch-arch
==============================================================================
--- trunk/openbios-devel/config/scripts/switch-arch Sat Oct 30 15:35:07 2010 (r926)
+++ trunk/openbios-devel/config/scripts/switch-arch Sat Oct 30 17:17:37 2010 (r927)
@@ -12,7 +12,7 @@
printf "Add \"unix-\" prefix to compile openbios-unix executable (native only)\n"
printf "Add \"builtin-\" prefix to compile openbios-builtin executables\n\n"
printf "Without prefixes, builtin and unix targets are selected\n\n"
- printf "Special targets: mol-ppc briq-ppc pearpc-ppc qemu-ppc xbox-x86\n\n"
+ printf "Special targets: mol-ppc briq-ppc pearpc-ppc qemu-ppc qemu-ppc64 xbox-x86\n\n"
printf "Example: $0 builtin-sparc32 unix-amd64 builtin-amd64\n"
exit 0
fi
@@ -41,6 +41,7 @@
fi
if test "$target" = "powerpc" -o "$target" = "ppc" \
+ -o "$target" = "powerpc64" -o "$target" = "ppc64" \
-o "$target" = "mips" -o "$target" = "s390" \
-o "$target" = "sparc32" -o "$target" = "sparc64" \
-o "$target" = "m68k" -o "$target" = "armv4b"; then
@@ -52,6 +53,7 @@
# target long bits test
if test "$target" = "sparc64" -o "$target" = "ia64" \
-o "$target" = "amd64" -o "$target" = "x86_64" \
+ -o "$target" = "powerpc64" -o "$target" = "ppc64" \
-o "$target" = "alpha"; then
targetlongbits="64"
else
@@ -132,7 +134,7 @@
target_list=""
for target in $*; do
case $target in
- unix-*|builtin-*|plain-*|mol-ppc|briq-ppc|pearpc-ppc|qemu-ppc|xbox-x86)
+ unix-*|builtin-*|plain-*|mol-ppc|briq-ppc|pearpc-ppc|qemu-ppc|qemu-ppc64|xbox-x86)
target_list="$target_list $target"
;;
cross-*)
@@ -189,7 +191,7 @@
pearpc-ppc)
pearpc="yes"
;;
- builtin-ppc|qemu-ppc)
+ builtin-ppc|qemu-ppc|builtin-ppc64|qemu-ppc64)
qemu="yes"
;;
xbox-x86)
@@ -215,6 +217,7 @@
esac
done
+ BASEARCH=$ARCH
case $ARCH in
amd64)
select_prefix x86_64
@@ -232,6 +235,13 @@
AS_FLAGS=
;;
+ ppc64)
+ select_prefix powerpc64
+ CFLAGS="-Wa,-a64 -m64 -msoft-float -fno-builtin"
+ AS_FLAGS="-Wa,-a64"
+ BASEARCH=ppc
+ ;;
+
sparc32)
select_prefix sparc
CFLAGS="-Wa,-xarch=v8 -Wa,-32 -m32 -mcpu=supersparc -fno-builtin"
@@ -279,7 +289,7 @@
mkdir -p $OBJDIR/host/include
mkdir -p $OBJDIR/host/kernel
mkdir -p $OBJDIR/forth
- ln -s ../../../include/arch/$ARCH $OBJDIR/target/include/asm
+ ln -s ../../../include/arch/$BASEARCH $OBJDIR/target/include/asm
#compile the host binary with target settings instead
#ln -s ../../../include/arch/$HOSTARCH $OBJDIR/host/include/asm
if [ "$mol" = "yes" ]; then
@@ -328,6 +338,9 @@
echo "<?xml version=\"1.0\"?><config>" > $ODIR/config.xml
# Generic
config_set_boolean CONFIG_$ARCH >> $ODIR/config.xml
+ if [ "$BASEARCH" != "$ARCH" ]; then
+ config_set_boolean CONFIG_$BASEARCH >> $ODIR/config.xml
+ fi
if [ "$mol" = "yes" ]; then
config_set_boolean CONFIG_MOL >> $ODIR/config.xml
fi
1
0
Oct. 30, 2010
Author: afaerber
Date: Sat Oct 30 15:35:07 2010
New Revision: 926
URL: http://tracker.coreboot.org/trac/openbios/changeset/926
Log:
switch-arch: Force cross-compilation on Mac OS X host
r879 broke ppc cross-compilation from Darwin/ppc host.
Symptom is that the assembler chokes on arch/ppc/qemu/start.S.
Always use a cross-compiler on Darwin host
since *-apple-darwin*-{gcc,ld} would produce Mach-O binaries.
Signed-off-by: Andreas Färber <andreas.faerber(a)web.de>
Modified:
trunk/openbios-devel/config/scripts/switch-arch
Modified: trunk/openbios-devel/config/scripts/switch-arch
==============================================================================
--- trunk/openbios-devel/config/scripts/switch-arch Sat Oct 30 15:18:31 2010 (r925)
+++ trunk/openbios-devel/config/scripts/switch-arch Sat Oct 30 15:35:07 2010 (r926)
@@ -250,7 +250,7 @@
AS_FLAGS="-Wa,-32"
;;
esac
- if [ "$ARCH" != "$HOSTARCH" ]; then
+ if [ "$ARCH" != "$HOSTARCH" -o `uname -s` = "Darwin" ]; then
cross="yes"
fi
crosscflags $HOSTARCH $ARCH
1
0
Author: mcayland
Date: Sat Oct 30 15:18:31 2010
New Revision: 925
URL: http://tracker.coreboot.org/trac/openbios/changeset/925
Log:
Alter SPARC32 memory routines so that they also update the relevant /memory and /virtual-memory properties.
The existing routines hard-coded the initial values into the device tree at startup, and then didn't update them which could
allow the romvec memory lists and the device tree memory properties to become out of sync.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)siriusit.co.uk>
Modified:
trunk/openbios-devel/arch/sparc32/lib.c
Modified: trunk/openbios-devel/arch/sparc32/lib.c
==============================================================================
--- trunk/openbios-devel/arch/sparc32/lib.c Sat Oct 30 14:22:06 2010 (r924)
+++ trunk/openbios-devel/arch/sparc32/lib.c Sat Oct 30 15:18:31 2010 (r925)
@@ -61,6 +61,12 @@
static unsigned long *context_table;
static unsigned long *l1;
+static phandle_t s_phandle_memory = 0;
+static phandle_t s_phandle_mmu = 0;
+static ucell *mem_reg = 0;
+static ucell *mem_avail = 0;
+static ucell *virt_avail = 0;
+
static struct linux_mlist_v0 totphys[1];
static struct linux_mlist_v0 totmap[1];
static struct linux_mlist_v0 totavail[1];
@@ -407,6 +413,24 @@
}
static void
+update_memory_properties(void)
+{
+ /* Update the device tree memory properties from the master
+ totphys, totmap and totavail romvec arrays */
+ mem_reg[0] = 0;
+ mem_reg[1] = pointer2cell(totphys[0].start_adr);
+ mem_reg[2] = totphys[0].num_bytes;
+
+ virt_avail[0] = 0;
+ virt_avail[1] = 0;
+ virt_avail[2] = pointer2cell(totmap[0].start_adr);
+
+ mem_avail[0] = 0;
+ mem_avail[1] = pointer2cell(totavail[0].start_adr);
+ mem_avail[2] = totavail[0].num_bytes;
+}
+
+static void
init_romvec_mem(void)
{
ptphys = totphys;
@@ -428,6 +452,13 @@
totmap[0].start_adr = &_start;
totmap[0].num_bytes = (unsigned long) &_iomem -
(unsigned long) &_start + PAGE_SIZE;
+
+ /* Pointers to device tree memory properties */
+ mem_reg = malloc(sizeof(ucell) * 3);
+ mem_avail = malloc(sizeof(ucell) * 3);
+ virt_avail = malloc(sizeof(ucell) * 3);
+
+ update_memory_properties();
}
char *obp_dumb_mmap(char *va, int which_io, unsigned int pa,
@@ -447,8 +478,6 @@
char *obp_dumb_memalloc(char *va, unsigned int size)
{
- static unsigned int next_free_address = 0xFFEDA000;
-
size = (size + 7) & ~7;
// XXX should use normal memory alloc
totavail[0].num_bytes -= size;
@@ -461,14 +490,16 @@
// ROM.
if (va == NULL) {
- // XXX should register virtual memory allocation
- va = (char *)(next_free_address - size);
- next_free_address -= size;
+ va = (char *)(totmap[0].start_adr - size);
+ totmap[0].start_adr -= size;
+ totmap[0].num_bytes += size;
DPRINTF("obp_dumb_memalloc req null -> 0x%p\n", va);
}
map_pages((unsigned long)va, totavail[0].num_bytes, 0, size);
+ update_memory_properties();
+
return va;
}
@@ -481,62 +512,51 @@
void
ob_init_mmu(void)
{
+ init_romvec_mem();
+
+ /* Find the phandles for the /memory and /virtual-memory nodes */
push_str("/memory");
- fword("find-device");
+ fword("find-package");
+ POP();
+ s_phandle_memory = POP();
- PUSH(0);
- fword("encode-int");
- PUSH(0);
- fword("encode-int");
- fword("encode+");
- PUSH(qemu_mem_size);
- fword("encode-int");
- fword("encode+");
- push_str("reg");
- fword("property");
+ push_str("/virtual-memory");
+ fword("find-package");
+ POP();
+ s_phandle_mmu = POP();
- PUSH(0);
- fword("encode-int");
- PUSH(0);
- fword("encode-int");
- fword("encode+");
- PUSH(va2pa((unsigned long)&_start) - PAGE_SIZE);
- fword("encode-int");
- fword("encode+");
- push_str("available");
- fword("property");
+ /* Setup /memory:reg (totphys) property */
+ push_str("/memory");
+ fword("find-device");
+ PUSH(pointer2cell(mem_reg));
+ PUSH(3 * sizeof(ucell));
+ push_str("reg");
+ PUSH_ph(s_phandle_memory);
+ fword("encode-property");
+ /* Setup /virtual-memory:avail (totmap) property */
push_str("/virtual-memory");
fword("find-device");
+ PUSH(pointer2cell(virt_avail));
+ PUSH(3 * sizeof(ucell));
+ push_str("available");
+ PUSH_ph(s_phandle_mmu);
+ fword("encode-property");
- PUSH(0);
- fword("encode-int");
- PUSH(0);
- fword("encode-int");
- fword("encode+");
- PUSH((unsigned long)&_start - PAGE_SIZE);
- fword("encode-int");
- fword("encode+");
-
- PUSH(0);
- fword("encode-int");
- fword("encode+");
- PUSH(va2pa((unsigned long)&_iomem));
- fword("encode-int");
- fword("encode+");
- PUSH(-va2pa((unsigned long)&_iomem));
- fword("encode-int");
- fword("encode+");
+ /* Setup /memory:avail (totavail) property */
+ push_str("/memory");
+ fword("find-device");
+ PUSH(pointer2cell(mem_avail));
+ PUSH(3 * sizeof(ucell));
push_str("available");
- fword("property");
+ PUSH_ph(s_phandle_memory);
+ fword("encode-property");
PUSH(0);
fword("active-package!");
bind_func("pgmap@", pgmap_fetch);
bind_func("pgmap!", pgmap_store);
bind_func("map-pages", ob_map_pages);
-
- init_romvec_mem();
}
/*
1
0
Author: afaerber
Date: Sat Oct 30 14:22:06 2010
New Revision: 924
URL: http://tracker.coreboot.org/trac/openbios/changeset/924
Log:
adb: Don't assume that pointers fit in 32 bits
The adb_dev_t state field is used to store a adb_kbd_t pointer.
It is unused in the mouse driver.
v2:
* Change field type from uint32_t to void* to avoid uintptr_t casts
in keyboard driver.
Signed-off-by: Andreas Färber <andreas.faerber(a)web.de>
Acked-by: Alexander Graf <agraf(a)suse.de>
Modified:
trunk/openbios-devel/drivers/adb_bus.h
trunk/openbios-devel/drivers/adb_kbd.c
Modified: trunk/openbios-devel/drivers/adb_bus.h
==============================================================================
--- trunk/openbios-devel/drivers/adb_bus.h Thu Oct 28 22:53:58 2010 (r923)
+++ trunk/openbios-devel/drivers/adb_bus.h Sat Oct 30 14:22:06 2010 (r924)
@@ -32,7 +32,7 @@
adb_bus_t *bus;
uint8_t addr;
uint8_t type;
- uint32_t state;
+ void *state;
};
#define ADB_BUF_SIZE 8
Modified: trunk/openbios-devel/drivers/adb_kbd.c
==============================================================================
--- trunk/openbios-devel/drivers/adb_kbd.c Thu Oct 28 22:53:58 2010 (r923)
+++ trunk/openbios-devel/drivers/adb_kbd.c Sat Oct 30 14:22:06 2010 (r924)
@@ -483,7 +483,7 @@
int key;
int ret;
- kbd = (void *)dev->state;
+ kbd = dev->state;
if (kbd->len > 0) {
ret = kbd->sequence[kbd->len-- - 1];
@@ -531,7 +531,7 @@
ADB_kbd_us, ADB_sequences);
kbd->next_key = -1;
kbd->len = 0;
- dev->state = (int32_t)kbd;
+ dev->state = kbd;
my_adb_dev = dev;
}
1
0
Author: mcayland
Date: Thu Oct 28 22:53:58 2010
New Revision: 923
URL: http://tracker.coreboot.org/trac/openbios/changeset/923
Log:
Change SPARC32 memory allocator to allocate memory starting from just below the OpenBIOS image downwards.
The existing code appeared to be allocating memory from the wrong property (map rather than avail) and so rather than allocating
memory starting from just below the OpenBIOS image downwards, it was simply reducing the reported size of the OpenBIOS image.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)siriusit.co.uk>
Modified:
trunk/openbios-devel/arch/sparc32/lib.c
Modified: trunk/openbios-devel/arch/sparc32/lib.c
==============================================================================
--- trunk/openbios-devel/arch/sparc32/lib.c Mon Oct 25 22:48:45 2010 (r922)
+++ trunk/openbios-devel/arch/sparc32/lib.c Thu Oct 28 22:53:58 2010 (r923)
@@ -451,9 +451,9 @@
size = (size + 7) & ~7;
// XXX should use normal memory alloc
- totmap[0].num_bytes -= size;
+ totavail[0].num_bytes -= size;
DPRINTF("obp_dumb_memalloc va 0x%p size %x at 0x%x\n", va, size,
- totmap[0].num_bytes);
+ totavail[0].num_bytes);
// If va is null, the allocator is supposed to pick a "suitable" address.
// (See OpenSolaric prom_alloc.c) There's not any real guidance as
@@ -467,7 +467,7 @@
DPRINTF("obp_dumb_memalloc req null -> 0x%p\n", va);
}
- map_pages((unsigned long)va, totmap[0].num_bytes, 0, size);
+ map_pages((unsigned long)va, totavail[0].num_bytes, 0, size);
return va;
}
1
0
Oct. 26, 2010
Hi all,
As it still seems there are some memory issues with SPARC32 (even with
the new patches), I've just tried increasing the memory for the Forth
machine from 128K to 256K by making the following change in
arch/sparc32/openbios.c:
--- arch/sparc32/openbios.c (revision 918)
+++ arch/sparc32/openbios.c (working copy)
@@ -26,7 +26,7 @@
#define NO_QEMU_PROTOS
#include "arch/common/fw_cfg.h"
-#define MEMORY_SIZE (128*1024) /* 16K ram for hosted system */
+#define MEMORY_SIZE (256*1024) /* 16K ram for hosted system */
#define DICTIONARY_SIZE (256*1024) /* 256K for the dictionary */
#define UUID_FMT
"%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x"
#define FW_CFG_SUN4M_DEPTH (FW_CFG_ARCH_LOCAL + 0x00)
However, with this change in place OpenBIOS just freezes on boot after
emitting "Configuration device id QEMU version 1 machine id 32". Does
anyone know anything about the SPARC32 memory code to know why changing
this constant doesn't just work?
ATB,
Mark.
--
Mark Cave-Ayland - Senior Technical Architect
PostgreSQL - PostGIS
Sirius Corporation plc - control through freedom
http://www.siriusit.co.uk
t: +44 870 608 0063
Sirius Labs: http://www.siriusit.co.uk/labs
3
4
[commit] r922 - in trunk/openbios-devel: arch/ppc/qemu drivers fs/ext2 fs/grubfs fs/hfs fs/hfsplus fs/iso9660 kernel libc libopenbios packages
by repository service Oct. 25, 2010
by repository service Oct. 25, 2010
Oct. 25, 2010
Author: afaerber
Date: Mon Oct 25 22:48:45 2010
New Revision: 922
URL: http://tracker.coreboot.org/trac/openbios/changeset/922
Log:
Don't assume that pointer and cell size are identical, part 1
On ppc64, cell size is 32 bits but pointers are 64-bit.
Thus, direct casts result in warnings, treated as errors.
Use [u]intptr_t cast or cell2pointer and pointer2cell macros as necessary.
v2:
* Drop changes related to physical addresses since physical addresses may be
wider than pointers (e.g., 36 bits on sparc32, as pointed out by Blue).
* Drop changes to cell2pointer() and pointer2cell() for now.
Signed-off-by: Andreas Färber <andreas.faerber(a)web.de>
Modified:
trunk/openbios-devel/arch/ppc/qemu/kernel.c
trunk/openbios-devel/arch/ppc/qemu/main.c
trunk/openbios-devel/arch/ppc/qemu/methods.c
trunk/openbios-devel/arch/ppc/qemu/ofmem.c
trunk/openbios-devel/drivers/adb_kbd.c
trunk/openbios-devel/drivers/escc.c
trunk/openbios-devel/drivers/ide.c
trunk/openbios-devel/fs/ext2/ext2_fs.c
trunk/openbios-devel/fs/grubfs/grubfs_fs.c
trunk/openbios-devel/fs/hfs/hfs_fs.c
trunk/openbios-devel/fs/hfsplus/hfsp_fs.c
trunk/openbios-devel/fs/iso9660/iso9660_fs.c
trunk/openbios-devel/kernel/internal.c
trunk/openbios-devel/libc/diskio.c
trunk/openbios-devel/libc/extra.c
trunk/openbios-devel/libopenbios/bindings.c
trunk/openbios-devel/libopenbios/bootinfo_load.c
trunk/openbios-devel/libopenbios/elf_load.c
trunk/openbios-devel/libopenbios/initprogram.c
trunk/openbios-devel/libopenbios/ofmem_common.c
trunk/openbios-devel/libopenbios/xcoff_load.c
trunk/openbios-devel/packages/deblocker.c
trunk/openbios-devel/packages/disk-label.c
trunk/openbios-devel/packages/mac-parts.c
trunk/openbios-devel/packages/nvram.c
trunk/openbios-devel/packages/pc-parts.c
trunk/openbios-devel/packages/video.c
Modified: trunk/openbios-devel/arch/ppc/qemu/kernel.c
==============================================================================
--- trunk/openbios-devel/arch/ppc/qemu/kernel.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/arch/ppc/qemu/kernel.c Mon Oct 25 22:48:45 2010 (r922)
@@ -40,13 +40,13 @@
{
ucell addr = 0xdeadbeef;
- if( PC >= (ucell) dict && PC <= (ucell) dict + dicthead )
- addr = *(ucell *) PC;
+ if( PC >= pointer2cell(dict) && PC <= pointer2cell(dict) + dicthead )
+ addr = *(ucell *)cell2pointer(PC);
- printk("panic: segmentation violation at %x\n", (int)segv_addr);
- printk("dict=0x%x here=0x%x(dict+0x%x) pc=0x%x(dict+0x%x)\n",
- (int)dict, (int)(dict + dicthead), dicthead,
- PC, PC - (ucell) dict);
+ printk("panic: segmentation violation at 0x%p\n", segv_addr);
+ printk("dict=0x%p here=0x%p(dict+0x%x) pc=0x%x(dict+0x%x)\n",
+ dict, (char*)dict + dicthead, dicthead,
+ PC, PC - pointer2cell(dict));
printk("dstackcnt=%d rstackcnt=%d instruction=%x\n",
dstackcnt, rstackcnt, addr);
@@ -75,8 +75,8 @@
* to initialize the memory allocator
*/
- PUSH( (ucell)memory );
- PUSH( (ucell)memory + MEMORY_SIZE );
+ PUSH( pointer2cell(memory) );
+ PUSH( pointer2cell(memory) + MEMORY_SIZE );
}
int
Modified: trunk/openbios-devel/arch/ppc/qemu/main.c
==============================================================================
--- trunk/openbios-devel/arch/ppc/qemu/main.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/arch/ppc/qemu/main.c Mon Oct 25 22:48:45 2010 (r922)
@@ -183,7 +183,7 @@
kernel_size = fw_cfg_read_i32(FW_CFG_KERNEL_SIZE);
if (kernel_size) {
kernel_image = fw_cfg_read_i32(FW_CFG_KERNEL_ADDR);
- kernel_cmdline = (const char *) fw_cfg_read_i32(FW_CFG_KERNEL_CMDLINE);
+ kernel_cmdline = (const char *)(uintptr_t) fw_cfg_read_i32(FW_CFG_KERNEL_CMDLINE);
initrd_image = fw_cfg_read_i32(FW_CFG_INITRD_ADDR);
initrd_size = fw_cfg_read_i32(FW_CFG_INITRD_SIZE);
printk("[ppc] Kernel already loaded (0x%8.8lx + 0x%8.8lx) "
Modified: trunk/openbios-devel/arch/ppc/qemu/methods.c
==============================================================================
--- trunk/openbios-devel/arch/ppc/qemu/methods.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/arch/ppc/qemu/methods.c Mon Oct 25 22:48:45 2010 (r922)
@@ -71,7 +71,7 @@
tty_read( void )
{
int ch, len = POP();
- char *p = (char*)POP();
+ char *p = (char*)cell2pointer(POP());
int ret=0;
if( len > 0 ) {
@@ -91,7 +91,7 @@
tty_write( void )
{
int i, len = POP();
- char *p = (char*)POP();
+ char *p = (char*)cell2pointer(POP());
for( i=0; i<len; i++ )
putchar( *p++ );
RET( len );
Modified: trunk/openbios-devel/arch/ppc/qemu/ofmem.c
==============================================================================
--- trunk/openbios-devel/arch/ppc/qemu/ofmem.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/arch/ppc/qemu/ofmem.c Mon Oct 25 22:48:45 2010 (r922)
@@ -105,7 +105,7 @@
ofmem_t* ofmem_arch_get_private(void)
{
- return (ofmem_t*)(get_heap_top() - OFMEM_SIZE);
+ return (ofmem_t*)cell2pointer(get_heap_top() - OFMEM_SIZE);
}
void* ofmem_arch_get_malloc_base(void)
Modified: trunk/openbios-devel/drivers/adb_kbd.c
==============================================================================
--- trunk/openbios-devel/drivers/adb_kbd.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/drivers/adb_kbd.c Mon Oct 25 22:48:45 2010 (r922)
@@ -556,7 +556,7 @@
char *addr;
int len, key, i;
len=POP();
- addr=(char *)POP();
+ addr=(char *)cell2pointer(POP());
for (i = 0; i < len; i++) {
key = adb_kbd_read(my_adb_dev);
Modified: trunk/openbios-devel/drivers/escc.c
==============================================================================
--- trunk/openbios-devel/drivers/escc.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/drivers/escc.c Mon Oct 25 22:48:45 2010 (r922)
@@ -137,7 +137,7 @@
int len;
len = POP();
- addr = (char *)POP();
+ addr = (char *)cell2pointer(POP());
if (len < 1)
printk("escc_read: bad len, addr %x len %x\n", (unsigned int)addr, len);
@@ -158,7 +158,7 @@
int i, len;
len = POP();
- addr = (unsigned char *)POP();
+ addr = (unsigned char *)cell2pointer(POP());
for (i = 0; i < len; i++) {
uart_putchar(*address, addr[i]);
Modified: trunk/openbios-devel/drivers/ide.c
==============================================================================
--- trunk/openbios-devel/drivers/ide.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/drivers/ide.c Mon Oct 25 22:48:45 2010 (r922)
@@ -1190,7 +1190,7 @@
{
cell n = POP(), cnt=n;
ucell blk = POP();
- unsigned char *dest = (unsigned char *)POP();
+ unsigned char *dest = (unsigned char *)cell2pointer(POP());
struct ide_drive *drive = *(struct ide_drive **)idx;
IDE_DPRINTF("ob_ide_read_blocks %lx block=%ld n=%ld\n",
Modified: trunk/openbios-devel/fs/ext2/ext2_fs.c
==============================================================================
--- trunk/openbios-devel/fs/ext2/ext2_fs.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/fs/ext2/ext2_fs.c Mon Oct 25 22:48:45 2010 (r922)
@@ -144,7 +144,7 @@
ext2_files_read( ext2_info_t *mi )
{
int count = POP();
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
ext2_COMMON *common = mi->common;
if (common->type != FILE)
@@ -177,7 +177,7 @@
static void
ext2_files_load( ext2_info_t *mi )
{
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
int count;
ext2_COMMON *common = mi->common;
@@ -201,14 +201,14 @@
if (common->type != FILE)
RET( 0 );
- RET( (ucell) strdup(common->file->path) );
+ RET( pointer2cell(strdup(common->file->path)) );
}
/* ( -- cstr ) */
static void
ext2_files_get_fstype( ext2_info_t *mi )
{
- PUSH( (ucell)strdup("ext2") );
+ PUSH( pointer2cell(strdup("ext2")) );
}
/* static method, ( pathstr len ihandle -- ) */
Modified: trunk/openbios-devel/fs/grubfs/grubfs_fs.c
==============================================================================
--- trunk/openbios-devel/fs/grubfs/grubfs_fs.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/fs/grubfs/grubfs_fs.c Mon Oct 25 22:48:45 2010 (r922)
@@ -238,7 +238,7 @@
grubfs_files_read( grubfs_info_t *mi )
{
int count = POP();
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
grubfile_t *file = mi->gfs->fd;
int ret;
@@ -295,7 +295,7 @@
static void
grubfs_files_load( grubfs_info_t *mi )
{
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
int count, ret;
grubfile_t *file = mi->gfs->fd;
@@ -314,7 +314,7 @@
grubfile_t *file = mi->gfs->fd;
const char *path = file->path;
- RET( (ucell) strdup(path) );
+ RET( pointer2cell(strdup(path)) );
}
/* ( -- cstr ) */
@@ -323,7 +323,7 @@
{
grubfs_t *gfs = mi->gfs;
- PUSH( (ucell)strdup(gfs->fsys->name) );
+ PUSH( pointer2cell(strdup(gfs->fsys->name)) );
}
Modified: trunk/openbios-devel/fs/hfs/hfs_fs.c
==============================================================================
--- trunk/openbios-devel/fs/hfs/hfs_fs.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/fs/hfs/hfs_fs.c Mon Oct 25 22:48:45 2010 (r922)
@@ -359,7 +359,7 @@
hfs_files_read( hfs_info_t *mi )
{
int count = POP();
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
hfscommon *common = mi->common;
if (common->type != FILE)
@@ -402,7 +402,7 @@
static void
hfs_files_load( hfs_info_t *mi )
{
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
int count;
hfscommon *common = mi->common;
@@ -461,14 +461,14 @@
if( strlen(buf) >= sizeof(buf) )
RET( 0 );
- RET( (ucell) strdup(buf+start) );
+ RET( pointer2cell(strdup(buf+start)) );
}
/* ( -- cstr ) */
static void
hfs_files_get_fstype( hfs_info_t *mi )
{
- PUSH( (ucell)strdup("HFS") );
+ PUSH( pointer2cell(strdup("HFS")) );
}
/* ( -- cstr|0 ) */
@@ -486,7 +486,7 @@
volname[0] = '\0';
}
- PUSH ((ucell)volname);
+ PUSH(pointer2cell(volname));
}
/* static method, ( pathstr len ihandle -- ) */
Modified: trunk/openbios-devel/fs/hfsplus/hfsp_fs.c
==============================================================================
--- trunk/openbios-devel/fs/hfsplus/hfsp_fs.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/fs/hfsplus/hfsp_fs.c Mon Oct 25 22:48:45 2010 (r922)
@@ -264,7 +264,7 @@
hfsp_files_read( hfsp_info_t *mi )
{
int count = POP();
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
hfsp_file_t *t = mi->hfspfile;
volume *vol = t->rec.tree->vol;
@@ -350,7 +350,7 @@
static void
hfsp_files_load( hfsp_info_t *mi )
{
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
hfsp_file_t *t = mi->hfspfile;
volume *vol = t->rec.tree->vol;
@@ -388,7 +388,7 @@
static void
hfsp_files_get_fstype( hfsp_info_t *mi )
{
- PUSH( (ucell)strdup("HFS+") );
+ PUSH( pointer2cell(strdup("HFS+")) );
}
/* ( -- cstr ) */
@@ -405,7 +405,7 @@
strncpy( buf, t->path, strlen(t->path) );
buf[strlen(t->path)] = 0;
- PUSH ((ucell)buf);
+ PUSH(pointer2cell(buf));
}
/* ( -- success? ) */
@@ -434,7 +434,7 @@
volname[0] = '\0';
}
- PUSH ((ucell)volname);
+ PUSH(pointer2cell(volname));
}
/* static method, ( pathstr len ihandle -- ) */
Modified: trunk/openbios-devel/fs/iso9660/iso9660_fs.c
==============================================================================
--- trunk/openbios-devel/fs/iso9660/iso9660_fs.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/fs/iso9660/iso9660_fs.c Mon Oct 25 22:48:45 2010 (r922)
@@ -90,7 +90,7 @@
iso9660_files_read( iso9660_info_t *mi )
{
int count = POP();
- char *buf = (char *)POP();
+ char *buf = (char *)cell2pointer(POP());
int ret;
if ( mi->common->type != FILE )
@@ -137,7 +137,7 @@
static void
iso9660_files_load( iso9660_info_t *mi)
{
- char *buf = (char*)POP();
+ char *buf = (char*)cell2pointer(POP());
int ret, size;
if ( mi->common->type != FILE )
Modified: trunk/openbios-devel/kernel/internal.c
==============================================================================
--- trunk/openbios-devel/kernel/internal.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/kernel/internal.c Mon Oct 25 22:48:45 2010 (r922)
@@ -208,7 +208,7 @@
exit(1);
#else
void (*funcptr) (void);
- funcptr=(void *)POP();
+ funcptr=(void *)cell2pointer(POP());
dbg_interp_printk("call: %x", funcptr);
funcptr();
#endif
@@ -329,7 +329,7 @@
#ifndef FCOMPILER
static ucell get_myself(void)
{
- static ucell **myself = NULL;
+ static ucell **myself = NULL;
if( !myself )
myself = (ucell**)findword("my-self") + 1;
return (*myself && **myself) ? (ucell)**myself : 0;
@@ -337,35 +337,35 @@
static void doivar(void)
{
- ucell r, *p = (ucell *)(*(ucell *) PC + sizeof(ucell));
+ ucell r, *p = (ucell *)(*(ucell *) cell2pointer(PC) + sizeof(ucell));
ucell ibase = get_myself();
dbg_interp_printk("ivar, offset: %d size: %d (ibase %d)\n", p[0], p[1], ibase );
- r = ibase ? ibase + p[0] : (ucell)&p[2];
+ r = ibase ? ibase + p[0] : pointer2cell(&p[2]);
PUSH( r );
}
static void doival(void)
{
- ucell r, *p = (ucell *)(*(ucell *) PC + sizeof(ucell));
+ ucell r, *p = (ucell *)(*(ucell *) cell2pointer(PC) + sizeof(ucell));
ucell ibase = get_myself();
dbg_interp_printk("ivar, offset: %d size: %d\n", p[0], p[1] );
- r = ibase ? ibase + p[0] : (ucell)&p[2];
- PUSH( *(ucell *)r );
+ r = ibase ? ibase + p[0] : pointer2cell(&p[2]);
+ PUSH( *(ucell *)cell2pointer(r) );
}
static void doidefer(void)
{
- ucell *p = (ucell *)(*(ucell *) PC + sizeof(ucell));
+ ucell *p = (ucell *)(*(ucell *) cell2pointer(PC) + sizeof(ucell));
ucell ibase = get_myself();
dbg_interp_printk("doidefer, offset: %d size: %d\n", p[0], p[1] );
PUSHR(PC);
- PC = ibase ? ibase + p[0] : (ucell)&p[2];
+ PC = ibase ? ibase + p[0] : pointer2cell(&p[2]);
PC -= sizeof(ucell);
}
#else
Modified: trunk/openbios-devel/libc/diskio.c
==============================================================================
--- trunk/openbios-devel/libc/diskio.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libc/diskio.c Mon Oct 25 22:48:45 2010 (r922)
@@ -150,7 +150,7 @@
if( lookup_xt(fdp->ih, "get-path", &fdp->get_path_xt) )
return NULL;
call_package( fdp->get_path_xt, fdp->ih );
- return (char*)POP();
+ return (char*)cell2pointer(POP());
}
const char *
@@ -160,7 +160,7 @@
if( lookup_xt(fdp->ih, "volume-name", &fdp->volume_name_xt) )
return NULL;
call_package( fdp->volume_name_xt, fdp->ih );
- return (char*)POP();
+ return (char*)cell2pointer(POP());
}
const char *
@@ -170,7 +170,7 @@
if( lookup_xt(fdp->ih, "get-fstype", &fdp->get_fstype_xt) )
return NULL;
call_package( fdp->get_fstype_xt, fdp->ih );
- return (char*)POP();
+ return (char*)cell2pointer(POP());
}
int
@@ -183,7 +183,7 @@
if (fd != -1) {
fdp = file_descriptors[fd];
- PUSH( (ucell)buf );
+ PUSH( pointer2cell(buf) );
PUSH( cnt );
call_package( fdp->read_xt, fdp->ih );
ret = POP();
Modified: trunk/openbios-devel/libc/extra.c
==============================================================================
--- trunk/openbios-devel/libc/extra.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libc/extra.c Mon Oct 25 22:48:45 2010 (r922)
@@ -39,7 +39,7 @@
i = vsnprintf(buf, sizeof(buf), fmt, args);
va_end(args);
- PUSH((ucell)buf);
+ PUSH(pointer2cell(buf));
PUSH(i);
fword("type");
Modified: trunk/openbios-devel/libopenbios/bindings.c
==============================================================================
--- trunk/openbios-devel/libopenbios/bindings.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libopenbios/bindings.c Mon Oct 25 22:48:45 2010 (r922)
@@ -28,7 +28,7 @@
void
push_str( const char *str )
{
- PUSH( (ucell)str );
+ PUSH( pointer2cell(str) );
PUSH( str ? strlen(str) : 0 );
}
@@ -101,7 +101,7 @@
void
bind_func( const char *name, void (*func)(void) )
{
- PUSH( (ucell)func );
+ PUSH( pointer2cell(func) );
push_str( name );
fword("is-cfunc");
}
@@ -111,7 +111,7 @@
{
PUSH_xt( xt );
PUSH( arg );
- PUSH( (cell)func );
+ PUSH( pointer2cell(func) );
push_str( name );
fword("is-xt-cfunc");
}
@@ -119,7 +119,7 @@
xt_t
bind_noname_func( void (*func)(void) )
{
- PUSH( (ucell)func );
+ PUSH( pointer2cell(func) );
fword("is-noname-cfunc");
return POP_xt();
}
@@ -249,7 +249,7 @@
pop_fstr_copy( void )
{
int len = POP();
- char *str, *p = (char*)POP();
+ char *str, *p = (char*)cell2pointer(POP());
if( !len )
return NULL;
str = malloc( len + 1 );
@@ -279,7 +279,7 @@
printk("set_property: NULL phandle\n");
return;
}
- PUSH((ucell)buf);
+ PUSH(pointer2cell(buf));
PUSH(len);
push_str( name );
PUSH_ph(ph);
@@ -309,7 +309,7 @@
len = POP();
if( retlen )
*retlen = len;
- return (char*)POP();
+ return (char*)cell2pointer(POP());
}
u32
@@ -426,7 +426,7 @@
call1_func( void )
{
void (*func)(cell v);
- func = (void*)POP();
+ func = (void*)cell2pointer(POP());
(*func)( POP() );
}
@@ -455,7 +455,7 @@
char *buf = NULL;
if( xt ) {
enterforth( xt );
- buf = (char*)POP();
+ buf = (char*)cell2pointer(POP());
}
(*(initfunc)methods[i].func)( buf );
continue;
@@ -463,7 +463,7 @@
if( !size )
bind_func( methods[i].name, methods[i].func );
else
- bind_xtfunc( methods[i].name, xt, (ucell)methods[i].func,
+ bind_xtfunc( methods[i].name, xt, pointer2cell(methods[i].func),
&call1_func );
}
Modified: trunk/openbios-devel/libopenbios/bootinfo_load.c
==============================================================================
--- trunk/openbios-devel/libopenbios/bootinfo_load.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libopenbios/bootinfo_load.c Mon Oct 25 22:48:45 2010 (r922)
@@ -156,7 +156,7 @@
filename = get_filename(bootpath, &directory);
feval("load-base");
- base = (char*)POP();
+ base = (char*)cell2pointer(POP());
feval("load-size");
size = POP();
Modified: trunk/openbios-devel/libopenbios/elf_load.c
==============================================================================
--- trunk/openbios-devel/libopenbios/elf_load.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libopenbios/elf_load.c Mon Oct 25 22:48:45 2010 (r922)
@@ -478,12 +478,12 @@
Elf_phdr *phdr;
size_t size, total_size = 0;
char *addr;
- cell tmp;
+ uintptr_t tmp;
/* TODO: manage ELF notes section */
feval("0 state-valid !");
feval("load-base");
- base = (char*)POP();
+ base = (char*)cell2pointer(POP());
ehdr = (Elf_ehdr *)base;
Modified: trunk/openbios-devel/libopenbios/initprogram.c
==============================================================================
--- trunk/openbios-devel/libopenbios/initprogram.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libopenbios/initprogram.c Mon Oct 25 22:48:45 2010 (r922)
@@ -41,42 +41,42 @@
addr = POP();
#ifdef CONFIG_LOADER_AOUT
- if (is_aout((struct exec *)addr)) {
+ if (is_aout((struct exec *)cell2pointer(addr))) {
aout_init_program();
return;
}
#endif
#ifdef CONFIG_LOADER_BOOTINFO
- if (is_bootinfo((char *)addr)) {
+ if (is_bootinfo((char *)cell2pointer(addr))) {
bootinfo_init_program();
return;
}
#endif
#ifdef CONFIG_LOADER_ELF
- if (is_elf((Elf_ehdr *)addr)) {
+ if (is_elf((Elf_ehdr *)cell2pointer(addr))) {
elf_init_program();
return;
}
#endif
#ifdef CONFIG_LOADER_FCODE
- if (is_fcode((unsigned char *)addr)) {
+ if (is_fcode((unsigned char *)cell2pointer(addr))) {
fcode_init_program();
return;
}
#endif
#ifdef CONFIG_LOADER_FORTH
- if (is_forth((char *)addr)) {
+ if (is_forth((char *)cell2pointer(addr))) {
forth_init_program();
return;
}
#endif
#ifdef CONFIG_LOADER_XCOFF
- if (is_xcoff((COFF_filehdr_t *)addr)) {
+ if (is_xcoff((COFF_filehdr_t *)cell2pointer(addr))) {
xcoff_init_program();
return;
}
Modified: trunk/openbios-devel/libopenbios/ofmem_common.c
==============================================================================
--- trunk/openbios-devel/libopenbios/ofmem_common.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libopenbios/ofmem_common.c Mon Oct 25 22:48:45 2010 (r922)
@@ -110,7 +110,7 @@
top = ofmem_arch_get_heap_top();
- if( (ucell)ofmem->next_malloc + size > top ) {
+ if( pointer2cell(ofmem->next_malloc) + size > top ) {
printk("out of malloc memory (%x)!\n", size );
return NULL;
}
@@ -183,10 +183,9 @@
printk("ofmem_set_property: NULL phandle\n");
return;
}
- PUSH((ucell)buf);
+ PUSH(pointer2cell(buf));
PUSH(len);
- PUSH((ucell)name);
- PUSH(strlen(name));
+ push_str(name);
PUSH_ph(ph);
fword("encode-property");
}
Modified: trunk/openbios-devel/libopenbios/xcoff_load.c
==============================================================================
--- trunk/openbios-devel/libopenbios/xcoff_load.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/libopenbios/xcoff_load.c Mon Oct 25 22:48:45 2010 (r922)
@@ -64,7 +64,7 @@
feval("0 state-valid !");
feval("load-base");
- base = (char*)POP();
+ base = (char*)cell2pointer(POP());
fhdr = (COFF_filehdr_t*)base;
@@ -111,22 +111,22 @@
if (strcmp(shdr->s_name, ".text") == 0) {
- memcpy((char*)shdr->s_vaddr, base + shdr->s_scnptr,
+ memcpy((char*)(uintptr_t)shdr->s_vaddr, base + shdr->s_scnptr,
shdr->s_size);
total_size += shdr->s_size;
#ifdef CONFIG_PPC
- flush_icache_range((char*)shdr->s_vaddr,
- (char*)(shdr->s_vaddr + shdr->s_size));
+ flush_icache_range((char*)(uintptr_t)shdr->s_vaddr,
+ (char*)(uintptr_t)(shdr->s_vaddr + shdr->s_size));
#endif
} else if (strcmp(shdr->s_name, ".data") == 0) {
- memcpy((char*)shdr->s_vaddr, base + shdr->s_scnptr,
+ memcpy((char*)(uintptr_t)shdr->s_vaddr, base + shdr->s_scnptr,
shdr->s_size);
total_size += shdr->s_size;
} else if (strcmp(shdr->s_name, ".bss") == 0) {
- memset((void *)shdr->s_vaddr, 0, shdr->s_size);
+ memset((void *)(uintptr_t)shdr->s_vaddr, 0, shdr->s_size);
total_size += shdr->s_size;
} else {
DPRINTF(" Skip '%s' section\n", shdr->s_name);
@@ -137,7 +137,7 @@
DPRINTF("XCOFF entry point: %x\n", *(uint32_t*)ahdr->entry);
// Initialise saved-program-state
- PUSH(*(uint32_t*)ahdr->entry);
+ PUSH(*(uint32_t*)(uintptr_t)ahdr->entry);
feval("saved-program-state >sps.entry !");
PUSH(total_size);
feval("saved-program-state >sps.file-size !");
Modified: trunk/openbios-devel/packages/deblocker.c
==============================================================================
--- trunk/openbios-devel/packages/deblocker.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/packages/deblocker.c Mon Oct 25 22:48:45 2010 (r922)
@@ -96,7 +96,7 @@
#define DO_IO( xt, buf, blk, n ) \
- ({ PUSH3((ucell)(buf), blk, n); call_parent(xt); POP(); })
+ ({ PUSH3(pointer2cell(buf), blk, n); call_parent(xt); POP(); })
typedef struct {
/* block operation */
@@ -141,7 +141,7 @@
do_readwrite( deblk_info_t *di, int is_write, xt_t xt )
{
int blk, i, n, len = POP();
- char *dest = (char*)POP();
+ char *dest = (char*)cell2pointer(POP());
int last=0, retlen=0;
work_t w[3];
ducell mark = ((ducell)di->mark_hi << BITS) | di->mark_lo;
Modified: trunk/openbios-devel/packages/disk-label.c
==============================================================================
--- trunk/openbios-devel/packages/disk-label.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/packages/disk-label.c Mon Oct 25 22:48:45 2010 (r922)
@@ -80,7 +80,7 @@
call_package(di->parent_seek_xt, my_parent());
POP();
- PUSH((ucell)block0);
+ PUSH(pointer2cell(block0));
PUSH(sizeof(block0));
call_package(di->parent_read_xt, my_parent());
status = POP();
@@ -88,7 +88,7 @@
goto out;
/* Find partition handler */
- PUSH( (ucell)block0 );
+ PUSH( pointer2cell(block0) );
selfword("find-part-handler");
ph = POP_ph();
if( ph ) {
Modified: trunk/openbios-devel/packages/mac-parts.c
==============================================================================
--- trunk/openbios-devel/packages/mac-parts.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/packages/mac-parts.c Mon Oct 25 22:48:45 2010 (r922)
@@ -42,7 +42,7 @@
DECLARE_NODE( macparts, INSTALL_OPEN, sizeof(macparts_info_t), "+/packages/mac-parts" );
#define SEEK( pos ) ({ DPUSH(pos); call_parent(di->seek_xt); POP(); })
-#define READ( buf, size ) ({ PUSH((ucell)buf); PUSH(size); call_parent(di->read_xt); POP(); })
+#define READ( buf, size ) ({ PUSH(pointer2cell(buf)); PUSH(size); call_parent(di->read_xt); POP(); })
/* ( open -- flag ) */
static void
@@ -267,7 +267,7 @@
static void
macparts_probe( macparts_info_t *dummy )
{
- desc_map_t *dmap = (desc_map_t*)POP();
+ desc_map_t *dmap = (desc_map_t*)cell2pointer(POP());
DPRINTF("macparts_probe %x ?= %x\n", dmap->sbSig, DESC_MAP_SIGNATURE);
if( __be16_to_cpu(dmap->sbSig) != DESC_MAP_SIGNATURE )
Modified: trunk/openbios-devel/packages/nvram.c
==============================================================================
--- trunk/openbios-devel/packages/nvram.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/packages/nvram.c Mon Oct 25 22:48:45 2010 (r922)
@@ -167,7 +167,7 @@
void
update_nvram( void )
{
- PUSH( (ucell)nvram.config->data );
+ PUSH( pointer2cell(nvram.config->data) );
PUSH( nvram.config_size );
fword("nvram-store-configs");
arch_nvram_put( nvram.data );
@@ -202,7 +202,7 @@
nvram.config_size = nvpart_size(p) - 0x10;
if( !once++ ) {
- PUSH( (ucell)p->data );
+ PUSH( pointer2cell(p->data) );
PUSH( nvram.config_size );
fword("nvram-load-configs");
}
@@ -256,7 +256,7 @@
nvram_read( nvram_ibuf_t *nd )
{
int len = POP();
- char *p = (char*)POP();
+ char *p = (char*)cell2pointer(POP());
int n=0;
while( nd->mark_lo < nvram.size && n < len ) {
@@ -272,7 +272,7 @@
nvram_write( nvram_ibuf_t *nd )
{
int len = POP();
- char *p = (char*)POP();
+ char *p = (char*)cell2pointer(POP());
int n=0;
while( nd->mark_lo < nvram.size && n < len ) {
Modified: trunk/openbios-devel/packages/pc-parts.c
==============================================================================
--- trunk/openbios-devel/packages/pc-parts.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/packages/pc-parts.c Mon Oct 25 22:48:45 2010 (r922)
@@ -38,7 +38,7 @@
DECLARE_NODE( pcparts, INSTALL_OPEN, sizeof(pcparts_info_t), "+/packages/pc-parts" );
#define SEEK( pos ) ({ DPUSH(pos); call_parent(di->seek_xt); POP(); })
-#define READ( buf, size ) ({ PUSH((ucell)buf); PUSH(size); call_parent(di->read_xt); POP(); })
+#define READ( buf, size ) ({ PUSH(pointer2cell(buf)); PUSH(size); call_parent(di->read_xt); POP(); })
/* three helper functions */
@@ -294,7 +294,7 @@
static void
pcparts_probe( pcparts_info_t *dummy )
{
- unsigned char *buf = (unsigned char *)POP();
+ unsigned char *buf = (unsigned char *)cell2pointer(POP());
DPRINTF("probing for PC partitions\n");
Modified: trunk/openbios-devel/packages/video.c
==============================================================================
--- trunk/openbios-devel/packages/video.c Mon Oct 25 21:26:40 2010 (r921)
+++ trunk/openbios-devel/packages/video.c Mon Oct 25 22:48:45 2010 (r922)
@@ -244,7 +244,7 @@
{
int count = POP();
int start = POP();
- unsigned char *p = (unsigned char*)POP();
+ unsigned char *p = (unsigned char*)cell2pointer(POP());
int i;
for( i=0; i<count; i++, p+=3 ) {
@@ -289,7 +289,7 @@
int len;
len = POP();
- addr = (char *)POP();
+ addr = (char *)cell2pointer(POP());
console_draw_fstr(addr, len);
PUSH(len);
1
0
A misplaced digit 8 made it look as if some signedness issue was present
somewhere between libopenbios/client.c:of_client_interface() and
arch/ppc/qemu/methods.c:ciface_claim(). This is not the case;
despite unsigned long -> ucell -> cell -> ucell conversions,
PUSH'ing 0x81234567 and POP'ing works as expected.
Fix the format string to avoid such confusion.
Add zero-padding while at it.
Signed-off-by: Andreas Färber <andreas.faerber(a)web.de>
---
libopenbios/client.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/libopenbios/client.c b/libopenbios/client.c
index a93d8a3..d8a9fdf 100644
--- a/libopenbios/client.c
+++ b/libopenbios/client.c
@@ -132,10 +132,10 @@ static void dump_service(prom_args_t *pb)
pb->args[0], pb->args[1], pb->args[2]);
#endif
} else if (strcmp(pb->service, "claim") == 0) {
- printk("claim(0x8%lx, %ld, %ld) = ",
+ printk("claim(0x%08lx, %ld, %ld) = ",
pb->args[0], pb->args[1], pb->args[2]);
} else if (strcmp(pb->service, "release") == 0) {
- printk("release(0x8%lx, %ld)\n",
+ printk("release(0x%08lx, %ld)\n",
pb->args[0], pb->args[1]);
} else if (strcmp(pb->service, "boot") == 0) {
printk("boot \"%s\"\n", (char*)pb->args[0]);
--
1.7.3
1
1
Author: afaerber
Date: Mon Oct 25 21:26:40 2010
New Revision: 921
URL: http://tracker.coreboot.org/trac/openbios/changeset/921
Log:
CIF: Fix trace output for claim and release
A misplaced digit 8 made it look as if some signedness issue was present
somewhere between libopenbios/client.c:of_client_interface() and
arch/ppc/qemu/methods.c:ciface_claim(). This is not the case;
despite unsigned long -> ucell -> cell -> ucell conversions,
PUSH'ing 0x81234567 and POP'ing works as expected.
Fix the format string to avoid such confusion.
Add zero-padding while at it.
Signed-off-by: Andreas Färber <andreas.faerber(a)web.de>
Modified:
trunk/openbios-devel/libopenbios/client.c
Modified: trunk/openbios-devel/libopenbios/client.c
==============================================================================
--- trunk/openbios-devel/libopenbios/client.c Sun Oct 24 23:34:21 2010 (r920)
+++ trunk/openbios-devel/libopenbios/client.c Mon Oct 25 21:26:40 2010 (r921)
@@ -132,10 +132,10 @@
pb->args[0], pb->args[1], pb->args[2]);
#endif
} else if (strcmp(pb->service, "claim") == 0) {
- printk("claim(0x8%lx, %ld, %ld) = ",
+ printk("claim(0x%08lx, %ld, %ld) = ",
pb->args[0], pb->args[1], pb->args[2]);
} else if (strcmp(pb->service, "release") == 0) {
- printk("release(0x8%lx, %ld)\n",
+ printk("release(0x%08lx, %ld)\n",
pb->args[0], pb->args[1]);
} else if (strcmp(pb->service, "boot") == 0) {
printk("boot \"%s\"\n", (char*)pb->args[0]);
1
0
Author: mcayland
Date: Sun Oct 24 23:34:21 2010
New Revision: 920
URL: http://tracker.coreboot.org/trac/openbios/changeset/920
Log:
Reduce SPARC32 stack space since otherwise compiling with -O0 results in a 'rom: requested regions overlap (rom
/home/build/rel-qemu-git/share/qemu/openbios-sparc32. free=0x0000000070101000, addr=0x0000000070000000)
rom loading failed' error when starting qemu.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)siriusit.co.uk>
Modified:
trunk/openbios-devel/arch/sparc32/context.c
Modified: trunk/openbios-devel/arch/sparc32/context.c
==============================================================================
--- trunk/openbios-devel/arch/sparc32/context.c Sun Oct 24 22:20:14 2010 (r919)
+++ trunk/openbios-devel/arch/sparc32/context.c Sun Oct 24 23:34:21 2010 (r920)
@@ -11,7 +11,7 @@
#include "openbios.h"
#define MAIN_STACK_SIZE 16384
-#define IMAGE_STACK_SIZE 4096*4
+#define IMAGE_STACK_SIZE 4096*2
#define debug printk
1
0