162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 262306a36Sopenharmony_ci/* 362306a36Sopenharmony_ci * Author: Huacai Chen <chenhuacai@loongson.cn> 462306a36Sopenharmony_ci * Copyright (C) 2020-2022 Loongson Technology Corporation Limited 562306a36Sopenharmony_ci */ 662306a36Sopenharmony_ci 762306a36Sopenharmony_ci#ifndef __ASM_VDSO_H 862306a36Sopenharmony_ci#define __ASM_VDSO_H 962306a36Sopenharmony_ci 1062306a36Sopenharmony_ci#include <linux/mm.h> 1162306a36Sopenharmony_ci#include <linux/mm_types.h> 1262306a36Sopenharmony_ci#include <vdso/datapage.h> 1362306a36Sopenharmony_ci 1462306a36Sopenharmony_ci#include <asm/barrier.h> 1562306a36Sopenharmony_ci 1662306a36Sopenharmony_ci/* 1762306a36Sopenharmony_ci * struct loongarch_vdso_info - Details of a VDSO image. 1862306a36Sopenharmony_ci * @vdso: Pointer to VDSO image (page-aligned). 1962306a36Sopenharmony_ci * @size: Size of the VDSO image (page-aligned). 2062306a36Sopenharmony_ci * @off_rt_sigreturn: Offset of the rt_sigreturn() trampoline. 2162306a36Sopenharmony_ci * @code_mapping: Special mapping structure for vdso code. 2262306a36Sopenharmony_ci * @code_mapping: Special mapping structure for vdso data. 2362306a36Sopenharmony_ci * 2462306a36Sopenharmony_ci * This structure contains details of a VDSO image, including the image data 2562306a36Sopenharmony_ci * and offsets of certain symbols required by the kernel. It is generated as 2662306a36Sopenharmony_ci * part of the VDSO build process, aside from the mapping page array, which is 2762306a36Sopenharmony_ci * populated at runtime. 2862306a36Sopenharmony_ci */ 2962306a36Sopenharmony_cistruct loongarch_vdso_info { 3062306a36Sopenharmony_ci void *vdso; 3162306a36Sopenharmony_ci unsigned long size; 3262306a36Sopenharmony_ci unsigned long offset_sigreturn; 3362306a36Sopenharmony_ci struct vm_special_mapping code_mapping; 3462306a36Sopenharmony_ci struct vm_special_mapping data_mapping; 3562306a36Sopenharmony_ci}; 3662306a36Sopenharmony_ci 3762306a36Sopenharmony_ciextern struct loongarch_vdso_info vdso_info; 3862306a36Sopenharmony_ci 3962306a36Sopenharmony_ci#endif /* __ASM_VDSO_H */ 40