Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp1960656imm; Thu, 11 Oct 2018 02:45:46 -0700 (PDT) X-Google-Smtp-Source: ACcGV63fRUjM/sl5RzIYKhAYXccNaQgqfHCreWayV1LzC6XQBg+Jie//t3SNVviAYEZoWwIXLUkP X-Received: by 2002:a62:6b0a:: with SMTP id g10-v6mr834869pfc.174.1539251146872; Thu, 11 Oct 2018 02:45:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539251146; cv=none; d=google.com; s=arc-20160816; b=JsbF+V1AU5On0q6JNeAHDvw+8O2NX+aW2lq5PLaeSCoFCWkPE6ToxuqBBsUTzjYKxf YJ3rVRTU9OHSzKQUVmFaDWuBhhG2SafCOYmDP8AxGmB84hQfwJTM36RyjUyThwm6PUMG r3TieuAn8ndWqypieR65Oc/zWE4oXVLyknEu7Y5izqLdWM/SNV/raGzkc2XJbENaJTvA 2tSaW0Vj+eu/Gi67BgS/I0FKGeWDkv4Y/373NN1pqsDX+Cc8ci3bh0sqyf7dY7Osflb5 esWxFIQ9lUzZM9ur/P4CfoqZZv89fSz11VRLYnFTQFC2pRDS0NX2mQAlawKl2n7Soy15 ybcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=LtCZbUsWMYjVj32A9qmOsgM1YUxvGL0Oj9GIX/p6xF0=; b=BlLqiZGeMQpEvjap+Y5eBlCMEgbOTfb6jtFIKakzkfUr2ZXctAClqXQQiVA4+5kOz/ cWXwnuun1C4csLiOk9eyQ8oy2Hy9GOTKxVY4I1963urQjd8D6k1v3cUmS2ZHI+dA6A6k mLm29h0NLIrbJ/j8pqENRTVxZFBuryx9JyXBHZX+jlXHRc76pwzK50YBk45r3IGIKdMx oKbqqiaRPFKyAtV/SucVB22Ykmndxk21D4WsgOTBFRIy+PjmJLUlk52uOCEy15XlIcVT BD7SdvSrhqrdk8z4EQSXVkQnC16jw1e+aXkYfLo24r2QnD86KJVx+N7PIyGIvcx15MhK qYpA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 34-v6si29482035plp.310.2018.10.11.02.45.32; Thu, 11 Oct 2018 02:45:46 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728361AbeJKRKj (ORCPT + 99 others); Thu, 11 Oct 2018 13:10:39 -0400 Received: from mx1.redhat.com ([209.132.183.28]:17451 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726215AbeJKRKj (ORCPT ); Thu, 11 Oct 2018 13:10:39 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BD2B137E80; Thu, 11 Oct 2018 09:44:09 +0000 (UTC) Received: from [10.72.12.114] (ovpn-12-114.pek2.redhat.com [10.72.12.114]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4F3A27A44B; Thu, 11 Oct 2018 09:44:04 +0000 (UTC) Subject: Re: [PATCH] virtio_net: enable tx after resuming from suspend To: Ake Koomsin Cc: "Michael S. Tsirkin" , "David S. Miller" , virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20181011075127.2608-1-ake@igel.co.jp> From: Jason Wang Message-ID: Date: Thu, 11 Oct 2018 17:44:01 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20181011075127.2608-1-ake@igel.co.jp> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Thu, 11 Oct 2018 09:44:09 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018年10月11日 15:51, Ake Koomsin wrote: > commit 713a98d90c5e ("virtio-net: serialize tx routine during reset") > disabled the virtio tx before going to suspend to avoid a use after free. > However, after resuming, it causes the virtio_net device to lose its > network connectivity. > > To solve the issue, we need to enable tx after resuming. > > Fixes commit 713a98d90c5e ("virtio-net: serialize tx routine during reset") > Signed-off-by: Ake Koomsin > --- > drivers/net/virtio_net.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c > index dab504ec5e50..3453d80f5f81 100644 > --- a/drivers/net/virtio_net.c > +++ b/drivers/net/virtio_net.c > @@ -2256,6 +2256,7 @@ static int virtnet_restore_up(struct virtio_device *vdev) > } > > netif_device_attach(vi->dev); > + netif_start_queue(vi->dev); I believe this is duplicated with netif_tx_wake_all_queues() in netif_device_attach() above? Thanks > return err; > } >