Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:gcomes.obs
crystalhd
opensuse421.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File opensuse421.patch of Package crystalhd
diff -Nraub crystalhd-driver.ori/crystalhd_lnx.c crystalhd-driver/crystalhd_lnx.c --- crystalhd-driver.ori/crystalhd_lnx.c 2021-12-07 15:36:43.635289088 -0400 +++ crystalhd-driver/crystalhd_lnx.c 2021-12-07 15:38:08.659580769 -0400 @@ -538,34 +538,10 @@ bar0, i2o_len, bar2, mem_len); /* bar-0 */ - rc = check_mem_region(bar0, i2o_len); - if (rc) { - printk(KERN_ERR "No valid mem region...\n"); - return -ENOMEM; - } - - pinfo->i2o_addr = ioremap_nocache(bar0, i2o_len); - if (!pinfo->i2o_addr) { - printk(KERN_ERR "Failed to remap i2o region...\n"); - return -ENOMEM; - } - pinfo->pci_i2o_start = bar0; pinfo->pci_i2o_len = i2o_len; /* bar-2 */ - rc = check_mem_region(bar2, mem_len); - if (rc) { - printk(KERN_ERR "No valid mem region...\n"); - return -ENOMEM; - } - - pinfo->mem_addr = ioremap_nocache(bar2, mem_len); - if (!pinfo->mem_addr) { - printk(KERN_ERR "Failed to remap mem region...\n"); - return -ENOMEM; - } - pinfo->pci_mem_start = bar2; pinfo->pci_mem_len = mem_len; @@ -576,6 +552,18 @@ return rc; } + pinfo->i2o_addr = pci_ioremap_bar(pinfo->pdev, 0); + if (!pinfo->i2o_addr) { + printk(KERN_ERR "Failed to remap i2o region...\n"); + return -ENOMEM; + } + + pinfo->mem_addr = pci_ioremap_bar(pinfo->pdev, 2); + if (!pinfo->mem_addr) { + printk(KERN_ERR "Failed to remap mem region...\n"); + return -ENOMEM; + } + dev_dbg(dev, "i2o_addr:0x%08lx Mapped addr:0x%08lx \n", (unsigned long)pinfo->i2o_addr, (unsigned long)pinfo->mem_addr); @@ -650,7 +638,7 @@ goto free_priv; } - snprintf(pinfo->name, 31, "crystalhd_pci_e:%d:%d:%d", + snprintf(pinfo->name, sizeof(pinfo->name), "crystalhd_pci_e:%d:%d:%d", pdev->bus->number, PCI_SLOT(pdev->devfn), PCI_FUNC(pdev->devfn));
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor