Lines Matching refs:nsize
21 int naddr, nsize, i; in dt_fixup_memory() local
32 if (getprop(root, "#size-cells", &nsize, sizeof(nsize)) < 0) in dt_fixup_memory()
33 nsize = 1; in dt_fixup_memory()
35 nsize = be32_to_cpu(nsize); in dt_fixup_memory()
36 if (nsize < 1 || nsize > 2) in dt_fixup_memory()
37 fatal("Can't cope with #size-cells == %d in /\n\r", nsize); in dt_fixup_memory()
43 if (nsize == 2) in dt_fixup_memory()
54 for (i = 1; i < (naddr + nsize); i++) in dt_fixup_memory()
58 setprop(memory, "reg", memreg, (naddr + nsize)*sizeof(u32)); in dt_fixup_memory()
137 void dt_get_reg_format(void *node, u32 *naddr, u32 *nsize) in dt_get_reg_format() argument
143 if (getprop(node, "#size-cells", nsize, 4) != 4) in dt_get_reg_format()
144 *nsize = 1; in dt_get_reg_format()
146 *nsize = be32_to_cpu(*nsize); in dt_get_reg_format()
212 int naddr, int nsize, int buflen) in find_range() argument
214 int nrange = nregaddr + naddr + nsize; in find_range()
222 copy_val(range_size, ranges + i + nregaddr + naddr, nsize); in find_range()
244 u32 naddr, nsize, prev_naddr, prev_nsize; in dt_xlate() local
251 dt_get_reg_format(parent, &naddr, &nsize); in dt_xlate()
252 if (nsize > 2) in dt_xlate()
255 offset = (naddr + nsize) * res; in dt_xlate()
257 if (reglen < offset + naddr + nsize || in dt_xlate()
258 MAX_PROP_LEN < (offset + naddr + nsize) * 4) in dt_xlate()
264 if (nsize == 2) { in dt_xlate()
271 prev_nsize = nsize; in dt_xlate()
278 dt_get_reg_format(parent, &naddr, &nsize); in dt_xlate()