Initialize/destory hw-properties within the hw-device.

This commit is contained in:
Andrew Cagney 1998-05-25 08:29:05 +00:00
parent 69be0d4cb8
commit 325a1ba876
4 changed files with 29 additions and 0 deletions

View File

@ -1,3 +1,11 @@
Mon May 25 18:21:38 1998 Andrew Cagney <cagney@b1.cygnus.com>
* hw-base.h (create_hw_property_data, delete_hw_property_data):
Declare.
* hw-base.c (hw_create, hw_delete): Call
* hw-properties.c (create_hw_property_data,
delete_hw_property_data): Define.
Mon May 25 17:40:46 1998 Andrew Cagney <cagney@b1.cygnus.com>
* hw-device.c, hw-properties.c: Include hw-base.h

View File

@ -418,6 +418,7 @@ hw_create (struct sim_state *sd,
/* Attach dummy ports */
create_hw_alloc_data (hw);
create_hw_property_data (hw);
create_hw_port_data (hw);
create_hw_event_data (hw);
@ -473,6 +474,7 @@ hw_delete (struct hw *me)
delete_hw_event_data (me);
delete_hw_port_data (me);
delete_hw_property_data (me);
/* now unlink us from the tree */
if (hw_parent (me))

View File

@ -150,6 +150,14 @@ extern void delete_hw_port_data
(struct hw *hw);
/* PROPERTIES */
extern void create_hw_property_data
(struct hw *hw);
extern void delete_hw_property_data
(struct hw *hw);
/* EVENTS */
extern void create_hw_event_data

View File

@ -42,6 +42,17 @@ struct hw_property_data {
unsigned sizeof_init_array;
};
void
create_hw_property_data (struct hw *me)
{
}
void
delete_hw_property_data (struct hw *me)
{
}
/* Device Properties: */
static struct hw_property_data *