Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp777944yba; Thu, 18 Apr 2019 09:21:51 -0700 (PDT) X-Google-Smtp-Source: APXvYqx6ggbCuL9m8yt5bHzPc68+v07nc+jhCMA3u1U1cLVTCGUYG5ZaBMLoLRgVAlO1C3GguaSp X-Received: by 2002:a63:6fcf:: with SMTP id k198mr88928073pgc.158.1555604511245; Thu, 18 Apr 2019 09:21:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555604511; cv=none; d=google.com; s=arc-20160816; b=RYcAdhvsWzHaozdApKSKvPP9aP7XJI2iK4WaZ5Z1CgevuliJNo1+5M0yrBBvBxWdpo LFaLHckj7+lpcz325v4UUdg/5Y3NN5hzwb7STHbW3Z6ilPjr38mPwmIIG7WorBINM/rl 1tEDfC8MtYGztaFEkr5eR55chomCT5M5SY7gD9huLgYMb8Coe3JqLn4IU832q6qIJHEe 1WDr4qEfFy536j08wxlRYe33gBQb0DAqjB7mWf5d4vWwHmQHIEqSz/QS7KRiNCBeoKLJ KTcFden05l75j5E/HBZFw+jpHbNZT83YaURPkzT0Uthq+h9+E51G4xFRpJMltzaIlOR3 BgzQ== 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:dkim-signature; bh=oSiywyWZOOkDew8YDIRL2lgfYPRWYKSt6r/K8nAvB38=; b=jDMUxBzHEJt9cuHMYSsoiRBwjY4UxhpXK62ldwJmkvBnVGVUpRA4MXNGxykEgjzwwX Jyqu3OIGxk8N+amyTapQGxbtoo4JzdsADMZQEmk5zuVfTHMm1oljbLnrFUs4+57agwGE h/sHfhX4ozBnGZOlJ13SvgELsUf5CgzjshNHopBk5bwKBCQrxB+U3uphH9EJ3VqQbPNg 5aG/riwaOFrEoQ1lYhPFJHYAQzq+97XgMiowKN0ZSje8Am89ZhodeNhJeRFB9H5Crm8F 3eGskQF3OSb4m5MuVneMHrja+dBO7sLsEgZSOUCbHM0OLyABA4EqxgHrmABOncQt5LpM rS0Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=UQuK3DBW; 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 w10si2442966plz.37.2019.04.18.09.21.36; Thu, 18 Apr 2019 09:21:51 -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; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=UQuK3DBW; 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 S2389736AbfDRQSm (ORCPT + 99 others); Thu, 18 Apr 2019 12:18:42 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:40612 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389016AbfDRQSl (ORCPT ); Thu, 18 Apr 2019 12:18:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=oSiywyWZOOkDew8YDIRL2lgfYPRWYKSt6r/K8nAvB38=; b=UQuK3DBWUvS3ekW0bjE1qVo6+ MJzsQy6sTGxK00p7qVJ4VFtC1fWyQ7xuIglmmJFdYRHtDzE+aNGMdNRLf3HLnPAOBrQLtgfLLqXkV roN4AQhtKnlTNAuwf8sTOFq6GZl/ptQS0UKstolaRecDOv644T1QMJ8t9ODMIMUpcOjuj03JuDO2M 1AG97LDrgEDRf5sUoXXV25MqNc5qhJpMQ2DK1Hb9Na19ziCgs8b4jrtYlU/QZ65chrvNKLIkN25d5 G1A3jBOm1AnpyhDDKhTNYMIfJFehyF56uHA5kl+sfAvNUyUKy4MQiZcM5LNHgtyUhIbKJDR3z9iiu BnpM8rboA==; Received: from hch by bombadil.infradead.org with local (Exim 4.90_1 #2 (Red Hat Linux)) id 1hH9kA-0006UQ-C7; Thu, 18 Apr 2019 16:18:34 +0000 Date: Thu, 18 Apr 2019 09:18:34 -0700 From: Christoph Hellwig To: Dan Williams Cc: Jeff Moyer , Jan Kara , Pankaj Gupta , linux-nvdimm , Linux Kernel Mailing List , virtualization@lists.linux-foundation.org, KVM list , linux-fsdevel , Linux ACPI , Qemu Developers , linux-ext4 , linux-xfs , Ross Zwisler , Vishal L Verma , Dave Jiang , "Michael S. Tsirkin" , Jason Wang , Matthew Wilcox , "Rafael J. Wysocki" , Christoph Hellwig , Len Brown , Theodore Ts'o , Andreas Dilger , "Darrick J. Wong" , lcapitulino@redhat.com, Kevin Wolf , Igor Mammedov , Nitesh Narayan Lal , Rik van Riel , Stefan Hajnoczi , Andrea Arcangeli , David Hildenbrand , david , cohuck@redhat.com, Xiao Guangrong , Paolo Bonzini , kilobyte@angband.pl, yuval shaia Subject: Re: [PATCH v5 1/6] libnvdimm: nd_region flush callback support Message-ID: <20190418161833.GA22970@infradead.org> References: <20190410040826.24371-1-pagupta@redhat.com> <20190410040826.24371-2-pagupta@redhat.com> <20190412083230.GA29850@quack2.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 18, 2019 at 09:05:05AM -0700, Dan Williams wrote: > > > I'd either add a comment about avoiding retpoline overhead here or just > > > make ->flush == NULL mean generic_nvdimm_flush(). Just so that people don't > > > get confused by the code. > > > > Isn't this premature optimization? I really don't like adding things > > like this without some numbers to show it's worth it. > > I don't think it's premature given this optimization technique is > already being deployed elsewhere, see: > > https://lwn.net/Articles/774347/ For one this one was backed by numbers, and second after feedback from Linux we switched to the NULL pointer check instead.