2005-01-12 06:41:05

by selvakumar nagendran

[permalink] [raw]
Subject: Making sys_read to operate only on pipefs

Hello linux-experts,
I am intercepting syscalls in kernel 2.4.28. I want
to intercept read system call for the pipefilesystem.
Ofcoure read is a more generic syscall. But while
intercepting it, I have to determine whether this one
operates on a pipe. If it is, I want to perform some
other work, else nothing should be done and the normal
work has to be performed.For this, can I compare the
read function pointer in file operation structure with
the function pipe_read prototype in pipe.c. Is it
possible? If not how can I do that?

Thanks,
selva



__________________________________
Do you Yahoo!?
All your favorites on one personal page ? Try My Yahoo!
http://my.yahoo.com


2005-01-12 10:34:36

by Martin Waitz

[permalink] [raw]
Subject: Re: Making sys_read to operate only on pipefs

hoi :)

On Tue, Jan 11, 2005 at 10:40:58PM -0800, selvakumar nagendran wrote:
> I am intercepting syscalls in kernel 2.4.28. I want
> to intercept read system call for the pipefilesystem.

why not simply add your code to pipe_read in fs/pipe.c?

--
Martin Waitz


Attachments:
(No filename) (266.00 B)
signature.asc (189.00 B)
Digital signature
Download all attachments