Last change
on this file was 99404, checked in by vboxsync, 2 years ago |
Devices/EFI/FirmwareNew: Update to edk2-stable202302 and make it build, bugref:4643
|
-
Property svn:eol-style
set to
native
|
File size:
889 bytes
|
Line | |
---|
1 | /** @file
|
---|
2 | InterlockedDecrement function
|
---|
3 |
|
---|
4 | Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
---|
5 | SPDX-License-Identifier: BSD-2-Clause-Patent
|
---|
6 |
|
---|
7 | **/
|
---|
8 |
|
---|
9 | /**
|
---|
10 | Microsoft Visual Studio 7.1 Function Prototypes for I/O Intrinsics.
|
---|
11 | **/
|
---|
12 |
|
---|
13 | long
|
---|
14 | _InterlockedDecrement (
|
---|
15 | long *lpAddend
|
---|
16 | );
|
---|
17 |
|
---|
18 | #pragma intrinsic(_InterlockedDecrement)
|
---|
19 |
|
---|
20 | /**
|
---|
21 | Performs an atomic decrement of an 32-bit unsigned integer.
|
---|
22 |
|
---|
23 | Performs an atomic decrement of the 32-bit unsigned integer specified by
|
---|
24 | Value and returns the decrement value. The decrement operation must be
|
---|
25 | performed using MP safe mechanisms. The state of the return value is not
|
---|
26 | guaranteed to be MP safe.
|
---|
27 |
|
---|
28 | @param Value A pointer to the 32-bit value to decrement.
|
---|
29 |
|
---|
30 | @return The decrement value.
|
---|
31 |
|
---|
32 | **/
|
---|
33 | UINT32
|
---|
34 | EFIAPI
|
---|
35 | InternalSyncDecrement (
|
---|
36 | IN volatile UINT32 *Value
|
---|
37 | )
|
---|
38 | {
|
---|
39 | return _InterlockedDecrement ((long *)(Value));
|
---|
40 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.