io_dev_init_and_check.puml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. @startuml
  2. participant arm_io_storage
  3. participant io_storage
  4. -> arm_io_storage : plat_get_image_source(image_id, &dev_handle, &image_spec)
  5. group init and check device (image_id)
  6. alt image_id = BL2_IMAGE_ID
  7. note over arm_io_storage
  8. get BL2_IMAGE_ID policy:
  9. - fip_dev_handle
  10. - open_fip()
  11. end note
  12. opt policy->check()
  13. arm_io_storage -> arm_io_storage : open_fip(spec)
  14. activate arm_io_storage
  15. arm_io_storage -> io_storage : io_dev_init(fip_dev_handle, FIP_IMAGE_ID)
  16. ref over io_storage : dev_init() on fip device
  17. arm_io_storage -> io_storage : io_open(fip_dev_handle, spec, &local_image_handle)
  18. ref over io_storage : io_open() on fip device
  19. arm_io_storage -> io_storage : io_close(local_image_handle)
  20. ref over io_storage : io_close() on fip device
  21. hnote over arm_io_storage
  22. fip_dev_handle ready
  23. end note
  24. end opt
  25. deactivate arm_io_storage
  26. else image_id = FIP_IMAGE_ID
  27. activate arm_io_storage
  28. note over arm_io_storage
  29. get FIP_IMAGE_ID policy:
  30. - memmap_dev_handle
  31. - open_memmap()
  32. end note
  33. opt policy->check()
  34. arm_io_storage -> arm_io_storage : open_memmap(spec)
  35. activate arm_io_storage
  36. arm_io_storage -> io_storage : io_dev_init(memmap_dev_handle, NULL)
  37. ref over io_storage : dev_init() on memmap device
  38. arm_io_storage -> io_storage : io_open(memmap_dev_handle, spec, &local_image_handle)
  39. ref over io_storage : io_open() on memmap device
  40. arm_io_storage -> io_storage : io_close(local_image_handle)
  41. ref over io_storage : io_close() on memmap device
  42. hnote over arm_io_storage
  43. memmap_dev_handle ready
  44. end note
  45. deactivate arm_io_storage
  46. end opt
  47. deactivate arm_io_storage
  48. end alt
  49. end group
  50. @enduml