All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: Michael Roth <mdroth@linux.vnet.ibm.com>
Cc: Bharata B Rao <bharata@linux.vnet.ibm.com>,
	lvivier@redhat.com, nikunj@linux.vnet.ibm.com,
	sursingh@redhat.com, qemu-devel@nongnu.org, qemu-ppc@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 0/4] spapr:DRC cleanups (part I)
Date: Thu, 1 Jun 2017 15:30:37 +1000	[thread overview]
Message-ID: <20170601053037.GC13397@umbus.fritz.box> (raw)
In-Reply-To: <149629114184.3207.6757927820110284250@loki>

[-- Attachment #1: Type: text/plain, Size: 1916 bytes --]

On Wed, May 31, 2017 at 11:25:41PM -0500, Michael Roth wrote:
> Quoting Bharata B Rao (2017-05-31 23:06:46)
> > On Thu, Jun 01, 2017 at 11:52:14AM +1000, David Gibson wrote:
> > > The code managing DRCs[0] has quite a few things that are more
> > > complicated than they need to be.  In particular the object
> > > representing a DRC has a bunch of method pointers, despite the fact
> > > that there are currently no subclasses, and even if there were the
> > > method implementations would be unlikely to differ.
> > 
> > So you are getting rid of a few methods. How about other methods ?
> > Specially attach and detach which have incorporated all the logic needed
> > to handle logical and physical DRs into their implementations ?
> 
> I would avoid any methods that incorporate special-casing for
> physical vs. logical DRCs, since that seems like a good logical
> starting point for moving to 'physical'/'logical' DRC
> sub-classes to help simplify the increasingly complicated
> state-tracking.

Right, I'm looking at making subclasses for each of the DRC types.
Possibly with intermediate subclasses for physical vs. logical, we'll
see how it works out.

> I also don't think we should expose DRC internal fields to
> outside callers (which attach/detach would involve).

Well.. just changing attach/detach to plain functions instead of
methods wouldn't break that.

> This
> series does that to some extent with the RTAS calls, but
> since those are now moved to spapr_drc.c it makes more sense.

Right - the semantics of the RTAS calls are tied closely to the DRC
semantics, so I don't think there's any point considering the RTAS
calls to be "outside" the DRC code itself.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2017-06-01  5:30 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-01  1:52 [Qemu-devel] [PATCH 0/4] spapr:DRC cleanups (part I) David Gibson
2017-06-01  1:52 ` [Qemu-devel] [PATCH 1/4] spapr: Move DRC RTAS calls into spapr_drc.c David Gibson
2017-06-01 13:36   ` Laurent Vivier
2017-06-01 16:05     ` Michael Roth
2017-06-02  3:21       ` David Gibson
2017-06-01 15:56   ` Michael Roth
2017-06-02  3:24     ` David Gibson
2017-06-01 16:08   ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2017-06-01  1:52 ` [Qemu-devel] [PATCH 2/4] spapr: Abolish DRC get_fdt method David Gibson
2017-06-01 14:01   ` Laurent Vivier
2017-06-01 16:09   ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2017-06-01  1:52 ` [Qemu-devel] [PATCH 3/4] spapr: Abolish DRC set_configured method David Gibson
2017-06-01 15:13   ` Laurent Vivier
2017-06-01 15:37   ` Michael Roth
2017-06-02  3:31     ` David Gibson
2017-06-01 16:14   ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2017-06-01  1:52 ` [Qemu-devel] [PATCH 4/4] spapr: Make DRC get_index and get_type methods into plain functions David Gibson
2017-06-01 15:19   ` Laurent Vivier
2017-06-01  4:06 ` [Qemu-devel] [PATCH 0/4] spapr:DRC cleanups (part I) Bharata B Rao
2017-06-01  4:21   ` David Gibson
2017-06-01  4:25   ` Michael Roth
2017-06-01  5:30     ` David Gibson [this message]
2017-06-01 15:41       ` [Qemu-devel] [Qemu-ppc] " Daniel Henrique Barboza
2017-06-02  3:35         ` David Gibson
2017-06-01 13:41 ` Daniel Henrique Barboza
2017-06-02  3:49 ` [Qemu-devel] " David Gibson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170601053037.GC13397@umbus.fritz.box \
    --to=david@gibson.dropbear.id.au \
    --cc=bharata@linux.vnet.ibm.com \
    --cc=lvivier@redhat.com \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=nikunj@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.org \
    --cc=sursingh@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.