Lines Matching refs:na
22 #define OF_CHECK_COUNTS(na, ns) ((na) > 0 && (na) <= OF_MAX_ADDR_CELLS && \ argument
27 static void __init of_dump_addr(const char *s, const __be32 *addr, int na) in of_dump_addr() argument
30 while(na--) in of_dump_addr()
35 static void __init of_dump_addr(const char *s, const __be32 *addr, int na) { } in of_dump_addr() argument
43 int na, int ns, int pna);
44 int (*translate)(__be32 *addr, u64 offset, int na);
71 int na, int ns, int pna) in fdt_bus_default_map() argument
75 cp = of_read_number(range, na); in fdt_bus_default_map()
76 s = of_read_number(range + na + pna, ns); in fdt_bus_default_map()
77 da = of_read_number(addr, na); in fdt_bus_default_map()
87 static int __init fdt_bus_default_translate(__be32 *addr, u64 offset, int na) in fdt_bus_default_translate() argument
89 u64 a = of_read_number(addr, na); in fdt_bus_default_translate()
90 memset(addr, 0, na * 4); in fdt_bus_default_translate()
92 if (na > 1) in fdt_bus_default_translate()
93 addr[na - 2] = cpu_to_fdt32(a >> 32); in fdt_bus_default_translate()
94 addr[na - 1] = cpu_to_fdt32(a & 0xffffffffu); in fdt_bus_default_translate()
112 int na, int ns, int pna, const char *rprop) in fdt_translate_one() argument
123 offset = of_read_number(addr, na); in fdt_translate_one()
133 rone = na + pna + ns; in fdt_translate_one()
135 offset = bus->map(addr, ranges, na, ns, pna); in fdt_translate_one()
143 memcpy(addr, ranges + na, 4 * pna); in fdt_translate_one()
169 int na, ns, pna, pns; in fdt_translate_address() local
189 bus->count_cells(blob, parent, &na, &ns); in fdt_translate_address()
190 if (!OF_CHECK_COUNTS(na, ns)) { in fdt_translate_address()
195 memcpy(addr, reg, na * 4); in fdt_translate_address()
198 na, ns, fdt_get_name(blob, parent, NULL)); in fdt_translate_address()
199 of_dump_addr("translating address:", addr, na); in fdt_translate_address()
210 result = of_read_number(addr, na); in fdt_translate_address()
228 addr, na, ns, pna, "ranges")) in fdt_translate_address()
232 na = pna; in fdt_translate_address()
236 of_dump_addr("one level translation:", addr, na); in fdt_translate_address()