From patchwork Tue Jul 16 09:08:39 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Kuchin X-Patchwork-Id: 11045579 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3042A13B1 for ; Tue, 16 Jul 2019 09:09:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1D88E26D08 for ; Tue, 16 Jul 2019 09:09:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 11347284E8; Tue, 16 Jul 2019 09:09:06 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.0 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 23C1C26D08 for ; Tue, 16 Jul 2019 09:09:04 +0000 (UTC) Received: from localhost ([::1]:46636 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hnJSJ-0001b3-Gl for patchwork-qemu-devel@patchwork.kernel.org; Tue, 16 Jul 2019 05:09:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49826) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hnJSA-0001Bt-HA for qemu-devel@nongnu.org; Tue, 16 Jul 2019 05:08:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hnJS9-0000uk-2d for qemu-devel@nongnu.org; Tue, 16 Jul 2019 05:08:54 -0400 Received: from forwardcorp1p.mail.yandex.net ([77.88.29.217]:46202) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hnJS8-0000qZ-FB; Tue, 16 Jul 2019 05:08:53 -0400 Received: from mxbackcorp1o.mail.yandex.net (mxbackcorp1o.mail.yandex.net [IPv6:2a02:6b8:0:1a2d::301]) by forwardcorp1p.mail.yandex.net (Yandex) with ESMTP id 1BEF32E1489; Tue, 16 Jul 2019 12:08:48 +0300 (MSK) Received: from smtpcorp1p.mail.yandex.net (smtpcorp1p.mail.yandex.net [2a02:6b8:0:1472:2741:0:8b6:10]) by mxbackcorp1o.mail.yandex.net (nwsmtp/Yandex) with ESMTP id 4yJEaq2cgi-8liuXbex; Tue, 16 Jul 2019 12:08:48 +0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex-team.ru; s=default; t=1563268128; bh=IAPuz1mCtbeDJgEG2GHY7V+hQF0B0Lrc4TWrQukY4Q4=; h=Message-Id:Date:Subject:To:From:Cc; b=zFJCuL8nbTN95TAYyvKfpD9EKjztcHThDkqVvnCc4D1pOfJ5lpqxXAOFp07gROey6 i7yY63KS6rIQSutPlRv2fTtdkTQLp/VBYDVm09sYdeyKV1MymC205U7dGFlAlUvzXE FMJB3G+ahnS0k8B4j3pBqjQ7PE0uRqdn59FNlhqM= Authentication-Results: mxbackcorp1o.mail.yandex.net; dkim=pass header.i=@yandex-team.ru Received: from dynamic-red.dhcp.yndx.net (dynamic-red.dhcp.yndx.net [2a02:6b8:0:408:250:b6ff:fe97:2682]) by smtpcorp1p.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id c0IeHuEGSf-8lwCZ2iK; Tue, 16 Jul 2019 12:08:47 +0300 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client certificate not present) From: Anton Kuchin To: qemu-devel@nongnu.org Date: Tue, 16 Jul 2019 12:08:39 +0300 Message-Id: <20190716090839.19708-1-antonkuchin@yandex-team.ru> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 77.88.29.217 Subject: [Qemu-devel] [PATCH] virtio-net: remove redundant qdev from VirtIONet X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-trivial@nongnu.org, Jason Wang , Anton Kuchin , "Michael S. Tsirkin" Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Anton Kuchin Reviewed-by: Michael S. Tsirkin --- hw/net/virtio-net.c | 3 +-- include/hw/virtio/virtio-net.h | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index b9e1cd71cf..16d2ad5927 100644 --- a/hw/net/virtio-net.c +++ b/hw/net/virtio-net.c @@ -387,7 +387,7 @@ static void rxfilter_notify(NetClientState *nc) VirtIONet *n = qemu_get_nic_opaque(nc); if (nc->rxfilter_notify_enabled) { - gchar *path = object_get_canonical_path(OBJECT(n->qdev)); + gchar *path = object_get_canonical_path(OBJECT(n)); qapi_event_send_nic_rx_filter_changed(!!n->netclient_name, n->netclient_name, path); g_free(path); @@ -2759,7 +2759,6 @@ static void virtio_net_device_realize(DeviceState *dev, Error **errp) nc->rxfilter_notify_enabled = 1; QTAILQ_INIT(&n->rsc_chains); - n->qdev = dev; } static void virtio_net_device_unrealize(DeviceState *dev, Error **errp) diff --git a/include/hw/virtio/virtio-net.h b/include/hw/virtio/virtio-net.h index b96f0c643f..4a1b599d48 100644 --- a/include/hw/virtio/virtio-net.h +++ b/include/hw/virtio/virtio-net.h @@ -174,7 +174,6 @@ struct VirtIONet { uint32_t *vlans; virtio_net_conf net_conf; NICConf nic_conf; - DeviceState *qdev; int multiqueue; uint16_t max_queues; uint16_t curr_queues;