[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <003001d2ae23$21e8f7d0$65bae770$@opengridcomputing.com>
Date: Wed, 5 Apr 2017 10:41:45 -0500
From: "Steve Wise" <swise@...ngridcomputing.com>
To: "'Sagi Grimberg'" <sagi@...mberg.me>,
"'Logan Gunthorpe'" <logang@...tatee.com>,
"'Christoph Hellwig'" <hch@....de>,
"'James E.J. Bottomley'" <jejb@...ux.vnet.ibm.com>,
"'Martin K. Petersen'" <martin.petersen@...cle.com>,
"'Jens Axboe'" <axboe@...nel.dk>,
"'Stephen Bates'" <sbates@...thlin.com>,
"'Max Gurtovoy'" <maxg@...lanox.com>,
"'Dan Williams'" <dan.j.williams@...el.com>,
"'Keith Busch'" <keith.busch@...el.com>,
"'Jason Gunthorpe'" <jgunthorpe@...idianresearch.com>
Cc: <linux-pci@...r.kernel.org>, <linux-scsi@...r.kernel.org>,
<linux-nvme@...ts.infradead.org>, <linux-rdma@...r.kernel.org>,
<linux-nvdimm@...ts.01.org>, <linux-kernel@...r.kernel.org>
Subject: RE: [RFC 2/8] cxgb4: setup pcie memory window 4 and create p2pmem region
>
>
> > +static void setup_memwin_p2pmem(struct adapter *adap)
> > +{
> > + unsigned int mem_base = t4_read_reg(adap,
> CIM_EXTMEM2_BASE_ADDR_A);
> > + unsigned int mem_size = t4_read_reg(adap,
> CIM_EXTMEM2_ADDR_SIZE_A);
> > +
> > + if (!use_p2pmem)
> > + return;
>
> This is weird, why even call this if !use_p2pmem?
>
The use_p2pmem was added after the original change. I'll update as you
suggest.
> > +static int init_p2pmem(struct adapter *adapter)
> > +{
> > + unsigned int mem_size = t4_read_reg(adapter,
> CIM_EXTMEM2_ADDR_SIZE_A);
> > + struct p2pmem_dev *p;
> > + int rc;
> > + struct resource res;
> > +
> > + if (!mem_size || !use_p2pmem)
> > + return 0;
>
> Again, weird...
Yup.
Powered by blists - more mailing lists