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: src/tapset ChangeLog nfs.stp


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


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