Re: Re: how do i write a file in soft irqs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 14, 2006 at 10:06:18PM -0700, kanishk rastogi wrote:
> 
> 
> Greg KH <greg@xxxxxxxxx> wrote: On Tue, Jun 13, 2006 at 11:16:41PM +0530, pradeep singh wrote:
> > On 6/13/06, Jesper Juhl  wrote:
> > [snip]
> > >Please search both the kernelnewbies and linux-kernel mailing list
> > >archives for why you should *not* write to files from the kernel - it
> > >has been discussed to death several times over.
> > Agreed it is not a best of the ideas to write to a file from kernel space.
> 
> Not the best?  No, how about "not allowed at all".
> 
> > But at time you may face such situations.
> 
> No, there are lots of other ways to solve such a "situation".
> 
> > How can we handle it?
> 
> Exactly why do you feel you have to write to a file?  What are the
> requirements that you are being told?
> 
> By me-----> we are to virtualize a tape device so the read and the write command comming from the SCSI mid layer into the queuecommand function (which is called in the soft irq context) into a file.........

Is this some wierd school assignment?

Just use a character device and stream the data out of that to
userspace.

good luck,

greg k-h

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux