You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
62 lines
1.9 KiB
Diff
62 lines
1.9 KiB
Diff
8 years ago
|
From 3e4dc755337ca86d29c9f21f5225a77595aee032 Mon Sep 17 00:00:00 2001
|
||
|
From: Ioana Radulescu <ruxandra.radulescu@nxp.com>
|
||
|
Date: Wed, 6 Apr 2016 12:12:06 +0300
|
||
|
Subject: [PATCH 213/226] staging: fsl-dpaa2/mac: Remove version checks
|
||
|
|
||
|
We intend to ensure backward compatibility with all MC versions
|
||
|
going forward, so we don't require an exact version match anymore
|
||
|
between MAC driver, DPMAC API version and DPMAC object version in
|
||
|
MC firmware.
|
||
|
|
||
|
Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
|
||
|
(cherry picked from commit eafc210ef421fb0dca67b67bf1a2fe98cd060c31)
|
||
|
---
|
||
|
drivers/staging/fsl-dpaa2/mac/mac.c | 29 ++---------------------------
|
||
|
1 file changed, 2 insertions(+), 27 deletions(-)
|
||
|
|
||
|
--- a/drivers/staging/fsl-dpaa2/mac/mac.c
|
||
|
+++ b/drivers/staging/fsl-dpaa2/mac/mac.c
|
||
|
@@ -481,30 +481,6 @@ static struct device_node *lookup_node(s
|
||
|
return NULL;
|
||
|
}
|
||
|
|
||
|
-static int check_dpmac_version(struct dpaa2_mac_priv *priv)
|
||
|
-{
|
||
|
- struct device *dev = &priv->mc_dev->dev;
|
||
|
- int mc_version = priv->attr.version.major;
|
||
|
-
|
||
|
- /* Check that the FLIB-defined version matches the one reported by MC */
|
||
|
- if (mc_version != DPMAC_VER_MAJOR) {
|
||
|
- dev_err(dev, "DPMAC FLIB version mismatch: MC says %d, we have %d\n",
|
||
|
- mc_version, DPMAC_VER_MAJOR);
|
||
|
- return -EINVAL;
|
||
|
- }
|
||
|
-
|
||
|
- /* ... and that we actually support it */
|
||
|
- if (mc_version < DPAA2_SUPPORTED_DPMAC_VERSION) {
|
||
|
- dev_err(dev, "Unsupported DPMAC FLIB version (%d)\n",
|
||
|
- mc_version);
|
||
|
- return -EINVAL;
|
||
|
- }
|
||
|
-
|
||
|
- dev_dbg(dev, "Using DPMAC FLIB version %d\n", mc_version);
|
||
|
-
|
||
|
- return 0;
|
||
|
-}
|
||
|
-
|
||
|
static int dpaa2_mac_probe(struct fsl_mc_device *mc_dev)
|
||
|
{
|
||
|
struct device *dev;
|
||
|
@@ -558,9 +534,8 @@ static int dpaa2_mac_probe(struct fsl_mc
|
||
|
goto err_close;
|
||
|
}
|
||
|
|
||
|
- err = check_dpmac_version(priv);
|
||
|
- if (err)
|
||
|
- goto err_close;
|
||
|
+ dev_info_once(dev, "Using DPMAC API %d.%d\n",
|
||
|
+ priv->attr.version.major, priv->attr.version.minor);
|
||
|
|
||
|
/* Look up the DPMAC node in the device-tree. */
|
||
|
dpmac_node = lookup_node(dev, priv->attr.id);
|