[PATCH -mm 3/3] PM: Do not check parent state in suspend and resume core code

Date

Sun, 17 Jun 2007 19:50:51 +0200

From: Rafael J. Wysocki <rjw@sisk.pl>

The checks if the device's parent is in the right state done indrivers/base/power/suspend.c and drivers/base/power/resume.c serve no particularpurpose, since if the parent is in a wrong power state, the device's suspend orresume callbacks are supposed to return an error anyway. Moreover, they arealso useless from the sanity checking point of view, because they rely on thecode being checked to set dev->parent->power.power_state.event appropriately,which need not happen if that code is buggy. For these reasons they can beremoved.