From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47406) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJzF9-0000bu-Ql for qemu-devel@nongnu.org; Mon, 04 Jul 2016 04:28:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bJzF6-0006Xh-LD for qemu-devel@nongnu.org; Mon, 04 Jul 2016 04:28:39 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50293) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJzF6-0006XV-FT for qemu-devel@nongnu.org; Mon, 04 Jul 2016 04:28:36 -0400 References: <1467440540-6630-1-git-send-email-zhangchen.fnst@cn.fujitsu.com> <1467440540-6630-2-git-send-email-zhangchen.fnst@cn.fujitsu.com> <5779CEB9.8020706@redhat.com> <577A137E.7090804@cn.fujitsu.com> From: Jason Wang Message-ID: <577A1E2B.6020002@redhat.com> Date: Mon, 4 Jul 2016 16:28:27 +0800 MIME-Version: 1.0 In-Reply-To: <577A137E.7090804@cn.fujitsu.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [RFC PATCH V2 1/3] filter-rewriter: introduce filter-rewriter initialization List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Zhang Chen , qemu devel Cc: Li Zhijian , Wen Congyang , zhanghailiang , "eddie . dong" , "Dr . David Alan Gilbert" On 2016=E5=B9=B407=E6=9C=8804=E6=97=A5 15:42, Zhang Chen wrote: >>> @item -object=20 >>> filter-dump,id=3D@var{id},netdev=3D@var{dev},file=3D@var{filename}][,= maxlen=3D@var{len}]=20 >>> >>> Dump the network traffic on netdev @var{dev} to the file=20 >>> specified by >>> diff --git a/vl.c b/vl.c >>> index c6b9a6f..b47be6a 100644 >>> --- a/vl.c >>> +++ b/vl.c >>> @@ -2866,7 +2866,8 @@ static bool object_create_initial(const char=20 >>> *type) >>> g_str_equal(type, "filter-dump") || >>> g_str_equal(type, "filter-mirror") || >>> g_str_equal(type, "filter-redirector") || >>> - g_str_equal(type, "colo-compare")) { >>> + g_str_equal(type, "colo-compare") || >>> + g_str_equal(type, "filter-rewriter")) { >> >> So this makes the patch can't be applied cleanly on master. > > Yes,filter-rewriter based on colo-base in colo-compare... > So, should we make colo-base be a independent patch set? > Now, colo-base used by colo-compare and filter-rewriter. > At least the codes in this series is pretty independent, so there's no=20 need I think. >> >> And I think we don't want to manually compare 100 kinds of filters in=20 >> the future. How about doing something better, e.g: >> >> - introduce something like filter_register_type() >> - recored the name of the type in a list >> - iterate it here >> >> ? >> > > Maybe we need do this after colo-compare and filter-rewriter be merged. > and make filter-dump and other filter all in this type. > > Thanks > Zhang Chen Yes. > >>> return false; >>> } >> >> >> >> .=20