Re: accessing files, devices, in kernel modules
- From: "miline" <milind.dumbare@xxxxxxxxx>
- Date: 28 Aug 2006 00:17:45 -0700
Yellow wrote:
hi there!Are you doing OPEN(filename, flags)?
I have just started studying the linux kernel, version 2.6. i read some
manuals, howtos, have already made some really simple modules, but when
I tried to do a little more complex work, I stumbled across some
dificulties.
well, what I want to is a kernel module that opens a regular file,
writes something to it, and closes it. easy, isn't it? I also thought
that ;)
but then I tried making a simple open over the file, but the module
complains it can't find the symbols open, close and write. Is there
anything unusual I must do to work with files in the kernel? none ofKernel opens the files with sys_open, similary sys_close, sys_read,
the manuals I read mentioned how to open and do some I/O over it.
now, to my real problem: I must record some sound, and then play it!
since in LInux everything is a file, I'm able to do it by means of
/dev/dsp. that's why I asked abou t how to work with regular files. but
I don't know if this way of accessing devices hold for modules. and I
can't open that file!
I looked at /proc/kallsyms, and open is there. I don't have a clue why
the module complains it couldn't find the open.
sys_write and so on.
thanks for any help you could provide, and sorry for such noob question
.
- Follow-Ups:
- Re: accessing files, devices, in kernel modules
- From: Yellow
- Re: accessing files, devices, in kernel modules
- References:
- accessing files, devices, in kernel modules
- From: Yellow
- accessing files, devices, in kernel modules
- Prev by Date: Re: startup question
- Next by Date: Re: How to trace functions in a driver??
- Previous by thread: Re: accessing files, devices, in kernel modules
- Next by thread: Re: accessing files, devices, in kernel modules
- Index(es):
Relevant Pages
|