Merge branch 'dbg-early-merge' of git://git.kernel.org/pub/scm/linux/kernel/git/jwess...
[pandora-kernel.git] / include / linux / kgdb.h
index 19d1b29..9340f34 100644 (file)
@@ -207,6 +207,17 @@ extern int kgdb_validate_break_address(unsigned long addr);
 extern int kgdb_arch_set_breakpoint(unsigned long addr, char *saved_instr);
 extern int kgdb_arch_remove_breakpoint(unsigned long addr, char *bundle);
 
+/**
+ *     kgdb_arch_late - Perform any architecture specific initalization.
+ *
+ *     This function will handle the late initalization of any
+ *     architecture specific callbacks.  This is an optional function for
+ *     handling things like late initialization of hw breakpoints.  The
+ *     default implementation does nothing.
+ */
+extern void kgdb_arch_late(void);
+
+
 /**
  * struct kgdb_arch - Describe architecture specific values.
  * @gdb_bpt_instr: The instruction to trigger a breakpoint.
@@ -247,6 +258,8 @@ struct kgdb_arch {
  * the I/O driver.
  * @post_exception: Pointer to a function that will do any cleanup work
  * for the I/O driver.
+ * @is_console: 1 if the end device is a console 0 if the I/O device is
+ * not a console
  */
 struct kgdb_io {
        const char              *name;
@@ -256,6 +269,7 @@ struct kgdb_io {
        int                     (*init) (void);
        void                    (*pre_exception) (void);
        void                    (*post_exception) (void);
+       int                     is_console;
 };
 
 extern struct kgdb_arch                arch_kgdb_ops;
@@ -271,6 +285,7 @@ extern int kgdb_mem2hex(char *mem, char *buf, int count);
 extern int kgdb_hex2mem(char *buf, char *mem, int count);
 
 extern int kgdb_isremovedbreak(unsigned long addr);
+extern void kgdb_schedule_breakpoint(void);
 
 extern int
 kgdb_handle_exception(int ex_vector, int signo, int err_code,
@@ -281,7 +296,10 @@ extern int                 kgdb_single_step;
 extern atomic_t                        kgdb_active;
 #define in_dbg_master() \
        (raw_smp_processor_id() == atomic_read(&kgdb_active))
+extern bool dbg_is_early;
+extern void __init dbg_late_init(void);
 #else /* ! CONFIG_KGDB */
 #define in_dbg_master() (0)
+#define dbg_late_init()
 #endif /* ! CONFIG_KGDB */
 #endif /* _KGDB_H_ */