Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 3478 → Rev 3479

/branches/sparc/boot/arch/sparc64/loader/ofwarch.c
56,23 → 56,19
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(CPUS_PARENT_NODE);
phandle ssm;
 
ssm = ofw_find_device("/ssm@0,0");
if (ssm == -1) {
node = ofw_get_child_node(ofw_root);
} else {
node = ofw_get_child_node(ssm);
}
 
if (node == 0 || node == -1) {
printf("Could not find any child nodes of the root node.\n");
return 0;
82,9 → 78,9
asm volatile ("ldxa [%1] %2, %0\n"
: "=r" (current_mid)
: "r" (0), "i" (ASI_UPA_CONFIG));
current_mid >>= UPA_CONFIG_MID_SHIFT;
current_mid &= UPA_CONFIG_MID_MASK;
: "r" (0), "i" (ASI_ICBUS_CONFIG));
current_mid >>= ICBUS_CONFIG_MID_SHIFT;
current_mid &= ICBUS_CONFIG_MID_MASK;
 
int cpus;