lkml.org 
[lkml]   [2021]   [Jun]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 3/6] firmware: xilinx: export the feature check of zynqmp firmware
From
Date


On 5/28/21 5:59 PM, Abhyuday Godhasara wrote:
> From: Rajan Vaja <rajan.vaja@xilinx.com>
>
> Export the zynqmp_pm_feature(), so it can be use by other as to get API
> version available in firmware.
>
> Signed-off-by: Rajan Vaja <rajan.vaja@xilinx.com>
> Signed-off-by: Abhyuday Godhasara <abhyuday.godhasara@xilinx.com>
> ---
> drivers/firmware/xilinx/zynqmp.c | 3 ++-
> include/linux/firmware/xlnx-zynqmp.h | 6 ++++++
> 2 files changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/firmware/xilinx/zynqmp.c b/drivers/firmware/xilinx/zynqmp.c
> index 33f190e..ce16a72 100644
> --- a/drivers/firmware/xilinx/zynqmp.c
> +++ b/drivers/firmware/xilinx/zynqmp.c
> @@ -153,7 +153,7 @@ static noinline int do_fw_call_hvc(u64 arg0, u64 arg1, u64 arg2,
> *
> * Return: Returns status, either success or error+reason
> */
> -static int zynqmp_pm_feature(u32 api_id)
> +int zynqmp_pm_feature(const u32 api_id)
> {
> int ret;
> u32 ret_payload[PAYLOAD_ARG_CNT];
> @@ -190,6 +190,7 @@ static int zynqmp_pm_feature(u32 api_id)
>
> return ret;
> }
> +EXPORT_SYMBOL_GPL(zynqmp_pm_feature);
>
> /**
> * zynqmp_pm_invoke_fn() - Invoke the system-level platform management layer
> diff --git a/include/linux/firmware/xlnx-zynqmp.h b/include/linux/firmware/xlnx-zynqmp.h
> index c715756..06ea5a4 100644
> --- a/include/linux/firmware/xlnx-zynqmp.h
> +++ b/include/linux/firmware/xlnx-zynqmp.h
> @@ -427,6 +427,7 @@ int zynqmp_pm_pinctrl_set_config(const u32 pin, const u32 param,
> u32 value);
> int zynqmp_pm_register_notifier(const u32 node, const u32 event,
> const u32 wake, const u32 enable);
> +int zynqmp_pm_feature(const u32 api_id);
> #else
> static inline int zynqmp_pm_get_api_version(u32 *version)
> {
> @@ -644,6 +645,11 @@ static inline int zynqmp_pm_register_notifier(const u32 node, const u32 event,
> {
> return -ENODEV;
> }
> +
> +static inline int zynqmp_pm_feature(const u32 api_id)
> +{
> + return -ENODEV;
> +}
> #endif
>
> #endif /* __FIRMWARE_ZYNQMP_H__ */
>

Acked-by: Michal Simek <michal.simek@xilinx.com>

Thanks,
Michal

\
 
 \ /
  Last update: 2021-06-21 13:47    [W:0.130 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site