Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'powerpc-5.19-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux

Pull powerpc fix from Michael Ellerman:

- On Power8 bare metal, fix creation of RNG platform devices, which are
needed for the /dev/hwrng driver to probe correctly.

Thanks to Jason A. Donenfeld, and Sachin Sant.

* tag 'powerpc-5.19-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
powerpc/powernv: delay rng platform device creation until later in boot

+10 -6
+10 -6
arch/powerpc/platforms/powernv/rng.c
··· 176 176 NULL) != pnv_get_random_long_early) 177 177 return 0; 178 178 179 - for_each_compatible_node(dn, NULL, "ibm,power-rng") { 180 - if (rng_create(dn)) 181 - continue; 182 - /* Create devices for hwrng driver */ 183 - of_platform_device_create(dn, NULL, NULL); 184 - } 179 + for_each_compatible_node(dn, NULL, "ibm,power-rng") 180 + rng_create(dn); 185 181 186 182 if (!ppc_md.get_random_seed) 187 183 return 0; ··· 201 205 202 206 static int __init pnv_rng_late_init(void) 203 207 { 208 + struct device_node *dn; 204 209 unsigned long v; 210 + 205 211 /* In case it wasn't called during init for some other reason. */ 206 212 if (ppc_md.get_random_seed == pnv_get_random_long_early) 207 213 pnv_get_random_long_early(&v); 214 + 215 + if (ppc_md.get_random_seed == powernv_get_random_long) { 216 + for_each_compatible_node(dn, NULL, "ibm,power-rng") 217 + of_platform_device_create(dn, NULL, NULL); 218 + } 219 + 208 220 return 0; 209 221 } 210 222 machine_subsys_initcall(powernv, pnv_rng_late_init);