Skip to content

Commit

Permalink
firmware: xilinx: Register event manager driver
Browse files Browse the repository at this point in the history
Use family code in order to register event manager
driver for Versal and Versal NET platforms, instead
of using compatible string.

Signed-off-by: Jay Buddhabhatti <jay.buddhabhatti@amd.com>
Link: https://lore.kernel.org/r/20231129112713.22718-4-jay.buddhabhatti@amd.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Jay Buddhabhatti authored and Greg Kroah-Hartman committed Dec 7, 2023
1 parent f689a0c commit a9d0618
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions drivers/firmware/xilinx/zynqmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1916,7 +1916,6 @@ ATTRIBUTE_GROUPS(zynqmp_firmware);
static int zynqmp_firmware_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
struct device_node *np;
struct zynqmp_devinfo *devinfo;
int ret;

Expand Down Expand Up @@ -1979,14 +1978,12 @@ static int zynqmp_firmware_probe(struct platform_device *pdev)

zynqmp_pm_api_debugfs_init();

np = of_find_compatible_node(NULL, NULL, "xlnx,versal");
if (np) {
if (pm_family_code == VERSAL_FAMILY_CODE) {
em_dev = platform_device_register_data(&pdev->dev, "xlnx_event_manager",
-1, NULL, 0);
if (IS_ERR(em_dev))
dev_err_probe(&pdev->dev, PTR_ERR(em_dev), "EM register fail with error\n");
}
of_node_put(np);

return of_platform_populate(dev->of_node, NULL, NULL, dev);
}
Expand Down

0 comments on commit a9d0618

Please sign in to comment.