mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netfilter/nf.git
synced 2026-04-18 06:34:27 -04:00
vdso: Remove remnants of architecture-specific time storage
All users of the time releated parts of the vDSO are now using the generic storage implementation. Remove the therefore unnecessary compatibility accessor functions and symbols. Co-developed-by: Nam Cao <namcao@linutronix.de> Signed-off-by: Nam Cao <namcao@linutronix.de> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250204-vdso-store-rng-v3-18-13a4669dfc8c@linutronix.de
This commit is contained in:
committed by
Thomas Gleixner
parent
998a8a2608
commit
ac1a42f4e4
@@ -128,8 +128,6 @@ struct vdso_time_data {
|
||||
struct arch_vdso_time_data arch_data;
|
||||
};
|
||||
|
||||
#define vdso_data vdso_time_data
|
||||
|
||||
/**
|
||||
* struct vdso_rng_data - vdso RNG state information
|
||||
* @generation: counter representing the number of RNG reseeds
|
||||
@@ -149,10 +147,7 @@ struct vdso_rng_data {
|
||||
* With the hidden visibility, the compiler simply generates a PC-relative
|
||||
* relocation, and this is what we need.
|
||||
*/
|
||||
#ifndef CONFIG_GENERIC_VDSO_DATA_STORE
|
||||
extern struct vdso_time_data _vdso_data[CS_BASES] __attribute__((visibility("hidden")));
|
||||
extern struct vdso_time_data _timens_data[CS_BASES] __attribute__((visibility("hidden")));
|
||||
#else
|
||||
#ifdef CONFIG_GENERIC_VDSO_DATA_STORE
|
||||
extern struct vdso_time_data vdso_u_time_data[CS_BASES] __attribute__((visibility("hidden")));
|
||||
extern struct vdso_rng_data vdso_u_rng_data __attribute__((visibility("hidden")));
|
||||
extern struct vdso_arch_data vdso_u_arch_data __attribute__((visibility("hidden")));
|
||||
@@ -160,17 +155,6 @@ extern struct vdso_arch_data vdso_u_arch_data __attribute__((visibility("hidden"
|
||||
extern struct vdso_time_data *vdso_k_time_data;
|
||||
extern struct vdso_rng_data *vdso_k_rng_data;
|
||||
extern struct vdso_arch_data *vdso_k_arch_data;
|
||||
#endif
|
||||
|
||||
/**
|
||||
* union vdso_data_store - Generic vDSO data page
|
||||
*/
|
||||
union vdso_data_store {
|
||||
struct vdso_time_data data[CS_BASES];
|
||||
u8 page[1U << CONFIG_PAGE_SHIFT];
|
||||
};
|
||||
|
||||
#ifdef CONFIG_GENERIC_VDSO_DATA_STORE
|
||||
|
||||
#define VDSO_ARCH_DATA_SIZE ALIGN(sizeof(struct vdso_arch_data), PAGE_SIZE)
|
||||
#define VDSO_ARCH_DATA_PAGES (VDSO_ARCH_DATA_SIZE >> PAGE_SHIFT)
|
||||
@@ -189,7 +173,6 @@ enum vdso_pages {
|
||||
/*
|
||||
* The generic vDSO implementation requires that gettimeofday.h
|
||||
* provides:
|
||||
* - __arch_get_vdso_data(): to get the vdso datapage.
|
||||
* - __arch_get_hw_counter(): to get the hw counter based on the
|
||||
* clock_mode.
|
||||
* - gettimeofday_fallback(): fallback for gettimeofday.
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include <asm/barrier.h>
|
||||
#include <vdso/datapage.h>
|
||||
|
||||
static __always_inline u32 vdso_read_begin(const struct vdso_data *vd)
|
||||
static __always_inline u32 vdso_read_begin(const struct vdso_time_data *vd)
|
||||
{
|
||||
u32 seq;
|
||||
|
||||
@@ -18,7 +18,7 @@ static __always_inline u32 vdso_read_begin(const struct vdso_data *vd)
|
||||
return seq;
|
||||
}
|
||||
|
||||
static __always_inline u32 vdso_read_retry(const struct vdso_data *vd,
|
||||
static __always_inline u32 vdso_read_retry(const struct vdso_time_data *vd,
|
||||
u32 start)
|
||||
{
|
||||
u32 seq;
|
||||
@@ -28,7 +28,7 @@ static __always_inline u32 vdso_read_retry(const struct vdso_data *vd,
|
||||
return seq != start;
|
||||
}
|
||||
|
||||
static __always_inline void vdso_write_begin(struct vdso_data *vd)
|
||||
static __always_inline void vdso_write_begin(struct vdso_time_data *vd)
|
||||
{
|
||||
/*
|
||||
* WRITE_ONCE() is required otherwise the compiler can validly tear
|
||||
@@ -40,7 +40,7 @@ static __always_inline void vdso_write_begin(struct vdso_data *vd)
|
||||
smp_wmb();
|
||||
}
|
||||
|
||||
static __always_inline void vdso_write_end(struct vdso_data *vd)
|
||||
static __always_inline void vdso_write_end(struct vdso_time_data *vd)
|
||||
{
|
||||
smp_wmb();
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user