• Dave Ertman's avatar
    ice: fix link event handling timing · 0ce6c34a
    Dave Ertman authored
    When the driver experiences a link event (especially link up)
    there can be multiple events generated. Some of these are
    link fault and still have a state of DOWN set.  The problem
    happens when the link comes UP during the PF driver handling
    one of the LINK DOWN events.  The status of the link is updated
    and is now seen as UP, so when the actual LINK UP event comes,
    the port information has already been updated to be seen as UP,
    even though none of the UP activities have been completed.
    
    After the link information has been updated in the link
    handler and evaluated for MEDIA PRESENT, if the state
    of the link has been changed to UP, treat the DOWN event
    as an UP event since the link is now UP.
    Signed-off-by: default avatarDave Ertman <david.m.ertman@intel.com>
    Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
    Signed-off-by: default avatarTony Nguyen <anthony.l.nguyen@intel.com>
    0ce6c34a
ice_main.c 179 KB