Received: by 10.213.65.68 with SMTP id h4csp1304652imn; Wed, 21 Mar 2018 07:35:08 -0700 (PDT) X-Google-Smtp-Source: AG47ELsq9FG7PRkjblBxi8Gqm4BStR7NCQbFJw+qdGi7z47WH3ME2ybKcr1RBuwDHnJ9J8PFN56T X-Received: by 10.99.126.87 with SMTP id o23mr15098344pgn.350.1521642908835; Wed, 21 Mar 2018 07:35:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521642908; cv=none; d=google.com; s=arc-20160816; b=g6BekwVAJlhpowatXBUt7u7+tWROWXTopVi6lOpgK7AzjUx7N8NrKxvlwhiDAj2ehY z/XoPevAeTbMbSu63k7MfxEU0SUgHuKA1CM89tFG/IvQtkXDDwT2Cd/trCr8xG5HoSGP X1aqrK35CztBxDXJFjc1d7bODGD+2C1gfiaiQChXMISyfqup240gqsYIURkQ08UYbC20 oS+2tLjYyDfSsh8ipHCNCcGYG4EVeYyhZNA4+LfxeDfz0G/EnOKWnjeuOCYkM2vWi7tp MTnQYrnaSX24iTcpeFl6igcezltnCUP7v50/xvmvLV1h+smZVT4p8nXeKuQPcmRGy5Lu 7fdQ== 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-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date :arc-authentication-results; bh=f+q/1Ys29DxFQr1aMic21RgKh5b/3dJgr7GOrAUn/pI=; b=cdUq24s54bhJsjFL2SWeZCfD33hYRU7cwlerYk2p7WB0Y0ISV0VPUuNxykeZazh0if VWpqaDr8W4K/OfHOHWTeY5MjZyy2VMARzys69m/BKOaValtTbfDm/ox6HlhLZRVxx+44 HZNa05ZDSrU8PPcf6mwlIf0GeL6boq3XiVmxhVNmEYbflRk1xQDx2bUDe0x2PXGyIAmt fPdaa3HpTUSCBYyME1wqSui4GDMt1KggAVodo0hq7zfNO+GOuTmzbaPQPkqh82aOYRpU 53447P8wDwqmb7j/wjKDD97lWLQTdu2IPQd2TOhztzv6lDvYZc7r4xWMAOcmoYF/RNOP nboQ== 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 i2si2825127pgc.818.2018.03.21.07.34.54; Wed, 21 Mar 2018 07:35:08 -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 S1752223AbeCUOeI (ORCPT + 99 others); Wed, 21 Mar 2018 10:34:08 -0400 Received: from mga09.intel.com ([134.134.136.24]:55715 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751985AbeCUOeF (ORCPT ); Wed, 21 Mar 2018 10:34:05 -0400 X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Mar 2018 07:34:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,340,1517904000"; d="scan'208";a="210142409" Received: from unknown (HELO localhost.localdomain) ([10.232.112.44]) by orsmga005.jf.intel.com with ESMTP; 21 Mar 2018 07:34:04 -0700 Date: Wed, 21 Mar 2018 08:36:18 -0600 From: Keith Busch To: Matias =?iso-8859-1?Q?Bj=F8rling?= Cc: Javier =?iso-8859-1?Q?Gonz=E1lez?= , "linux-block@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Javier =?iso-8859-1?Q?Gonz=E1lez?= , Christoph Hellwig , Sagi Grimberg Subject: Re: [PATCH 08/12] lightnvm: implement get log report chunk helpers Message-ID: <20180321143617.GD12909@localhost.localdomain> References: <1520004080-27760-1-git-send-email-javier@cnexlabs.com> <1520004080-27760-9-git-send-email-javier@cnexlabs.com> <8a0a3bad-26a4-ca2f-4bd8-5c71858f6d00@lightnvm.io> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <8a0a3bad-26a4-ca2f-4bd8-5c71858f6d00@lightnvm.io> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 21, 2018 at 03:06:05AM -0700, Matias Bj?rling wrote: > > outside of nvme core so that we can use it form lightnvm. > > > > Signed-off-by: Javier Gonz?lez > > --- > > drivers/lightnvm/core.c | 11 +++++++ > > drivers/nvme/host/core.c | 6 ++-- > > drivers/nvme/host/lightnvm.c | 74 ++++++++++++++++++++++++++++++++++++++++++++ > > drivers/nvme/host/nvme.h | 3 ++ > > include/linux/lightnvm.h | 24 ++++++++++++++ > > 5 files changed, 115 insertions(+), 3 deletions(-) > > > > diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c > > index 2e9e9f973a75..af642ce6ba69 100644 > > --- a/drivers/nvme/host/core.c > > +++ b/drivers/nvme/host/core.c > > @@ -2127,9 +2127,9 @@ static int nvme_init_subsystem(struct nvme_ctrl *ctrl, struct nvme_id_ctrl *id) > > return ret; > > } > > > > -static int nvme_get_log_ext(struct nvme_ctrl *ctrl, struct nvme_ns *ns, > > - u8 log_page, void *log, > > - size_t size, size_t offset) > > +int nvme_get_log_ext(struct nvme_ctrl *ctrl, struct nvme_ns *ns, > > + u8 log_page, void *log, > > + size_t size, size_t offset) > > { > > struct nvme_command c = { }; > > unsigned long dwlen = size / 4 - 1; > > diff --git a/drivers/nvme/host/lightnvm.c b/drivers/nvme/host/lightnvm.c > > index 08f0f6b5bc06..ffd64a83c8c3 100644 > > --- a/drivers/nvme/host/lightnvm.c > > +++ b/drivers/nvme/host/lightnvm.c > > @@ -35,6 +35,10 @@ enum nvme_nvm_admin_opcode { > > nvme_nvm_admin_set_bb_tbl = 0xf1, > > }; > > > > > > > > > diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h > > index 1ca08f4993ba..505f797f8c6c 100644 > > --- a/drivers/nvme/host/nvme.h > > +++ b/drivers/nvme/host/nvme.h > > @@ -396,6 +396,9 @@ int nvme_reset_ctrl(struct nvme_ctrl *ctrl); > > int nvme_delete_ctrl(struct nvme_ctrl *ctrl); > > int nvme_delete_ctrl_sync(struct nvme_ctrl *ctrl); > > > > +int nvme_get_log_ext(struct nvme_ctrl *ctrl, struct nvme_ns *ns, > > + u8 log_page, void *log, size_t size, size_t offset); > > + > > extern const struct attribute_group nvme_ns_id_attr_group; > > extern const struct block_device_operations nvme_ns_head_ops; > > > > > Keith, Christoph, Sagi, Is it okay that these two changes that exposes > the nvme_get_log_ext fn are carried through Jens' tree after the nvme > tree for 4.17 has been pulled? That's okay with me. Alteratively, if you want to split the generic nvme part out, I can apply that immediately and the API will be in the first nvme-4.17 pull request.