|
@@ -13,6 +13,7 @@
|
|
#include <linux/msi.h>
|
|
#include <linux/msi.h>
|
|
#include <linux/dma-mapping.h>
|
|
#include <linux/dma-mapping.h>
|
|
#include <linux/delay.h>
|
|
#include <linux/delay.h>
|
|
|
|
+#include <linux/io.h>
|
|
|
|
|
|
#include <linux/fsl/mc.h>
|
|
#include <linux/fsl/mc.h>
|
|
#include "../../include/dpaa2-io.h"
|
|
#include "../../include/dpaa2-io.h"
|
|
@@ -146,10 +147,20 @@ static int dpaa2_dpio_probe(struct fsl_mc_device *dpio_dev)
|
|
* Set the CENA regs to be the cache inhibited area of the portal to
|
|
* Set the CENA regs to be the cache inhibited area of the portal to
|
|
* avoid coherency issues if a user migrates to another core.
|
|
* avoid coherency issues if a user migrates to another core.
|
|
*/
|
|
*/
|
|
- desc.regs_cena = ioremap_wc(dpio_dev->regions[1].start,
|
|
|
|
- resource_size(&dpio_dev->regions[1]));
|
|
|
|
- desc.regs_cinh = ioremap(dpio_dev->regions[1].start,
|
|
|
|
- resource_size(&dpio_dev->regions[1]));
|
|
|
|
|
|
+ desc.regs_cena = devm_memremap(dev, dpio_dev->regions[1].start,
|
|
|
|
+ resource_size(&dpio_dev->regions[1]),
|
|
|
|
+ MEMREMAP_WC);
|
|
|
|
+ if (!desc.regs_cena) {
|
|
|
|
+ dev_err(dev, "devm_memremap failed\n");
|
|
|
|
+ goto err_allocate_irqs;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ desc.regs_cinh = devm_ioremap(dev, dpio_dev->regions[1].start,
|
|
|
|
+ resource_size(&dpio_dev->regions[1]));
|
|
|
|
+ if (!desc.regs_cinh) {
|
|
|
|
+ dev_err(dev, "devm_ioremap failed\n");
|
|
|
|
+ goto err_allocate_irqs;
|
|
|
|
+ }
|
|
|
|
|
|
err = fsl_mc_allocate_irqs(dpio_dev);
|
|
err = fsl_mc_allocate_irqs(dpio_dev);
|
|
if (err) {
|
|
if (err) {
|