Just can't understand UTRACE_SYSCALL_RESUMED code.

To the pointed, I tried to read the docs:

        * When %UTRACE_STOP is used in @report_syscall_entry, then @task
        * stops before attempting the system call.  In this case, another
        * @report_syscall_entry callback follows after @task resumes;

Probably I misread this comment, or code (or both) but this is not
what utrace_report_syscall_entry().

The second reporting loop is done if the tracee stops, and its
->resume = UTRACE_REPORT after wakeup.

This can happen if, during the first report, one engine returns
UTRACE_STOP and another engine returns UTRACE_REPORT.

Or, no matter how many engines we have, the tracer uses UTRACE_REPORT
to wakeup the tracee after SYSCALL_ENTRY stop.

In any case, what is the rationality?

And how can we trust "if (utrace->resume == UTRACE_REPORT)" ?
If we have multiple engines, some engine can use UTRACE_INTERRUPT ?

Oleg.

Reply via email to