mirror of
https://github.com/torvalds/linux.git
synced 2026-12-01 19:12:36 +00:00
The indirection through the resources array is unnecessarily complicated
and resuling in using IS_ERR() and PTR_ERR() on a valid address. A local
variable for the devm_ioremap_resource() return value is both easier to
read and matches expectations when reading code.
Reported-by: Dan Carpenter <[email protected]>
Closes: https://lore.kernel.org/asahi/[email protected]/
Suggested-by: Vladimir Oltean <[email protected]>
Fixes: 8e98ca1e74 ("phy: apple: Add Apple Type-C PHY")
Signed-off-by: Janne Grunau <[email protected]>
Reviewed-by: Sven Peter <[email protected]>
Reviewed-by: Vladimir Oltean <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Vinod Koul <[email protected]>