Re: adding semaphores to my device driver

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

 





On Tue, Sep 14, 2010 at 10:31 PM, Greg Freemyer <greg.freemyer@xxxxxxxxx> wrote:
I think a mutex will do what you need.

Have you looked at:   Documentation/mutex-design.txt

You should find the Documentation folder at the top level of your
kernel source tree.

The mutex calls are at the bottom of the file.

Ok.

Look around at the kernel source for some example uses.  Especially
where to call mutex_init().  You obviously don't want to call that in
your write() routine.

Why not in write routine?
I discussed this thing with a friend he suggested to implement this in write routine() .

[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