* [Qemu-devel] [PATCH] e1000: use alias for default model
@ 2015-09-28 5:40 Jason Wang
2015-09-28 8:57 ` Markus Armbruster
0 siblings, 1 reply; 3+ messages in thread
From: Jason Wang @ 2015-09-28 5:40 UTC (permalink / raw)
To: qemu-devel, jasowang; +Cc: Markus Armbruster
Instead of using a new type for default model (82540em), using an
alias for this to avoid bit duplication.
Cc: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
hw/net/e1000.c | 8 +-------
qdev-monitor.c | 1 +
2 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/hw/net/e1000.c b/hw/net/e1000.c
index 09c9e9d..910de3a 100644
--- a/hw/net/e1000.c
+++ b/hw/net/e1000.c
@@ -1647,7 +1647,7 @@ static const TypeInfo e1000_base_info = {
static const E1000Info e1000_devices[] = {
{
- .name = "e1000-82540em",
+ .name = "e1000",
.device_id = E1000_DEV_ID_82540EM,
.revision = 0x03,
.phy_id2 = E1000_PHY_ID2_8254xx_DEFAULT,
@@ -1666,11 +1666,6 @@ static const E1000Info e1000_devices[] = {
},
};
-static const TypeInfo e1000_default_info = {
- .name = "e1000",
- .parent = "e1000-82540em",
-};
-
static void e1000_register_types(void)
{
int i;
@@ -1688,7 +1683,6 @@ static void e1000_register_types(void)
type_register(&type_info);
}
- type_register_static(&e1000_default_info);
}
type_init(e1000_register_types)
diff --git a/qdev-monitor.c b/qdev-monitor.c
index eb7aef2..00f6303 100644
--- a/qdev-monitor.c
+++ b/qdev-monitor.c
@@ -50,6 +50,7 @@ static const QDevAlias qdev_alias_table[] = {
{ "lsi53c895a", "lsi" },
{ "ich9-ahci", "ahci" },
{ "kvm-pci-assign", "pci-assign" },
+ { "e1000", "e1000-82540em" },
{ }
};
--
2.1.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH] e1000: use alias for default model
2015-09-28 5:40 [Qemu-devel] [PATCH] e1000: use alias for default model Jason Wang
@ 2015-09-28 8:57 ` Markus Armbruster
2015-09-29 3:16 ` Jason Wang
0 siblings, 1 reply; 3+ messages in thread
From: Markus Armbruster @ 2015-09-28 8:57 UTC (permalink / raw)
To: Jason Wang; +Cc: qemu-devel
Jason Wang <jasowang@redhat.com> writes:
> Instead of using a new type for default model (82540em), using an
> alias for this to avoid bit duplication.
Suggest to rephrase as
Instead of duplicating the "e1000-82540em" device model as "e1000",
make the latter an alias for the former.
> Cc: Markus Armbruster <armbru@redhat.com>
> Signed-off-by: Jason Wang <jasowang@redhat.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH] e1000: use alias for default model
2015-09-28 8:57 ` Markus Armbruster
@ 2015-09-29 3:16 ` Jason Wang
0 siblings, 0 replies; 3+ messages in thread
From: Jason Wang @ 2015-09-29 3:16 UTC (permalink / raw)
To: Markus Armbruster; +Cc: qemu-devel
On 09/28/2015 04:57 PM, Markus Armbruster wrote:
> Jason Wang <jasowang@redhat.com> writes:
>
>> Instead of using a new type for default model (82540em), using an
>> alias for this to avoid bit duplication.
> Suggest to rephrase as
>
> Instead of duplicating the "e1000-82540em" device model as "e1000",
> make the latter an alias for the former.
Fix like this and apply the patch in my tree.
>
>> Cc: Markus Armbruster <armbru@redhat.com>
>> Signed-off-by: Jason Wang <jasowang@redhat.com>
> Reviewed-by: Markus Armbruster <armbru@redhat.com>
Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-09-29 3:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-28 5:40 [Qemu-devel] [PATCH] e1000: use alias for default model Jason Wang
2015-09-28 8:57 ` Markus Armbruster
2015-09-29 3:16 ` Jason Wang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).