What is the difference between semaphore and spinlock?
Answer / sandeep
Spinlock is a busy wait. Semaphore is a sleep wait.
Spinlocks are used to get exclusive access to critical
section whereas semaphores are used for exclusive access and
also to synchronize processes and threads.
Spin locks are used when the critical sections it is
protecting is small and are held for a short time.
Semaphores can be held for longer time. Semaphores use spin
locks to access its control structures.
Spinlocks are kernel locking mechanism where as semaphores
are used in both kernel and user space.
Semaphores should not be used in interrupt handlers since
the code sleeps if the semaphore is not acquired.
Is This Answer Correct ? | 7 Yes | 0 No |
will u plz send me the complete steps of installation of red hat linux on intel's core 2 duo processor?
I have accidently deleted my fstab... how do i recover/ regenerate the file?????? in rescue mode i cannot create a new file since the filesystem is readonly and could not mount in readwrite mode ?????????
what is difference between inetd and xinetd
As a system admin i want to know some things what are the troubleshooting issues we are facing frequently and what are the tickets will be raised.
How to build new filesystem ? and what is irig file system?
My Linux server in the two lan card one lan card is ok working but second lan card after restart daily lan card deactivate and then manual activate then properly working but after restart repeat this problem.(Fedora O.S.) Pls tell me solved this problem.
what is NIS Server...?
What is the other method of installing Linux O.S other than Text, GUI mode? Why we prefer that for installation of Linux in Real time?
What is the complete name of the default configuration file for LILO?
How do display error messages instantly when command fails?
what is meant by mysql clustering
How find out drivers of installed devices in linux (RHEL)?