From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alexander Graf <agraf@suse.de>
Cc: "kvm@vger.kernel.org" <kvm@vger.kernel.org>,
kvm-ppc <kvm-ppc@vger.kernel.org>, Avi Kivity <avi@redhat.com>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: [PATCH v2] spapr: Add "memop" hypercall
Date: Fri, 25 May 2012 09:24:24 +0000 [thread overview]
Message-ID: <1337937864.16119.20.camel@pasglop> (raw)
In-Reply-To: <CDED084B-4C4E-4935-96C3-B6535CE0D5C6@suse.de>
On Fri, 2012-05-25 at 10:54 +0200, Alexander Graf wrote:
> >> case x:
> >> foo();
> >> break();
> >>
> >>> break;
> >>> + case 1: tmp = lduw_phys(src); break;
> >>> + case 2: tmp = ldl_phys(src); break;
> >>> + case 3: tmp = ldq_phys(src); break;
> >>> + default:
> >>> + return H_PARAMETER;
> >
> > Checkpatch absolutely complained and I decided to ignore it, seriously,
> > you really want to replace a nice & readable piece of code with
> > something that takes 3 pages and is generally gross & ugly ?
> >
> > Some times, you have to ignore check patch and let sanity prevail.
>
> I'm not all that keen on coding style rules. But check out
> arch/powerpc/kvm/emulate.c and tell me that it's a good idea to go
> with this "clean" approach. If you want it really clean, put the whole
> chunk above into a geberic helper that allows for everyone to say
> "read n bytes of data with native endianness into a u64". In that
> code, the more verbose coding style checkpatch suggests doesn't hurt
> and your function becomes even easier to read :)
I find your lack of taste disturbing Luke :-)
> Yeah, it's a shame I didn't read through it more thoroughly earlier - at least it didn't take weeks in this round ;).
>
> No worries though, if you can't make it until Monday, I'll fix it up myself afterwards :). There's no black magic involved here,
> so I should be ok to respin myself.
Sure. No worries. To test it properly you really need a newer SLOF and
the patch to add -vga tho, I'll sort that out when I'm back.
Cheers,
Ben.
> Alex
WARNING: multiple messages have this Message-ID (diff)
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alexander Graf <agraf@suse.de>
Cc: "kvm@vger.kernel.org" <kvm@vger.kernel.org>,
kvm-ppc <kvm-ppc@vger.kernel.org>, Avi Kivity <avi@redhat.com>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: [PATCH v2] spapr: Add "memop" hypercall
Date: Fri, 25 May 2012 19:24:24 +1000 [thread overview]
Message-ID: <1337937864.16119.20.camel@pasglop> (raw)
In-Reply-To: <CDED084B-4C4E-4935-96C3-B6535CE0D5C6@suse.de>
On Fri, 2012-05-25 at 10:54 +0200, Alexander Graf wrote:
> >> case x:
> >> foo();
> >> break();
> >>
> >>> break;
> >>> + case 1: tmp = lduw_phys(src); break;
> >>> + case 2: tmp = ldl_phys(src); break;
> >>> + case 3: tmp = ldq_phys(src); break;
> >>> + default:
> >>> + return H_PARAMETER;
> >
> > Checkpatch absolutely complained and I decided to ignore it, seriously,
> > you really want to replace a nice & readable piece of code with
> > something that takes 3 pages and is generally gross & ugly ?
> >
> > Some times, you have to ignore check patch and let sanity prevail.
>
> I'm not all that keen on coding style rules. But check out
> arch/powerpc/kvm/emulate.c and tell me that it's a good idea to go
> with this "clean" approach. If you want it really clean, put the whole
> chunk above into a geberic helper that allows for everyone to say
> "read n bytes of data with native endianness into a u64". In that
> code, the more verbose coding style checkpatch suggests doesn't hurt
> and your function becomes even easier to read :)
I find your lack of taste disturbing Luke :-)
> Yeah, it's a shame I didn't read through it more thoroughly earlier - at least it didn't take weeks in this round ;).
>
> No worries though, if you can't make it until Monday, I'll fix it up myself afterwards :). There's no black magic involved here,
> so I should be ok to respin myself.
Sure. No worries. To test it properly you really need a newer SLOF and
the patch to add -vga tho, I'll sort that out when I'm back.
Cheers,
Ben.
> Alex
WARNING: multiple messages have this Message-ID (diff)
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alexander Graf <agraf@suse.de>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
kvm-ppc <kvm-ppc@vger.kernel.org>,
"kvm@vger.kernel.org" <kvm@vger.kernel.org>,
Avi Kivity <avi@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v2] spapr: Add "memop" hypercall
Date: Fri, 25 May 2012 19:24:24 +1000 [thread overview]
Message-ID: <1337937864.16119.20.camel@pasglop> (raw)
In-Reply-To: <CDED084B-4C4E-4935-96C3-B6535CE0D5C6@suse.de>
On Fri, 2012-05-25 at 10:54 +0200, Alexander Graf wrote:
> >> case x:
> >> foo();
> >> break();
> >>
> >>> break;
> >>> + case 1: tmp = lduw_phys(src); break;
> >>> + case 2: tmp = ldl_phys(src); break;
> >>> + case 3: tmp = ldq_phys(src); break;
> >>> + default:
> >>> + return H_PARAMETER;
> >
> > Checkpatch absolutely complained and I decided to ignore it, seriously,
> > you really want to replace a nice & readable piece of code with
> > something that takes 3 pages and is generally gross & ugly ?
> >
> > Some times, you have to ignore check patch and let sanity prevail.
>
> I'm not all that keen on coding style rules. But check out
> arch/powerpc/kvm/emulate.c and tell me that it's a good idea to go
> with this "clean" approach. If you want it really clean, put the whole
> chunk above into a geberic helper that allows for everyone to say
> "read n bytes of data with native endianness into a u64". In that
> code, the more verbose coding style checkpatch suggests doesn't hurt
> and your function becomes even easier to read :)
I find your lack of taste disturbing Luke :-)
> Yeah, it's a shame I didn't read through it more thoroughly earlier - at least it didn't take weeks in this round ;).
>
> No worries though, if you can't make it until Monday, I'll fix it up myself afterwards :). There's no black magic involved here,
> so I should be ok to respin myself.
Sure. No worries. To test it properly you really need a newer SLOF and
the patch to add -vga tho, I'll sort that out when I'm back.
Cheers,
Ben.
> Alex
next prev parent reply other threads:[~2012-05-25 9:24 UTC|newest]
Thread overview: 49+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-21 7:24 [PATCH] spapr: Add "memop" hypercall Benjamin Herrenschmidt
2012-05-21 7:24 ` Benjamin Herrenschmidt
2012-05-21 8:38 ` Alexander Graf
2012-05-21 8:38 ` Alexander Graf
2012-05-21 8:59 ` Benjamin Herrenschmidt
2012-05-21 8:59 ` Benjamin Herrenschmidt
2012-05-21 9:06 ` Alexander Graf
2012-05-21 9:06 ` Alexander Graf
2012-05-21 9:47 ` Avi Kivity
2012-05-21 9:47 ` Avi Kivity
2012-05-21 10:04 ` Benjamin Herrenschmidt
2012-05-21 10:04 ` Benjamin Herrenschmidt
2012-05-21 10:07 ` Avi Kivity
2012-05-21 10:07 ` Avi Kivity
2012-05-21 11:48 ` Benjamin Herrenschmidt
2012-05-21 11:48 ` Benjamin Herrenschmidt
2012-05-21 13:55 ` Avi Kivity
2012-05-21 13:55 ` Avi Kivity
2012-05-21 21:59 ` Benjamin Herrenschmidt
2012-05-21 21:59 ` Benjamin Herrenschmidt
2012-05-25 3:12 ` Benjamin Herrenschmidt
2012-05-25 3:12 ` Benjamin Herrenschmidt
2012-05-28 10:40 ` Avi Kivity
2012-05-28 10:40 ` Avi Kivity
2012-05-30 8:25 ` Alexander Graf
2012-05-30 8:25 ` Alexander Graf
2012-05-31 3:22 ` Benjamin Herrenschmidt
2012-05-31 3:22 ` Benjamin Herrenschmidt
2012-05-25 3:53 ` [PATCH v2] " Benjamin Herrenschmidt
2012-05-25 3:53 ` [Qemu-devel] " Benjamin Herrenschmidt
2012-05-25 3:53 ` Benjamin Herrenschmidt
2012-05-25 8:30 ` Alexander Graf
2012-05-25 8:30 ` [Qemu-devel] " Alexander Graf
2012-05-25 8:30 ` Alexander Graf
2012-05-25 8:36 ` Benjamin Herrenschmidt
2012-05-25 8:36 ` [Qemu-devel] " Benjamin Herrenschmidt
2012-05-25 8:36 ` Benjamin Herrenschmidt
2012-05-25 8:54 ` Alexander Graf
2012-05-25 8:54 ` [Qemu-devel] " Alexander Graf
2012-05-25 8:54 ` Alexander Graf
2012-05-25 9:24 ` Benjamin Herrenschmidt [this message]
2012-05-25 9:24 ` [Qemu-devel] " Benjamin Herrenschmidt
2012-05-25 9:24 ` Benjamin Herrenschmidt
2012-05-25 10:29 ` Alexander Graf
2012-05-25 10:29 ` [Qemu-devel] " Alexander Graf
2012-05-25 10:29 ` Alexander Graf
2012-05-25 12:41 ` Benjamin Herrenschmidt
2012-05-25 12:41 ` [Qemu-devel] " Benjamin Herrenschmidt
2012-05-25 12:41 ` Benjamin Herrenschmidt
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=1337937864.16119.20.camel@pasglop \
--to=benh@kernel.crashing.org \
--cc=agraf@suse.de \
--cc=avi@redhat.com \
--cc=kvm-ppc@vger.kernel.org \
--cc=kvm@vger.kernel.org \
--cc=qemu-devel@nongnu.org \
/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.