PATCH/OBVIOUS Remove various trailing spaces in linux-osdata.c
[deliverable/binutils-gdb.git] / gdb / i386-fbsd-nat.c
index a5b20c243cbf5c84d9ce2821ed5d1df69917205f..ced369e690d333e7fc9240a5461799d5b4fe8ad9 100644 (file)
@@ -46,7 +46,7 @@ public:
   void resume (ptid_t, int, enum gdb_signal) override;
 
 #if defined(HAVE_PT_GETDBREGS) && defined(USE_SIGTRAP_SIGINFO)
-  int supports_stopped_by_hw_breakpoint () override;
+  bool supports_stopped_by_hw_breakpoint () override;
 #endif
 };
 
@@ -58,14 +58,14 @@ static i386_fbsd_nat_target the_i386_fbsd_nat_target;
 void
 i386_fbsd_nat_target::resume (ptid_t ptid, int step, enum gdb_signal signal)
 {
-  pid_t pid = ptid_get_pid (ptid);
+  pid_t pid = ptid.pid ();
   int request = PT_STEP;
 
   if (pid == -1)
     /* Resume all threads.  This only gets used in the non-threaded
        case, where "resume all threads" and "resume inferior_ptid" are
        the same.  */
-    pid = ptid_get_pid (inferior_ptid);
+    pid = inferior_ptid.pid ();
 
   if (!step)
     {
@@ -123,13 +123,13 @@ i386fbsd_supply_pcb (struct regcache *regcache, struct pcb *pcb)
     return 0;
 
   pcb->pcb_esp += 4;
-  regcache_raw_supply (regcache, I386_EDI_REGNUM, &pcb->pcb_edi);
-  regcache_raw_supply (regcache, I386_ESI_REGNUM, &pcb->pcb_esi);
-  regcache_raw_supply (regcache, I386_EBP_REGNUM, &pcb->pcb_ebp);
-  regcache_raw_supply (regcache, I386_ESP_REGNUM, &pcb->pcb_esp);
-  regcache_raw_supply (regcache, I386_EBX_REGNUM, &pcb->pcb_ebx);
-  regcache_raw_supply (regcache, I386_EIP_REGNUM, &pcb->pcb_eip);
-  regcache_raw_supply (regcache, I386_GS_REGNUM, &pcb->pcb_gs);
+  regcache->raw_supply (I386_EDI_REGNUM, &pcb->pcb_edi);
+  regcache->raw_supply (I386_ESI_REGNUM, &pcb->pcb_esi);
+  regcache->raw_supply (I386_EBP_REGNUM, &pcb->pcb_ebp);
+  regcache->raw_supply (I386_ESP_REGNUM, &pcb->pcb_esp);
+  regcache->raw_supply (I386_EBX_REGNUM, &pcb->pcb_ebx);
+  regcache->raw_supply (I386_EIP_REGNUM, &pcb->pcb_eip);
+  regcache->raw_supply (I386_GS_REGNUM, &pcb->pcb_gs);
 
   return 1;
 }
@@ -148,7 +148,7 @@ i386_fbsd_nat_target::read_description ()
     {
       struct ptrace_xstate_info info;
 
-      if (ptrace (PT_GETXSTATE_INFO, ptid_get_pid (inferior_ptid),
+      if (ptrace (PT_GETXSTATE_INFO, inferior_ptid.pid (),
                  (PTRACE_TYPE_ARG3) &info, sizeof (info)) == 0)
        {
          x86bsd_xsave_len = info.xsave_len;
@@ -167,17 +167,17 @@ i386_fbsd_nat_target::read_description ()
 #if defined(HAVE_PT_GETDBREGS) && defined(USE_SIGTRAP_SIGINFO)
 /* Implement the supports_stopped_by_hw_breakpoints method.  */
 
-int
+bool
 i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint ()
 {
-  return 1;
+  return true;
 }
 #endif
 
 void
 _initialize_i386fbsd_nat (void)
 {
-  add_target (&the_i386_fbsd_nat_target);
+  add_inf_child_target (&the_i386_fbsd_nat_target);
 
   /* Support debugging kernel virtual memory images.  */
   bsd_kvm_add_target (i386fbsd_supply_pcb);
This page took 0.024942 seconds and 4 git commands to generate.