2018-12-12 14:12:45 +00:00
|
|
|
// SPDX-License-Identifier: GPL-2.0+
|
|
|
|
/*
|
|
|
|
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
|
|
|
|
*
|
|
|
|
* From arch/x86/lib/asm-offsets.c
|
|
|
|
*
|
|
|
|
* This program is used to generate definitions needed by
|
|
|
|
* assembly language modules.
|
|
|
|
*/
|
|
|
|
|
2020-10-31 03:38:53 +00:00
|
|
|
#include <asm/global_data.h>
|
2018-12-12 14:12:45 +00:00
|
|
|
#include <linux/kbuild.h>
|
|
|
|
|
|
|
|
int main(void)
|
|
|
|
{
|
|
|
|
DEFINE(GD_BOOT_HART, offsetof(gd_t, arch.boot_hart));
|
2020-04-21 18:15:01 +00:00
|
|
|
DEFINE(GD_FIRMWARE_FDT_ADDR, offsetof(gd_t, arch.firmware_fdt_addr));
|
2022-09-02 08:47:39 +00:00
|
|
|
#if !CONFIG_IS_ENABLED(XIP)
|
2022-09-21 06:34:54 +00:00
|
|
|
#ifdef CONFIG_AVAILABLE_HARTS
|
2019-03-17 18:28:37 +00:00
|
|
|
DEFINE(GD_AVAILABLE_HARTS, offsetof(gd_t, arch.available_harts));
|
2022-09-21 06:34:54 +00:00
|
|
|
#endif
|
2019-04-30 05:49:33 +00:00
|
|
|
#endif
|
2018-12-12 14:12:45 +00:00
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|