From patchwork Thu Mar 21 03:02:36 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amos Kong X-Patchwork-Id: 229541 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 96E402C00C3 for ; Thu, 21 Mar 2013 14:03:02 +1100 (EST) Received: from localhost ([::1]:42482 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UIVmO-0006n3-Lr for incoming@patchwork.ozlabs.org; Wed, 20 Mar 2013 23:03:00 -0400 Received: from eggs.gnu.org ([208.118.235.92]:40313) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UIVm9-0006mx-VG for qemu-devel@nongnu.org; Wed, 20 Mar 2013 23:02:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UIVm9-00052t-2M for qemu-devel@nongnu.org; Wed, 20 Mar 2013 23:02:45 -0400 Received: from mx1.redhat.com ([209.132.183.28]:51390) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UIVm8-00052p-R5 for qemu-devel@nongnu.org; Wed, 20 Mar 2013 23:02:44 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r2L32gVD017364 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 20 Mar 2013 23:02:42 -0400 Received: from t430s.nay.redhat.com.com ([10.66.5.185]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r2L32d2o021637; Wed, 20 Mar 2013 23:02:39 -0400 From: Amos Kong To: virtualization@lists.linux-foundation.org Date: Thu, 21 Mar 2013 11:02:36 +0800 Message-Id: <1363834956-9409-1-git-send-email-akong@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: Amos Kong , qemu-devel@nongnu.org, stefanha@redhat.com, mst@redhat.com Subject: [Qemu-devel] [RFC virt-spec PATCH] only writing out the last byte of MAC makes it have effect X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org The lengcy guests don't have mac programming command, we don't know when it's safe to use MAC. We can change QEMU to make MAC change effect when the last byte of MAC is written to config space. Signed-off-by: Amos Kong --- virtio-spec.lyx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/virtio-spec.lyx b/virtio-spec.lyx index dbc4ef0..bb289fb 100644 --- a/virtio-spec.lyx +++ b/virtio-spec.lyx @@ -5430,7 +5430,7 @@ T_CTRL_MAC_TABLE_SET. \begin_layout Standard -\change_inserted -1930653948 1358506710 +\change_inserted -1930653948 1363832689 The config space \begin_inset Quotes eld \end_inset @@ -5464,6 +5464,15 @@ mac Therefore, VIRTIO_NET_CTRL_MAC_ADDR_SET is preferred, especially while the NIC is up. The command-specific-data is a 6-byte MAC address. +\end_layout + +\begin_layout Standard + +\change_inserted -1930653948 1363833477 +The legacy guests don't support the new command, they still change MAC address + in original way, that's not atomic. + For more robust, QEMU only makes the MAC change effect when the last byte + of MAC address is written to config space. \change_unchanged \end_layout