From: Huacai Chen Date: Tue, 4 Nov 2014 06:13:24 +0000 (+0800) Subject: MIPS: Loongson-3: Add PHYS48_TO_HT40 support X-Git-Tag: omap-for-v3.19/fixes-rc1~122^2~138 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f490682a6b21ffed5acd7a0d49d8371e5e625d7a;p=pandora-kernel.git MIPS: Loongson-3: Add PHYS48_TO_HT40 support The width of HT-bus is only 40-bit, but Loongson-3 has 48-bit physical address. This implies only node-0's memory is DMAable because high bits (Node ID) will lost. Fortunately, by configuring address windows in firmware, we can extract 2bit Node ID (bit 44~47, only bit 44~45 used now) from Loongson-3's 48-bit address space and embed it into 40-bit (bit 37~38). Every NUMA node can do DMA now (however, maximum memory of each node is reduced to 2^37 = 128GB). Signed-off-by: Huacai Chen Cc: John Crispin Cc: Steven J. Hill Cc: linux-mips@linux-mips.org Cc: Fuxin Zhang Cc: Zhangjin Wu Patchwork: https://patchwork.linux-mips.org/patch/8321/ Signed-off-by: Ralf Baechle --- Reading git-diff-tree failed