Received: from eggs.gnu.org ([2001:4830:134:3::10]:40144) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1Iij-0002YG-LN for qemu-devel@nongnu.org; Tue, 24 Nov 2015 13:53:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a1Iig-0002jx-Fp for qemu-devel@nongnu.org; Tue, 24 Nov 2015 13:53:41 -0500 Received: from mx1.redhat.com ([209.132.183.28]:54164) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1Iig-0002jt-Ak for qemu-devel@nongnu.org; Tue, 24 Nov 2015 13:53:38 -0500 From: Markus Armbruster References: <1448384789-14830-1-git-send-email-armbru@redhat.com> <1448384789-14830-5-git-send-email-armbru@redhat.com> <1442536458.16567531.1448385430286.JavaMail.zimbra@redhat.com> <87ziy3pap5.fsf@blackfin.pond.sub.org> <401942375.16589360.1448386975444.JavaMail.zimbra@redhat.com> Date: Tue, 24 Nov 2015 19:53:34 +0100 In-Reply-To: <401942375.16589360.1448386975444.JavaMail.zimbra@redhat.com> (=?utf-8?Q?=22Marc-Andr=C3=A9?= Lureau"'s message of "Tue, 24 Nov 2015 12:42:55 -0500 (EST)") Message-ID: <87a8q3mdox.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH for-2.5 4/5] ivshmem: Mark questionable socket type test FIXME List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?utf-8?Q?Marc-Andr=C3=A9?= Lureau Cc: marcandre lureau , claudio fontana , qemu-devel@nongnu.org, Paolo Bonzini Marc-Andr=C3=A9 Lureau writes: > Hi > > ----- Original Message ----- >> Marc-Andr=C3=A9 Lureau writes: >>=20 >> > ----- Original Message ----- >> >> Signed-off-by: Markus Armbruster >> >> --- >> >> hw/misc/ivshmem.c | 1 + >> >> 1 file changed, 1 insertion(+) >> >>=20 >> >> diff --git a/hw/misc/ivshmem.c b/hw/misc/ivshmem.c >> >> index 83d7bd3..a6bfdde 100644 >> >> --- a/hw/misc/ivshmem.c >> >> +++ b/hw/misc/ivshmem.c >> >> @@ -939,6 +939,7 @@ static void pci_ivshmem_realize(PCIDevice *dev, E= rror >> >> **errp) >> >> memory_region_add_subregion(&s->bar, 0, mr); >> >> pci_register_bar(PCI_DEVICE(s), 2, attr, &s->bar); >> >> } else if (s->server_chr !=3D NULL) { >> >> + /* FIXME replace this test, it works basically by chance */ >> > >> > I wouldn't say it like that, but ack anyway. >>=20 >> I'm happy to consider a rephrased comment. > > Although Paolo used "chance" too, I think the proper comment would be > the following: > > FIXME: only pty and socket chardevs set chr->filename, other set to > the default---the backend name. I'm afraid that doesn't convey what needs fixing. > ie, to me it's not just by "chance" :) Well, it's certainly not by design! What about: + /* FIXME do not rely on what chr drivers put into filename */ [...]