/branches/sparc/boot/arch/sparc64/loader/ofwarch.c |
---|
56,12 → 56,23 |
return flag != -1; |
} |
/* |
* Node among whose children the CPU nodes are located. |
*/ |
#if defined (OPEN_BOOT) |
#define CPUS_PARENT_NODE ofw_root |
#elif defined (SMART_FIRMWARE) |
#define CPUS_PARENT_NODE ofw_find_device("/ssm@0,0") |
#endif |
int ofw_cpu(void) |
{ |
char type_name[BUF_SIZE]; |
phandle node; |
node = ofw_get_child_node(ofw_root); |
node = ofw_get_child_node(CPUS_PARENT_NODE); |
if (node == 0 || node == -1) { |
printf("Could not find any child nodes of the root node.\n"); |
return 0; |
84,8 → 95,12 |
if (strcmp(type_name, "cpu") == 0) { |
uint32_t mid; |
if (ofw_get_property(node, "upa-portid", &mid, |
sizeof(mid)) <= 0) |
/* "upa-portid" for US, "portid" for US-III */ |
if (ofw_get_property( |
node, "upa-portid", |
&mid, sizeof(mid)) <= 0 |
&& ofw_get_property(node, "portid", |
&mid, sizeof(mid)) <= 0) |
continue; |
if (current_mid != mid) { |
/branches/sparc/boot/arch/ppc32/Makefile.inc |
---|
26,6 → 26,8 |
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
# |
DEFS += -DSMART_FIRMWARE |
build: $(BASE)/image.boot |
$(BASE)/image.boot: depend arch/$(ARCH)/loader/image.boot |
/branches/sparc/boot/arch/ppc64/Makefile.inc |
---|
26,6 → 26,8 |
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
# |
DEFS += -DOPEN_BOOT |
build: $(BASE)/image.boot |
$(BASE)/image.boot: depend arch/$(ARCH)/loader/image.boot |
35,7 → 37,7 |
-rm arch/$(ARCH)/loader/image.boot |
arch/$(ARCH)/loader/image.boot: |
make -C arch/$(ARCH)/loader COMPILER=$(COMPILER) KERNELDIR=../../../$(KERNELDIR) USPACEDIR=../../../$(USPACEDIR) |
make -C arch/$(ARCH)/loader COMPILER=$(COMPILER) KERNELDIR=../../../$(KERNELDIR) USPACEDIR=../../../$(USPACEDIR) "DEFS=$(DEFS)" |
clean: generic_clean |
make -C arch/$(ARCH)/loader clean COMPILER=$(COMPILER) KERNELDIR=../../../$(KERNELDIR) USPACEDIR=../../../$(USPACEDIR) |