* Can the kernel access /?
@ 2001-04-27 14:28 Matt
2001-04-27 15:15 ` Xavier Bestel
2001-04-30 18:35 ` Alan Cox
0 siblings, 2 replies; 3+ messages in thread
From: Matt @ 2001-04-27 14:28 UTC (permalink / raw)
To: linux-kernel
I'm writing a device driver for a DSP card that requires some software
loaded onto the card for it to function, currently I'm copying the
software to the /dev node and the driver is doing the magic in it's
write() handler.
Can the driver pull the file from the filesystem if I were to pass the
path of the file as an argument on loading the module?
I'm not sure it can, but perhaps someone could settle my curiosity and
perhaps point me to some code that does this in the kernel?
I'm thinking that if it could, things like the P6 Microcode driver would
be perhaps done this way too...
Cheers
Matt
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Can the kernel access /?
2001-04-27 14:28 Can the kernel access /? Matt
@ 2001-04-27 15:15 ` Xavier Bestel
2001-04-30 18:35 ` Alan Cox
1 sibling, 0 replies; 3+ messages in thread
From: Xavier Bestel @ 2001-04-27 15:15 UTC (permalink / raw)
To: Matt; +Cc: linux-kernel
Le 27 Apr 2001 15:28:04 +0100, Matt a écrit :
> I'm writing a device driver for a DSP card that requires some software
> loaded onto the card for it to function, currently I'm copying the
> software to the /dev node and the driver is doing the magic in it's
> write() handler.
>
> Can the driver pull the file from the filesystem if I were to pass the
> path of the file as an argument on loading the module?
It's generally considered a better idea to load your firmware with a
userspace app doing an ioctl or a mmap on your driver - no nasty races
to take care of, only proven codepaths used.
Xav
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Can the kernel access /?
2001-04-27 14:28 Can the kernel access /? Matt
2001-04-27 15:15 ` Xavier Bestel
@ 2001-04-30 18:35 ` Alan Cox
1 sibling, 0 replies; 3+ messages in thread
From: Alan Cox @ 2001-04-30 18:35 UTC (permalink / raw)
To: Matt; +Cc: linux-kernel
> Can the driver pull the file from the filesystem if I were to pass the
> path of the file as an argument on loading the module?
Yes but its a bad idea. You dont want to force pathnames into the kernel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2001-04-30 18:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-04-27 14:28 Can the kernel access /? Matt
2001-04-27 15:15 ` Xavier Bestel
2001-04-30 18:35 ` Alan Cox
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox