• Jean Delvare's avatar
    PCI/AER: Log actual error causes in aer_inject · 96b45ea5
    Jean Delvare authored
    The aer_inject driver is very quiet.  In most cases, it merely returns an
    error code to user-space, leaving the user with little clue about the
    actual reason for the failure.
    
    So, log error messages for 4 of the most frequent causes of failure:
    * Can't find the root port of the specified device.
    * Device doesn't support AER.
    * Root port doesn't support AER.
    * AER device not found.
    
    This gives the user a chance to understand why aer-inject failed.
    
    Based on a preliminary patch by Thomas Renninger.
    Signed-off-by: default avatarJean Delvare <jdelvare@suse.de>
    Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
    CC: Borislav Petkov <bp@suse.de>
    CC: Thomas Renninger <trenn@suse.de>
    96b45ea5
aer_inject.c 13.5 KB