retimer: Fix issues in suspending PD task during retimer scan
retimer: Fix issues in suspending PD task during retimer scan

When AP scans retimer for firmware update, it requests EC to suspend
PD task of NDA (no device attached) PD ports.

Then pd_set_suspend() sets suspend flag TC_FLAGS_REQUEST_SUSPEND,
and wakes up PD task to check new flag. However in this case, the flow
exits early to avoid deadlock when running from task which is going
to be suspended. We expect next time PD task runs (after 5ms), it
can detect this flag and suspend itself. This is found to be working
only when the PD task does not enter low power mode immediately after
this flag is set. In cases, where the PD task enters low power mode,
PD is not suspended and so AP could not scan the retimer successfully.

Move to hook_call to suspend PD task, so pd_set_suspend() can execute
all the way to wake up PD task, and process the suspend flag.

BUG=b:180573726
BRANCH=none
TEST=Tested Voxel DVT, together with coreboot and kernel
changes, make sure retimers of NDA ports are in sysfs entries.
Coreboot changes are merged. Kernel patches list is:
https://chromium-review.googlesource.com/c/chromiumos/
third_party/kernel/+/2670719

Signed-off-by: li feng <0fd15d95d647a38d004d7ac9a3d0587bb1c98551@intel.com>
Change-Id: I98bf2a028ee8fe3623f2e465a02a6edeff1b6e3f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2709560
Reviewed-by: Rajmohan Mani <e2d8246fac097e5b4bbb1acd0b9bb7762d90f9f0@intel.com>
Reviewed-by: Keith Short <f6d578f97033c25f1206cb57d52f358974c82954@chromium.org>

coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec,coreboot/chrome-ec