diff options
author | Laurentiu Tudor <laurentiu.tudor@nxp.com> | 2017-11-17 15:38:34 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-11-27 09:20:41 +0100 |
commit | 19e2be77f36cfd5930569cad2d197f31a576cf88 (patch) | |
tree | 76e3c0323e2d6726bc85b1d8697b4cc5dddb5fd1 /drivers/staging/fsl-mc/bus/dprc-driver.c | |
parent | 47433b630b7b30d0daa360c64308c0f4c9632986 (diff) | |
download | op-kernel-dev-19e2be77f36cfd5930569cad2d197f31a576cf88.zip op-kernel-dev-19e2be77f36cfd5930569cad2d197f31a576cf88.tar.gz |
staging: fsl-mc: use device_type instead of strcmp()
Replace strcmp() based device type checks with the standard device
model type.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/fsl-mc/bus/dprc-driver.c')
-rw-r--r-- | drivers/staging/fsl-mc/bus/dprc-driver.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/fsl-mc/bus/dprc-driver.c b/drivers/staging/fsl-mc/bus/dprc-driver.c index 28a6b87..131c715 100644 --- a/drivers/staging/fsl-mc/bus/dprc-driver.c +++ b/drivers/staging/fsl-mc/bus/dprc-driver.c @@ -593,7 +593,7 @@ static int dprc_probe(struct fsl_mc_device *mc_dev) bool msi_domain_set = false; u16 major_ver, minor_ver; - if (strcmp(mc_dev->obj_desc.type, "dprc") != 0) + if (!is_fsl_mc_bus_dprc(mc_dev)) return -EINVAL; if (dev_get_msi_domain(&mc_dev->dev)) @@ -745,7 +745,7 @@ static int dprc_remove(struct fsl_mc_device *mc_dev) int error; struct fsl_mc_bus *mc_bus = to_fsl_mc_bus(mc_dev); - if (strcmp(mc_dev->obj_desc.type, "dprc") != 0) + if (!is_fsl_mc_bus_dprc(mc_dev)) return -EINVAL; if (!mc_dev->mc_io) return -EINVAL; |