Commit 5e2ccf6d authored by Suresh B. Siddha's avatar Suresh B. Siddha Committed by David Mosberger

[PATCH] ia64: 1/2 fix for generic kernel

Current 2.5 kernels are broken with CONFIG_IA64_GENERIC option. Two unused
members are still remaining in the structure, resulting in corruption of
structure elements during the MACHVEC_INIT initialization. Attached patch
fixes this problem.
parent 2f38795e
...@@ -10,19 +10,6 @@ ...@@ -10,19 +10,6 @@
struct ia64_machine_vector ia64_mv; struct ia64_machine_vector ia64_mv;
/*
* Most platforms use this routine for mapping page frame addresses into a memory map
* index.
*
* Note: we can't use __pa() because map_nr_dense(X) MUST map to something >= max_mapnr if
* X is outside the identity mapped kernel space.
*/
unsigned long
map_nr_dense (unsigned long addr)
{
return (addr - PAGE_OFFSET) >> PAGE_SHIFT;
}
static struct ia64_machine_vector * static struct ia64_machine_vector *
lookup_machvec (const char *name) lookup_machvec (const char *name)
{ {
......
...@@ -23,8 +23,6 @@ struct page; ...@@ -23,8 +23,6 @@ struct page;
typedef void ia64_mv_setup_t (char **); typedef void ia64_mv_setup_t (char **);
typedef void ia64_mv_cpu_init_t(void); typedef void ia64_mv_cpu_init_t(void);
typedef void ia64_mv_irq_init_t (void); typedef void ia64_mv_irq_init_t (void);
typedef void ia64_mv_pci_fixup_t (int);
typedef unsigned long ia64_mv_map_nr_t (unsigned long);
typedef void ia64_mv_mca_init_t (void); typedef void ia64_mv_mca_init_t (void);
typedef void ia64_mv_mca_handler_t (void); typedef void ia64_mv_mca_handler_t (void);
typedef void ia64_mv_cmci_handler_t (int, void *, struct pt_regs *); typedef void ia64_mv_cmci_handler_t (int, void *, struct pt_regs *);
...@@ -120,8 +118,6 @@ struct ia64_machine_vector { ...@@ -120,8 +118,6 @@ struct ia64_machine_vector {
ia64_mv_setup_t *setup; ia64_mv_setup_t *setup;
ia64_mv_cpu_init_t *cpu_init; ia64_mv_cpu_init_t *cpu_init;
ia64_mv_irq_init_t *irq_init; ia64_mv_irq_init_t *irq_init;
ia64_mv_pci_fixup_t *pci_fixup;
ia64_mv_map_nr_t *map_nr;
ia64_mv_mca_init_t *mca_init; ia64_mv_mca_init_t *mca_init;
ia64_mv_mca_handler_t *mca_handler; ia64_mv_mca_handler_t *mca_handler;
ia64_mv_cmci_handler_t *cmci_handler; ia64_mv_cmci_handler_t *cmci_handler;
......
...@@ -3,8 +3,6 @@ ...@@ -3,8 +3,6 @@
extern ia64_mv_setup_t dig_setup; extern ia64_mv_setup_t dig_setup;
extern ia64_mv_irq_init_t dig_irq_init; extern ia64_mv_irq_init_t dig_irq_init;
extern ia64_mv_pci_fixup_t iosapic_pci_fixup;
extern ia64_mv_map_nr_t map_nr_dense;
/* /*
* This stuff has dual use! * This stuff has dual use!
......
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
extern ia64_mv_setup_t hpsim_setup; extern ia64_mv_setup_t hpsim_setup;
extern ia64_mv_irq_init_t hpsim_irq_init; extern ia64_mv_irq_init_t hpsim_irq_init;
extern ia64_mv_map_nr_t map_nr_dense;
/* /*
* This stuff has dual use! * This stuff has dual use!
......
...@@ -2,8 +2,6 @@ ...@@ -2,8 +2,6 @@
#define _ASM_IA64_MACHVEC_HPZX1_h #define _ASM_IA64_MACHVEC_HPZX1_h
extern ia64_mv_setup_t dig_setup; extern ia64_mv_setup_t dig_setup;
extern ia64_mv_pci_fixup_t hpzx1_pci_fixup;
extern ia64_mv_map_nr_t map_nr_dense;
extern ia64_mv_pci_alloc_consistent sba_alloc_consistent; extern ia64_mv_pci_alloc_consistent sba_alloc_consistent;
extern ia64_mv_pci_free_consistent sba_free_consistent; extern ia64_mv_pci_free_consistent sba_free_consistent;
extern ia64_mv_pci_map_single sba_map_single; extern ia64_mv_pci_map_single sba_map_single;
......
...@@ -36,10 +36,8 @@ ...@@ -36,10 +36,8 @@
extern ia64_mv_setup_t sn1_setup; extern ia64_mv_setup_t sn1_setup;
extern ia64_mv_cpu_init_t sn_cpu_init; extern ia64_mv_cpu_init_t sn_cpu_init;
extern ia64_mv_irq_init_t sn1_irq_init; extern ia64_mv_irq_init_t sn1_irq_init;
extern ia64_mv_map_nr_t sn1_map_nr;
extern ia64_mv_send_ipi_t sn1_send_IPI; extern ia64_mv_send_ipi_t sn1_send_IPI;
extern ia64_mv_global_tlb_purge_t sn1_global_tlb_purge; extern ia64_mv_global_tlb_purge_t sn1_global_tlb_purge;
extern ia64_mv_pci_fixup_t sn1_pci_fixup;
extern ia64_mv_inb_t sn1_inb; extern ia64_mv_inb_t sn1_inb;
extern ia64_mv_inw_t sn1_inw; extern ia64_mv_inw_t sn1_inw;
extern ia64_mv_inl_t sn1_inl; extern ia64_mv_inl_t sn1_inl;
......
...@@ -36,13 +36,11 @@ ...@@ -36,13 +36,11 @@
extern ia64_mv_setup_t sn_setup; extern ia64_mv_setup_t sn_setup;
extern ia64_mv_cpu_init_t sn_cpu_init; extern ia64_mv_cpu_init_t sn_cpu_init;
extern ia64_mv_irq_init_t sn_irq_init; extern ia64_mv_irq_init_t sn_irq_init;
extern ia64_mv_map_nr_t sn2_map_nr;
extern ia64_mv_send_ipi_t sn2_send_IPI; extern ia64_mv_send_ipi_t sn2_send_IPI;
extern ia64_mv_global_tlb_purge_t sn2_global_tlb_purge; extern ia64_mv_global_tlb_purge_t sn2_global_tlb_purge;
extern ia64_mv_irq_desc sn_irq_desc; extern ia64_mv_irq_desc sn_irq_desc;
extern ia64_mv_irq_to_vector sn_irq_to_vector; extern ia64_mv_irq_to_vector sn_irq_to_vector;
extern ia64_mv_local_vector_to_irq sn_local_vector_to_irq; extern ia64_mv_local_vector_to_irq sn_local_vector_to_irq;
extern ia64_mv_pci_fixup_t sn_pci_fixup;
extern ia64_mv_inb_t sn_inb; extern ia64_mv_inb_t sn_inb;
extern ia64_mv_inw_t sn_inw; extern ia64_mv_inw_t sn_inw;
extern ia64_mv_inl_t sn_inl; extern ia64_mv_inl_t sn_inl;
...@@ -72,10 +70,8 @@ extern ia64_mv_pci_dma_supported sn_pci_dma_supported; ...@@ -72,10 +70,8 @@ extern ia64_mv_pci_dma_supported sn_pci_dma_supported;
#define platform_setup sn_setup #define platform_setup sn_setup
#define platform_cpu_init sn_cpu_init #define platform_cpu_init sn_cpu_init
#define platform_irq_init sn_irq_init #define platform_irq_init sn_irq_init
#define platform_map_nr sn2_map_nr
#define platform_send_ipi sn2_send_IPI #define platform_send_ipi sn2_send_IPI
#define platform_global_tlb_purge sn2_global_tlb_purge #define platform_global_tlb_purge sn2_global_tlb_purge
#define platform_pci_fixup sn_pci_fixup
#define platform_inb sn_inb #define platform_inb sn_inb
#define platform_inw sn_inw #define platform_inw sn_inw
#define platform_inl sn_inl #define platform_inl sn_inl
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment