Message ID | 20210923172647.72738-4-ben.widawsky@intel.com |
---|---|
State | New, archived |
Headers | show |
Series | [v2,1/9] cxl: Convert "RBI" to enum | expand |
On Thu, Sep 23, 2021 at 10:26 AM Ben Widawsky <ben.widawsky@intel.com> wrote: > > Quoting Dan, "... the request + release regions should probably just be > dropped. It's not like any of the register enumeration would collide > with someone else who already has the registers mapped. The collision > only comes when the registers are mapped for their final usage, and that > will have more precision in the request." Looks good to me: Reviewed-by: Dan Williams <dan.j.williams@intel.com> > > Recommended-by: Dan Williams <dan.j.williams@intel.com> This isn't one of the canonical tags: Documentation/process/submitting-patches.rst I'll change this to Suggested-by: > Signed-off-by: Ben Widawsky <ben.widawsky@intel.com> > --- > drivers/cxl/pci.c | 5 ----- > 1 file changed, 5 deletions(-) > > diff --git a/drivers/cxl/pci.c b/drivers/cxl/pci.c > index ccc7c2573ddc..7256c236fdb3 100644 > --- a/drivers/cxl/pci.c > +++ b/drivers/cxl/pci.c > @@ -453,9 +453,6 @@ static int cxl_pci_setup_regs(struct cxl_mem *cxlm) > return -ENXIO; > } > > - if (pci_request_mem_regions(pdev, pci_name(pdev))) > - return -ENODEV; > - > /* Get the size of the Register Locator DVSEC */ > pci_read_config_dword(pdev, regloc + PCI_DVSEC_HEADER1, ®loc_size); > regloc_size = FIELD_GET(PCI_DVSEC_HEADER1_LENGTH_MASK, regloc_size); > @@ -499,8 +496,6 @@ static int cxl_pci_setup_regs(struct cxl_mem *cxlm) > n_maps++; > } > > - pci_release_mem_regions(pdev); > - > for (i = 0; i < n_maps; i++) { > ret = cxl_map_regs(cxlm, &maps[i]); > if (ret) > -- > 2.33.0 >
diff --git a/drivers/cxl/pci.c b/drivers/cxl/pci.c index ccc7c2573ddc..7256c236fdb3 100644 --- a/drivers/cxl/pci.c +++ b/drivers/cxl/pci.c @@ -453,9 +453,6 @@ static int cxl_pci_setup_regs(struct cxl_mem *cxlm) return -ENXIO; } - if (pci_request_mem_regions(pdev, pci_name(pdev))) - return -ENODEV; - /* Get the size of the Register Locator DVSEC */ pci_read_config_dword(pdev, regloc + PCI_DVSEC_HEADER1, ®loc_size); regloc_size = FIELD_GET(PCI_DVSEC_HEADER1_LENGTH_MASK, regloc_size); @@ -499,8 +496,6 @@ static int cxl_pci_setup_regs(struct cxl_mem *cxlm) n_maps++; } - pci_release_mem_regions(pdev); - for (i = 0; i < n_maps; i++) { ret = cxl_map_regs(cxlm, &maps[i]); if (ret)
Quoting Dan, "... the request + release regions should probably just be dropped. It's not like any of the register enumeration would collide with someone else who already has the registers mapped. The collision only comes when the registers are mapped for their final usage, and that will have more precision in the request." Recommended-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Ben Widawsky <ben.widawsky@intel.com> --- drivers/cxl/pci.c | 5 ----- 1 file changed, 5 deletions(-)