40 #define DDR3_MR0CF 0x80010011U
42 static unsigned long long ibm_currituck_memsize;
43 static unsigned long long ibm_currituck_detect_memsize(
void)
57 memsize += (0x800000ULL <<
reg);
63 static void ibm_currituck_fixups(
void)
65 void *devp = finddevice(
"/");
70 while ((devp = find_node_by_devtype(devp,
"pci"))) {
71 if (getprop(devp,
"dma-ranges", dma_ranges,
sizeof(dma_ranges)) < 0) {
72 printf(
"%s: Failed to get dma-ranges\r\n", __func__);
76 dma_ranges[5] = ibm_currituck_memsize >> 32;
77 dma_ranges[6] = ibm_currituck_memsize & 0xffffffff
UL;
79 setprop(devp,
"dma-ranges", dma_ranges,
sizeof(dma_ranges));
83 #define SPRN_PIR 0x11E
91 ibm_currituck_memsize = ibm_currituck_detect_memsize();
92 if (ibm_currituck_memsize >> 32)
95 end_of_ram = ibm_currituck_memsize;
96 avail_ram = end_of_ram - (
unsigned long)
_end;
105 fatal(
"Invalid device tree blob\n");
108 "cpu",
sizeof(
"cpu"));
110 fatal(
"Cannot find cpu node\n");
112 if (timebase && (size == 4))