Messages in this thread | | | From | Thomas Gleixner <> | Subject | Re: [patch 14/45] posix-timers: Consolidate interval retrieval | Date | Sat, 01 Jul 2023 20:01:01 +0200 |
| |
On Fri, Jun 30 2023 at 16:04, Frederic Weisbecker wrote: > On Fri, Jun 30, 2023 at 03:07:17PM +0200, Thomas Gleixner wrote: >> How exactly does this end up being copied to user space if ret != 0? > > kc->timer_get() doesn't return any value. > > So before the patch, interval is retrieved only if the target is not reaped: > > timer_gettime() { > do_timer_gettime() { > posix_cpu_timer_get() { > p = cpu_timer_task_rcu(timer); > if (p) > itp->interval = .... > } > } > } > > After the patch it's retrieved unconditionally: > > timer_gettime() { > do_timer_gettime() { > //unconditionally set > itp->interval = .... > posix_cpu_timer_get() { > p = cpu_timer_task_rcu(timer); > if (!p) > //doesn't return any value so no failure reported
Duh. you are right ...
| |