* as.h [NEED_DECLARATION_FFS] (ffs): Prototype and alphabetize.
[deliverable/binutils-gdb.git] / gdb / nto-tdep.h
index e22e8fd525cd5630dadca5fdd9c30a7dfe58e5cd..c903bab6398dac37108af3af7829e63b916a232a 100644 (file)
 
 #include "defs.h"
 #include "solist.h"
-
-/* Generic functions in nto-tdep.c.  */
-
-extern void nto_init_solib_absolute_prefix (void);
-
-char **nto_parse_redirection (char *start_argv[], char **in,
-                             char **out, char **err);
-
-int proc_iterate_over_mappings (int (*func) (int, CORE_ADDR));
-
-void nto_relocate_section_addresses (struct so_list *, struct section_table *);
-
-int nto_map_arch_to_cputype (const char *);
-
-int nto_find_and_open_solib (char *, unsigned, char **);
-
-/* Dummy function for initializing nto_target_ops on targets which do
-   not define a particular regset.  */
-void nto_dummy_supply_regset (char *regs);
+#include "osabi.h"
+#include "regset.h"
 
 /* Target operations defined for Neutrino targets (<target>-nto-tdep.c).  */
 
 struct nto_target_ops
 {
-  int nto_internal_debugging;
-  unsigned nto_cpuinfo_flags;
-  int nto_cpuinfo_valid;
-
-  int (*nto_regset_id) (int);
-  void (*nto_supply_gregset) (char *);
-  void (*nto_supply_fpregset) (char *);
-  void (*nto_supply_altregset) (char *);
-  void (*nto_supply_regset) (int, char *);
-  int (*nto_register_area) (int, int, unsigned *);
-  int (*nto_regset_fill) (int, char *);
-  struct link_map_offsets *(*nto_fetch_link_map_offsets) (void);
-};
-
-extern struct nto_target_ops current_nto_target;
-
 /* For 'maintenance debug nto-debug' command.  */
-#define nto_internal_debugging \
-       (current_nto_target.nto_internal_debugging)
+  int internal_debugging;
 
 /* The CPUINFO flags from the remote.  Currently used by
    i386 for fxsave but future proofing other hosts.
@@ -76,47 +42,69 @@ extern struct nto_target_ops current_nto_target;
    depending on our host/target.  It would only be invalid
    if we were talking to an older pdebug which didn't support
    the cpuinfo message.  */
-#define nto_cpuinfo_flags \
-       (current_nto_target.nto_cpuinfo_flags)
+  unsigned cpuinfo_flags;
 
 /* True if successfully retrieved cpuinfo from remote.  */
-#define nto_cpuinfo_valid \
-       (current_nto_target.nto_cpuinfo_valid)
+  int cpuinfo_valid;
 
 /* Given a register, return an id that represents the Neutrino
    regset it came from.  If reg == -1 update all regsets.  */
-#define nto_regset_id(reg) \
-       (*current_nto_target.nto_regset_id) (reg)
+  int (*regset_id) (int);
 
-#define nto_supply_gregset(regs) \
-       (*current_nto_target.nto_supply_gregset) (regs)
+  void (*supply_gregset) (char *);
 
-#define nto_supply_fpregset(regs) \
-       (*current_nto_target.nto_supply_fpregset) (regs)
+  void (*supply_fpregset) (char *);
 
-#define nto_supply_altregset(regs) \
-       (*current_nto_target.nto_supply_altregset) (regs)
+  void (*supply_altregset) (char *);
 
 /* Given a regset, tell gdb about registers stored in data.  */
-#define nto_supply_regset(regset, data) \
-       (*current_nto_target.nto_supply_regset) (regset, data)
+  void (*supply_regset) (int, char *);
 
 /* Given a register and regset, calculate the offset into the regset
    and stuff it into the last argument.  If regno is -1, calculate the
    size of the entire regset.  Returns length of data, -1 if unknown
    regset, 0 if unknown register.  */
-#define nto_register_area(reg, regset, off) \
-       (*current_nto_target.nto_register_area) (reg, regset, off)
+  int (*register_area) (int, int, unsigned *);
 
 /* Build the Neutrino register set info into the data buffer.  
    Return -1 if unknown regset, 0 otherwise.  */
-#define nto_regset_fill(regset, data) \
-       (*current_nto_target.nto_regset_fill) (regset, data)
+  int (*regset_fill) (int, char *);
 
 /* Gives the fetch_link_map_offsets function exposure outside of
    solib-svr4.c so that we can override relocate_section_addresses().  */
-#define nto_fetch_link_map_offsets() \
-       (*current_nto_target.nto_fetch_link_map_offsets) ()
+  struct link_map_offsets *(*fetch_link_map_offsets) (void);
+
+/* Used by nto_elf_osabi_sniffer to determine if we're connected to an
+   Neutrino target.  */
+  enum gdb_osabi (*is_nto_target) (bfd *abfd);
+};
+
+extern struct nto_target_ops current_nto_target;
+
+#define nto_internal_debugging (current_nto_target.internal_debugging)
+
+#define nto_cpuinfo_flags (current_nto_target.cpuinfo_flags)
+
+#define nto_cpuinfo_valid (current_nto_target.cpuinfo_valid)
+
+#define nto_regset_id (current_nto_target.regset_id)
+
+#define nto_supply_gregset (current_nto_target.supply_gregset)
+
+#define nto_supply_fpregset (current_nto_target.supply_fpregset)
+
+#define nto_supply_altregset (current_nto_target.supply_altregset)
+
+#define nto_supply_regset (current_nto_target.supply_regset)
+
+#define nto_register_area (current_nto_target.register_area)
+
+#define nto_regset_fill (current_nto_target.regset_fill)
+
+#define nto_fetch_link_map_offsets \
+(current_nto_target.fetch_link_map_offsets)
+
+#define nto_is_nto_target (current_nto_target.is_nto_target)
 
 /* Keep this consistant with neutrino syspage.h.  */
 enum
@@ -153,4 +141,41 @@ typedef struct _debug_regs
   qnx_reg64 padding[1024];
 } nto_regset_t;
 
+/* Generic functions in nto-tdep.c.  */
+
+void nto_init_solib_absolute_prefix (void);
+
+void nto_set_target(struct nto_target_ops *);
+
+char **nto_parse_redirection (char *start_argv[], char **in,
+                             char **out, char **err);
+
+int proc_iterate_over_mappings (int (*func) (int, CORE_ADDR));
+
+void nto_relocate_section_addresses (struct so_list *,
+                                    struct section_table *);
+
+int nto_map_arch_to_cputype (const char *);
+
+int nto_find_and_open_solib (char *, unsigned, char **);
+
+enum gdb_osabi nto_elf_osabi_sniffer (bfd *abfd);
+
+void nto_initialize_signals (void);
+
+void nto_generic_supply_gpregset (const struct regset *, struct regcache *,
+                                 int, const void *, size_t);
+
+void nto_generic_supply_fpregset (const struct regset *, struct regcache *,
+                                 int, const void *, size_t);
+
+void nto_generic_supply_altregset (const struct regset *, struct regcache *,
+                                  int, const void *, size_t);
+
+/* Dummy function for initializing nto_target_ops on targets which do
+   not define a particular regset.  */
+void nto_dummy_supply_regset (char *regs);
+
+int nto_in_dynsym_resolve_code (CORE_ADDR pc);
+
 #endif
This page took 0.025913 seconds and 4 git commands to generate.