On 07/24/2017 04:05 AM, Benjamin Herrenschmidt wrote:
> On Sun, 2017-07-23 at 17:00 +0530, Vasant Hegde wrote:>> SBE on P9 provides one shot programmable timer facility. We can use this>> to implement OPAL timers and hence limit the reliance on the Linux>> heartbeat (similar to HW timer facility provided by SLW on P8).>>>> Design:>> - We will continue to run Linux heartbeat.>> - Each chip has SBE. This patch always schedules timer on SBE on master chip.>> - Timer MBOX has two options (start/stop timer). We cannot modify inflight>> timer message. Hence we reschedule timer if new timer value is greater than>> current time and less than scheduled timer value.>> Can't they fix their interface to match what we need instead ?
We had asked them .. but they told they are not supporting multiple timer.
So if new timer request is < inflight timer then we have to cancel and schedule
new timer.
>>> - SBE expects timeout value in milliseconds. We track timeout value in TB.>> Hence we convert tb to milliseconds before sending request to SBE.>> This is WAYYYYYY to coarse resolution. We want microseconds. They need> to fix their stuff.
We will check with FW folks on this.
-Vasant

On Mon, 2017-07-24 at 19:21 +0530, Vasant Hegde wrote:
> > > Can't they fix their interface to match what we need instead ?> > We had asked them .. but they told they are not supporting multiple timer.> > So if new timer request is < inflight timer then we have to cancel and schedule > new timer.
Why can't they have a "modify timer" request instead of requiring us to
send 2 requests ? That sounds brain dead. We should push, it's a
requirement from us. After all, afaik, we are the only user of that
facility.
> > > > > > - SBE expects timeout value in milliseconds. We track timeout value in TB.> > > Hence we convert tb to milliseconds before sending request to SBE.> > > > This is WAYYYYYY to coarse resolution. We want microseconds. They need> > to fix their stuff.> > We will check with FW folks on this.
Ben.