Lines Matching +full:firmware +full:- +full:phandle
1 // SPDX-License-Identifier: GPL-2.0-or-later
17 /* The following structure is used to communicate with open firmware.
89 rets[i-1] = be32_to_cpu(args.args[nargs+i]); in of_call_prom_ret()
109 static int need_map = -1;
115 phandle oprom, chosen; in check_of_version()
119 if (oprom == (phandle) -1) in check_of_version()
123 version[sizeof(version)-1] = 0; in check_of_version()
125 if (!string_match(version, "Open Firmware, 1.") in check_of_version()
129 if (chosen == (phandle) -1) { in check_of_version()
131 if (chosen == (phandle) -1) { in check_of_version()
163 ret = of_call_prom_ret("call-method", 5, 2, &result, "claim", memory, in of_claim()
165 if (ret != 0 || result == -1) in of_claim()
166 return -1; in of_claim()
167 ret = of_call_prom_ret("call-method", 5, 2, &result, "claim", chosen_mmu, in of_claim()
170 ret = of_call_prom("call-method", 6, 1, "map", chosen_mmu, in of_claim()
181 /* With some older POWER4 firmware we need to claim the area the kernel in of_vmlinux_alloc()
185 addr = (unsigned long) of_claim(start, end - start, 0); in of_vmlinux_alloc()
187 start, end, end - start, addr); in of_vmlinux_alloc()
209 int of_getprop(const void *phandle, const char *name, void *buf, in of_getprop() argument
212 return of_call_prom("getprop", 4, 1, phandle, name, buf, buflen); in of_getprop()
215 int of_setprop(const void *phandle, const char *name, const void *buf, in of_setprop() argument
218 return of_call_prom("setprop", 4, 1, phandle, name, buf, buflen); in of_setprop()