]> rtime.felk.cvut.cz Git - zynq/linux.git/commitdiff
ARM64: zynqmp: Remove rollback in pm domain power off in case of error
authorMirela Simonovic <mirela.simonovic@aggios.com>
Tue, 6 Dec 2016 13:57:23 +0000 (14:57 +0100)
committerMichal Simek <michal.simek@xilinx.com>
Tue, 20 Dec 2016 06:58:09 +0000 (07:58 +0100)
Removed reversing the power off operation in the case of an error.
An error could appear only if something is wrong with the communication
to the PFW and in that case, reversing the operation makes no sense
because it relies on the same communication channel. Added print for an
error case.

Signed-off-by: Mirela Simonovic <mirela.simonovic@aggios.com>
Acked-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drivers/soc/xilinx/zynqmp/pm_domains.c

index 8c69f9fc824720a8ae3310301c9755b9dcc0c5cb..5906d934bda3a73c4d3da576ceebef8f811da799 100644 (file)
@@ -87,20 +87,15 @@ static int zynqmp_gpd_power_off(struct generic_pm_domain *domain)
                                                ZYNQMP_PM_REQUEST_ACK_NO);
                /**
                 * If powering down of any node inside this domain fails,
-                * turn on previously powered down nodes of this domain
+                * report and return the error
                 */
-               if (status)
-                       goto err_turn_on;
+               if (status) {
+                       pr_err("%s error %d, node %u\n", __func__, status,
+                               pd->node_ids[i]);
+                       return status;
+               }
        }
-       return 0;
 
-err_turn_on:
-       for (i++; i < pd->node_id_num; i++) {
-               zynqmp_pm_set_requirement(pd->node_ids[i],
-                                       ZYNQMP_PM_CAPABILITY_ACCESS,
-                                       ZYNQMP_PM_MAX_QOS,
-                                       ZYNQMP_PM_REQUEST_ACK_NO);
-       }
        return status;
 }