1 #ifndef _ASM_IA64_CRASHDUMP_H
2 #define _ASM_IA64_CRASHDUMP_H
5 * linux/include/asm-ia64/diskdump.h
7 * Copyright (c) 2004 FUJITSU LIMITED
8 * Copyright (c) 2003 Red Hat, Inc. All rights reserved.
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2, or (at your option)
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
28 #include <linux/elf.h>
29 #include <asm/unwind.h>
30 #include <asm/ptrace.h>
32 extern void ia64_do_copy_regs(struct unw_frame_info *, void *arg);
33 extern void ia64_freeze_cpu(struct unw_frame_info *, void *arg);
34 extern void ia64_start_dump(struct unw_frame_info *, void *arg);
35 extern int page_is_ram(unsigned long);
36 extern unsigned long next_ram_page(unsigned long);
38 #define platform_timestamp(x) ({ x = ia64_get_itc(); })
40 #define platform_fix_regs() \
42 struct unw_frame_info *info = platform_arg; \
44 current->thread.ksp = (__u64)info->sw - 16; \
48 #define platform_init_stack(stackptr) do { } while (0)
49 #define platform_cleanup_stack(stackptr) do { } while (0)
51 typedef asmlinkage void (*crashdump_func_t)(struct pt_regs *, void *);
53 /* Container to hold dump hander information */
54 struct dump_call_param {
55 crashdump_func_t func;
59 static inline void platform_start_crashdump(void *stackptr,
60 crashdump_func_t dumpfunc,
63 struct dump_call_param param;
65 param.func = dumpfunc;
67 unw_init_running(ia64_start_dump, ¶m);
70 #endif /* __KERNEL__ */
72 #endif /* _ASM_IA64_CRASHDUMP_H */