---
title: OSBitOrAtomic8
framework: kernel
role: symbol
role_heading: Function
path: kernel/1576478-osbitoratomic8
---

# OSBitOrAtomic8

8-bit logical or operation, performed atomically with respect to all devices that participate in the coherency architecture of the platform.

## Declaration

```occ
UInt8 OSBitOrAtomic8(UInt32 mask, volatile UInt8 *address);
```

## Parameters

- `mask`: The mask to logically or with the value.
- `address`: The address of the value to update atomically.

## Return Value

Return Value The value before the bitwise operation.

## Discussion

Discussion This function guarantees atomicity only with main system memory. It is specifically unsuitable for use on noncacheable memory such as that in devices; this function cannot guarantee atomicity, for example, on memory mapped from a PCI device. Additionally, this function incorporates a memory barrier on systems with weakly-ordered memory architectures. The OSBitOrAtomic8 function logically ors the bits of the specified mask into the value at the specified address and returns the original value.

## See Also

### Boolean Operations

- [OSBitAndAtomic](kernel/1576481-osbitandatomic.md)
- [OSBitAndAtomic8](kernel/1576487-osbitandatomic8.md)
- [OSBitAndAtomic16](kernel/1576453-osbitandatomic16.md)
- [OSBitOrAtomic](kernel/1576467-osbitoratomic.md)
- [OSBitOrAtomic16](kernel/1576466-osbitoratomic16.md)
- [OSBitXorAtomic](kernel/1576476-osbitxoratomic.md)
- [OSBitXorAtomic8](kernel/1576459-osbitxoratomic8.md)
- [OSBitXorAtomic16](kernel/1576464-osbitxoratomic16.md)
