Answer Posted / achal
The above is correct. To be more specific, a CPU might need
to access some hardware device say I2c interface. Now if 2
processes in running state try to acquire and use I2c for
some data transfer, it might create problems, when one of
them hasn't finished its operations with the device. So
whenever some process has to make use of I2C it should lock
upon the mutex object for I2c device. And after the
operation gets finished it unlocks the mutex. Now some
other process can use I2c by mutex lock.
Similarly mutex object can be used to safegaurd some other
device resources.
| Is This Answer Correct ? | 22 Yes | 4 No |
Post New Answer View All Answers
Explain whether we can use semaphore or mutex or spinlock in interrupt context in linux kernel?
Describe to me some bad code you've read or inherited lately.
what is a pure function in arm terminology?
Tell me why embedded system is useful?
Implement a
What's the difference between asynchrony and concurrency?
What is interrupt latency? How can you reduce it?
Given time, cost, client satisfaction and best practices, how will you prioritize them for a project you are working on? Explain why.
What kinds of problems can you hit with locking model? And a lockless model?
What does DMA address will deal with?
what is embedded system in a computer system?
What are some examples of anti-patterns?
What trade offs do you have for resource contention?
Explain me what are the rules followed by mutexes?
Explain the properties of a object oriented programming language.