diff options
author | Scott Lobdell <slobdell@google.com> | 2021-02-05 18:00:54 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2021-02-05 18:00:54 +0000 |
commit | c800319ca06bb624b67d33741336fa42e9dd2667 (patch) | |
tree | cae72caa0322a7ecec0fecf813ae0d7c14ffd980 /libc/private/bsd_sys_param.h | |
parent | ea1e0a27d3fb999f3015dfd7b42d9ba699284f10 (diff) | |
parent | 3cfe8f2ca3589184c6329a6fa4fadf7a5ebaa0d4 (diff) |
Merge "Merge SP1A.210122.003 Change-Id: I38a0c2cf0aed3762aafe4b1fa8a69dd03106fa39" into s-keystone-qcom-dev
Diffstat (limited to 'libc/private/bsd_sys_param.h')
-rw-r--r-- | libc/private/bsd_sys_param.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/libc/private/bsd_sys_param.h b/libc/private/bsd_sys_param.h new file mode 100644 index 000000000..8c936c459 --- /dev/null +++ b/libc/private/bsd_sys_param.h @@ -0,0 +1,21 @@ +/* + * Copyright (C) 2014 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#pragma once + +/* OpenBSD has these in <sys/param.h>, but "ALIGN" isn't something we want to reserve. */ +#define ALIGNBYTES (sizeof(uintptr_t) - 1) +#define ALIGN(p) (((uintptr_t)(p) + ALIGNBYTES) & ~ALIGNBYTES) |