Removal of the CONFIG_PDC_NARROW option.
Subsystems (2)
Hello All,
I promised jejb a long time ago to get rid of the CONFIG_PDC_NARROW config option and replace it with a run-time check. This will allow 64-bit kernels to run on any 64-bit capable system and does not need to be compiled special to run with narrow firmware. I finally finished this task and have committed it to CVS head.
I have attached the patch for review and I am posting to both lists since some users might use the option and wonder about it when this option is no longer present.
I have tested this patch on C200 (narrow firmware), K460 (wide firmware), and A500 (wide firmware).
Thanks,
- Ryan
Index: Makefile
===================================================================
RCS file: /var/cvs/linux-2.6/Makefile,v
retrieving revision 1.186
Makefile +1 -1
@@ -1,7 +1,7 @@ VERSION = 2 PATCHLEVEL = 6 SUBLEVEL = 6 -EXTRAVERSION =-rc3-pa6 +EXTRAVERSION =-rc3-pa7 NAME=Zonked Quokka # *DOCUMENTATION*
Index: arch/parisc/Kconfig
===================================================================
RCS file: /var/cvs/linux-2.6/arch/parisc/Kconfig,v retrieving revision 1.17
arch/parisc/Kconfig +0 -12
@@ -117,18 +117,6 @@ config PARISC64 config 64BIT def_bool PARISC64 -config PDC_NARROW - bool "32-bit firmware" - depends on PARISC64 - help - This option will enable owners of C160, C180, C200, C240, C360, J280, - J282, J2240 and some D/K/R class to run a 64bit kernel with their - 32bit PDC firmware. - - Nobody should try this option unless they know what they are doing. - - If unsure, say N. - config SMP bool "Symmetric multi-processing support" ---help---
Index: arch/parisc/kernel/firmware.c
===================================================================
RCS file: /var/cvs/linux-2.6/arch/parisc/kernel/firmware.c,v retrieving revision 1.6
arch/parisc/kernel/firmware.c +49 -14
95 lines not on this page · raw message
Index: arch/parisc/kernel/head64.S
===================================================================
RCS file: /var/cvs/linux-2.6/arch/parisc/kernel/head64.S,v retrieving revision 1.7
arch/parisc/kernel/head64.S +0 -2
@@ -165,7 +165,6 @@ common_stext: tophys_r1 %r10 std %r11, TASK_PT_GR11(%r10) -#ifndef CONFIG_PDC_NARROW /* Switch to wide mode; Superdome doesn't support narrow PDC ** calls. */
@@ -175,7 +174,6 @@ common_stext: bv (%rp) ssm PSW_SM_W,%r0 2: -#endif /* CONFIG_PDC_NARROW */ /* Set Wide mode as the "Default" (eg for traps) ** First trap occurs *right* after (or part of) rfi for slave CPUs.
Index: arch/parisc/kernel/processor.c
===================================================================
RCS file: /var/cvs/linux-2.6/arch/parisc/kernel/processor.c,v retrieving revision 1.3
arch/parisc/kernel/processor.c +1 -0
@@ -276,6 +276,7 @@ int __init init_per_cpu(int cpunum)int ret;struct pdc_coproc_cfg coproc_cfg; +set_firmware_width (); ret =pdc_coproc_cfg (&coproc_cfg);if (ret >=0 && coproc_cfg.ccr_functional) {
Index: arch/parisc/kernel/setup.c
===================================================================
RCS file: /var/cvs/linux-2.6/arch/parisc/kernel/setup.c,v retrieving revision 1.4
arch/parisc/kernel/setup.c +5 -2
@@ -121,8 +121,11 @@ void __init setup_arch(char **cmdline_p)pdc_console_init (); -#ifdef CONFIG_PDC_NARROW -printk (KERN_INFO "Kernel is using PDC in 32-bit mode.\n" ); +#ifdef __LP64__ +extern int parisc_narrow_firmware; +if (parisc_narrow_firmware) { +printk (KERN_INFO "Kernel is using PDC in 32-bit mode.\n" ); + }#endif setup_pdc ();setup_cmdline (cmdline_p);
Index: include/asm-parisc/pdc.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/asm-parisc/pdc.h,v retrieving revision 1.4
include/asm-parisc/pdc.h +1 -0
@@ -949,6 +949,7 @@ int pdc_tod_read(struct pdc_tod *tod);int pdc_tod_set (unsigned long sec,unsigned long usec);#ifdef __LP64__ +void set_firmware_width (void );int pdc_mem_mem_table (struct pdc_memory_table_raddr *r_addr,struct pdc_memory_table *tbl,unsigned long entries);#endif