1779df224SSven Schnelle#!/bin/sh 2779df224SSven Schnelle# SPDX-License-Identifier: GPL-2.0 3779df224SSven Schnelle 4779df224SSven Schnelle# 5779df224SSven Schnelle# Match symbols in the DSO that look like VDSO_*; produce a header file 6779df224SSven Schnelle# of constant offsets into the shared object. 7779df224SSven Schnelle# 8779df224SSven Schnelle# Doing this inside the Makefile will break the $(filter-out) function, 9779df224SSven Schnelle# causing Kbuild to rebuild the vdso-offsets header file every time. 10779df224SSven Schnelle# 11779df224SSven Schnelle# Inspired by arm64 version. 12779df224SSven Schnelle# 13779df224SSven Schnelle 14779df224SSven SchnelleLC_ALL=C 15779df224SSven Schnellesed -n 's/\([0-9a-f]*\) . __kernel_\(.*\)/\#define vdso64_offset_\2\t0x\1/p' 16