This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
RE: src/tapset ChangeLog nfs.stp
- From: "Stone, Joshua I" <joshua dot i dot stone at intel dot com>
- To: "Wenji Huang" <wenji dot huang at oracle dot com>
- Cc: <systemtap at sourceware dot org>
- Date: Mon, 20 Aug 2007 10:40:07 -0700
- Subject: RE: src/tapset ChangeLog nfs.stp
- References: <20070820081200.17595.qmail@sourceware.org>
wenji@sourceware.org wrote:
> CVSROOT: /cvs/systemtap
> Module name: src
> Changes by: wenji@sourceware.org 2007-08-20 08:12:00
>
> Modified files:
> tapset : ChangeLog nfs.stp
>
> Log message:
> 2007-08-20 Wenji Huang <wenji.huang@oracle.com>
>
> * nfs.stp (nfs.fop.aio_read, nfs.fop.aio_write): Modify
evaluating count.
> (__iov_length): New function.
> (nfs.fop.sendfile, nfs.aop.set_page_dirty,
nfs.aop.prepare_write,
> nfs.aop.release_page): Fix typo.
The new __iov_length() should not trust its parameters. If it's ever
called with a bad pointer or bad nr_segs, the call to kernel
iov_length() will cause a system crash.
The only safe way to handle this is to duplicate the functionality of
iov_length() with our own code that uses kread(). Thankfully it is a
small function in this case.
Josh