qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 00/27] ACPI hardware-reduced support


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] [PATCH 00/27] ACPI hardware-reduced support
Date: Tue, 23 Oct 2018 08:55:37 -0400

On Tue, Oct 23, 2018 at 11:00:18AM +0200, Samuel Ortiz wrote:
> > I wonder whether the code can be refactored slightly differently:
> > instead of common code calling out to platform specific one,
> > have platform code call out to generic one.
> > That would avoid indicectiin

should have been indirection

> > but I'm not sure at what cost
> > in complexity.
> I may be misunderstanding your point, so forgive me if that's the case.
> But the code refactoring actually lead to both of the code paths you're
> describing. The generic code calls into platform specific hooks for
> potentially calling custom ACPI tables, but the platform code also uses
> the now shared generic code.

Right. So if instead of both we could have only platform calling generic
code, we could drop some of the hooks.

What I'm saying is that if I look at patches 1-17 which are supposed to
be just refactorings, somehow at the surface instead of reducing lines
of code they add 100 LOC.

And the whole patchset adds about 1000 LOC, by comparison e.g. pc_q35.c
is just 400 LOC since q35 and pc share a bunch of code.  I wonder why
can't more code be shared with e.g. ARM which also has a virt machine
type. In other words, assuming we are doing PV, can't it be more
portable.

Again all that's still because all I read is the diffstats, it's without
reading the patches, sorry about that.

-- 
MST



reply via email to

[Prev in Thread] Current Thread [Next in Thread]