diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/qe/fdt.c | 8 | ||||
-rw-r--r-- | drivers/qe/qe.c | 19 |
2 files changed, 14 insertions, 13 deletions
diff --git a/drivers/qe/fdt.c b/drivers/qe/fdt.c index 1a123b8..5a0f277 100644 --- a/drivers/qe/fdt.c +++ b/drivers/qe/fdt.c @@ -75,16 +75,16 @@ error: void ft_qe_setup(void *blob) { do_fixup_by_prop_u32(blob, "device_type", "qe", 4, - "bus-frequency", gd->qe_clk, 1); + "bus-frequency", gd->arch.qe_clk, 1); do_fixup_by_prop_u32(blob, "device_type", "qe", 4, "brg-frequency", gd->arch.brg_clk, 1); do_fixup_by_compat_u32(blob, "fsl,qe", - "clock-frequency", gd->qe_clk, 1); + "clock-frequency", gd->arch.qe_clk, 1); do_fixup_by_compat_u32(blob, "fsl,qe", - "bus-frequency", gd->qe_clk, 1); + "bus-frequency", gd->arch.qe_clk, 1); do_fixup_by_compat_u32(blob, "fsl,qe", "brg-frequency", gd->arch.brg_clk, 1); do_fixup_by_compat_u32(blob, "fsl,qe-gtm", - "clock-frequency", gd->qe_clk / 2, 1); + "clock-frequency", gd->arch.qe_clk / 2, 1); fdt_fixup_qe_firmware(blob); } diff --git a/drivers/qe/qe.c b/drivers/qe/qe.c index 72c585c..5fd2135 100644 --- a/drivers/qe/qe.c +++ b/drivers/qe/qe.c @@ -58,21 +58,22 @@ uint qe_muram_alloc(uint size, uint align) uint savebase; align_mask = align - 1; - savebase = gd->mp_alloc_base; + savebase = gd->arch.mp_alloc_base; - if ((off = (gd->mp_alloc_base & align_mask)) != 0) - gd->mp_alloc_base += (align - off); + off = gd->arch.mp_alloc_base & align_mask; + if (off != 0) + gd->arch.mp_alloc_base += (align - off); if ((off = size & align_mask) != 0) size += (align - off); - if ((gd->mp_alloc_base + size) >= gd->mp_alloc_top) { - gd->mp_alloc_base = savebase; + if ((gd->arch.mp_alloc_base + size) >= gd->arch.mp_alloc_top) { + gd->arch.mp_alloc_base = savebase; printf("%s: ran out of ram.\n", __FUNCTION__); } - retloc = gd->mp_alloc_base; - gd->mp_alloc_base += size; + retloc = gd->arch.mp_alloc_base; + gd->arch.mp_alloc_base += size; memset((void *)&qe_immr->muram[retloc], 0, size); @@ -183,8 +184,8 @@ void qe_init(uint qe_base) out_be32(&qe_immr->iram.iready,QE_IRAM_READY); #endif - gd->mp_alloc_base = QE_DATAONLY_BASE; - gd->mp_alloc_top = gd->mp_alloc_base + QE_DATAONLY_SIZE; + gd->arch.mp_alloc_base = QE_DATAONLY_BASE; + gd->arch.mp_alloc_top = gd->arch.mp_alloc_base + QE_DATAONLY_SIZE; qe_sdma_init(); qe_snums_init(); |