summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorYe Li <ye.li@nxp.com>2020-04-29 10:35:13 +0800
committerStefano Babic <sbabic@denx.de>2020-05-03 15:31:48 +0200
commit932c1ed328f7965e430dde98cd3403c39b22a4bc (patch)
tree8e8a0fb034d9b8f1f55b1f5805d1e1b547ab9f97 /common
parent407e3844fc8bafb5a648180ec33c2ca806c1a126 (diff)
downloadu-boot-932c1ed328f7965e430dde98cd3403c39b22a4bc.tar.gz
u-boot-932c1ed328f7965e430dde98cd3403c39b22a4bc.tar.bz2
u-boot-932c1ed328f7965e430dde98cd3403c39b22a4bc.zip
spl: sdp: Add a callback to clean up USB driver
Because SDP directly jumps to next level boot image, we'd better clean up the USB driver before it. Implement a weak callback function, that spl sdp can use it to clean up USB driver. Signed-off-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
Diffstat (limited to 'common')
-rw-r--r--common/spl/spl_sdp.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/common/spl/spl_sdp.c b/common/spl/spl_sdp.c
index 82bce0bd2e..d150951b86 100644
--- a/common/spl/spl_sdp.c
+++ b/common/spl/spl_sdp.c
@@ -39,6 +39,7 @@ static int spl_sdp_load_image(struct spl_image_info *spl_image,
ret = spl_sdp_handle(controller_index, spl_image);
debug("SDP ended\n");
+ board_usb_cleanup(controller_index, USB_INIT_DEVICE);
return ret;
}
SPL_LOAD_IMAGE_METHOD("USB SDP", 0, BOOT_DEVICE_BOARD, spl_sdp_load_image);