@@ -291,9 +291,14 @@ def xlnx_rpmsg_ipi_parse(tree, node, openamp_channel_info,
291291
292292 return True
293293
294- def xlnx_rpmsg_kernel_update_ipis (tree , host_ipi , remote_ipi , gic_node_phandle ,
295- core_node , openamp_channel_info , channel_id ):
296- print (" -> xlnx_rpmsg_kernel_update_ipis" , host_ipi , remote_ipi , core_node , channel_id )
294+
295+ def xlnx_rpmsg_update_ipis (tree , channel_id , openamp_channel_info , verbose = 0 ):
296+ native = openamp_channel_info ["rpmsg_native_" + channel_id ]
297+ platform = openamp_channel_info ["platform" ]
298+ core_node = openamp_channel_info ["core_node" + channel_id ]
299+ host_ipi = openamp_channel_info ["host_ipi_" + channel_id ]
300+ remote_ipi = openamp_channel_info ["remote_ipi_" + channel_id ]
301+ print (" -> xlnx_rpmsg_update_ipis" , host_ipi , remote_ipi , core_node , channel_id )
297302
298303 # in case of remote run, flip the ipis so that its present for remote parsing later
299304 if openamp_channel_info ['role' + channel_id ] == 'remote' :
@@ -303,43 +308,14 @@ def xlnx_rpmsg_kernel_update_ipis(tree, host_ipi, remote_ipi, gic_node_phandle,
303308
304309 target_remote_node = [ node for node in host_ipi .subnodes (children_only = True ) if node .propval ('xlnx,ipi-id' ) == remote_ipi .propval ('xlnx,ipi-id' ) ]
305310 if target_remote_node == []:
306- print ("ERROR: xlnx_rpmsg_kernel_update_ipis : could not find host to remote ipi mapping." )
311+ print ("ERROR: xlnx_rpmsg_update_ipis : could not find host to remote ipi mapping." )
307312 return False
308313
309314 core_node + LopperProp (name = "mboxes" , value = [target_remote_node [0 ].phandle , 0 , target_remote_node [0 ].phandle , 1 ])
310315 core_node + LopperProp (name = "mbox-names" , value = ["tx" , "rx" ])
311316
312317 return True
313318
314- def xlnx_rpmsg_update_ipis (tree , channel_id , openamp_channel_info , verbose = 0 ):
315- native = openamp_channel_info ["rpmsg_native_" + channel_id ]
316- platform = openamp_channel_info ["platform" ]
317- core_node = openamp_channel_info ["core_node" + channel_id ]
318- host_ipi = openamp_channel_info ["host_ipi_" + channel_id ]
319- remote_ipi = openamp_channel_info ["remote_ipi_" + channel_id ]
320- controller_parent = None
321- amba_node = None
322- gic_node_phandle = None
323-
324- if platform == SOC_TYPE .VERSAL :
325- gic_node_phandle = tree ["/apu-bus/interrupt-controller@f9000000" ].phandle
326- elif platform == SOC_TYPE .VERSAL_NET :
327- gic_node_phandle = tree ["/apu-bus/interrupt-controller@e2000000" ].phandle
328- elif platform == SOC_TYPE .VERSAL2 :
329- gic_node_phandle = tree ["/apu-bus/interrupt-controller@e2000000" ].phandle
330- elif platform == SOC_TYPE .ZYNQMP :
331- gic_node_phandle = tree ["/apu-bus/interrupt-controller@f9010000" ].phandle
332- elif platform == SOC_TYPE .ZYNQ :
333- gic_node_phandle = tree ["/axi/interrupt-controller@f8f01000" ].phandle
334- core_node + LopperProp (name = "interrupt-parent" ,value = [gic_node_phandle ])
335- return True
336- else :
337- print ("invalid platform" )
338- return False
339-
340- return xlnx_rpmsg_kernel_update_ipis (tree , host_ipi , remote_ipi , gic_node_phandle ,
341- core_node , openamp_channel_info , channel_id )
342-
343319
344320def xlnx_rpmsg_update_tree (tree , node , channel_id , openamp_channel_info , verbose = 0 ):
345321 print (" -> xlnx_rpmsg_update_tree" , node , channel_id )
0 commit comments