init.c 821 B

123456789101112131415161718192021222324252627282930313233343536
  1. // SPDX-License-Identifier: GPL-2.0
  2. /*
  3. * init.c: Initialize internal variables used by the PROM
  4. * library functions.
  5. *
  6. * Copyright (C) 1995 David S. Miller ([email protected])
  7. */
  8. #include <linux/kernel.h>
  9. #include <linux/init.h>
  10. #include <asm/openprom.h>
  11. #include <asm/oplib.h>
  12. struct linux_romvec *romvec;
  13. enum prom_major_version prom_vers;
  14. unsigned int prom_rev, prom_prev;
  15. /* The root node of the prom device tree. */
  16. int prom_root_node;
  17. /* Pointer to the device tree operations structure. */
  18. struct linux_nodeops *prom_nodeops;
  19. /* You must call prom_init() before you attempt to use any of the
  20. * routines in the prom library.
  21. * It gets passed the pointer to the PROM vector.
  22. */
  23. void __init prom_init(struct linux_romvec *rp)
  24. {
  25. romvec = rp;
  26. /* Initialization successful. */
  27. return;
  28. }