• Michal Swiatkowski's avatar
    ice: split probe into smaller functions · 5b246e53
    Michal Swiatkowski authored
    Part of code from probe can be reused in reload flow. Move this code to
    separate function. Create unroll functions for each part of
    initialization, like: ice_init_dev() and ice_deinit_dev(). It
    simplifies unrolling and can be used in remove flow.
    
    Avoid freeing port info as it could be reused in reload path.
    Will be freed in remove path since is allocated via devm_kzalloc().
    
    Also clean the remove path to reflect the init steps.
    Signed-off-by: default avatarMichal Swiatkowski <michal.swiatkowski@linux.intel.com>
    Tested-by: Gurucharan G <gurucharanx.g@intel.com> (A Contingent worker at Intel)
    Signed-off-by: default avatarTony Nguyen <anthony.l.nguyen@intel.com>
    5b246e53
ice_common.c 156 KB