Manage objfiles with shared_ptr
[deliverable/binutils-gdb.git] / sim / common / dv-core.c
index e84f70d8ab2292f507090225e6b14713153407c4..3e2bcaa52fb0693ced912cba45fba9dcc343373d 100644 (file)
@@ -1,33 +1,34 @@
-/*  This file is part of the program psim.
-    
-    Copyright (C) 1994-1996, Andrew Cagney <cagney@highland.com.au>
-    
-    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.
-    
-    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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-    
-    */
+/* The common simulator framework for GDB, the GNU Debugger.
+
+   Copyright 2002-2019 Free Software Foundation, Inc.
+
+   Contributed by Andrew Cagney and Red Hat.
+
+   This file is part of GDB.
+
+   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 3 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.
+
+   You should have received a copy of the GNU General Public License
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 
 #include "sim-main.h"
-#include "hw-base.h"
+#include "hw-main.h"
 
 /* DEVICE
-   
+
    core - root of the device tree
-   
+
    DESCRIPTION
-   
+
    The core device, positioned at the root of the device tree appears
    to its child devices as a normal device just like every other
    device in the tree.
@@ -52,13 +53,11 @@ dv_core_attach_address_callback (struct hw *me,
                                 address_word nr_bytes,
                                 struct hw *client)
 {
-  HW_TRACE ((me, "attach (level=%d, space=%d, addr=0x%lx, nr_bytes=%ld, client=0x%lx)",
-            level, space, (unsigned long) addr, (unsigned long) nr_bytes, (unsigned long) client));
+  HW_TRACE ((me, "attach - level=%d, space=%d, addr=0x%lx, nr_bytes=%ld, client=%s",
+            level, space, (unsigned long) addr, (unsigned long) nr_bytes, hw_path (client)));
   /* NOTE: At preset the space is assumed to be zero.  Perhaphs the
      space should be mapped onto something for instance: space0 -
      unified memory; space1 - IO memory; ... */
-  if (space != 0)
-    hw_abort (me, "Hey! Unknown space %d", space);
   sim_core_attach (hw_system (me),
                   NULL, /*cpu*/
                   level,
@@ -112,7 +111,7 @@ dv_core_finish (struct hw *me)
   set_hw_dma_read_buffer (me, dv_core_dma_read_buffer_callback);
 }
 
-const struct hw_device_descriptor dv_core_descriptor[] = {
+const struct hw_descriptor dv_core_descriptor[] = {
   { "core", dv_core_finish, },
-  { NULL },
+  { NULL, NULL },
 };
This page took 0.02595 seconds and 4 git commands to generate.