mirror of
https://gitlab.com/qemu-project/openbios.git
synced 2024-02-13 08:34:06 +08:00
ppc: Don't set up RTAS for OldWorld Macs
According to historical device trees, pre-iMac Macs do not seem to have the /rtas node. Make /rtas conditional to NewWorld Macs for now, while allowing to extend this to future CHRP machines. This means that the ppc-softmmu would by default not have it, except when using -M mac99. ppc64-softmmu would get it by default. Signed-off-by: Andreas Färber <andreas.faerber@web.de> git-svn-id: svn://coreboot.org/openbios/trunk/openbios-devel@936 f158a5a8-5612-0410-a976-696ce0be7e32
This commit is contained in:
committed by
Andreas Färber
parent
b544062187
commit
8d8e29fce6
@@ -753,14 +753,20 @@ arch_of_init( void )
|
|||||||
node_methods_init(buf);
|
node_methods_init(buf);
|
||||||
|
|
||||||
#ifdef CONFIG_RTAS
|
#ifdef CONFIG_RTAS
|
||||||
if( !(ph=find_dev("/rtas")) )
|
/* OldWorld Macs don't have an /rtas node. */
|
||||||
|
switch (machine_id) {
|
||||||
|
case ARCH_MAC99:
|
||||||
|
case ARCH_MAC99_U3:
|
||||||
|
if (!(ph = find_dev("/rtas"))) {
|
||||||
printk("Warning: No /rtas node\n");
|
printk("Warning: No /rtas node\n");
|
||||||
else {
|
} else {
|
||||||
unsigned long size = 0x1000;
|
unsigned long size = 0x1000;
|
||||||
while (size < (unsigned long)of_rtas_end - (unsigned long)of_rtas_start)
|
while (size < (unsigned long)of_rtas_end - (unsigned long)of_rtas_start)
|
||||||
size *= 2;
|
size *= 2;
|
||||||
set_property(ph, "rtas-size", (char*)&size, sizeof(size));
|
set_property(ph, "rtas-size", (char*)&size, sizeof(size));
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (fw_cfg_read_i16(FW_CFG_NOGRAPHIC)) {
|
if (fw_cfg_read_i16(FW_CFG_NOGRAPHIC)) {
|
||||||
|
|||||||
@@ -304,7 +304,9 @@ node_methods_init( const char *cpuname )
|
|||||||
{
|
{
|
||||||
phandle_t chosen, ph;
|
phandle_t chosen, ph;
|
||||||
#ifdef CONFIG_RTAS
|
#ifdef CONFIG_RTAS
|
||||||
|
if (is_newworld()) {
|
||||||
REGISTER_NODE( rtas );
|
REGISTER_NODE( rtas );
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
REGISTER_NODE( ciface );
|
REGISTER_NODE( ciface );
|
||||||
REGISTER_NODE( memory );
|
REGISTER_NODE( memory );
|
||||||
|
|||||||
Reference in New Issue
Block a user