check if top cb is null to avoid hard fault top cb is allowed to be null in api so this is required Signed-off-by: Declan Snyder <declan.snyder@nxp.com>