ACK: [PATCH] opal: prd_info: make a couple of functions static to reduce global scope

Alex Hung alex.hung at canonical.com
Fri Feb 3 03:23:53 UTC 2017


On 2017-01-31 12:49 AM, Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> prd_present and prd_dev_query are currently in global scope and don't
> need to be. Make them static.  Also make the fwts_prd_flags const.
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
>  src/opal/prd_info.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/src/opal/prd_info.c b/src/opal/prd_info.c
> index 2a762dd..04e0f4a 100644
> --- a/src/opal/prd_info.c
> +++ b/src/opal/prd_info.c
> @@ -33,12 +33,13 @@
>
>  static const char *prd_devnode = "/dev/opal-prd";
>
> -bool prd_present(int fwts_prd_flags) {
> +static bool prd_present(const int fwts_prd_flags)
> +{
>  	return !access(prd_devnode, fwts_prd_flags);
>  }
>
>  #ifdef HAVE_ASM_OPAL_PRD_H
> -int prd_dev_query(fwts_framework *fw)
> +static int prd_dev_query(fwts_framework *fw)
>  {
>
>  	int fd = 0;
>


Acked-by: Alex Hung <alex.hung at canonical.com>



More information about the fwts-devel mailing list