diff options
| author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-10 16:32:24 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-10 16:32:24 -0400 |
| commit | 62933d36ac98360da45f43df989277df002b034b (patch) | |
| tree | 1164d4f10bb56b757f0507ed49d7aa4b17a9dc2b /arch/powerpc/kernel/prom.c | |
| parent | 0ab598099c18affd73a21482274c00e8119236be (diff) | |
| parent | f64071200acc124bd0d641ef7d750f38fbf5f8b8 (diff) | |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (24 commits)
[POWERPC] Fix compile error with kexec and CONFIG_SMP=n
[POWERPC] Split initrd logic out of early_init_dt_scan_chosen() to fix warning
[POWERPC] Fix warning in hpte_decode(), and generalize it
[POWERPC] Minor pSeries IOMMU debug cleanup
[POWERPC] PS3: Fix sys manager build error
[POWERPC] Assorted janitorial EEH cleanups
[POWERPC] We don't define CONFIG_HAVE_ARCH_EARLY_PFN_TO_NID
[POWERPC] pmu_sys_suspended is only defined for PPC32
[POWERPC] Fix incorrect calculation of I/O window addresses
[POWERPC] celleb: Update celleb_defconfig
[POWERPC] celleb: Fix parsing of machine type hack command line option
[POWERPC] celleb: Fix PCI config space accesses to subordinate buses
[POWERPC] celleb: Fix support for multiple PCI domains
[POWERPC] Wire up sys_utimensat
[POWERPC] CPM_UART: Removed __init from cpm_uart_init_portdesc to fix warning
[POWERPC] User rheap from arch/powerpc/lib
[POWERPC] 83xx: Fix the PCI ranges in the MPC834x_MDS device tree.
[POWERPC] 83xx: Fix the PCI ranges in the MPC832x_MDS device tree.
[POWERPC] CPM_UART: cpm_uart_set_termios should take ktermios, not termios
[POWERPC] Change rheap functions to use ulongs instead of pointers
...
Diffstat (limited to 'arch/powerpc/kernel/prom.c')
| -rw-r--r-- | arch/powerpc/kernel/prom.c | 47 |
1 files changed, 31 insertions, 16 deletions
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c index caef555f2dc0..c065b5550368 100644 --- a/arch/powerpc/kernel/prom.c +++ b/arch/powerpc/kernel/prom.c | |||
| @@ -716,11 +716,40 @@ static int __init early_init_dt_scan_cpus(unsigned long node, | |||
| 716 | return 0; | 716 | return 0; |
| 717 | } | 717 | } |
| 718 | 718 | ||
| 719 | #ifdef CONFIG_BLK_DEV_INITRD | ||
| 720 | static void __init early_init_dt_check_for_initrd(unsigned long node) | ||
| 721 | { | ||
| 722 | unsigned long l; | ||
| 723 | u32 *prop; | ||
| 724 | |||
| 725 | DBG("Looking for initrd properties... "); | ||
| 726 | |||
| 727 | prop = of_get_flat_dt_prop(node, "linux,initrd-start", &l); | ||
| 728 | if (prop) { | ||
| 729 | initrd_start = (unsigned long)__va(of_read_ulong(prop, l/4)); | ||
| 730 | |||
| 731 | prop = of_get_flat_dt_prop(node, "linux,initrd-end", &l); | ||
| 732 | if (prop) { | ||
| 733 | initrd_end = (unsigned long) | ||
| 734 | __va(of_read_ulong(prop, l/4)); | ||
| 735 | initrd_below_start_ok = 1; | ||
| 736 | } else { | ||
| 737 | initrd_start = 0; | ||
| 738 | } | ||
| 739 | } | ||
| 740 | |||
| 741 | DBG("initrd_start=0x%lx initrd_end=0x%lx\n", initrd_start, initrd_end); | ||
| 742 | } | ||
| 743 | #else | ||
| 744 | static inline void early_init_dt_check_for_initrd(unsigned long node) | ||
| 745 | { | ||
| 746 | } | ||
| 747 | #endif /* CONFIG_BLK_DEV_INITRD */ | ||
| 748 | |||
| 719 | static int __init early_init_dt_scan_chosen(unsigned long node, | 749 | static int __init early_init_dt_scan_chosen(unsigned long node, |
| 720 | const char *uname, int depth, void *data) | 750 | const char *uname, int depth, void *data) |
| 721 | { | 751 | { |
| 722 | unsigned long *lprop; | 752 | unsigned long *lprop; |
| 723 | u32 *prop; | ||
| 724 | unsigned long l; | 753 | unsigned long l; |
| 725 | char *p; | 754 | char *p; |
| 726 | 755 | ||
| @@ -762,21 +791,7 @@ static int __init early_init_dt_scan_chosen(unsigned long node, | |||
| 762 | crashk_res.end = crashk_res.start + *lprop - 1; | 791 | crashk_res.end = crashk_res.start + *lprop - 1; |
| 763 | #endif | 792 | #endif |
| 764 | 793 | ||
| 765 | #ifdef CONFIG_BLK_DEV_INITRD | 794 | early_init_dt_check_for_initrd(node); |
| 766 | DBG("Looking for initrd properties... "); | ||
| 767 | prop = of_get_flat_dt_prop(node, "linux,initrd-start", &l); | ||
| 768 | if (prop) { | ||
| 769 | initrd_start = (unsigned long)__va(of_read_ulong(prop, l/4)); | ||
| 770 | prop = of_get_flat_dt_prop(node, "linux,initrd-end", &l); | ||
| 771 | if (prop) { | ||
| 772 | initrd_end = (unsigned long)__va(of_read_ulong(prop, l/4)); | ||
| 773 | initrd_below_start_ok = 1; | ||
| 774 | } else { | ||
| 775 | initrd_start = 0; | ||
| 776 | } | ||
| 777 | } | ||
| 778 | DBG("initrd_start=0x%lx initrd_end=0x%lx\n", initrd_start, initrd_end); | ||
| 779 | #endif /* CONFIG_BLK_DEV_INITRD */ | ||
| 780 | 795 | ||
| 781 | /* Retreive command line */ | 796 | /* Retreive command line */ |
| 782 | p = of_get_flat_dt_prop(node, "bootargs", &l); | 797 | p = of_get_flat_dt_prop(node, "bootargs", &l); |
