--- crash-4.1.1/task.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/task.c 2009-12-07 08:50:22.000000000 -0500 @@ -568,6 +568,32 @@ } +int +in_irq_ctx(ulonglong type, int cpu, ulong addr) +{ + if (!(tt->flags & IRQSTACKS)) + return FALSE; + + switch (type) + { + case BT_SOFTIRQ: + if (tt->softirq_ctx[cpu] && + (addr >= tt->softirq_ctx[cpu]) && + (addr < (tt->softirq_ctx[cpu] + STACKSIZE()))) + return TRUE; + break; + + case BT_HARDIRQ: + if (tt->hardirq_ctx[cpu] && + (addr >= tt->hardirq_ctx[cpu]) && + (addr < (tt->hardirq_ctx[cpu] + STACKSIZE()))) + return TRUE; + break; + } + + return FALSE; +} + /* * Allocate or re-allocated space for the task_context array and task list. */ --- crash-4.1.1/kernel.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/kernel.c 2009-12-04 17:21:21.000000000 -0500 @@ -2099,6 +2099,22 @@ } } +int +in_alternate_stack(int cpu, ulong address) +{ + if (machdep->in_alternate_stack) + if (machdep->in_alternate_stack(cpu, address)) + return TRUE; + + if (tt->flags & IRQSTACKS) { + if (in_irq_ctx(BT_SOFTIRQ, cpu, address) || + in_irq_ctx(BT_HARDIRQ, cpu, address)) + return TRUE; + } + + return FALSE; +} + /* * Gather the EIP, ESP and stack address for the target task, and passing * them on to the machine-specific back trace command. @@ -2168,16 +2184,30 @@ } if (bt->hp) { - if (bt->hp->esp && !INSTACK(bt->hp->esp, bt)) + if (bt->hp->esp && !INSTACK(bt->hp->esp, bt) && + !in_alternate_stack(bt->tc->processor, bt->hp->esp)) error(INFO, - "non-process stack address for this task: %lx\n (valid range: %lx - %lx)\n", + "non-process stack address for this task: %lx\n" + " (valid range: %lx - %lx)\n", bt->hp->esp, bt->stackbase, bt->stacktop); + eip = bt->hp->eip; esp = bt->hp->esp; machdep->get_stack_frame(bt, eip ? NULL : &eip, esp ? NULL : &esp); - + + if (in_irq_ctx(BT_HARDIRQ, bt->tc->processor, esp)) { + bt->stackbase = tt->hardirq_ctx[bt->tc->processor]; + bt->stacktop = bt->stackbase + STACKSIZE(); + alter_stackbuf(bt); + bt->flags |= BT_HARDIRQ; + } else if (in_irq_ctx(BT_SOFTIRQ, bt->tc->processor, esp)) { + bt->stackbase = tt->softirq_ctx[bt->tc->processor]; + bt->stacktop = bt->stackbase + STACKSIZE(); + alter_stackbuf(bt); + bt->flags |= BT_SOFTIRQ; + } } else if (XEN_HYPER_MODE()) machdep->get_stack_frame(bt, &eip, &esp); else if (NETDUMP_DUMPFILE()) @@ -2253,6 +2283,11 @@ SIZE(irq_ctx) - (sizeof(char *)*2)); fprintf(fp, "--- ---\n"); + if (in_irq_ctx(BT_SOFTIRQ, bt->tc->processor, btloc.hp->esp)) { + btloc.flags |= BT_SOFTIRQ; + btloc.stackbase = tt->softirq_ctx[bt->tc->processor]; + btloc.stacktop = btloc.stackbase + STACKSIZE(); + } break; case BT_SOFTIRQ: @@ -2349,21 +2384,37 @@ break; } - bt->flags &= ~(BT_HARDIRQ|BT_SOFTIRQ); - bt->stackbase = GET_STACKBASE(bt->tc->task); - bt->stacktop = GET_STACKTOP(bt->tc->task); - - if (!readmem(bt->stackbase, KVADDR, bt->stackbuf, - bt->stacktop - bt->stackbase, - "restore_stack contents", RETURN_ON_ERROR)) { - error(INFO, "restore_stack of stack at %lx failed\n", - bt->stackbase); - type = 0; + if ((type == BT_HARDIRQ) && bt->instptr && + in_irq_ctx(BT_SOFTIRQ, bt->tc->processor, bt->stkptr)) { + bt->flags &= ~BT_HARDIRQ; + bt->flags |= BT_SOFTIRQ; + bt->stackbase = tt->softirq_ctx[bt->tc->processor]; + bt->stacktop = bt->stackbase + STACKSIZE(); + if (!readmem(bt->stackbase, KVADDR, bt->stackbuf, + bt->stacktop - bt->stackbase, + "restore softirq_ctx stack", RETURN_ON_ERROR)) { + error(INFO, + "read of softirq stack at %lx failed\n", + bt->stackbase); + type = 0; + } + } else { + bt->flags &= ~(BT_HARDIRQ|BT_SOFTIRQ); + bt->stackbase = GET_STACKBASE(bt->tc->task); + bt->stacktop = GET_STACKTOP(bt->tc->task); + + if (!readmem(bt->stackbase, KVADDR, bt->stackbuf, + bt->stacktop - bt->stackbase, + "restore_stack contents", RETURN_ON_ERROR)) { + error(INFO, "restore_stack of stack at %lx failed\n", + bt->stackbase); + type = 0; + } + + if (!(bt->instptr && INSTACK(bt->stkptr, bt))) + type = 0; } - if (!(bt->instptr && INSTACK(bt->stkptr, bt))) - type = 0; - if (type) { if (!BT_REFERENCE_CHECK(bt)) fprintf(fp, "--- %s ---\n", type == BT_HARDIRQ ? --- crash-4.1.1/configure.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/configure.c 2009-12-09 15:33:38.000000000 -0500 @@ -998,7 +998,7 @@ printf("Vendor: Red Hat, Inc.\n"); printf("Packager: Dave Anderson \n"); printf("ExclusiveOS: Linux\n"); - printf("ExclusiveArch: i386 alpha ia64 ppc ppc64 ppc64pseries ppc64iseries x86_64 s390 s390x\n"); + printf("ExclusiveArch: %%{ix86} alpha ia64 ppc ppc64 ppc64pseries ppc64iseries x86_64 s390 s390x\n"); printf("Buildroot: %%{_tmppath}/%%{name}-root\n"); printf("BuildRequires: ncurses-devel zlib-devel\n"); printf("Requires: binutils\n"); --- crash-4.1.1/s390dbf.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/s390dbf.c 2009-12-02 15:21:39.000000000 -0500 @@ -3,6 +3,16 @@ * * Copyright (C) IBM Corp. 2006 * Author(s): Michael Holzheu + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #if defined(S390) || defined(S390X) --- crash-4.1.1/x86_64.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/x86_64.c 2009-12-07 08:47:03.000000000 -0500 @@ -43,6 +43,7 @@ static void x86_64_back_trace_cmd(struct bt_info *); static ulong x86_64_in_exception_stack(struct bt_info *, int *); static ulong x86_64_in_irqstack(struct bt_info *); +static int x86_64_in_alternate_stack(int, ulong); static void x86_64_low_budget_back_trace_cmd(struct bt_info *); static void x86_64_dwarf_back_trace_cmd(struct bt_info *); static void x86_64_get_dumpfile_stack_frame(struct bt_info *, ulong *, ulong *); @@ -315,11 +316,15 @@ MEMBER_OFFSET_INIT(user_regs_struct_ss, "user_regs_struct", "ss"); STRUCT_SIZE_INIT(user_regs_struct, "user_regs_struct"); + machdep->vmalloc_start = x86_64_vmalloc_start; + vt->vmalloc_start = machdep->vmalloc_start(); + machdep->init_kernel_pgd(); if (STRUCT_EXISTS("x8664_pda")) x86_64_cpu_pda_init(); else x86_64_per_cpu_init(); x86_64_ist_init(); + machdep->in_alternate_stack = x86_64_in_alternate_stack; if ((machdep->machspec->irqstack = (char *) malloc(machdep->machspec->stkinfo.isize)) == NULL) error(FATAL, "cannot malloc irqstack space."); @@ -335,7 +340,6 @@ &machdep->nr_irqs); else machdep->nr_irqs = 224; /* NR_IRQS (at least) */ - machdep->vmalloc_start = x86_64_vmalloc_start; machdep->dump_irq = x86_64_dump_irq; if (!machdep->hz) { machdep->hz = HZ; @@ -502,6 +506,7 @@ fprintf(fp, "xen_kdump_p2m_create: x86_64_xen_kdump_p2m_create()\n"); fprintf(fp, " line_number_hooks: x86_64_line_number_hooks\n"); fprintf(fp, " value_to_symbol: x86_64_value_to_symbol()\n"); + fprintf(fp, " in_alternate_stack: x86_64_in_alternate_stack()\n"); fprintf(fp, " last_pgd_read: %lx\n", machdep->last_pgd_read); fprintf(fp, " last_pmd_read: %lx\n", machdep->last_pmd_read); fprintf(fp, " last_ptbl_read: %lx\n", machdep->last_ptbl_read); @@ -825,7 +830,7 @@ if (cpus > 1) kt->flags |= SMP; - if ((i = get_cpus_online()) && (i < cpus)) + if ((i = get_cpus_online()) && (!cpus || (i < cpus))) kt->cpus = get_highest_cpu_online() + 1; else kt->cpus = cpus; @@ -2503,6 +2508,29 @@ return irqstack; } +static int +x86_64_in_alternate_stack(int cpu, ulong rsp) +{ + int i; + struct machine_specific *ms; + + ms = machdep->machspec; + + if (ms->stkinfo.ibase[cpu] && + (rsp >= ms->stkinfo.ibase[cpu]) && + (rsp < (ms->stkinfo.ibase[cpu] + ms->stkinfo.isize))) + return TRUE; + + for (i = 0; i < MAX_EXCEPTION_STACKS; i++) { + if (ms->stkinfo.ebase[cpu][i] && + (rsp >= ms->stkinfo.ebase[cpu][i]) && + (rsp < (ms->stkinfo.ebase[cpu][i] + ms->stkinfo.esize[i]))) + return TRUE; + } + + return FALSE; +} + #define STACK_TRANSITION_ERRMSG_E_I_P \ "cannot transition from exception stack to IRQ stack to current process stack:\n exception stack pointer: %lx\n IRQ stack pointer: %lx\n process stack pointer: %lx\n current stack base: %lx\n" #define STACK_TRANSITION_ERRMSG_E_P \ @@ -4254,7 +4282,7 @@ cpus++; } - if ((i = get_cpus_online()) && (i < cpus)) + if ((i = get_cpus_online()) && (!cpus || (i < cpus))) cpus = get_highest_cpu_online() + 1; return cpus; --- crash-4.1.1/lkcd_x86_trace.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/lkcd_x86_trace.c 2009-12-04 16:19:09.000000000 -0500 @@ -8,6 +8,16 @@ * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 David Anderson * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted as noted from the following LKCD files: * * lkcdutils-4.1/lcrash/arch/i386/lib/dis.c @@ -753,6 +763,7 @@ instr_rec_t irp; syment_t *sp; #ifdef REDHAT + int check_IRQ_stack_switch = 0; syment_t *jmpsp, *trampsp; ulong offset; int frmsize_restore = 0; @@ -768,6 +779,9 @@ return(-1); } #ifdef REDHAT + if (STREQ(sp->name, "do_IRQ") && (tt->flags & IRQSTACKS)) + check_IRQ_stack_switch++; + if (STREQ(sp->name, "stext_lock") || STRNEQ(sp->name, ".text.lock.")) { jmpsp = x86_text_lock_jmp(pc, &offset); if (jmpsp) { @@ -802,6 +816,12 @@ } #ifdef REDHAT /* + * Account for do_IRQ() stack switch. + */ + if (check_IRQ_stack_switch && (irp.opcode == 0xff02) && + (irp.operand[0].op_reg == 0x7)) + break; + /* * Account for embedded "ret" instructions screwing up * the frame size calculation. */ --- crash-4.1.1/netdump.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/netdump.c 2009-12-03 10:28:59.000000000 -0500 @@ -3,12 +3,15 @@ * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 David Anderson * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Red Hat, Inc. All rights reserved. * - * This software may be freely redistributed under the terms of the - * GNU General Public License. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. * * Author: David Anderson */ @@ -694,6 +697,9 @@ else note32 = (Elf32_Nhdr *)nd->nt_prstatus; + if (!note32) + goto panic_task_undetermined; + len = sizeof(Elf32_Nhdr); len = roundup(len + note32->n_namesz, 4); len = roundup(len + note32->n_descsz, 4); @@ -738,6 +744,9 @@ else note64 = (Elf64_Nhdr *)nd->nt_prstatus; + if (!note64) + goto panic_task_undetermined; + len = sizeof(Elf64_Nhdr); len = roundup(len + note64->n_namesz, 4); user_regs = (char *)((char *)note64 + len + @@ -1302,6 +1311,11 @@ int others; struct pt_load_segment *pls; + if ((char *)prog > (nd->elf_header + nd->header_size)) + error(FATAL, + "Elf32_Phdr pointer: %lx ELF header end: %lx\n\n", + (char *)prog, nd->elf_header + nd->header_size); + if (store_pt_load_data) pls = &nd->pt_load_segments[store_pt_load_data-1]; else @@ -1391,6 +1405,11 @@ else pls = NULL; + if ((char *)prog > (nd->elf_header + nd->header_size)) + error(FATAL, + "Elf64_Phdr pointer: %lx ELF header end: %lx\n\n", + (char *)prog, nd->elf_header + nd->header_size); + netdump_print("Elf64_Phdr:\n"); netdump_print(" p_type: %lx ", prog->p_type); switch (prog->p_type) @@ -1577,11 +1596,10 @@ ptr = (char *)note + sizeof(Elf32_Nhdr); if (ptr > (nd->elf_header + nd->header_size)) { - if (CRASHDEBUG(1)) - error(WARNING, - "Elf32_Nhdr pointer: %lx ELF header end: %lx\n", - (char *)note, nd->elf_header + nd->header_size); - remaining = 0; + error(WARNING, + "Elf32_Nhdr pointer: %lx ELF header end: %lx\n", + (char *)note, nd->elf_header + nd->header_size); + return 0; } else remaining = (uint64_t)((nd->elf_header + nd->header_size) - ptr); @@ -1796,11 +1814,10 @@ xen_core = vmcoreinfo = FALSE; if (ptr > (nd->elf_header + nd->header_size)) { - if (CRASHDEBUG(1)) - error(WARNING, - "Elf64_Nhdr pointer: %lx ELF header end: %lx\n\n", - (char *)note, nd->elf_header + nd->header_size); - remaining = 0; + error(WARNING, + "Elf64_Nhdr pointer: %lx ELF header end: %lx\n\n", + (char *)note, nd->elf_header + nd->header_size); + return 0; } else remaining = (uint64_t)((nd->elf_header + nd->header_size) - ptr); --- crash-4.1.1/diskdump.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/diskdump.c 2009-12-02 15:19:25.000000000 -0500 @@ -12,12 +12,15 @@ * Copyright (C) 2005 FUJITSU LIMITED * Copyright (C) 2005 NEC Corporation * - * This software may be freely redistributed under the terms of the - * GNU General Public License. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "defs.h" --- crash-4.1.1/xendump.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/xendump.c 2009-12-02 15:22:53.000000000 -0500 @@ -4,12 +4,15 @@ * Copyright (C) 2006, 2007, 2008 David Anderson * Copyright (C) 2006, 2007, 2008 Red Hat, Inc. All rights reserved. * - * This software may be freely redistributed under the terms of the - * GNU General Public License. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "defs.h" --- crash-4.1.1/unwind.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind.c 2009-12-02 15:35:14.000000000 -0500 @@ -9,6 +9,16 @@ * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 David Anderson * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted from: * * arch/ia64/kernel/unwind.c (kernel-2.4.18-6.23) --- crash-4.1.1/unwind_decoder.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind_decoder.c 2009-12-02 15:35:51.000000000 -0500 @@ -9,6 +9,16 @@ * Copyright (C) 2002, 2003, 2004, 2005 David Anderson * Copyright (C) 2002, 2003, 2004, 2005 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted from: * * arch/ia64/kernel/unwind_decoder.c (kernel-2.4.18-6.23) --- crash-4.1.1/unwind_x86_32_64.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind_x86_32_64.c 2009-12-02 15:22:34.000000000 -0500 @@ -1,3 +1,15 @@ +/* + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + #if defined(X86_64) /* * Support for genarating DWARF CFI based backtraces. --- crash-4.1.1/kvmdump.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/kvmdump.c 2009-12-02 15:19:52.000000000 -0500 @@ -4,12 +4,15 @@ * Copyright (C) 2009 David Anderson * Copyright (C) 2009 Red Hat, Inc. All rights reserved. * - * This software may be freely redistributed under the terms of the - * GNU General Public License. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "defs.h" --- crash-4.1.1/qemu.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/qemu.c 2009-12-02 15:21:09.000000000 -0500 @@ -5,6 +5,16 @@ * Written by Paolo Bonzini. * * Portions Copyright (C) 2009 David Anderson + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include --- crash-4.1.1/qemu-load.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/qemu-load.c 2009-12-02 15:21:17.000000000 -0500 @@ -5,6 +5,16 @@ * Written by Paolo Bonzini. * * Portions Copyright (C) 2009 David Anderson + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #define _GNU_SOURCE --- crash-4.1.1/defs.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/defs.h 2009-12-07 08:47:20.000000000 -0500 @@ -791,6 +791,7 @@ void (*get_xendump_regs)(struct xendump_data *, struct bt_info *, ulong *, ulong *); void (*clear_machdep_cache)(void); int (*xen_kdump_p2m_create)(struct xen_kdump_data *); + int (*in_alternate_stack)(int, ulong); }; /* @@ -3666,6 +3667,7 @@ ulong generic_get_stacktop(ulong); void dump_task_table(int); void sort_context_array(void); +int in_irq_ctx(ulonglong, int, ulong); /* * extensions.c @@ -3712,6 +3714,7 @@ void paravirt_init(void); void print_stack_text_syms(struct bt_info *, ulong, ulong); void back_trace(struct bt_info *); +int in_alternate_stack(int, ulong); ulong cpu_map_addr(const char *type); #define BT_RAW (0x1ULL) #define BT_SYMBOLIC_ARGS (0x2ULL) --- crash-4.1.1/netdump.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/netdump.h 2009-12-02 15:09:50.000000000 -0500 @@ -3,12 +3,15 @@ * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 David Anderson * Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Red Hat, Inc. All rights reserved. * - * This software may be freely redistributed under the terms of the - * GNU General Public License. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. * * Author: David Anderson */ --- crash-4.1.1/diskdump.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/diskdump.h 2009-12-02 15:12:36.000000000 -0500 @@ -6,12 +6,15 @@ * Copyright (C) 2005 FUJITSU LIMITED * Copyright (C) 2005 NEC Corporation * - * This software may be freely redistributed under the terms of the - * GNU General Public License. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include --- crash-4.1.1/xendump.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/xendump.h 2009-12-02 15:11:03.000000000 -0500 @@ -4,12 +4,15 @@ * Copyright (C) 2006, 2007 David Anderson * Copyright (C) 2006, 2007 Red Hat, Inc. All rights reserved. * - * This software may be freely redistributed under the terms of the - * GNU General Public License. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/kvmdump.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/kvmdump.h 2009-12-02 15:08:47.000000000 -0500 @@ -4,12 +4,15 @@ * Copyright (C) 2009 David Anderson * Copyright (C) 2009 Red Hat, Inc. All rights reserved. * - * This software may be freely redistributed under the terms of the - * GNU General Public License. + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #define KVMDUMP_CACHED_PAGES 32 --- crash-4.1.1/qemu-load.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/qemu-load.h 2009-12-02 15:10:01.000000000 -0500 @@ -3,6 +3,16 @@ * * Copyright (C) 2009 Red Hat, Inc. * Written by Paolo Bonzini. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #ifndef QEMU_LOAD_H --- crash-4.1.1/unwind.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind.h 2009-12-02 15:36:09.000000000 -0500 @@ -13,6 +13,16 @@ * Copyright (C) 2002, 2003, 2004, 2005 David Anderson * Copyright (C) 2002, 2003, 2004, 2005 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted from: * * include/asm-ia64/fpu.h (kernel-2.4.18-6.23) --- crash-4.1.1/unwind_i.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind_i.h 2009-12-02 15:36:36.000000000 -0500 @@ -9,6 +9,16 @@ * Copyright (C) 2002, 2003, 2004, 2005 David Anderson * Copyright (C) 2002, 2003, 2004, 2005 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted from: * * arch/ia64/kernel/unwind_i.h (kernel-2.4.18-6.23) --- crash-4.1.1/rse.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/rse.h 2009-12-02 15:36:54.000000000 -0500 @@ -12,6 +12,16 @@ * Copyright (C) 2002, 2003, 2004, 2005 David Anderson * Copyright (C) 2002, 2003, 2004, 2005 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted from: * * include/asm-ia64/rse.h (2.4.9-e.3) --- crash-4.1.1/unwind_x86.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind_x86.h 2009-12-02 15:10:45.000000000 -0500 @@ -1,2 +1,12 @@ - +/* + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ --- crash-4.1.1/unwind_x86_64.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/unwind_x86_64.h 2009-12-02 15:10:32.000000000 -0500 @@ -1,3 +1,15 @@ +/* + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + #define CONFIG_64BIT 1 #define NULL ((void *)0) --- crash-4.1.1/lkcd_x86_trace.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/lkcd_x86_trace.h 2009-12-03 10:34:59.000000000 -0500 @@ -8,6 +8,16 @@ * Copyright (C) 2002, 2003, 2004, 2005 David Anderson * Copyright (C) 2002, 2003, 2004, 2005 Red Hat, Inc. All rights reserved. * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * * Adapted as noted from the following LKCD files: * * lkcdutils-4.1/libklib/include/asm-i386/kl_types.h --- crash-4.1.1/lkcd_fix_mem.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/lkcd_fix_mem.h 2009-12-02 15:13:48.000000000 -0500 @@ -1,3 +1,15 @@ +/* + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + /* OBSOLETE */ #ifdef IA64 --- crash-4.1.1/Makefile 2009-12-09 15:40:34.000000000 -0500 +++ crash-4.1.2/Makefile 2009-12-09 15:40:34.000000000 -0500 @@ -207,7 +207,7 @@ ${GDB}/gdb/ppc-linux-tdep.o GDB_7.0_FILES= -GDB_7.0_OFILES= +GDB_7.0_OFILES=${GDB}/gdb/symtab.o # # GDB_FLAGS is passed up from the gdb Makefile. --- crash-4.1.1/extensions/snap.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/snap.c 2009-11-25 15:37:25.000000000 -0500 @@ -30,7 +30,7 @@ { NULL } }; -static size_t generate_elf_header(int, int, char *); +static char *generate_elf_header(int, int, char *); static int verify_paddr(physaddr_t); static void init_ram_segments(void); static int print_progress(const char *, ulong); @@ -68,6 +68,9 @@ char *filename; struct node_table *nt; int type; + char *elf_header; + Elf64_Phdr *load; + int load_index; if (!supported) error(FATAL, "command not supported on the %s architecture\n", @@ -113,12 +116,17 @@ init_ram_segments(); - if (!(offset = generate_elf_header(type, fd, filename))) + if (!(elf_header = generate_elf_header(type, fd, filename))) error(FATAL, "cannot generate ELF header\n"); + load = (Elf64_Phdr *)(elf_header + sizeof(Elf64_Ehdr) + sizeof(Elf64_Phdr)); + load_index = machine_type("X86_64") || machine_type("IA64") ? 1 : 0; + for (n = 0; n < vt->numnodes; n++) { nt = &vt->node_table[n]; paddr = nt->start_paddr; + offset = load[load_index + n].p_offset; + for (c = 0; c < nt->size; c++, paddr += PAGESIZE()) { if (!verify_paddr(paddr)) continue; @@ -126,7 +134,7 @@ "memory page", QUIET|RETURN_ON_ERROR)) continue; - lseek(fd, (off_t)(paddr + offset), SEEK_SET); + lseek(fd, (off_t)(paddr + offset - nt->start_paddr), SEEK_SET); if (write(fd, &buf[0], PAGESIZE()) != PAGESIZE()) error(FATAL, "write to dumpfile failed\n"); @@ -140,6 +148,7 @@ sprintf(buf, "/bin/ls -l %s\n", filename); system(buf); + FREEBUF(elf_header); FREEBUF(buf); } @@ -375,7 +384,7 @@ return len; } -static size_t +char * generate_elf_header(int type, int fd, char *filename) { int i, n; @@ -581,15 +590,14 @@ len = write(fd, buffer + (data_offset - offset), offset); if (len < 0) { perror(filename); - data_offset = 0; - break; + FREEBUF(buffer); + return NULL; } offset -= len; } - FREEBUF(buffer); - return data_offset; + return buffer; } struct ram_segments { --- crash-4.1.1/extensions/snap.mk 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/snap.mk 2009-12-03 10:38:26.000000000 -0500 @@ -1,3 +1,18 @@ +# +# Copyright (C) 2009 David Anderson +# Copyright (C) 2009 Red Hat, Inc. All rights reserved. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# + ifeq ($(shell arch), i686) TARGET=X86 TARGET_CFLAGS=-D_FILE_OFFSET_BITS=64 --- crash-4.1.1/extensions/libsial/Makefile 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/Makefile 2009-12-02 15:39:42.000000000 -0500 @@ -4,7 +4,16 @@ # # Makefile for LIBSIAL # - +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# # Must be berkeley yacc. Bison will not cut it YACC = bison --- crash-4.1.1/extensions/libsial/mkbaseop.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/mkbaseop.c 2009-12-02 15:39:54.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2000 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include --- crash-4.1.1/extensions/libsial/sial_alloc.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_alloc.c 2009-12-02 15:40:11.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #define MEMDEBUG 1 --- crash-4.1.1/extensions/libsial/sial_api.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_api.c 2009-12-02 15:40:18.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial.h" #include "sial.tab.h" --- crash-4.1.1/extensions/libsial/sial_api.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_api.h 2009-12-02 15:40:25.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ /* minor and major version number */ --- crash-4.1.1/extensions/libsial/sial_builtin.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_builtin.c 2009-12-02 15:40:32.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial_case.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_case.c 2009-12-02 15:40:39.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ /* Set of functions to handle the case construct. --- crash-4.1.1/extensions/libsial/sial_define.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_define.c 2009-12-02 15:40:45.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial_func.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_func.c 2009-12-02 15:40:50.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial.h 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial.h 2009-12-02 15:40:57.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial_api.h" typedef unsigned long long caddr; --- crash-4.1.1/extensions/libsial/sial_input.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_input.c 2009-12-02 15:41:05.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial.l 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial.l 2009-12-02 15:41:12.000000000 -0500 @@ -1,6 +1,16 @@ %{ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ %} --- crash-4.1.1/extensions/libsial/sial-lsed 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial-lsed 2009-12-02 15:44:07.000000000 -0500 @@ -1,3 +1,14 @@ +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# s/yyback/sialback/g s/yybgin/sialbgin/g s/yycrank/sialcrank/g --- crash-4.1.1/extensions/libsial/sial_member.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_member.c 2009-12-02 15:41:27.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include "sial.h" --- crash-4.1.1/extensions/libsial/sial_node.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_node.c 2009-12-02 15:41:34.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ /* These function are use to allocate a new node. --- crash-4.1.1/extensions/libsial/sial_num.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_num.c 2009-12-02 15:41:39.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial_op.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_op.c 2009-12-02 15:41:44.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial.h" #include "sial.tab.h" --- crash-4.1.1/extensions/libsial/sialpp.l 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sialpp.l 2009-12-02 15:41:49.000000000 -0500 @@ -1,6 +1,16 @@ %{ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #define YY_NO_UNPUT --- crash-4.1.1/extensions/libsial/sialpp-lsed 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sialpp-lsed 2009-12-02 15:44:38.000000000 -0500 @@ -1,3 +1,14 @@ +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# s/yyback/sialppback/g s/yybgin/sialppbgin/g s/yycrank/sialppcrank/g --- crash-4.1.1/extensions/libsial/sialpp.y 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sialpp.y 2009-12-02 15:42:02.000000000 -0500 @@ -1,6 +1,16 @@ %{ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ /* This is the grammar for the preprocessor expression evaluation. --- crash-4.1.1/extensions/libsial/sial_print.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_print.c 2009-12-02 15:42:07.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial_stat.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_stat.c 2009-12-02 15:42:12.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial.h" #include "sial.tab.h" --- crash-4.1.1/extensions/libsial/sial_str.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_str.c 2009-12-02 15:42:17.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial_type.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_type.c 2009-12-02 15:42:26.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial.h" #include "sial.tab.h" --- crash-4.1.1/extensions/libsial/sial_util.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_util.c 2009-12-02 15:42:32.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial.h" #include --- crash-4.1.1/extensions/libsial/sial_var.c 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial_var.c 2009-12-02 15:42:41.000000000 -0500 @@ -1,5 +1,15 @@ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include #include --- crash-4.1.1/extensions/libsial/sial.y 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/libsial/sial.y 2009-12-02 15:42:48.000000000 -0500 @@ -1,6 +1,16 @@ %{ /* * Copyright 2001 Silicon Graphics, Inc. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. */ #include "sial.h" #include --- crash-4.1.1/extensions/sial.mk 2009-12-09 15:40:10.000000000 -0500 +++ crash-4.1.2/extensions/sial.mk 2009-12-02 15:28:20.000000000 -0500 @@ -1,4 +1,14 @@ # +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + ifeq ($(TARGET), PPC64) TARGET_FLAGS = -D$(TARGET) -m64 else