|
|
|
Re: Semaphore | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
>> > Imagine a driver which only one app can use at a time (perhaps a serial >> > port). The kernel will take a lock when the user space app open()s the >> > device node and release it when it close()s. >> > If the app segfaults in between the open() and close() the lock will >> > still get released. The kernel always cleans up open files for stopped >> > processes, regardless of how they stop. During this cleanup the kernel >> > will close() the device node, and as a result the driver will release >> > the lock. Can you please point to some code in Linux Kernel that does the job? Thanks, --- KostaZ _______________________________________________ Kernelnewbies mailing list Kernelnewbies@xxxxxxxxxxxxxxxxx http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
[Newbies FAQ] [Linux Kernel Development] [IETF Annouce] [Git] [Networking] [Security] [Bugtraq] [Photo] [Yosemite] [MIPS Linux] [ARM Linux] [Linux Security] [Linux Networking] [Linux RAID] [Linux SCSI] [Linux ACPI]
![]() |
![]() |