lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <87plzddpg3.fsf@mail.lhotse>
Date:   Mon, 11 Dec 2023 21:05:32 +1100
From:   Michael Ellerman <mpe@...erman.id.au>
To:     Luming Yu <luming.yu@...ngroup.cn>, linuxppc-dev@...ts.ozlabs.org,
        linux-kernel@...r.kernel.org, npiggin@...il.com,
        christophe.leroy@...roup.eu
Cc:     luming.yu@...il.com, ke.zhao@...ngroup.cn, dawei.li@...ngroup.cn,
        shenghui.qu@...ngroup.cn, Luming Yu <luming.yu@...ngroup.cn>
Subject: Re: [PATCH 1/1] powerpc/debug: implement HAVE_USER_RETURN_NOTIFIER

Luming Yu <luming.yu@...ngroup.cn> writes:

> The support for user return notifier infrastructure
> is hooked into powerpc architecture.
> ---
>  arch/powerpc/Kconfig                    |  1 +
>  arch/powerpc/include/asm/entry-common.h | 16 ++++++++++++++++
>  arch/powerpc/include/asm/thread_info.h  |  2 ++
>  arch/powerpc/kernel/process.c           |  2 ++
>  4 files changed, 21 insertions(+)
>  create mode 100644 arch/powerpc/include/asm/entry-common.h
>
> diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
> index c10229c0243c..b968068cc04a 100644
> --- a/arch/powerpc/Kconfig
> +++ b/arch/powerpc/Kconfig
> @@ -277,6 +277,7 @@ config PPC
>  	select HAVE_STACKPROTECTOR		if PPC64 && $(cc-option,-mstack-protector-guard=tls -mstack-protector-guard-reg=r13)
>  	select HAVE_STATIC_CALL			if PPC32
>  	select HAVE_SYSCALL_TRACEPOINTS
> +	select HAVE_USER_RETURN_NOTIFIER
>  	select HAVE_VIRT_CPU_ACCOUNTING
>  	select HAVE_VIRT_CPU_ACCOUNTING_GEN
>  	select HOTPLUG_SMT			if HOTPLUG_CPU
> diff --git a/arch/powerpc/include/asm/entry-common.h b/arch/powerpc/include/asm/entry-common.h
> new file mode 100644
> index 000000000000..51f1eb767696
> --- /dev/null
> +++ b/arch/powerpc/include/asm/entry-common.h
> @@ -0,0 +1,16 @@
> +/* SPDX-License-Identifier: GPL-2.0 */
> +#ifndef ARCH_POWERPC_ENTRY_COMMON_H
> +#define ARCH_POWERPC_ENTRY_COMMON_H
> +
> +#include <linux/user-return-notifier.h>
> +
> +static inline void arch_exit_to_user_mode_prepare(struct pt_regs *regs,
> +						  unsigned long ti_work)
> +{
> +	if (ti_work & _TIF_USER_RETURN_NOTIFY)
> +		fire_user_return_notifiers();
> +}
> +
> +#define arch_exit_to_user_mode_prepare arch_exit_to_user_mode_prepare

AFAICS this is never called because we don't use CONFIG_GENERIC_ENTRY ?

cheers

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ