LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
	"Christoph Hellwig" <hch@lst.de>,
	"Matias Bjørling" <m@bjorling.me>
Subject: linux-next: manual merge of the block tree with Linus' tree
Date: Mon, 14 Dec 2015 12:36:36 +1100	[thread overview]
Message-ID: <20151214123636.2a1d0c9d@canb.auug.org.au> (raw)

Hi Jens,

Today's linux-next merge of the block tree got a conflict in:

  drivers/nvme/host/lightnvm.c

between commit:

  16f26c3aa9b9 ("lightnvm: replace req queue with nvmdev for lld")

from Linus' tree and commit:

  ac02dddec633 ("NVMe: fix build with CONFIG_NVM enabled")

from the block tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

diff --cc drivers/nvme/host/lightnvm.c
index 15f2acb4d5cd,09cf0b99d2fa..000000000000
--- a/drivers/nvme/host/lightnvm.c
+++ b/drivers/nvme/host/lightnvm.c
@@@ -271,10 -273,9 +271,9 @@@ static int init_grps(struct nvm_id *nvm
  	return 0;
  }
  
 -static int nvme_nvm_identity(struct request_queue *q, struct nvm_id *nvm_id)
 +static int nvme_nvm_identity(struct nvm_dev *nvmdev, struct nvm_id *nvm_id)
  {
 -	struct nvme_ns *ns = q->queuedata;
 +	struct nvme_ns *ns = nvmdev->q->queuedata;
- 	struct nvme_dev *dev = ns->dev;
  	struct nvme_nvm_id *nvme_nvm_id;
  	struct nvme_nvm_command c = {};
  	int ret;
@@@ -308,13 -309,12 +307,12 @@@ out
  	return ret;
  }
  
 -static int nvme_nvm_get_l2p_tbl(struct request_queue *q, u64 slba, u32 nlb,
 +static int nvme_nvm_get_l2p_tbl(struct nvm_dev *nvmdev, u64 slba, u32 nlb,
  				nvm_l2p_update_fn *update_l2p, void *priv)
  {
 -	struct nvme_ns *ns = q->queuedata;
 +	struct nvme_ns *ns = nvmdev->q->queuedata;
- 	struct nvme_dev *dev = ns->dev;
  	struct nvme_nvm_command c = {};
- 	u32 len = queue_max_hw_sectors(dev->admin_q) << 9;
+ 	u32 len = queue_max_hw_sectors(ns->ctrl->admin_q) << 9;
  	u32 nlb_pr_rq = len / sizeof(u64);
  	u64 cmd_slba = slba;
  	void *entries;
@@@ -359,9 -359,8 +357,9 @@@ static int nvme_nvm_get_bb_tbl(struct n
  				int nr_blocks, nvm_bb_update_fn *update_bbtbl,
  				void *priv)
  {
 +	struct request_queue *q = nvmdev->q;
  	struct nvme_ns *ns = q->queuedata;
- 	struct nvme_dev *dev = ns->dev;
+ 	struct nvme_ctrl *ctrl = ns->ctrl;
  	struct nvme_nvm_command c = {};
  	struct nvme_nvm_bb_tbl *bb_tbl;
  	int tblsz = sizeof(struct nvme_nvm_bb_tbl) + nr_blocks;
@@@ -415,11 -413,10 +413,10 @@@ out
  	return ret;
  }
  
 -static int nvme_nvm_set_bb_tbl(struct request_queue *q, struct nvm_rq *rqd,
 +static int nvme_nvm_set_bb_tbl(struct nvm_dev *nvmdev, struct nvm_rq *rqd,
  								int type)
  {
 -	struct nvme_ns *ns = q->queuedata;
 +	struct nvme_ns *ns = nvmdev->q->queuedata;
- 	struct nvme_dev *dev = ns->dev;
  	struct nvme_nvm_command c = {};
  	int ret = 0;
  
@@@ -517,12 -512,11 +514,11 @@@ static int nvme_nvm_erase_block(struct 
  	return nvme_submit_sync_cmd(q, (struct nvme_command *)&c, NULL, 0);
  }
  
 -static void *nvme_nvm_create_dma_pool(struct request_queue *q, char *name)
 +static void *nvme_nvm_create_dma_pool(struct nvm_dev *nvmdev, char *name)
  {
 -	struct nvme_ns *ns = q->queuedata;
 +	struct nvme_ns *ns = nvmdev->q->queuedata;
- 	struct nvme_dev *dev = ns->dev;
  
- 	return dma_pool_create(name, dev->dev, PAGE_SIZE, PAGE_SIZE, 0);
+ 	return dma_pool_create(name, ns->ctrl->dev, PAGE_SIZE, PAGE_SIZE, 0);
  }
  
  static void nvme_nvm_destroy_dma_pool(void *pool)
@@@ -573,19 -567,14 +569,20 @@@ void nvme_nvm_unregister(struct request
  	nvm_unregister(disk_name);
  }
  
 +/* move to shared place when used in multiple places. */
 +#define PCI_VENDOR_ID_CNEX 0x1d1d
 +#define PCI_DEVICE_ID_CNEX_WL 0x2807
 +#define PCI_DEVICE_ID_CNEX_QEMU 0x1f1f
 +
  int nvme_nvm_ns_supported(struct nvme_ns *ns, struct nvme_id_ns *id)
  {
- 	struct nvme_dev *dev = ns->dev;
- 	struct pci_dev *pdev = to_pci_dev(dev->dev);
+ 	struct nvme_ctrl *ctrl = ns->ctrl;
+ 	/* XXX: this is poking into PCI structures from generic code! */
+ 	struct pci_dev *pdev = to_pci_dev(ctrl->dev);
  
  	/* QEMU NVMe simulator - PCI ID + Vendor specific bit */
 -	if (pdev->vendor == PCI_VENDOR_ID_INTEL && pdev->device == 0x5845 &&
 +	if (pdev->vendor == PCI_VENDOR_ID_CNEX &&
 +				pdev->device == PCI_DEVICE_ID_CNEX_QEMU &&
  							id->vs[0] == 0x1)
  		return 1;
  

             reply	other threads:[~2015-12-14  1:36 UTC|newest]

Thread overview: 103+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-14  1:36 Stephen Rothwell [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-11-25 23:38 Stephen Rothwell
2021-11-26  5:30 ` Christoph Hellwig
2021-11-01  1:36 Stephen Rothwell
2021-10-25  2:26 Stephen Rothwell
2021-08-17  5:25 Stephen Rothwell
2021-08-17 16:40 ` Tejun Heo
2021-08-17 16:50   ` Christoph Hellwig
2021-08-17 16:52     ` Tejun Heo
2021-08-09  4:29 Stephen Rothwell
2021-08-09 14:05 ` Jens Axboe
2020-12-14  3:56 Stephen Rothwell
2020-09-23  4:05 Stephen Rothwell
2020-01-28  0:38 Stephen Rothwell
2020-01-28  0:40 ` Jens Axboe
2019-04-15  3:06 Stephen Rothwell
2019-04-15 14:15 ` Jens Axboe
2019-04-15  3:00 Stephen Rothwell
2019-03-05  1:48 Stephen Rothwell
2018-11-16  2:19 Stephen Rothwell
2018-11-16  2:21 ` Jens Axboe
2017-09-04  3:09 Stephen Rothwell
2017-06-30  2:08 Stephen Rothwell
2017-06-26  2:44 Stephen Rothwell
2017-06-26  2:28 Stephen Rothwell
2017-06-23  3:06 Stephen Rothwell
2017-06-23  3:09 ` Jens Axboe
2017-06-23  3:24   ` Stephen Rothwell
2017-06-23  3:27     ` Jens Axboe
2017-06-23  3:33       ` Stephen Rothwell
2017-06-23  3:56         ` Jens Axboe
2017-06-23  3:29     ` Jens Axboe
2016-07-21  3:08 Stephen Rothwell
2016-07-08  3:07 Stephen Rothwell
2016-07-08  4:14 ` Stephen Rothwell
2016-07-08 14:11   ` Konrad Rzeszutek Wilk
2016-06-14  2:44 Stephen Rothwell
2016-05-03  4:25 Stephen Rothwell
2016-05-03 20:03 ` Jens Axboe
2016-03-07  3:12 Stephen Rothwell
2016-03-07  3:08 Stephen Rothwell
2016-03-01  0:25 Stephen Rothwell
2016-02-18  2:10 Stephen Rothwell
2016-01-13  2:07 Stephen Rothwell
2015-12-31  3:34 Stephen Rothwell
2016-01-21 22:46 ` Stephen Rothwell
2016-01-21 22:48   ` Jens Axboe
2015-12-07  4:27 Stephen Rothwell
2015-12-07  4:16 Stephen Rothwell
2015-10-06  1:33 Stephen Rothwell
2015-08-27  2:36 Stephen Rothwell
2015-08-17  4:04 Stephen Rothwell
2015-06-04  4:51 Stephen Rothwell
2015-06-04  4:36 Stephen Rothwell
2015-06-03  3:33 Stephen Rothwell
2015-06-03  3:28 Stephen Rothwell
2015-06-01  4:56 Stephen Rothwell
2015-06-01 14:31 ` Mike Snitzer
2015-04-13  4:58 Stephen Rothwell
2015-01-27  4:03 Stephen Rothwell
2014-03-17  3:55 Stephen Rothwell
2014-03-10 15:39 Mark Brown
2013-11-01  3:25 Stephen Rothwell
2013-09-25  3:11 Stephen Rothwell
2013-05-01  5:17 Stephen Rothwell
2013-03-26  2:05 Stephen Rothwell
2012-12-07  2:44 Stephen Rothwell
2012-10-31  2:04 Stephen Rothwell
2012-10-31 13:55 ` Ben Hutchings
2012-10-31 13:57   ` Jens Axboe
2012-11-01 10:04   ` Herton Ronaldo Krzesinski
2011-11-01  5:15 Stephen Rothwell
2011-11-01  8:09 ` Jens Axboe
2011-11-01  9:03   ` Stephen Rothwell
2011-05-19  1:34 Stephen Rothwell
2011-03-21  0:43 Stephen Rothwell
2011-03-21  9:48 ` Jens Axboe
2011-03-07  2:19 Stephen Rothwell
2011-03-07  6:36 ` Tejun Heo
2011-03-07  8:42   ` Jens Axboe
2011-03-07 10:41     ` Sedat Dilek
2011-03-07 10:47       ` Tejun Heo
2011-03-07 11:14         ` Sedat Dilek
2011-03-07 11:16           ` Jens Axboe
2011-03-07 11:25             ` Sedat Dilek
2011-03-07 11:26               ` Jens Axboe
2011-03-07 11:35                 ` Sedat Dilek
2011-03-07 11:46                   ` Jens Axboe
2011-03-07 12:26                     ` Sedat Dilek
2011-03-07 11:42               ` Stephen Rothwell
2011-03-07 11:38             ` Stephen Rothwell
2010-09-16  2:04 Stephen Rothwell
2010-04-29  3:52 Stephen Rothwell
2010-04-29  7:33 ` Jens Axboe
2010-03-17  1:52 Stephen Rothwell
2010-03-17  2:03 ` Li Zefan
2010-02-25  3:10 Stephen Rothwell
2010-02-25  7:47 ` Jens Axboe
2010-02-25 23:11   ` Stephen Rothwell
2009-06-25  3:15 Stephen Rothwell
2009-06-25  3:30 ` Stephen Rothwell
2009-06-25  6:38   ` Jens Axboe
2009-06-25  7:42     ` Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20151214123636.2a1d0c9d@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=axboe@kernel.dk \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=m@bjorling.me \
    --subject='Re: linux-next: manual merge of the block tree with Linus'\'' tree' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).