| Date | Sat, 23 Mar 2013 18:46:05 +0100 | From | Oleg Nesterov <> | Subject | Re: [PATCH 4/7] uretprobes: return probe entry, prepare_uretprobe() |
| |
On 03/22, Anton Arapov wrote: > > @@ -1513,20 +1596,26 @@ static void handler_chain(struct uprobe *uprobe, struct pt_regs *regs) > { > struct uprobe_consumer *uc; > int remove = UPROBE_HANDLER_REMOVE; > + bool prep = false; /* prepare return uprobe, when needed */ > int rc = 0; > > down_read(&uprobe->register_rwsem); > for (uc = uprobe->consumers; uc; uc = uc->next) { > if (uc->handler) > rc = uc->handler(uc, regs); > - else > + else { > + prep |= true; > remove = 0; > + }
This looks wrong (see also my reply to 1/7).
What if uc->handler != NULL and uc->ret_handler != NULL ? We need
if (uc->rer_handler) need_prep = true;
Oleg.
|