| 1 |
|
| 2 | #include <asm/page.h>
|
| 3 |
|
| 4 | |
| 5 | * .boot.data section is shared between the decompressor code and the
|
| 6 | * decompressed kernel. The decompressor will store values in it, and copy
|
| 7 | * over to the decompressed image before starting it.
|
| 8 | *
|
| 9 | * .boot.data variables are kept in separate .boot.data.<var name> sections,
|
| 10 | * which are sorted by alignment first, then by name before being merged
|
| 11 | * into single .boot.data section. This way big holes cased by page aligned
|
| 12 | * structs are avoided and linker produces consistent result.
|
| 13 |
|
| 14 | #define BOOT_DATA \
|
| 15 | . = ALIGN(PAGE_SIZE); \
|
| 16 | .boot.data : { \
|
| 17 | __boot_data_start = .; \
|
| 18 | *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.boot.data*))) \
|
| 19 | __boot_data_end = .; \
|
| 20 | }
|
| 21 |
|
| 22 | |
| 23 | * .boot.preserved.data is similar to .boot.data, but it is not part of the
|
| 24 | * .init section and thus will be preserved for later use in the decompressed
|
| 25 | * kernel.
|
| 26 |
|
| 27 | #define BOOT_DATA_PRESERVED \
|
| 28 | . = ALIGN(PAGE_SIZE); \
|
| 29 | .boot.preserved.data : { \
|
| 30 | __boot_data_preserved_start = .; \
|
| 31 | *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.boot.preserved.data*))) \
|
| 32 | __boot_data_preserved_end = .; \
|
| 33 | }
|