Changeset 47990


Ignore:
Timestamp:
2015-12-23T18:11:49+01:00 (2 years ago)
Author:
rmilecki
Message:

ledtrig-netdev: reset link status & stats after changing device_name

Previously switching to non-existing device (interface) could result in
leaving LED on.

Signed-off-by: Rafał Miłecki <zajec5@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/generic/files/drivers/leds/ledtrig-netdev.c

    r47987 r47990  
    123123        if (size > 0 && trigger_data->device_name[size-1] == '\n') 
    124124                trigger_data->device_name[size-1] = 0; 
     125        trigger_data->link_up = 0; 
     126        trigger_data->last_activity = 0; 
    125127 
    126128        if (trigger_data->device_name[0] != 0) { 
Note: See TracChangeset for help on using the changeset viewer.