* [Qemu-devel] [PATCH] hw: edu: drop DO_UPCAST
@ 2018-10-13 5:51 Li Qiang
2018-10-13 8:09 ` Paolo Bonzini
0 siblings, 1 reply; 2+ messages in thread
From: Li Qiang @ 2018-10-13 5:51 UTC (permalink / raw)
To: pbonzini; +Cc: qemu-devel, Li Qiang
Signed-off-by: Li Qiang <liq3ea@163.com>
---
hw/misc/edu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/misc/edu.c b/hw/misc/edu.c
index 0687ffd343..cdcf550dd7 100644
--- a/hw/misc/edu.c
+++ b/hw/misc/edu.c
@@ -342,7 +342,7 @@ static void *edu_fact_thread(void *opaque)
static void pci_edu_realize(PCIDevice *pdev, Error **errp)
{
- EduState *edu = DO_UPCAST(EduState, pdev, pdev);
+ EduState *edu = EDU(pdev);
uint8_t *pci_conf = pdev->config;
pci_config_set_interrupt_pin(pci_conf, 1);
@@ -365,7 +365,7 @@ static void pci_edu_realize(PCIDevice *pdev, Error **errp)
static void pci_edu_uninit(PCIDevice *pdev)
{
- EduState *edu = DO_UPCAST(EduState, pdev, pdev);
+ EduState *edu = EDU(pdev);
qemu_mutex_lock(&edu->thr_mutex);
edu->stopping = true;
--
2.17.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] hw: edu: drop DO_UPCAST
2018-10-13 5:51 [Qemu-devel] [PATCH] hw: edu: drop DO_UPCAST Li Qiang
@ 2018-10-13 8:09 ` Paolo Bonzini
0 siblings, 0 replies; 2+ messages in thread
From: Paolo Bonzini @ 2018-10-13 8:09 UTC (permalink / raw)
To: Li Qiang; +Cc: qemu-devel
On 13/10/2018 07:51, Li Qiang wrote:
> Signed-off-by: Li Qiang <liq3ea@163.com>
> ---
> hw/misc/edu.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hw/misc/edu.c b/hw/misc/edu.c
> index 0687ffd343..cdcf550dd7 100644
> --- a/hw/misc/edu.c
> +++ b/hw/misc/edu.c
> @@ -342,7 +342,7 @@ static void *edu_fact_thread(void *opaque)
>
> static void pci_edu_realize(PCIDevice *pdev, Error **errp)
> {
> - EduState *edu = DO_UPCAST(EduState, pdev, pdev);
> + EduState *edu = EDU(pdev);
> uint8_t *pci_conf = pdev->config;
>
> pci_config_set_interrupt_pin(pci_conf, 1);
> @@ -365,7 +365,7 @@ static void pci_edu_realize(PCIDevice *pdev, Error **errp)
>
> static void pci_edu_uninit(PCIDevice *pdev)
> {
> - EduState *edu = DO_UPCAST(EduState, pdev, pdev);
> + EduState *edu = EDU(pdev);
>
> qemu_mutex_lock(&edu->thr_mutex);
> edu->stopping = true;
>
Queued, thanks.
Paolo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-10-13 8:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-13 5:51 [Qemu-devel] [PATCH] hw: edu: drop DO_UPCAST Li Qiang
2018-10-13 8:09 ` Paolo Bonzini
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.