Commit 1ce9f0dc authored by ssangani-xlnx's avatar ssangani-xlnx

2022.1 Patch: Ported changes from pull request...

2022.1 Patch: Ported changes from pull request https://github.com/Xilinx/dma_ip_drivers/pull/167 to fix XRT build issues while integrating qdma linux driver in to XRT stack

Ported changes from pull request https://github.com/Xilinx/dma_ip_drivers/pull/167 to fix XRT build issues while integrating qdma linux driver in to XRT stack
parent 35276a7a
RELEASE: 2022.1 RELEASE: 2022.1 Patch
=============== =====================
This release is validated for This release is validated for
- QDMA4.0 2020.1 Patch based example design - QDMA4.0 2020.1 Patch based example design
...@@ -104,6 +104,11 @@ CPM5 ...@@ -104,6 +104,11 @@ CPM5
- Debug register dump for ST and MM Errors - Debug register dump for ST and MM Errors
- Dual Instance support - Dual Instance support
2022.1 Patch Updates
--------------------
- Ported changes from pull request https://github.com/Xilinx/dma_ip_drivers/pull/167 to fix XRT build issues while integrating qdma linux driver in to XRT stack
KNOWN ISSUES: KNOWN ISSUES:
============= =============
- CPM5 Only - CPM5 Only
......
...@@ -18,9 +18,9 @@ ...@@ -18,9 +18,9 @@
#include "qdma_platform.h" #include "qdma_platform.h"
#include "qdma_soft_reg.h" #include "qdma_soft_reg.h"
#include "qdma_soft_access.h" #include "qdma_soft_access.h"
#include "qdma_cpm4_access.h" #include "qdma_cpm4_access/qdma_cpm4_access.h"
#include "eqdma_soft_access.h" #include "eqdma_soft_access.h"
#include "eqdma_cpm5_access.h" #include "eqdma_cpm5_access/eqdma_cpm5_access.h"
#include "qdma_reg_dump.h" #include "qdma_reg_dump.h"
#ifdef ENABLE_WPP_TRACING #ifdef ENABLE_WPP_TRACING
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#define QDMA_VERSION_MAJOR 2022 #define QDMA_VERSION_MAJOR 2022
#define QDMA_VERSION_MINOR 1 #define QDMA_VERSION_MINOR 1
#define QDMA_VERSION_PATCH 0 #define QDMA_VERSION_PATCH 1
#define QDMA_VERSION_STR \ #define QDMA_VERSION_STR \
__stringify(QDMA_VERSION_MAJOR) "." \ __stringify(QDMA_VERSION_MAJOR) "." \
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
#define LIBQDMA_VERSION_MAJOR 2022 #define LIBQDMA_VERSION_MAJOR 2022
#define LIBQDMA_VERSION_MINOR 1 #define LIBQDMA_VERSION_MINOR 1
#define LIBQDMA_VERSION_PATCH 0 #define LIBQDMA_VERSION_PATCH 1
#define LIBQDMA_VERSION_STR \ #define LIBQDMA_VERSION_STR \
__stringify(LIBQDMA_VERSION_MAJOR) "." \ __stringify(LIBQDMA_VERSION_MAJOR) "." \
......
...@@ -202,16 +202,20 @@ static void xdev_reset_work(struct work_struct *work) ...@@ -202,16 +202,20 @@ static void xdev_reset_work(struct work_struct *work)
pci_release_regions(pdev); pci_release_regions(pdev);
pci_disable_device(pdev); pci_disable_device(pdev);
#ifndef __XRT__
rv = pci_request_regions(pdev, "qdma-vf"); rv = pci_request_regions(pdev, "qdma-vf");
if (rv) { if (rv) {
pr_err("cannot obtain PCI resources\n"); pr_err("cannot obtain PCI resources\n");
return; return;
} }
#endif
rv = pci_enable_device(pdev); rv = pci_enable_device(pdev);
if (rv) { if (rv) {
pr_err("cannot enable PCI device\n"); pr_err("cannot enable PCI device\n");
#ifndef __XRT__
pci_release_regions(pdev); pci_release_regions(pdev);
#endif
return; return;
} }
...@@ -236,7 +240,6 @@ static void xdev_reset_work(struct work_struct *work) ...@@ -236,7 +240,6 @@ static void xdev_reset_work(struct work_struct *work)
qdma_device_offline(pdev, (unsigned long)xdev, qdma_device_offline(pdev, (unsigned long)xdev,
XDEV_FLR_INACTIVE); XDEV_FLR_INACTIVE);
} }
} }
#endif #endif
...@@ -594,7 +597,7 @@ static int xdev_identify_bars(struct xlnx_dma_dev *xdev, struct pci_dev *pdev) ...@@ -594,7 +597,7 @@ static int xdev_identify_bars(struct xlnx_dma_dev *xdev, struct pci_dev *pdev)
/*****************************************************************************/ /*****************************************************************************/
/** /**
* xdev_map_bars() - allocate the dma device * xdev_alloc() - allocate the dma device
* *
* @param[in] conf: qdma device configuration * @param[in] conf: qdma device configuration
* *
...@@ -997,12 +1000,14 @@ int qdma_device_open(const char *mod_name, struct qdma_dev_conf *conf, ...@@ -997,12 +1000,14 @@ int qdma_device_open(const char *mod_name, struct qdma_dev_conf *conf,
return -EINVAL; return -EINVAL;
} }
#ifndef __XRT__
rv = pci_request_regions(pdev, mod_name); rv = pci_request_regions(pdev, mod_name);
if (rv) { if (rv) {
/* Just info, some other driver may have claimed the device. */ /* Just info, some other driver may have claimed the device. */
dev_info(&pdev->dev, "cannot obtain PCI resources\n"); dev_info(&pdev->dev, "cannot obtain PCI resources\n");
return rv; return rv;
} }
#endif
rv = pci_enable_device(pdev); rv = pci_enable_device(pdev);
if (rv) { if (rv) {
...@@ -1190,7 +1195,9 @@ disable_device: ...@@ -1190,7 +1195,9 @@ disable_device:
pci_disable_device(pdev); pci_disable_device(pdev);
release_regions: release_regions:
#ifndef __XRT__
pci_release_regions(pdev); pci_release_regions(pdev);
#endif
return rv; return rv;
} }
...@@ -1240,7 +1247,9 @@ int qdma_device_close(struct pci_dev *pdev, unsigned long dev_hndl) ...@@ -1240,7 +1247,9 @@ int qdma_device_close(struct pci_dev *pdev, unsigned long dev_hndl)
pci_disable_relaxed_ordering(pdev); pci_disable_relaxed_ordering(pdev);
pci_disable_extended_tag(pdev); pci_disable_extended_tag(pdev);
#ifndef __XRT__
pci_release_regions(pdev); pci_release_regions(pdev);
#endif
pci_disable_device(pdev); pci_disable_device(pdev);
xdev_list_remove(xdev); xdev_list_remove(xdev);
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
#define DRV_MOD_MAJOR 2022 #define DRV_MOD_MAJOR 2022
#define DRV_MOD_MINOR 1 #define DRV_MOD_MINOR 1
#define DRV_MOD_PATCHLEVEL 0 #define DRV_MOD_PATCHLEVEL 1
#define DRV_MODULE_VERSION \ #define DRV_MODULE_VERSION \
__stringify(DRV_MOD_MAJOR) "." \ __stringify(DRV_MOD_MAJOR) "." \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment