diff options
| -rw-r--r-- | arch/mips/powertv/Kconfig | 9 | ||||
| -rw-r--r-- | arch/mips/powertv/asic/asic_devices.c | 12 | ||||
| -rw-r--r-- | arch/mips/powertv/init.c | 4 | ||||
| -rw-r--r-- | arch/mips/powertv/reset.c | 12 |
4 files changed, 2 insertions, 35 deletions
diff --git a/arch/mips/powertv/Kconfig b/arch/mips/powertv/Kconfig index 1a1b03ea6398..dd91fbacbcba 100644 --- a/arch/mips/powertv/Kconfig +++ b/arch/mips/powertv/Kconfig | |||
| @@ -1,14 +1,7 @@ | |||
| 1 | config BOOTLOADER_DRIVER | ||
| 2 | bool "PowerTV Bootloader Driver Support" | ||
| 3 | default n | ||
| 4 | depends on POWERTV | ||
| 5 | help | ||
| 6 | Use this option if you want to load bootloader driver. | ||
| 7 | |||
| 8 | config BOOTLOADER_FAMILY | 1 | config BOOTLOADER_FAMILY |
| 9 | string "POWERTV Bootloader Family string" | 2 | string "POWERTV Bootloader Family string" |
| 10 | default "85" | 3 | default "85" |
| 11 | depends on POWERTV && !BOOTLOADER_DRIVER | 4 | depends on POWERTV |
| 12 | help | 5 | help |
| 13 | This value should be specified when the bootloader driver is disabled | 6 | This value should be specified when the bootloader driver is disabled |
| 14 | and must be exactly two characters long. Families supported are: | 7 | and must be exactly two characters long. Families supported are: |
diff --git a/arch/mips/powertv/asic/asic_devices.c b/arch/mips/powertv/asic/asic_devices.c index 0238af1ba503..8380605d597d 100644 --- a/arch/mips/powertv/asic/asic_devices.c +++ b/arch/mips/powertv/asic/asic_devices.c | |||
| @@ -147,20 +147,10 @@ static __init noinline void platform_set_family(void) | |||
| 147 | if (check_forcefamily(forced_family) == 0) | 147 | if (check_forcefamily(forced_family) == 0) |
| 148 | bootldr_family = BOOTLDRFAMILY(forced_family[0], | 148 | bootldr_family = BOOTLDRFAMILY(forced_family[0], |
| 149 | forced_family[1]); | 149 | forced_family[1]); |
| 150 | else { | 150 | else |
| 151 | |||
| 152 | #ifdef CONFIG_BOOTLOADER_DRIVER | ||
| 153 | bootldr_family = (unsigned short) kbldr_GetSWFamily(); | ||
| 154 | #else | ||
| 155 | #if defined(CONFIG_BOOTLOADER_FAMILY) | ||
| 156 | bootldr_family = (unsigned short) BOOTLDRFAMILY( | 151 | bootldr_family = (unsigned short) BOOTLDRFAMILY( |
| 157 | CONFIG_BOOTLOADER_FAMILY[0], | 152 | CONFIG_BOOTLOADER_FAMILY[0], |
| 158 | CONFIG_BOOTLOADER_FAMILY[1]); | 153 | CONFIG_BOOTLOADER_FAMILY[1]); |
| 159 | #else | ||
| 160 | #error "Unknown Bootloader Family" | ||
| 161 | #endif | ||
| 162 | #endif | ||
| 163 | } | ||
| 164 | 154 | ||
| 165 | pr_info("Bootloader Family = 0x%04X\n", bootldr_family); | 155 | pr_info("Bootloader Family = 0x%04X\n", bootldr_family); |
| 166 | 156 | ||
diff --git a/arch/mips/powertv/init.c b/arch/mips/powertv/init.c index a01baff52cae..498926377e51 100644 --- a/arch/mips/powertv/init.c +++ b/arch/mips/powertv/init.c | |||
| @@ -87,8 +87,4 @@ void __init prom_init(void) | |||
| 87 | 87 | ||
| 88 | configure_platform(); | 88 | configure_platform(); |
| 89 | prom_meminit(); | 89 | prom_meminit(); |
| 90 | |||
| 91 | #ifndef CONFIG_BOOTLOADER_DRIVER | ||
| 92 | pr_info("\nBootloader driver isn't loaded...\n"); | ||
| 93 | #endif | ||
| 94 | } | 90 | } |
diff --git a/arch/mips/powertv/reset.c b/arch/mips/powertv/reset.c index 0007652cb774..11c32fbf2784 100644 --- a/arch/mips/powertv/reset.c +++ b/arch/mips/powertv/reset.c | |||
| @@ -21,24 +21,12 @@ | |||
| 21 | #include <linux/io.h> | 21 | #include <linux/io.h> |
| 22 | #include <asm/reboot.h> /* Not included by linux/reboot.h */ | 22 | #include <asm/reboot.h> /* Not included by linux/reboot.h */ |
| 23 | 23 | ||
| 24 | #ifdef CONFIG_BOOTLOADER_DRIVER | ||
| 25 | #include <asm/mach-powertv/kbldr.h> | ||
| 26 | #endif | ||
| 27 | |||
| 28 | #include <asm/mach-powertv/asic_regs.h> | 24 | #include <asm/mach-powertv/asic_regs.h> |
| 29 | #include "reset.h" | 25 | #include "reset.h" |
| 30 | 26 | ||
| 31 | static void mips_machine_restart(char *command) | 27 | static void mips_machine_restart(char *command) |
| 32 | { | 28 | { |
| 33 | #ifdef CONFIG_BOOTLOADER_DRIVER | ||
| 34 | /* | ||
| 35 | * Call the bootloader's reset function to ensure | ||
| 36 | * that persistent data is flushed before hard reset | ||
| 37 | */ | ||
| 38 | kbldr_SetCauseAndReset(); | ||
| 39 | #else | ||
| 40 | writel(0x1, asic_reg_addr(watchdog)); | 29 | writel(0x1, asic_reg_addr(watchdog)); |
| 41 | #endif | ||
| 42 | } | 30 | } |
| 43 | 31 | ||
| 44 | void mips_reboot_setup(void) | 32 | void mips_reboot_setup(void) |
