From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752473AbbIXIuI (ORCPT ); Thu, 24 Sep 2015 04:50:08 -0400 Received: from mail-wi0-f174.google.com ([209.85.212.174]:35457 "EHLO mail-wi0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751492AbbIXIuE (ORCPT ); Thu, 24 Sep 2015 04:50:04 -0400 Message-ID: <5603B938.1@plexistor.com> Date: Thu, 24 Sep 2015 11:50:00 +0300 From: Boaz Harrosh User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Dave Chinner , Dan Williams CC: linux-nvdimm , "linux-kernel@vger.kernel.org" , Alexander Viro , linux-fsdevel , Andrew Morton , "Kirill A. Shutemov" Subject: Re: [PATCH v2] dax: fix NULL pointer in __dax_pmd_fault() References: <1442950582-10140-1-git-send-email-ross.zwisler@linux.intel.com> <20150922141333.c28e3c5d800267937ca7b29a@linux-foundation.org> <20150922233016.GH3902@dastard> <20150923090459.GO19114@dastard> In-Reply-To: <20150923090459.GO19114@dastard> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/23/2015 12:04 PM, Dave Chinner wrote: > On Tue, Sep 22, 2015 at 08:00:29PM -0700, Dan Williams wrote: <> >> The kaddr is coming from the devm_memremap() in the pmem driver that >> gets unmapped after the device is released by the driver. > > Perhaps the better solution is to not tear down the block device > until all active references have gone away? i.e. unbind puts the > device into a persistent error state and forces all active mappings > to refault. Hence all future accesses error out and then when the > user unmounts the unhappy filesystem the last reference to the > blockdev goes away and the mappings can be torn down safely... > Me too > Cheers, > > Dave. >