Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

firmware: xilinx: Remove eemi ops for request_node

Use direct function call instead of using eemi ops for request_node.

Signed-off-by: Rajan Vaja <rajan.vaja@xilinx.com>
Signed-off-by: Jolly Shah <jolly.shah@xilinx.com>
Link: https://lore.kernel.org/r/1587761887-4279-17-git-send-email-jolly.shah@xilinx.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Rajan Vaja and committed by
Greg Kroah-Hartman
bf8b27ed 951d0a97

+12 -12
+3 -4
drivers/firmware/xilinx/zynqmp.c
··· 742 742 * 743 743 * Return: Returns status, either success or error+reason 744 744 */ 745 - static int zynqmp_pm_request_node(const u32 node, const u32 capabilities, 746 - const u32 qos, 747 - const enum zynqmp_pm_request_ack ack) 745 + int zynqmp_pm_request_node(const u32 node, const u32 capabilities, 746 + const u32 qos, const enum zynqmp_pm_request_ack ack) 748 747 { 749 748 return zynqmp_pm_invoke_fn(PM_REQUEST_NODE, node, capabilities, 750 749 qos, ack, NULL); 751 750 } 751 + EXPORT_SYMBOL_GPL(zynqmp_pm_request_node); 752 752 753 753 /** 754 754 * zynqmp_pm_release_node() - Release a node ··· 810 810 } 811 811 812 812 static const struct zynqmp_eemi_ops eemi_ops = { 813 - .request_node = zynqmp_pm_request_node, 814 813 .release_node = zynqmp_pm_release_node, 815 814 .set_requirement = zynqmp_pm_set_requirement, 816 815 .fpga_load = zynqmp_pm_fpga_load,
+1 -4
drivers/soc/xilinx/zynqmp_pm_domains.c
··· 163 163 int ret; 164 164 struct zynqmp_pm_domain *pd; 165 165 166 - if (!eemi_ops->request_node) 167 - return -ENXIO; 168 - 169 166 pd = container_of(domain, struct zynqmp_pm_domain, gpd); 170 167 171 168 /* If this is not the first device to attach there is nothing to do */ 172 169 if (domain->device_count) 173 170 return 0; 174 171 175 - ret = eemi_ops->request_node(pd->node_id, 0, 0, 172 + ret = zynqmp_pm_request_node(pd->node_id, 0, 0, 176 173 ZYNQMP_PM_REQUEST_ACK_BLOCKING); 177 174 /* If requesting a node fails print and return the error */ 178 175 if (ret) {
+8 -4
include/linux/firmware/xlnx-zynqmp.h
··· 296 296 struct zynqmp_eemi_ops { 297 297 int (*fpga_load)(const u64 address, const u32 size, const u32 flags); 298 298 int (*fpga_get_status)(u32 *value); 299 - int (*request_node)(const u32 node, 300 - const u32 capabilities, 301 - const u32 qos, 302 - const enum zynqmp_pm_request_ack ack); 303 299 int (*release_node)(const u32 node); 304 300 int (*set_requirement)(const u32 node, 305 301 const u32 capabilities, ··· 332 336 int zynqmp_pm_reset_get_status(const enum zynqmp_pm_reset reset, u32 *status); 333 337 int zynqmp_pm_init_finalize(void); 334 338 int zynqmp_pm_set_suspend_mode(u32 mode); 339 + int zynqmp_pm_request_node(const u32 node, const u32 capabilities, 340 + const u32 qos, const enum zynqmp_pm_request_ack ack); 335 341 #else 336 342 static inline struct zynqmp_eemi_ops *zynqmp_pm_get_eemi_ops(void) 337 343 { ··· 427 429 return -ENODEV; 428 430 } 429 431 static inline int zynqmp_pm_set_suspend_mode(u32 mode) 432 + { 433 + return -ENODEV; 434 + } 435 + static inline int zynqmp_pm_request_node(const u32 node, const u32 capabilities, 436 + const u32 qos, 437 + const enum zynqmp_pm_request_ack ack) 430 438 { 431 439 return -ENODEV; 432 440 }