From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark McLoughlin Subject: Re: QemuOpts changes breaks multiple nic options Date: Tue, 13 Oct 2009 09:58:28 +0100 Message-ID: <1255424308.3136.13.camel@blaa> References: <200910121705.03870.tahm@linux.vnet.ibm.com> Reply-To: Mark McLoughlin Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org To: Tom Lendacky Return-path: Received: from mx1.redhat.com ([209.132.183.28]:20277 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756678AbZJMJAp (ORCPT ); Tue, 13 Oct 2009 05:00:45 -0400 In-Reply-To: <200910121705.03870.tahm@linux.vnet.ibm.com> Sender: kvm-owner@vger.kernel.org List-ID: Hi Tom, On Mon, 2009-10-12 at 17:05 -0500, Tom Lendacky wrote: > The recent change to QemuOpts for the -net nic option breaks specifying -net > nic,... more than once. The net_init_nic function's return value in net.c is > a table index, which is non-zero after the first time it is called. The > qemu_opts_foreach function in qemu-option.c receives the non-zero return value > and stops processing further -net options (like associated -net tap options). > It looks like the usb net function makes use of the index value, so the fix > might best be to have qemu_opts_foreach check for a return code < 0 as being > an error? Thanks for the report; I sent a patch to qemu-devel yesterday: http://lists.gnu.org/archive/html/qemu-devel/2009-10/msg01070.html Cheers, Mark.