summaryrefslogtreecommitdiff
path: root/kernel/src/utils/align.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/src/utils/align.hpp')
-rw-r--r--kernel/src/utils/align.hpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/src/utils/align.hpp b/kernel/src/utils/align.hpp
new file mode 100644
index 0000000..2f2c665
--- /dev/null
+++ b/kernel/src/utils/align.hpp
@@ -0,0 +1,2 @@
+#define ALIGNUP(VALUE, c) ((VALUE + c - 1) & ~(c - 1))
+#define ALIGNDOWN(VALUE, c) ((VALUE / c) * c) \ No newline at end of file