[PATCH v2 2/5] powerpc/rtas: Remove unused rtas_service_present()

Andrew Donnellan ajd at linux.ibm.com
Mon Nov 20 14:56:46 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>
> 
> rtas_service_present() has no more users.
> 
> rtas_function_implemented() is now the appropriate API for
> determining
> whether a given RTAS function is available to call.
> 
> Signed-off-by: Nathan Lynch <nathanl at linux.ibm.com>

grep confirms this.

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

> ---
>  arch/powerpc/include/asm/rtas.h | 1 -
>  arch/powerpc/kernel/rtas.c      | 5 -----
>  2 files changed, 6 deletions(-)
> 
> diff --git a/arch/powerpc/include/asm/rtas.h
> b/arch/powerpc/include/asm/rtas.h
> index 3bf7f0a4b07e..c6568a647cd0 100644
> --- a/arch/powerpc/include/asm/rtas.h
> +++ b/arch/powerpc/include/asm/rtas.h
> @@ -409,7 +409,6 @@ static inline bool
> rtas_function_implemented(const rtas_fn_handle_t handle)
>  	return rtas_function_token(handle) != RTAS_UNKNOWN_SERVICE;
>  }
>  extern int rtas_token(const char *service);
> -extern int rtas_service_present(const char *service);
>  extern int rtas_call(int token, int, int, int *, ...);
>  void rtas_call_unlocked(struct rtas_args *args, int token, int
> nargs,
>  			int nret, ...);
> diff --git a/arch/powerpc/kernel/rtas.c b/arch/powerpc/kernel/rtas.c
> index eddc031c4b95..b5b340a91157 100644
> --- a/arch/powerpc/kernel/rtas.c
> +++ b/arch/powerpc/kernel/rtas.c
> @@ -900,11 +900,6 @@ int rtas_token(const char *service)
>  }
>  EXPORT_SYMBOL_GPL(rtas_token);
>  
> -int rtas_service_present(const char *service)
> -{
> -	return rtas_token(service) != RTAS_UNKNOWN_SERVICE;
> -}
> -
>  #ifdef CONFIG_RTAS_ERROR_LOGGING
>  
>  static u32 rtas_error_log_max __ro_after_init = RTAS_ERROR_LOG_MAX;
> 

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


More information about the Linuxppc-dev mailing list