Texas Instruments TMS320 User Manual page 162

Dsp/bios v5.40
Hide thumbs Also See for TMS320:
Table of Contents

Advertisement

Power Management
Type of Event
Disable SWI & TSK Scheduling
V/F Scaling
Before notifying clients registered for
pending setpoint change notification.
Sleep
Before notifying clients registered for
going to deep sleep or going to deep
sleep until restart notification.
4-58
4) The application decides to change the V/F setpoint, and calls
PWRM_changeSetpoint to initiate the setpoint change. It may do this, for
example, because of a change in the device's mode.
5) Before the setpoint change, PWRM validates the change request and
then notifies all registered clients of the impending setpoint change.
Clients are notified in the same order they registered for notification
(FIFO order).
6) PWRM calls the Power Scaling Library to change the V/F setpoint.
7) After the setpoint change, PWRM notifies clients that the setpoint has
been changed.
If a client's notification function can take immediate action it should do so and
return PWRM_NOTIFYDONE. If the notification function cannot take action
because it must wait, it should return PWRM_NOTIFYNOTDONE. Later,
when that client has completed its required action (for example, on the next
interrupt from the device), it should call the delayedCompletionFunction
indicated to it by PWRM_registerNotify. The PWRM module waits until all
clients have returned PWRM_NOTIFYDONE before continuing. If a client
does not signal that it is done within the timeout specified, PWRM returns
PWRM_ETIMEOUT, indicating a system failure.
Before notifying clients of a power event, PWRM firsts disable SWI and TSK
scheduling to protect against preemption while the event is being processed.
The following table shows when SWI and TSK scheduling is disabled and re-
enabled around event processing:
Since SWI and TSK scheduling are disabled during PWRM notifications,
clients cannot rely on SWI or TSK scheduling to finish PWRM event
processing. HWIs can be used to determine and signal completion of
processing of the power event. For example, to allow an in-process DMA
operation to complete, the DMA ISR can still run, and then call the
delayedCompletionFunction to signal to PWRM that the client has finished
processing the event.
Re-enable Scheduling
After changing the setpoint and notifying clients
registered for completed setpoint change
notification.
After wakeup and notifying clients registered for
woken from deep sleep notification.

Advertisement

Table of Contents
loading

Table of Contents