13.10.2015 18:38, Dmitry Osipenko пишет:
13.10.2015 17:11, Dmitry Osipenko пишет:
+        ptimer_set_limit(tb->timer, value, 0);
+        ptimer_set_count(tb->timer, value);


Umm... looking more at these lines, I think it might put in a trouble in some
corner case. It might worth trying to make ptimer more flexible rather than to
workaround it's imperfection.


I looked into moving specific trigger/start/stop logic into the ptimer and it really doesn't worth churning the ptimer code, since no other device has similar requirements (or they are just incomplete/broken). I'll add one-line patch in V5 for ptimer_set_limit() to make ptimer_get_count() return correct value for the disabled timer, so we won't need the above ad-hoc.

--
Dmitry

Reply via email to