myriadrf / xtrx_linux_pcie_drv

XTRX PCI driver for linux
Apache License 2.0
16 stars 22 forks source link

Copy Paste Error Mapping Bar 1 #10

Closed AtaraxyApps closed 2 years ago

AtaraxyApps commented 3 years ago

The bar1 mapping error checking is referencing Bar0 https://github.com/xtrx-sdr/xtrx_linux_pcie_drv/blob/5ae3a3e877e5b04da6e1cfdcca2d2f124857ddb0/xtrx.c#L1193-L1197

Should be:

    bar1_addr = pci_iomap(pdev, 1, 1 << 16);
    if (!bar1_addr) {
        dev_err(&pdev->dev, "Failed to map BAR 1.\n");
        goto err_unmap0;
    }