cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

ksym_race.c (283B)


      1// SPDX-License-Identifier: GPL-2.0
      2#include <vmlinux.h>
      3#include <bpf/bpf_helpers.h>
      4
      5extern int bpf_testmod_ksym_percpu __ksym;
      6
      7SEC("tc")
      8int ksym_fail(struct __sk_buff *ctx)
      9{
     10	return *(int *)bpf_this_cpu_ptr(&bpf_testmod_ksym_percpu);
     11}
     12
     13char _license[] SEC("license") = "GPL";