Vadim Bendebury | d881367 | 2015-05-27 17:13:38 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2015 The Chromium OS Authors. All rights reserved. |
| 3 | * Use of this source code is governed by a BSD-style license that can be |
| 4 | * found in the LICENSE file. |
| 5 | */ |
| 6 | |
| 7 | #ifndef __BITS_FP_H_ |
| 8 | #define __BITS_FP_H_ |
Vadim Bendebury | 258ca73 | 2015-05-28 16:35:41 -0700 | [diff] [blame] | 9 | |
Vadim Bendebury | f788ffb | 2015-06-05 12:57:27 -0700 | [diff] [blame] | 10 | BOOL BitIsSet(unsigned int bitNum, // IN: number of the bit in 'bArray' |
| 11 | BYTE *bArray, // IN: array containing the bit |
| 12 | unsigned int arraySize // IN: size in bytes of 'bArray' |
| 13 | ); |
Vadim Bendebury | d881367 | 2015-05-27 17:13:38 -0700 | [diff] [blame] | 14 | // |
| 15 | // |
| 16 | // BitSet() |
| 17 | // |
| 18 | // This function will set the indicated bit in bArray. |
| 19 | // |
Vadim Bendebury | f788ffb | 2015-06-05 12:57:27 -0700 | [diff] [blame] | 20 | void BitSet(unsigned int bitNum, // IN: number of the bit in 'bArray' |
| 21 | BYTE *bArray, // IN: array containing the bit |
| 22 | unsigned int arraySize // IN: size in bytes of 'bArray' |
| 23 | ); |
Vadim Bendebury | 258ca73 | 2015-05-28 16:35:41 -0700 | [diff] [blame] | 24 | |
| 25 | // |
| 26 | // |
| 27 | // BitClear() |
| 28 | // |
| 29 | // This function will clear the indicated bit in bArray. |
| 30 | // |
Vadim Bendebury | f788ffb | 2015-06-05 12:57:27 -0700 | [diff] [blame] | 31 | void BitClear(unsigned int bitNum, // IN: number of the bit in 'bArray'. |
| 32 | BYTE *bArray, // IN: array containing the bit |
| 33 | unsigned int arraySize // IN: size in bytes of 'bArray' |
| 34 | ); |
Vadim Bendebury | 258ca73 | 2015-05-28 16:35:41 -0700 | [diff] [blame] | 35 | |
Vadim Bendebury | d881367 | 2015-05-27 17:13:38 -0700 | [diff] [blame] | 36 | #endif |