摘要 |
In one embodiment of the invention, a method of semaphoring between a system firmware and ACPI subsystem, includes: prior to entering a critical section by a first entity, checking a turn flag to determine if a second entity has a turn to access a critical section; if the second entity has the turn, then checking an In flag of the second entity to determine if the second entity is in the critical section; if the second entity is in the critical section, then waiting for the second entity to exit the critical section; and entering the critical section by the first entity. The method may further include: if the second entity is not in the critical section, then entering the critical section by the first entity.
|