[PATCH v2 3/5] powerpc/rtas: Move post_mobility_fixup() declaration to pseries

Andrew Donnellan ajd at linux.ibm.com
Mon Nov 20 14:58:41 AEDT 2023


On Tue, 2023-11-14 at 11:22 -0600, Nathan Lynch via B4 Relay wrote:
> From: Nathan Lynch <nathanl at linux.ibm.com>
> 
> This is a pseries-specific function declaration that doesn't belong
> in
> rtas.h. Move it to the pseries platform code and adjust
> pseries/suspend.c accordingly.
> 
> Signed-off-by: Nathan Lynch <nathanl at linux.ibm.com>

This looks correct to me (the other user is in mobility.c which already
has the header file included).

Reviewed-by: Andrew Donnellan <ajd at linux.ibm.com>

> ---
>  arch/powerpc/include/asm/rtas.h          | 1 -
>  arch/powerpc/platforms/pseries/pseries.h | 1 +
>  arch/powerpc/platforms/pseries/suspend.c | 1 +
>  3 files changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/powerpc/include/asm/rtas.h
> b/arch/powerpc/include/asm/rtas.h
> index c6568a647cd0..2365668fc13e 100644
> --- a/arch/powerpc/include/asm/rtas.h
> +++ b/arch/powerpc/include/asm/rtas.h
> @@ -444,7 +444,6 @@ extern void pSeries_log_error(char *buf, unsigned
> int err_type, int fatal);
>  #ifdef CONFIG_PPC_PSERIES
>  extern time64_t last_rtas_event;
>  extern int clobbering_unread_rtas_event(void);
> -extern void post_mobility_fixup(void);
>  int rtas_syscall_dispatch_ibm_suspend_me(u64 handle);
>  #else
>  static inline int clobbering_unread_rtas_event(void) { return 0; }
> diff --git a/arch/powerpc/platforms/pseries/pseries.h
> b/arch/powerpc/platforms/pseries/pseries.h
> index 8376f03f932a..1c2d736f600d 100644
> --- a/arch/powerpc/platforms/pseries/pseries.h
> +++ b/arch/powerpc/platforms/pseries/pseries.h
> @@ -55,6 +55,7 @@ extern int dlpar_detach_node(struct device_node *);
>  extern int dlpar_acquire_drc(u32 drc_index);
>  extern int dlpar_release_drc(u32 drc_index);
>  extern int dlpar_unisolate_drc(u32 drc_index);
> +void post_mobility_fixup(void);
>  
>  void queue_hotplug_event(struct pseries_hp_errorlog *hp_errlog);
>  int handle_dlpar_errorlog(struct pseries_hp_errorlog *hp_errlog);
> diff --git a/arch/powerpc/platforms/pseries/suspend.c
> b/arch/powerpc/platforms/pseries/suspend.c
> index 5c43435472cc..382003dfdb9a 100644
> --- a/arch/powerpc/platforms/pseries/suspend.c
> +++ b/arch/powerpc/platforms/pseries/suspend.c
> @@ -13,6 +13,7 @@
>  #include <asm/mmu.h>
>  #include <asm/rtas.h>
>  #include <asm/topology.h>
> +#include "pseries.h"
>  
>  static struct device suspend_dev;
>  
> 

-- 
Andrew Donnellan    OzLabs, ADL Canberra
ajd at linux.ibm.com   IBM Australia Limited


More information about the Linuxppc-dev mailing list