Hi Kai,

> >> I share the concern for the IO/CPU cost, but I don't think it
> >> matters much in which daemon this is done. Especially if some slack
> >> is> allowed for the timers (which should be the case), ofonod will be
> >> scheduled when the CPU is anyways woken up (e.g. modem/audio interrupts 
> >> wake up pulseaudio). 
> >
> > this is not really true. We can not wakeup ofonod every single second.
> > You might wanna start running powertop.
> 
> uhm, but I'm not claiming that. I was just stating that moving 
> the timers to e.g. pulseaudio in this case won't save much if 
> anything (the CPU will be woken up anyways, and the cost between 
> scheduling ofonod or a thread from PA, has really no difference
> to overall consumption.. the CPU is woken up anyways and roughly
> the same code to handle the timer is run).
> 
> So whether this code is in oFono or elsewhere, does not matter
> much (to overall power consumption). The main question is of course 
> how often the counters are synced.

actually it does matter since you have no extra context switch and in
addition you not accidentally wake up PA and then ofonod. You have one
centralized wakeup of one thread.

Of course this should be smart and done along with the PA audio
processing and not async to that one.

If we consider that the only sensible thing is to track the actual
talking time, then PA becomes a nice choice for this.

This doesn't mean that you should be implementing it, but I am still
maintaining that this would be a pretty damn smart way of solving this
efficiently.

> Personally I think the every-10sec interval is too short.
> It's also highly system specific when wakeups start to get 
> too costly, so picking up one value seems difficult.

My take here is that a granularity of 1 minute is enough.

Doing this every 10 seconds and displaying it on a per second level
sounds insane to me.

Regards

Marcel


_______________________________________________
ofono mailing list
ofono@ofono.org
http://lists.ofono.org/listinfo/ofono

Reply via email to