Changeset ae88aa7 in rtems for c/src/libchip/ide

Timestamp:
03/10/14 07:15:37 (10 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, 5, master
Children:
d50acdbb
Parents:
b1196e3
git-author:
Sebastian Huber <sebastian.huber@…> (03/10/14 07:15:37)
git-committer:
Sebastian Huber <sebastian.huber@…> (03/11/14 09:58:09)
Message:

sapi: Use one SMP lock for all chains

This partially reverts commit 1215fd4d9426a59d568560e9a485628560363133.

In order to support profiling of SMP locks and provide a future
compatible SMP locks API it is necessary to add an SMP lock destroy
function. Since the commit above adds an SMP lock to each chain control
we would have to add a rtems_chain_destroy() function as well. This
complicates the chain usage dramatically. Thus revert the patch above.
A global SMP lock for all chains is used to implement the protected
chain operations.

Advantages:

  • The SAPI chain API is now identical on SMP and non-SMP configurations.
  • The size of the chain control is reduced and is then equal to the Score chains.
  • The protected chain operations work correctly on SMP.

Disadvantage:

  • Applications using many different chains and the protected operations may notice lock contention.

The chain control size drop is a huge benefit (SAPI chain controls are
66% larger than the Score chain controls). The only disadvantage is not
really a problem since these applications can use specific interrupt
locks and unprotected chain operations to avoid this issue.

(No files)

Note: See TracChangeset for help on using the changeset viewer.