Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1465940imm; Wed, 8 Aug 2018 18:19:50 -0700 (PDT) X-Google-Smtp-Source: AA+uWPwPEnmpRNGZBtNDXja9MNNIYh30dFvNo2eWVDqto9r5uwpqygKVorjX3bcGBe8uUyvV+k2o X-Received: by 2002:aa7:860b:: with SMTP id p11-v6mr44604pfn.247.1533777589921; Wed, 08 Aug 2018 18:19:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533777589; cv=none; d=google.com; s=arc-20160816; b=UA+mp1x4s6iONZA0fR3bq5AZQYEzXFJdw8DmYi8+pGRMXmgVVsxOYGqVVNQTpCpwTb 9oz0Zx8G648f8EWeD7HpYnfg1aQMeojo4OyzoMUB0grOol6jzUeeGTR/xEq96WuEUfxP ij93fdBtu089p5g4rMAXuZ2jpAMAsYrI6DsmyUc5L6gJcAgYhiZG4uGDOZGaZv3XUh7n eEpSnngDSGEOqJcPWAs7CsMlKs38eCnG0rH0KtMAIKGemuABIJaMl/XYMwIMIRZ+i5D4 6rNfPsRs36vF+ORUUb2BiPT+pG1Vi1dT4VC9zFfwyYR8bmGk5NTBFRrt4MMFi0GY322W rqvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=UZP/DSK8WAJyABMiFutvCyagrikNWW7n28qCllXfTFA=; b=pjYVqRqM9FeqTOPg+7iLlCDgVWxYd2xIP/eoRI8ZoIYZBJqvmYojtT2C1g4MOEcbz8 TqcHlOy+CSkkUV1aXdcrwV7DI1hhDShBtrQxFwkZ80EC1aCuYXR4pCwp9G3659wrTElA wN+cxxYlekupC9qr/e1eDzYAcWLEljj2wG0v0QwlAlJNukpRw1SC9U9H1QxQ8c9juFnQ ExPfD92GBHZNiiGnxydlZLWouxZixyQCPg1uDOBARjN/eI6SxTa5OqeGFdrE4Z4wHH2V oGOMc1PTMlP+DLr1Sve6hmfOtidQdKbhcK434+zbkmLMG48uI9h2zh4y0KqwfkKDqgm7 Xcug== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f12-v6si5470569pgg.653.2018.08.08.18.19.33; Wed, 08 Aug 2018 18:19:49 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731506AbeHIDk6 (ORCPT + 99 others); Wed, 8 Aug 2018 23:40:58 -0400 Received: from nautica.notk.org ([91.121.71.147]:55034 "EHLO nautica.notk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727530AbeHIDk5 (ORCPT ); Wed, 8 Aug 2018 23:40:57 -0400 Received: by nautica.notk.org (Postfix, from userid 1001) id 062B1C009; Thu, 9 Aug 2018 03:18:43 +0200 (CEST) Date: Thu, 9 Aug 2018 03:18:28 +0200 From: Dominique Martinet To: piaojun Cc: "akpm@linux-foundation.org" , Eric Van Hensbergen , Ron Minnich , Latchesar Ionkov , Greg Kurz , Linux Kernel Mailing List , v9fs-developer@lists.sourceforge.net Subject: Re: [PATCH] net/9p/trans_virtio.c: decrease the refcount of 9p virtio device when removing it Message-ID: <20180809011828.GA2966@nautica> References: <5B6AA65E.3030907@huawei.com> <20180808083630.GB16121@nautica> <5B6AB081.6090608@huawei.com> <20180808094014.GA5585@nautica> <5B6B8E96.9070302@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <5B6B8E96.9070302@huawei.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org piaojun wrote on Thu, Aug 09, 2018: > > What exact kernel commit are you running? > > My kernel commit id 6edf1d4cb0acde, and I replace the 9p code with > 9p-next. And I wonder if this will work well? That is somewhere on top of 4.18-rc1 and got merged in 4.18-rc4, which are close enough so while I can question the practice I don't see why not. I've just tried the following: $ git checkout 6edf1d4cb0acde $ git checkout martinetd/9p-next net/9p fs/9p include/net/9p (martinetd/9p-next is 9f961802a7 as of this mail) $ uname -r 4.18.0-rc1+ $ lsmod | grep -E '^9pnet_virtio' || echo "not loaded" 9pnet_virtio 32768 0 $ sudo modprobe -r 9pnet_virtio $ lsmod | grep -E '^9pnet_virtio' || echo "not loaded" not loaded $ sudo modprobe 9pnet_virtio $ sudo mount -t 9p -o debug=1,trans=virtio shm /mnt $ ls /mnt $ cat /sys/module/9pnet_virtio/drivers/virtio\:9pnet_virtio/*/mount_tag tmpshm (these could use a new line...) $ sudo umount /mnt $ sudo modprobe -r 9pnet_virtio $ lsmod | grep -E '^9pnet_virtio' || echo "not loaded" not loaded The /sys/devices/pci*/*/virtio*/mount_tag files are also removed properly; I don't see any problem. Not being able to reproduce is fine in general, but I also get problems when applying the patch and unloading the module multiple times so I can't help but question this patch and think your problem lies somewhere else. -- Dominique