move DCD checks to perform_dcd
move DCD checks to perform_dcd

Check whether a DCD is valid or not in perform_dcd. This avoids
code duplication, but there is no functional change.

Signed-off-by: Stefan Agner <8bf81831f67286fff829779134e88c94b37210a1@toradex.com>

bwalle/imx_usb_loader,boundarydevices/imx_usb_loader