Skip to contentSkip to conversation

PM: sleep: remove unneeded break

PATCH Applied [email protected] 2 participants 2 messages Oct 19, 2020 – Oct 22, 2020

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 PM: sleep: remove unneeded break

From: Tom Rix <[email protected]>

A break is not needed if it is preceded by a return

---
 drivers/base/power/main.c | 1 -
 1 file changed, 1 deletion(-)
drivers/base/power/main.c +0 -1
index 205a06752ca9..c7ac49042cee 100644
@@ -363,7 +363,6 @@ static pm_callback_t pm_op(const struct dev_pm_ops *ops, pm_message_t state)
 	case PM_EVENT_THAW:
 	case PM_EVENT_RECOVER:
 		return ops->thaw;
-		break;
 	case PM_EVENT_RESTORE:
 		return ops->restore;
 #endif /* CONFIG_HIBERNATE_CALLBACKS */
Signature · 1 line
2.18.1
maintainer Applied
#1 lore raw
Quoted 15 lines · On Mon, Oct 19, 2020 at 10:03 PM <[email protected]> wrote:

From: Tom Rix <[email protected]>

A break is not needed if it is preceded by a return

---
 drivers/base/power/main.c | 1 -
 1 file changed, 1 deletion(-)
drivers/base/power/main.c +0 -0
index 205a06752ca9..c7ac49042cee 100644

drivers/base/power/main.c static pm_callback_t pm_op(const struct dev_pm_ops *ops, pm_message_t state)

Quoted 8 lines
drivers/base/power/main.c +0 -2
@@ -363,7 +363,6 @@ static pm_callback_t pm_op(const struct dev_pm_ops *ops, pm_message_t state)
        case PM_EVENT_THAW:
        case PM_EVENT_RECOVER:
                return ops->thaw;
-               break;
        case PM_EVENT_RESTORE:
                return ops->restore;
 #endif /* CONFIG_HIBERNATE_CALLBACKS */
--

Applied as 5.10-rc material with edits in the subject and changelog, thanks!