.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
---|
1 | 2 | /* -*- linux-c -*- ------------------------------------------------------- * |
---|
2 | 3 | * |
---|
3 | 4 | * Copyright (C) 1991, 1992 Linus Torvalds |
---|
4 | 5 | * Copyright 2007 rPath, Inc. - All Rights Reserved |
---|
5 | 6 | * Copyright 2009 Intel Corporation; author H. Peter Anvin |
---|
6 | 7 | * |
---|
7 | | - * This file is part of the Linux kernel, and is made available under |
---|
8 | | - * the terms of the GNU General Public License version 2. |
---|
9 | | - * |
---|
10 | 8 | * ----------------------------------------------------------------------- */ |
---|
11 | 9 | |
---|
12 | 10 | /* |
---|
13 | 11 | * Main module for the real-mode kernel code |
---|
14 | 12 | */ |
---|
| 13 | +#include <linux/build_bug.h> |
---|
15 | 14 | |
---|
16 | 15 | #include "boot.h" |
---|
17 | 16 | #include "string.h" |
---|
.. | .. |
---|
34 | 33 | u16 cl_offset; |
---|
35 | 34 | }; |
---|
36 | 35 | const struct old_cmdline * const oldcmd = |
---|
37 | | - (const struct old_cmdline *)OLD_CL_ADDRESS; |
---|
| 36 | + absolute_pointer(OLD_CL_ADDRESS); |
---|
38 | 37 | |
---|
39 | | - BUILD_BUG_ON(sizeof boot_params != 4096); |
---|
40 | | - memcpy(&boot_params.hdr, &hdr, sizeof hdr); |
---|
| 38 | + BUILD_BUG_ON(sizeof(boot_params) != 4096); |
---|
| 39 | + memcpy(&boot_params.hdr, &hdr, sizeof(hdr)); |
---|
41 | 40 | |
---|
42 | 41 | if (!boot_params.hdr.cmd_line_ptr && |
---|
43 | 42 | oldcmd->cl_magic == OLD_CL_MAGIC) { |
---|