2023-10-26 19:24:14

by Pandey, Radhey Shyam

[permalink] [raw]
Subject: [PATCH] firmware: xilinx: Move EXPORT_SYMBOL_GPL next to zynqmp_pm_feature definition

From: Rajan Vaja <[email protected]>

As mentioned in Documentation/process/coding-style.rst:
In source files, separate functions with one blank line. If the function
is exported, the **EXPORT** macro for it should follow immediately after
the closing function brace line.

So inline with guideline move zynqmp_pm_feature export symbol after its
definition.

Fixes: 218f01a80aea ("firmware: xilinx: always check API version for IOCTL/QUERY")
Signed-off-by: Rajan Vaja <[email protected]>
Signed-off-by: Radhey Shyam Pandey <[email protected]>
---
drivers/firmware/xilinx/zynqmp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/firmware/xilinx/zynqmp.c b/drivers/firmware/xilinx/zynqmp.c
index 4cc1ac7f76ed..b0d22d4455d9 100644
--- a/drivers/firmware/xilinx/zynqmp.c
+++ b/drivers/firmware/xilinx/zynqmp.c
@@ -226,7 +226,6 @@ static int do_feature_check_call(const u32 api_id)

return ret;
}
-EXPORT_SYMBOL_GPL(zynqmp_pm_feature);

/**
* zynqmp_pm_feature() - Check whether given feature is supported or not and
@@ -246,6 +245,7 @@ int zynqmp_pm_feature(const u32 api_id)

return ret;
}
+EXPORT_SYMBOL_GPL(zynqmp_pm_feature);

/**
* zynqmp_pm_is_function_supported() - Check whether given IOCTL/QUERY function
--
2.34.1


2023-10-27 14:17:04

by Michal Simek

[permalink] [raw]
Subject: Re: [PATCH] firmware: xilinx: Move EXPORT_SYMBOL_GPL next to zynqmp_pm_feature definition



On 10/26/23 21:23, Radhey Shyam Pandey wrote:
> From: Rajan Vaja <[email protected]>
>
> As mentioned in Documentation/process/coding-style.rst:
> In source files, separate functions with one blank line. If the function
> is exported, the **EXPORT** macro for it should follow immediately after
> the closing function brace line.
>
> So inline with guideline move zynqmp_pm_feature export symbol after its
> definition.
>
> Fixes: 218f01a80aea ("firmware: xilinx: always check API version for IOCTL/QUERY")
> Signed-off-by: Rajan Vaja <[email protected]>
> Signed-off-by: Radhey Shyam Pandey <[email protected]>
> ---
> drivers/firmware/xilinx/zynqmp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/firmware/xilinx/zynqmp.c b/drivers/firmware/xilinx/zynqmp.c
> index 4cc1ac7f76ed..b0d22d4455d9 100644
> --- a/drivers/firmware/xilinx/zynqmp.c
> +++ b/drivers/firmware/xilinx/zynqmp.c
> @@ -226,7 +226,6 @@ static int do_feature_check_call(const u32 api_id)
>
> return ret;
> }
> -EXPORT_SYMBOL_GPL(zynqmp_pm_feature);
>
> /**
> * zynqmp_pm_feature() - Check whether given feature is supported or not and
> @@ -246,6 +245,7 @@ int zynqmp_pm_feature(const u32 api_id)
>
> return ret;
> }
> +EXPORT_SYMBOL_GPL(zynqmp_pm_feature);
>
> /**
> * zynqmp_pm_is_function_supported() - Check whether given IOCTL/QUERY function

Reviewed-by: Michal Simek <[email protected]>

Thanks,
Michal