diff --git a/lisa/_assets/kmodules/lisa/tp.c b/lisa/_assets/kmodules/lisa/tp.c index c11d82b15a71311095b97e23ddcf4bb895eecdbc..e1b2675b9ac286032b8c8ae7a57e38fa9dbeeaf7 100644 --- a/lisa/_assets/kmodules/lisa/tp.c +++ b/lisa/_assets/kmodules/lisa/tp.c @@ -47,19 +47,19 @@ static inline void _trace_se(struct sched_entity *se, trace_event(cpu, path, comm, pid, &se->avg); } -static void sched_pelt_cfs_probe(struct feature *feature, struct cfs_rq *cfs_rq) +static void sched_pelt_cfs_probe(void *feature, struct cfs_rq *cfs_rq) { _trace_cfs(cfs_rq, trace_lisa__sched_pelt_cfs); } DEFINE_TP_EVENT_FEATURE(lisa__sched_pelt_cfs, pelt_cfs_tp, sched_pelt_cfs_probe); -static void uclamp_util_cfs_probe(struct feature *feature, struct cfs_rq *cfs_rq) { +static void uclamp_util_cfs_probe(void *feature, struct cfs_rq *cfs_rq) { bool __maybe_unused is_root_rq = ((struct cfs_rq *)&rq_of(cfs_rq)->cfs == cfs_rq); trace_lisa__uclamp_util_cfs(is_root_rq, rq_of(cfs_rq), cfs_rq); } DEFINE_TP_EVENT_FEATURE(lisa__uclamp_util_cfs, pelt_cfs_tp, uclamp_util_cfs_probe); -static void sched_pelt_rt_probe(struct feature *feature, struct rq *rq) +static void sched_pelt_rt_probe(void *feature, struct rq *rq) { const struct sched_avg *avg = lisa_rq_avg_rt(rq); int cpu = lisa_rq_cpu(rq); @@ -71,7 +71,7 @@ static void sched_pelt_rt_probe(struct feature *feature, struct rq *rq) } DEFINE_TP_EVENT_FEATURE(lisa__sched_pelt_rt, pelt_rt_tp, sched_pelt_rt_probe); -static void sched_pelt_dl_probe(struct feature *feature, struct rq *rq) +static void sched_pelt_dl_probe(void *feature, struct rq *rq) { const struct sched_avg *avg = lisa_rq_avg_dl(rq); int cpu = lisa_rq_cpu(rq); @@ -83,7 +83,7 @@ static void sched_pelt_dl_probe(struct feature *feature, struct rq *rq) } DEFINE_TP_EVENT_FEATURE(lisa__sched_pelt_dl, pelt_dl_tp, sched_pelt_dl_probe); -static void sched_pelt_irq_probe(struct feature *feature, struct rq *rq) +static void sched_pelt_irq_probe(void *feature, struct rq *rq) { const struct sched_avg *avg = lisa_rq_avg_irq(rq); int cpu = lisa_rq_cpu(rq); @@ -95,13 +95,13 @@ static void sched_pelt_irq_probe(struct feature *feature, struct rq *rq) } DEFINE_TP_EVENT_FEATURE(lisa__sched_pelt_irq, pelt_irq_tp, sched_pelt_irq_probe); -static void sched_pelt_se_probe(struct feature *feature, struct sched_entity *se) +static void sched_pelt_se_probe(void *feature, struct sched_entity *se) { _trace_se(se, trace_lisa__sched_pelt_se); } DEFINE_TP_EVENT_FEATURE(lisa__sched_pelt_se, pelt_se_tp, sched_pelt_se_probe); -static void uclamp_util_se_probe(struct feature *feature, struct sched_entity *se) +static void uclamp_util_se_probe(void *feature, struct sched_entity *se) { struct cfs_rq __maybe_unused *cfs_rq = get_se_cfs_rq(se); @@ -112,7 +112,7 @@ static void uclamp_util_se_probe(struct feature *feature, struct sched_entity *s } DEFINE_TP_EVENT_FEATURE(lisa__uclamp_util_se, pelt_se_tp, uclamp_util_se_probe); -static void sched_overutilized_probe(struct feature *feature, struct root_domain *rd, bool overutilized) +static void sched_overutilized_probe(void *feature, struct root_domain *rd, bool overutilized) { if (trace_lisa__sched_overutilized_enabled()) { char span[SPAN_SIZE]; @@ -125,7 +125,7 @@ static void sched_overutilized_probe(struct feature *feature, struct root_domain DEFINE_TP_EVENT_FEATURE(lisa__sched_overutilized, sched_overutilized_tp, sched_overutilized_probe); #if LINUX_VERSION_CODE >= KERNEL_VERSION(5,9,0) -static void sched_update_nr_running_probe(struct feature *feature, struct rq *rq, int change) +static void sched_update_nr_running_probe(void *feature, struct rq *rq, int change) { if (trace_lisa__sched_update_nr_running_enabled()) { int cpu = lisa_rq_cpu(rq); @@ -136,13 +136,13 @@ static void sched_update_nr_running_probe(struct feature *feature, struct rq *rq } DEFINE_TP_EVENT_FEATURE(lisa__sched_update_nr_running, sched_update_nr_running_tp, sched_update_nr_running_probe); -static void sched_util_est_cfs_probe(struct feature *feature, struct cfs_rq *cfs_rq) +static void sched_util_est_cfs_probe(void *feature, struct cfs_rq *cfs_rq) { _trace_cfs(cfs_rq, trace_lisa__sched_util_est_cfs); } DEFINE_TP_EVENT_FEATURE(lisa__sched_util_est_cfs, sched_util_est_cfs_tp, sched_util_est_cfs_probe); -static void sched_util_est_se_probe(struct feature *feature, struct sched_entity *se) +static void sched_util_est_se_probe(void *feature, struct sched_entity *se) { _trace_se(se, trace_lisa__sched_util_est_se); } @@ -150,7 +150,7 @@ DEFINE_TP_EVENT_FEATURE(lisa__sched_util_est_se, sched_util_est_se_tp, sched_uti #endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(5,10,0) && (defined(CONFIG_ARM64) || defined(CONFIG_ARM)) -static void sched_cpu_capacity_probe(struct feature *feature, struct rq *rq) +static void sched_cpu_capacity_probe(void *feature, struct rq *rq) { trace_lisa__sched_cpu_capacity(rq); } diff --git a/lisa/_kmod.py b/lisa/_kmod.py index 384ceab6b7f26e653d118ca3a3d21add28dd30b4..9eafca561830e9d546907da9b6e6323a410e0d28 100644 --- a/lisa/_kmod.py +++ b/lisa/_kmod.py @@ -2015,17 +2015,6 @@ class FtraceDynamicKmod(DynamicKmod): """ Dynamic module providing some custom ftrace events. """ - - def install(self, *args, **kwargs): - config = self.target.plat_info['kernel']['config'] - - # Check for CFI as registering tracepoint probes apparently results in - # violations - if config.get('CFI_CLANG', False) and not config.get('CFI_PERMISSIVE', False): - raise CannotLoadModuleError('CFI (Control-flow integrity) is enabled and loading the module will crash the kernel. Setting CONFIG_CFI_PERMISSIVE=y will turn the crash into a warning') - else: - return super().install(*args, **kwargs) - def _get_symbols(self, section=None): content = self._compile() elf = ELFFile(BytesIO(content))