l2x0.c 655 B

1234567891011121314151617181920212223242526272829303132
  1. /*
  2. * l2 cache initialization for CSR SiRFprimaII
  3. *
  4. * Copyright (c) 2011 Cambridge Silicon Radio Limited, a CSR plc group company.
  5. *
  6. * Licensed under GPLv2 or later.
  7. */
  8. #include <linux/init.h>
  9. #include <linux/kernel.h>
  10. #include <linux/of.h>
  11. #include <asm/hardware/cache-l2x0.h>
  12. static struct of_device_id prima2_l2x0_ids[] = {
  13. { .compatible = "sirf,prima2-pl310-cache" },
  14. {},
  15. };
  16. static int __init sirfsoc_l2x0_init(void)
  17. {
  18. struct device_node *np;
  19. np = of_find_matching_node(NULL, prima2_l2x0_ids);
  20. if (np) {
  21. pr_info("Initializing prima2 L2 cache\n");
  22. return l2x0_of_init(0x40000, 0);
  23. }
  24. return 0;
  25. }
  26. early_initcall(sirfsoc_l2x0_init);