Hi,
spin_locks are busy-looping locks, they needssanother processor to help them to escape the busy loop. So, I think spin_locks are useless for a single processor embedded system. Is it right ?
regards, Saturn
Hi,
spin_locks are busy-looping locks, they needssanother processor to help them to escape the busy loop. So, I think spin_locks are useless for a single processor embedded system. Is it right ?
regards, Saturn
No. Some embedded systems have interrupts too...
But spin_lock() in the include/linux/spin_lock.h is nothing to do if CONFIG_SMP does not define. So, if spin_lock_bh() is invoked, it just disable BH but not lock the critical session. Right ?
Have something to add? Share your thoughts — no account required.
Ask the community — no account required