Hyperbus changes for v5.17-rc1

Hyperbus changes:
 
 Couple of fixes in Renesas hyperbus rpc-if driver to avoid crash on
 module remove and for missing check for error value in probe.
 -----BEGIN PGP SIGNATURE-----
 
 iQFEBAABCAAuFiEEyRC2zAhGcGjrhiNExEYeRXyRFuMFAmHFzxgQHHZpZ25lc2hy
 QHRpLmNvbQAKCRDERh5FfJEW462AB/93JmhhKIPM6F0gwlm5fCUT6Q0HRUeXeGRS
 42z21CbxG7dlf8/VUbNpNJjrMv1wYBVUlyIDZejIdLmXQVK3cdrbHv5lls96uDq6
 0tmCemctHfUjbMfINy7cwTMmOkLkimtV59pilP2eXDq63O2AIUc1guGiSwbiCQ9u
 yl0/tOVu2BTpahiMk+Us6ljFMhAdS7vSGpW8QbmNt9Z0Dh8B9qr3iahQswHP/cEa
 Y1NxZz84QZRWb1TZ6x9LHEsqNf3SFM6NIaA+qUnS8fguQaEMBzrkabsgSZ7eHKY5
 8ffqEQ8XVpNxqNBiBx3tjVIZmYJLOPsW95QV4VjzU/jjSd++f24M
 =tzl8
 -----END PGP SIGNATURE-----

Merge tag 'cfi/for-5.17' into mtd/next

Hyperbus changes for v5.17-rc1

Hyperbus changes:

Couple of fixes in Renesas hyperbus rpc-if driver to avoid crash on
module remove and for missing check for error value in probe.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
This commit is contained in:
Miquel Raynal 2021-12-31 13:28:36 +01:00
commit 2dc6de1cd3
1 changed files with 5 additions and 3 deletions

View File

@ -124,7 +124,9 @@ static int rpcif_hb_probe(struct platform_device *pdev)
if (!hyperbus)
return -ENOMEM;
rpcif_sw_init(&hyperbus->rpc, pdev->dev.parent);
error = rpcif_sw_init(&hyperbus->rpc, pdev->dev.parent);
if (error)
return error;
platform_set_drvdata(pdev, hyperbus);
@ -150,9 +152,9 @@ static int rpcif_hb_remove(struct platform_device *pdev)
{
struct rpcif_hyperbus *hyperbus = platform_get_drvdata(pdev);
int error = hyperbus_unregister_device(&hyperbus->hbdev);
struct rpcif *rpc = dev_get_drvdata(pdev->dev.parent);
rpcif_disable_rpm(rpc);
rpcif_disable_rpm(&hyperbus->rpc);
return error;
}