This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Cannot access data passed in via gettimeofday


Perry Cheng <perryche@us.ibm.com> writes:

> [...]  I can't seem to see the data at all despite using the
> copy_from_user function to copy data from user to kernel space.
> [...]

Please be aware that might_sleep functions such as copy_from_user
should not generally be called from systemtap probe handlers.
Instead, one needs to use the atomic variants provided in the standard
tapset ... except we seem to lack a variant for copying over a struct
or an integer!  We have had one old bug to improve target expression
syntax so this would be automated (#2049, to allow e.g. $tv=>tv_sec).

All that doesn't explain though why you're getting odd results.  Does
the $tv pointer value itself seem plausible?  Kernel/gcc version?


- FChE


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]