Changeset c621f4aa in mainline for boot/generic/include/align.h
- Timestamp:
- 2010-07-25T10:11:13Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 377cce8
- Parents:
- 24a2517 (diff), a2da43c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 moved
-
boot/generic/include/align.h (moved) (moved from boot/generic/align.h ) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
boot/generic/include/align.h
r24a2517 rc621f4aa 1 1 /* 2 * Copyright (c) 200 6Jakub Jermar2 * Copyright (c) 2005 Jakub Jermar 3 3 * All rights reserved. 4 4 * … … 27 27 */ 28 28 29 /** @addtogroup generic 30 * @{ 31 */ 32 /** @file 29 /** 30 * @file 31 * @brief Macros for making values and addresses aligned. 33 32 */ 34 33 … … 36 35 #define BOOT_ALIGN_H_ 37 36 37 /** Align to the nearest lower address. 38 * 39 * @param s Address or size to be aligned. 40 * @param a Size of alignment, must be power of 2. 41 */ 42 #define ALIGN_DOWN(s, a) ((s) & ~((a) - 1)) 43 38 44 /** Align to the nearest higher address. 39 45 * 40 * @param addrAddress or size to be aligned.41 * @param a lignSize of alignment, must be power of 2.46 * @param s Address or size to be aligned. 47 * @param a Size of alignment, must be power of 2. 42 48 */ 43 #define ALIGN_UP( addr, align) (((addr) + ((align) - 1)) & ~((align) - 1))49 #define ALIGN_UP(s, a) (((s) + ((a) - 1)) & ~((a) - 1)) 44 50 45 51 #endif
Note:
See TracChangeset
for help on using the changeset viewer.
