From patchwork Sun Apr 10 15:14:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Fleytman X-Patchwork-Id: 8789501 Return-Path: X-Original-To: patchwork-qemu-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 7816A9F39A for ; Sun, 10 Apr 2016 15:20:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D32C7201CD for ; Sun, 10 Apr 2016 15:20:22 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 373B120212 for ; Sun, 10 Apr 2016 15:20:22 +0000 (UTC) Received: from localhost ([::1]:35265 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apH9w-0008IQ-Np for patchwork-qemu-devel@patchwork.kernel.org; Sun, 10 Apr 2016 11:20:20 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50482) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apH5N-0007bn-N3 for qemu-devel@nongnu.org; Sun, 10 Apr 2016 11:15:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1apH5L-00087Z-Ml for qemu-devel@nongnu.org; Sun, 10 Apr 2016 11:15:37 -0400 Received: from mail-wm0-x22d.google.com ([2a00:1450:400c:c09::22d]:38474) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apH5L-00086r-ET for qemu-devel@nongnu.org; Sun, 10 Apr 2016 11:15:35 -0400 Received: by mail-wm0-x22d.google.com with SMTP id u206so74667101wme.1 for ; Sun, 10 Apr 2016 08:15:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=daynix-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=ri5r72w79wGZ5kaRvnDa529GVULxaGWFExU5P5jdmZU=; b=rTPkMihMWqV2yc686GXVY6uAmL3RMKkbbaOrj7cuETVk+IPIslAn8zoMFA7sZB9gG4 1uVd9fc+s6l8RoFrs8PTZ6NF4THityEJfnvo6jGWcDfntIC1Dlq1zEBsyTAd3CUoOAe5 /pT/wrO6kdQwciPXTx5hXS28Gy2VQL+C88TBrNwfblJg3C60npMUEg3eALZ3P/cHbFO0 TFe1MRUN6Co57DigNsZN+fSqX1JbYh0rESTmcqqPHUunoXn7LH3jVML4KuWn8npr2wxQ ErYtmgoglcYbFt6Lo+d4+XNuWbIodOWFBO+PfAEwHhQsR53DzY2CUZuw6OyQnmbiku6D ODrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=ri5r72w79wGZ5kaRvnDa529GVULxaGWFExU5P5jdmZU=; b=KqqmvY9BDXCUr2VZAX5PvvRidnp7g4yVSyVw2tModpWEXPDpITpCYek7ZroR8Obq8C ugP8iakAYRMOdSMG0xT11Yvcv/QEmcVh/26vaJFxBcwzy8uq5yCAi+PIusjMwsEbH9ml qCLL0gCQg+OxFHxKzmpf6ECMJUH73Q5HTatVdsTAwUb2QCsb/cSbUWfDu5sQsog0vCHl F+yotukSQVVbwQ6NsKnIPl/Sp4XJX+BEPwQ0RQJ/qt9exupiqsJhblqz3gy5boYf9npI 5+8z35Qind5jckcq8ljLIAmMxo843S/LrATIiJ57Qy+QmpVTj3RFaEZ2atV+gj49t49q QHhg== X-Gm-Message-State: AD7BkJLRhqF9oRQ5fkff9SPeijW9EKOU0HfVUJHvoVYuHKzR3gFvxQ1vX5/3UmEXql67Cg== X-Received: by 10.194.105.42 with SMTP id gj10mr19453725wjb.49.1460301334928; Sun, 10 Apr 2016 08:15:34 -0700 (PDT) Received: from bark.daynix ([5.102.236.99]) by smtp.gmail.com with ESMTPSA id j71sm12685874wmj.21.2016.04.10.08.15.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 10 Apr 2016 08:15:34 -0700 (PDT) From: Dmitry Fleytman To: qemu-devel@nongnu.org Date: Sun, 10 Apr 2016 18:14:56 +0300 Message-Id: <1460301305-5321-8-git-send-email-dmitry@daynix.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1460301305-5321-1-git-send-email-dmitry@daynix.com> References: <1460301305-5321-1-git-send-email-dmitry@daynix.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::22d Subject: [Qemu-devel] [PATCH v4 07/16] net: Add macros for MAC address tracing X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Yan Vugenfirer , Jason Wang , Leonid Bloch , Shmulik Ladkani , "Michael S. Tsirkin" Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Dmitry Fleytman These macros will be used by future commits introducing e1000e device emulation and by vmxnet3 tracing code. Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch --- include/net/net.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/net/net.h b/include/net/net.h index 73e4c46..129d46b 100644 --- a/include/net/net.h +++ b/include/net/net.h @@ -9,6 +9,11 @@ #include "migration/vmstate.h" #include "qapi-types.h" +#define MAC_FMT "%02X:%02X:%02X:%02X:%02X:%02X" +#define MAC_ARG(x) ((uint8_t *)(x))[0], ((uint8_t *)(x))[1], \ + ((uint8_t *)(x))[2], ((uint8_t *)(x))[3], \ + ((uint8_t *)(x))[4], ((uint8_t *)(x))[5] + #define MAX_QUEUE_NUM 1024 /* Maximum GSO packet size (64k) plus plenty of room for