162306a36Sopenharmony_ci#!/bin/sh 262306a36Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0 362306a36Sopenharmony_ci 462306a36Sopenharmony_ci# 562306a36Sopenharmony_ci# Match symbols in the DSO that look like VDSO_*; produce a header file 662306a36Sopenharmony_ci# of constant offsets into the shared object. 762306a36Sopenharmony_ci# 862306a36Sopenharmony_ci# Doing this inside the Makefile will break the $(filter-out) function, 962306a36Sopenharmony_ci# causing Kbuild to rebuild the vdso-offsets header file every time. 1062306a36Sopenharmony_ci# 1162306a36Sopenharmony_ci# Inspired by arm64 version. 1262306a36Sopenharmony_ci# 1362306a36Sopenharmony_ci 1462306a36Sopenharmony_ciLC_ALL=C 1562306a36Sopenharmony_cised -n 's/\([0-9a-f]*\) . __kernel_\(.*\)/\#define vdso32_offset_\2\t0x\1/p' 16