projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3f02ded
)
ASoC: SOF: imx: Fix an IS_ERR() vs NULL bug in imx_parse_ioremap_memory()
author
Dan Carpenter
<dan.carpenter@linaro.org>
Mon, 17 Feb 2025 07:32:44 +0000
(10:32 +0300)
committer
Mark Brown
<broonie@kernel.org>
Tue, 18 Feb 2025 16:16:30 +0000
(16:16 +0000)
The devm_ioremap() function doesn't return error pointers, it returns
NULL on error. Update the checking to match.
Fixes:
651e0ed391b1
("ASoC: SOF: imx: introduce more common structures and functions")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Link:
https://patch.msgid.link/68973636-eab8-4d82-8359-ae2c8f60f261@stanley.mountain
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/imx/imx-common.c
patch
|
blob
|
blame
|
history
diff --git
a/sound/soc/sof/imx/imx-common.c
b/sound/soc/sof/imx/imx-common.c
index c3594815e60e88f183f6113fd0733362060e9172..ea4651a0995c0145035d14281a8a8157bd715d3f 100644
(file)
--- a/
sound/soc/sof/imx/imx-common.c
+++ b/
sound/soc/sof/imx/imx-common.c
@@
-338,9
+338,9
@@
static int imx_parse_ioremap_memory(struct snd_sof_dev *sdev)
}
sdev->bar[blk_type] = devm_ioremap(sdev->dev, base, size);
- if (
IS_ERR(sdev->bar[blk_type])
)
+ if (
!sdev->bar[blk_type]
)
return dev_err_probe(sdev->dev,
-
PTR_ERR(sdev->bar[blk_type])
,
+
-ENOMEM
,
"failed to ioremap %s region\n",
chip_info->memory[i].name);
}