From: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
To: jerin.jacob@caviumnetworks.com,
santosh.shukla@caviumnetworks.com, hemant.agrawal@nxp.com,
thomas@monjalon.net, ferruh.yigit@intel.com
Cc: dev@dpdk.org, Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Subject: [dpdk-dev] [PATCH] bus: fix dpaa returning IOVA as PA
Date: Tue, 6 Feb 2018 21:51:56 +0530 [thread overview]
Message-ID: <20180206162156.2104-1-pbhagavatula@caviumnetworks.com> (raw)
Fix dpaa bus returning IOVA as PA when there is no device attached to
the bus.
Fixes: 1ee9569576f6 ("config: enable dpaaX drivers for generic ARMv8")
Fixes: d5a4e3a00c4a ("bus/dpaa: set IOVA mode as physical")
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
---
Currently Octeontx platform is broken due to this, please merge this asap.
drivers/bus/dpaa/dpaa_bus.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/bus/dpaa/dpaa_bus.c b/drivers/bus/dpaa/dpaa_bus.c
index 41ee640e2..579870297 100644
--- a/drivers/bus/dpaa/dpaa_bus.c
+++ b/drivers/bus/dpaa/dpaa_bus.c
@@ -501,6 +501,10 @@ rte_dpaa_find_device(const struct rte_device *start, rte_dev_cmp_t cmp,
static enum rte_iova_mode
rte_dpaa_get_iommu_class(void)
{
+ if ((access(DPAA_DEV_PATH1, F_OK) != 0) &&
+ (access(DPAA_DEV_PATH2, F_OK) != 0)) {
+ return RTE_IOVA_DC;
+ }
return RTE_IOVA_PA;
}
--
2.16.0
next reply other threads:[~2018-02-06 16:22 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-06 16:21 Pavan Nikhilesh [this message]
2018-02-06 17:22 ` [dpdk-dev] [PATCH v2] bus/dpaa: fix dpaa returning IOVA as PA by default Pavan Nikhilesh
2018-02-06 17:28 ` Hemant Agrawal
2018-02-06 17:39 ` Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180206162156.2104-1-pbhagavatula@caviumnetworks.com \
--to=pbhagavatula@caviumnetworks.com \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@intel.com \
--cc=hemant.agrawal@nxp.com \
--cc=jerin.jacob@caviumnetworks.com \
--cc=santosh.shukla@caviumnetworks.com \
--cc=thomas@monjalon.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).