mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
platform/x86: intel_pmc_ipc: Remove dev_err() usage after platform_get_irq()
We don't need dev_err() messages when platform_get_irq() fails now that
platform_get_irq() prints an error message itself when something goes
wrong. Let's remove these prints with a simple semantic patch.
// <smpl>
@@
expression ret;
struct platform_device *E;
@@
ret =
(
platform_get_irq(E, ...)
|
platform_get_irq_byname(E, ...)
);
if ( \( ret < 0 \| ret <= 0 \) )
{
(
-if (ret != -EPROBE_DEFER)
-{ ...
-dev_err(...);
-... }
|
...
-dev_err(...);
)
...
}
// </smpl>
While we're here, remove braces on if statements that only have one
statement (manually).
Cc: Andy Shevchenko <[email protected]>
Cc: Greg Kroah-Hartman <[email protected]>
Cc: Enric Balletbo i Serra <[email protected]>
Cc: Hans de Goede <[email protected]>
Cc: "Darren Hart (VMware)" <[email protected]>
Cc: Roman Kiryanov <[email protected]>
Cc: Vadim Pasternak <[email protected]>
Cc: Greg Kroah-Hartman <[email protected]>
Signed-off-by: Stephen Boyd <[email protected]>
Signed-off-by: Andy Shevchenko <[email protected]>
This commit is contained in:
parent
e3168b8743
commit
5094421306
1 changed files with 1 additions and 3 deletions
|
|
@ -936,10 +936,8 @@ static int ipc_plat_probe(struct platform_device *pdev)
|
|||
spin_lock_init(&ipcdev.gcr_lock);
|
||||
|
||||
ipcdev.irq = platform_get_irq(pdev, 0);
|
||||
if (ipcdev.irq < 0) {
|
||||
dev_err(&pdev->dev, "Failed to get irq\n");
|
||||
if (ipcdev.irq < 0)
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
ret = ipc_plat_get_res(pdev);
|
||||
if (ret) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue