forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-13 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e
kernel/arch/x86/boot/compressed/mkpiggy.c
....@@ -1,27 +1,13 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /* ----------------------------------------------------------------------- *
23 *
34 * Copyright (C) 2009 Intel Corporation. All rights reserved.
4
- *
5
- * This program is free software; you can redistribute it and/or
6
- * modify it under the terms of the GNU General Public License version
7
- * 2 as published by the Free Software Foundation.
8
- *
9
- * This program is distributed in the hope that it will be useful,
10
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
11
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
- * GNU General Public License for more details.
13
- *
14
- * You should have received a copy of the GNU General Public License
15
- * along with this program; if not, write to the Free Software
16
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
17
- * 02110-1301, USA.
185 *
196 * H. Peter Anvin <hpa@linux.intel.com>
207 *
218 * -----------------------------------------------------------------------
229 *
2310 * Outputs a small assembly wrapper with the appropriate symbols defined.
24
- *
2511 */
2612
2713 #include <stdlib.h>
....@@ -74,6 +60,12 @@
7460 printf(".incbin \"%s\"\n", argv[1]);
7561 printf("input_data_end:\n");
7662
63
+ printf(".section \".rodata\",\"a\",@progbits\n");
64
+ printf(".globl input_len\n");
65
+ printf("input_len:\n\t.long %lu\n", ilen);
66
+ printf(".globl output_len\n");
67
+ printf("output_len:\n\t.long %lu\n", (unsigned long)olen);
68
+
7769 retval = 0;
7870 bail:
7971 if (f)