Skip to contentSkip to conversation

qdev: Start disentangling bus from device

PATCH In review Andreas Färber 2 participants 2 messages Feb 12, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 qdev: Start disentangling bus from device

Move bus type and related APIs to a separate file bus.c. This is a first step in breaking up qdev.c into more manageable chunks.

---
Here's a first step in breaking up qdev.c, originally prepared as part of my QOM device reset refactoring. Amazingly it still applied.

 hw/core/Makefile.objs |   1 +
 hw/core/bus.c         | 248 ++++++++++++++++++++++++++++++++++++++++++++++++++
 hw/core/qdev.c        | 222 --------------------------------------------
 3 files changed, 249 insertions(+), 222 deletions(-)
 create mode 100644 hw/core/bus.c
hw/core/Makefile.objs +1 -0
index abb3560..b4f88e3 100644
@@ -1,5 +1,6 @@
 # core qdev-related obj files, also used by *-user:
 common-obj-y += qdev.o qdev-properties.o
+common-obj-y += bus.o
 common-obj-y += fw-path-provider.o
 # irq.o needed for qdev GPIO handling:
 common-obj-y += irq.o
hw/core/bus.c new file +248 -0

248 lines not on this page · raw message

hw/core/qdev.c +0 -222

248 lines not on this page · raw message

Signature · 1 line
2.6.2
Reviewed-by on v1 1/1
#1 lore raw
Quoted 8 lines · Andreas Färber

Move bus type and related APIs to a separate file bus.c. This is a first step in breaking up qdev.c into more manageable chunks.

---
Here's a first step in breaking up qdev.c, originally prepared as part of my QOM device reset refactoring. Amazingly it still applied.

Quoted 5 lines
 hw/core/Makefile.objs |   1 +
 hw/core/bus.c         | 248 ++++++++++++++++++++++++++++++++++++++++++++++++++
 hw/core/qdev.c        | 222 --------------------------------------------
 3 files changed, 249 insertions(+), 222 deletions(-)
 create mode 100644 hw/core/bus.c

Makes sense to me. I eyeballed the patch to confirm that it's purely moving code.

thanks
-- PMM