From: Jan Kiszka <jan.kiszka@web.de>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: zwu.kernel@gmail.com, Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>,
qemu-devel@nongnu.org, stefanha@linux.vnet.ibm.com
Subject: Re: [Qemu-devel] [PATCH 1/2] slirp: remove duplicate definition
Date: Wed, 15 Feb 2012 10:48:16 +0100 [thread overview]
Message-ID: <4F3B7F60.1060503@web.de> (raw)
In-Reply-To: <20120215093800.GB30825@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1492 bytes --]
On 2012-02-15 10:38, Michael S. Tsirkin wrote:
> On Wed, Feb 15, 2012 at 09:30:23AM +0100, Jan Kiszka wrote:
>> On 2012-02-15 09:12, zwu.kernel@gmail.com wrote:
>>> From: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>
>>>
>>> Signed-off-by: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>
>>> ---
>>> slirp/if.c | 2 --
>>> 1 files changed, 0 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/slirp/if.c b/slirp/if.c
>>> index 2852396..8e0cac2 100644
>>> --- a/slirp/if.c
>>> +++ b/slirp/if.c
>>> @@ -8,8 +8,6 @@
>>> #include <slirp.h>
>>> #include "qemu-timer.h"
>>>
>>> -#define ifs_init(ifm) ((ifm)->ifs_next = (ifm)->ifs_prev = (ifm))
>>> -
>>> static void
>>> ifs_insque(struct mbuf *ifm, struct mbuf *ifmhead)
>>> {
>>
>> Let's grab the chance and move ifs_init to mbuf.h.
>>
>> Jan
>>
>
> Since you mention it - why does slirp have all these
> defines in the first place?
>
> slirp/mbuf.h:#define m_nextpkt m_hdr.mh_nextpkt
> slirp/mbuf.h:#define ifs_next m_nextpkt
>
> Seriously, #define for a field name?
> This is just crazy, and violates our coding style
> which requires macros to be PPER_CAS_WITH_UNDERSCORES
>
This is a total mess, I agree, and I'd warmly welcome patches to clean
this up.
I can only speculate on the reasons. Maybe the intention was to keep the
core minimally modified and wrap all the conflicts it causes away. Given
that slirp outside QEMU is dead, this is no longer a valid reason (if it
ever was).
Jan
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]
next prev parent reply other threads:[~2012-02-15 9:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-15 8:12 [Qemu-devel] [PATCH 1/2] slirp: remove duplicate definition zwu.kernel
2012-02-15 8:30 ` Jan Kiszka
2012-02-15 9:38 ` Michael S. Tsirkin
2012-02-15 9:48 ` Jan Kiszka [this message]
2012-02-15 23:02 ` Andreas Färber
2012-02-15 23:21 ` Peter Maydell
2012-02-17 13:43 ` Jan Kiszka
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=4F3B7F60.1060503@web.de \
--to=jan.kiszka@web.de \
--cc=mst@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@linux.vnet.ibm.com \
--cc=wuzhy@linux.vnet.ibm.com \
--cc=zwu.kernel@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).