• Fabio Estevam's avatar
    net: fec: Do not use netdev messages too early · a19a0582
    Fabio Estevam authored
    When a valid MAC address is not found the current messages
    are shown:
    
    fec 2188000.ethernet (unnamed net_device) (uninitialized): Invalid MAC address: 00:00:00:00:00:00
    fec 2188000.ethernet (unnamed net_device) (uninitialized): Using random MAC address: aa:9f:25:eb:7e:aa
    
    Since the network device has not been registered at this point, it is better
    to use dev_err()/dev_info() instead, which will provide cleaner log
    messages like these:
    
    fec 2188000.ethernet: Invalid MAC address: 00:00:00:00:00:00
    fec 2188000.ethernet: Using random MAC address: aa:9f:25:eb:7e:aa
    
    Tested on a imx6dl-pico-pi board.
    Signed-off-by: default avatarFabio Estevam <festevam@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    a19a0582
fec_main.c 96.3 KB