Commit 890c4e2c authored by Anton Blanchard's avatar Anton Blanchard

Merge samba.org:/scratch/anton/linux-2.5

into samba.org:/scratch/anton/tmp3
parents ad6ab150 2c40f8df
...@@ -39,6 +39,10 @@ $(boottarget-y): vmlinux ...@@ -39,6 +39,10 @@ $(boottarget-y): vmlinux
rm -f .config arch/ppc64/defconfig rm -f .config arch/ppc64/defconfig
cp -f arch/ppc64/configs/$(@:config=defconfig) arch/ppc64/defconfig cp -f arch/ppc64/configs/$(@:config=defconfig) arch/ppc64/defconfig
install: vmlinux
echo doing ppc64 make install
$(Q)$(MAKE) $(build)=$(boot) BOOTIMAGE=$(BOOTIMAGE) $@
archclean: archclean:
$(Q)$(MAKE) $(clean)=$(boot) $(Q)$(MAKE) $(clean)=$(boot)
......
...@@ -122,5 +122,7 @@ $(obj)/imagesize.c: vmlinux ...@@ -122,5 +122,7 @@ $(obj)/imagesize.c: vmlinux
awk '{printf "unsigned long vmlinux_memsize = 0x%s;\n", substr($$1,8)}' \ awk '{printf "unsigned long vmlinux_memsize = 0x%s;\n", substr($$1,8)}' \
>> $(obj)/imagesize.c >> $(obj)/imagesize.c
install: $(CONFIGURE) $(BOOTIMAGE)
sh -x $(src)/install.sh "$(KERNELRELEASE)" "$(obj)/zImage" "$(TOPDIR)/System.map" "$(INSTALL_PATH)"
clean-files := $(patsubst $(obj)/%,%, $(obj-boot)) clean-files := $(patsubst $(obj)/%,%, $(obj-boot))
...@@ -115,8 +115,17 @@ unsigned long eeh_check_failure(void *token, unsigned long val) ...@@ -115,8 +115,17 @@ unsigned long eeh_check_failure(void *token, unsigned long val)
ret = rtas_call(ibm_read_slot_reset_state, 3, 3, rets, ret = rtas_call(ibm_read_slot_reset_state, 3, 3, rets,
dn->eeh_config_addr, BUID_HI(dn->phb->buid), BUID_LO(dn->phb->buid)); dn->eeh_config_addr, BUID_HI(dn->phb->buid), BUID_LO(dn->phb->buid));
if (ret == 0 && rets[1] == 1 && rets[0] >= 2) { if (ret == 0 && rets[1] == 1 && rets[0] >= 2) {
panic("EEH: MMIO failure (%ld) on device:\n %s %s\n", /*
rets[0], pci_name(dev), dev->dev.name); * XXX We should create a separate sysctl for this.
*
* Since the panic_on_oops sysctl is used to halt
* the system in light of potential corruption, we
* can use it here.
*/
if (panic_on_oops)
panic("EEH: MMIO failure (%ld) on device:\n%s\n", rets[0], pci_name(dev));
else
printk("EEH: MMIO failure (%ld) on device:\n%s\n", rets[0], pci_name(dev));
} }
} }
eeh_false_positives++; eeh_false_positives++;
......
...@@ -40,6 +40,15 @@ ...@@ -40,6 +40,15 @@
#define DO_SOFT_DISABLE #define DO_SOFT_DISABLE
#endif #endif
/* copy saved SOFTE bit or EE bit from saved MSR depending
* if we are doing soft-disable or not
*/
#ifdef DO_SOFT_DISABLE
#define DO_COPY_EE() ld r20,SOFTE(r1)
#else
#define DO_COPY_EE() rldicl r20,r23,49,63
#endif
/* /*
* hcall interface to pSeries LPAR * hcall interface to pSeries LPAR
*/ */
...@@ -618,11 +627,7 @@ stab_bolted_user_return: ...@@ -618,11 +627,7 @@ stab_bolted_user_return:
ld r4,_DAR(r1) ld r4,_DAR(r1)
ld r5,_DSISR(r1) ld r5,_DSISR(r1)
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1) /* Copy saved SOFTE bit */
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x300 li r6,0x300
bl .save_remaining_regs bl .save_remaining_regs
bl .do_page_fault bl .do_page_fault
...@@ -644,12 +649,9 @@ DataAccessSLB_common: ...@@ -644,12 +649,9 @@ DataAccessSLB_common:
or. r3,r3,r3 /* Check return code */ or. r3,r3,r3 /* Check return code */
beq fast_exception_return /* Return if we succeeded */ beq fast_exception_return /* Return if we succeeded */
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x380 li r6,0x380
li r5,0
bl .save_remaining_regs bl .save_remaining_regs
bl .do_page_fault bl .do_page_fault
b .ret_from_except b .ret_from_except
...@@ -670,13 +672,9 @@ InstructionAccess_common: ...@@ -670,13 +672,9 @@ InstructionAccess_common:
bl .do_hash_page_ISI /* Try to handle as hpte fault */ bl .do_hash_page_ISI /* Try to handle as hpte fault */
1: 1:
mr r4,r22 mr r4,r22
mr r5,r23 rlwinm r5,r23,0,4,4 /* We only care about PR in error_code */
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x400 li r6,0x400
bl .save_remaining_regs bl .save_remaining_regs
bl .do_page_fault bl .do_page_fault
...@@ -692,12 +690,9 @@ InstructionAccessSLB_common: ...@@ -692,12 +690,9 @@ InstructionAccessSLB_common:
beq+ fast_exception_return /* Return if we succeeded */ beq+ fast_exception_return /* Return if we succeeded */
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x480 li r6,0x480
li r5,0
bl .save_remaining_regs bl .save_remaining_regs
bl .do_page_fault bl .do_page_fault
b .ret_from_except b .ret_from_except
...@@ -769,11 +764,7 @@ HardwareInterrupt_entry: ...@@ -769,11 +764,7 @@ HardwareInterrupt_entry:
Alignment_common: Alignment_common:
EXCEPTION_PROLOG_COMMON EXCEPTION_PROLOG_COMMON
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x600 li r6,0x600
bl .save_remaining_regs bl .save_remaining_regs
bl .AlignmentException bl .AlignmentException
...@@ -783,11 +774,7 @@ Alignment_common: ...@@ -783,11 +774,7 @@ Alignment_common:
ProgramCheck_common: ProgramCheck_common:
EXCEPTION_PROLOG_COMMON EXCEPTION_PROLOG_COMMON
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x700 li r6,0x700
bl .save_remaining_regs bl .save_remaining_regs
bl .ProgramCheckException bl .ProgramCheckException
...@@ -798,11 +785,7 @@ FPUnavailable_common: ...@@ -798,11 +785,7 @@ FPUnavailable_common:
EXCEPTION_PROLOG_COMMON EXCEPTION_PROLOG_COMMON
bne .load_up_fpu /* if from user, just load it up */ bne .load_up_fpu /* if from user, just load it up */
addi r3,r1,STACK_FRAME_OVERHEAD addi r3,r1,STACK_FRAME_OVERHEAD
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0x800 li r6,0x800
bl .save_remaining_regs bl .save_remaining_regs
bl .KernelFPUnavailableException bl .KernelFPUnavailableException
...@@ -818,11 +801,7 @@ SystemCall_common: ...@@ -818,11 +801,7 @@ SystemCall_common:
beq+ HardwareInterrupt_entry beq+ HardwareInterrupt_entry
1: 1:
#endif #endif
#ifdef DO_SOFT_DISABLE DO_COPY_EE()
ld r20,SOFTE(r1)
#else
rldicl r20,r23,49,63 /* copy EE bit from saved MSR */
#endif
li r6,0xC00 li r6,0xC00
bl .save_remaining_regs bl .save_remaining_regs
bl .DoSyscall bl .DoSyscall
......
...@@ -427,6 +427,7 @@ unsigned long __init find_and_init_phbs(void) ...@@ -427,6 +427,7 @@ unsigned long __init find_and_init_phbs(void)
void pcibios_name_device(struct pci_dev *dev) void pcibios_name_device(struct pci_dev *dev)
{ {
#if 0
struct device_node *dn; struct device_node *dn;
/* /*
...@@ -446,6 +447,7 @@ void pcibios_name_device(struct pci_dev *dev) ...@@ -446,6 +447,7 @@ void pcibios_name_device(struct pci_dev *dev)
} }
} }
} }
#endif
} }
void __init pcibios_fixup_device_resources(struct pci_dev *dev, void __init pcibios_fixup_device_resources(struct pci_dev *dev,
......
...@@ -267,6 +267,15 @@ void xics_disable_irq(u_int virq) ...@@ -267,6 +267,15 @@ void xics_disable_irq(u_int virq)
irq, call_status); irq, call_status);
return; return;
} }
/* Have to set XIVE to 0xff to be able to remove a slot */
call_status = rtas_call(ibm_set_xive, 3, 1, NULL, irq, default_server,
0xff);
if (call_status != 0) {
printk("xics_disable_irq: irq=%x: ibm_set_xive(0xff) returned %lx\n",
irq, call_status);
return;
}
} }
void xics_end_irq(u_int irq) void xics_end_irq(u_int irq)
......
...@@ -46,8 +46,10 @@ int debugger_kernel_faults = 1; ...@@ -46,8 +46,10 @@ int debugger_kernel_faults = 1;
void bad_page_fault(struct pt_regs *, unsigned long, int); void bad_page_fault(struct pt_regs *, unsigned long, int);
/* /*
* For 600- and 800-family processors, the error_code parameter is DSISR * The error_code parameter is
* for a data fault, SRR1 for an instruction fault. * - DSISR for a non-SLB data access fault,
* - SRR1 & 0x08000000 for a non-SLB instruction access fault
* - 0 any SLB fault.
*/ */
void do_page_fault(struct pt_regs *regs, unsigned long address, void do_page_fault(struct pt_regs *regs, unsigned long address,
unsigned long error_code) unsigned long error_code)
...@@ -58,17 +60,6 @@ void do_page_fault(struct pt_regs *regs, unsigned long address, ...@@ -58,17 +60,6 @@ void do_page_fault(struct pt_regs *regs, unsigned long address,
unsigned long code = SEGV_MAPERR; unsigned long code = SEGV_MAPERR;
unsigned long is_write = error_code & 0x02000000; unsigned long is_write = error_code & 0x02000000;
/*
* Fortunately the bit assignments in SRR1 for an instruction
* fault and DSISR for a data fault are mostly the same for the
* bits we are interested in. But there are some bits which
* indicate errors in DSISR but can validly be set in SRR1.
*/
if (regs->trap == 0x400)
error_code &= 0x48200000;
else if (regs->trap != 0x300) /* ensure error_code is 0 on SLB miss */
error_code = 0;
#ifdef CONFIG_DEBUG_KERNEL #ifdef CONFIG_DEBUG_KERNEL
if (debugger_fault_handler && (regs->trap == 0x300 || if (debugger_fault_handler && (regs->trap == 0x300 ||
regs->trap == 0x380)) { regs->trap == 0x380)) {
......
...@@ -183,8 +183,6 @@ extern struct device_node *find_type_devices(const char *type); ...@@ -183,8 +183,6 @@ extern struct device_node *find_type_devices(const char *type);
extern struct device_node *find_path_device(const char *path); extern struct device_node *find_path_device(const char *path);
extern struct device_node *find_compatible_devices(const char *type, extern struct device_node *find_compatible_devices(const char *type,
const char *compat); const char *compat);
extern struct device_node *find_pci_device_OFnode(unsigned char bus,
unsigned char dev_fn);
extern struct device_node *find_all_nodes(void); extern struct device_node *find_all_nodes(void);
extern int device_is_compatible(struct device_node *device, const char *); extern int device_is_compatible(struct device_node *device, const char *);
extern int machine_is_compatible(const char *compat); extern int machine_is_compatible(const char *compat);
......
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