projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
234e6d2
)
ata: ahci: ceva: Updated code by using dev_err_probe()
author
Piyush Mehta
<piyush.mehta@xilinx.com>
Fri, 5 Mar 2021 09:10:29 +0000
(14:40 +0530)
committer
Jens Axboe
<axboe@kernel.dk>
Tue, 6 Apr 2021 15:25:01 +0000
(09:25 -0600)
Updated code with already prepared dev_err_probe(). It reduces code size
and simplifies EPROBE_DEFER handling.
Also, unify message format for similar error cases.
Signed-off-by: Piyush Mehta <piyush.mehta@xilinx.com>
Acked-by: Michal Simek <michal.simek@xilinx.com>
Link:
https://lore.kernel.org/r/20210305091029.23378-1-piyush.mehta@xilinx.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/ata/ahci_ceva.c
patch
|
blob
|
history
diff --git
a/drivers/ata/ahci_ceva.c
b/drivers/ata/ahci_ceva.c
index b9802185907db8f98e02d2d18c6c8f65064a80e9..50b56cd0039d287267269250a04b184328e2159b 100644
(file)
--- a/
drivers/ata/ahci_ceva.c
+++ b/
drivers/ata/ahci_ceva.c
@@
-206,11
+206,9
@@
static int ceva_ahci_probe(struct platform_device *pdev)
cevapriv->rst = devm_reset_control_get_optional_exclusive(&pdev->dev,
NULL);
- if (IS_ERR(cevapriv->rst)) {
- if (PTR_ERR(cevapriv->rst) != -EPROBE_DEFER)
- dev_err(&pdev->dev, "failed to get reset: %ld\n",
- PTR_ERR(cevapriv->rst));
- }
+ if (IS_ERR(cevapriv->rst))
+ dev_err_probe(&pdev->dev, PTR_ERR(cevapriv->rst),
+ "failed to get reset\n");
hpriv = ahci_platform_get_resources(pdev, 0);
if (IS_ERR(hpriv))