> On Mon, 2005-03-21 at 01:24 -0800, Siddharth Taneja wrote: > > Hi, > > > > I am trying to build a simple character device driver which > > supports only the open, read and release interface. The code > > compiles fine and the module gets inserted also fine but when I > > do cat <device name>, the read function is entered multiple > > times, resulting in multiple and same outputs("we did it" cat command would just open the file and keep calling read system call until read returns 0 (which means there is no more data to be read) or some error occurs. Modify your read implementation to return the actual number of bytes read and 0 when there is no more data to be read. Gopu. -- ___________________________________________________________ Sign-up for Ads Free at Mail.com http://promo.mail.com/adsfreejump.htm -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/