• Yazen Ghannam's avatar
    x86/mce/AMD: Get address from already initialized block · 27bd5950
    Yazen Ghannam authored
    The block address is saved after the block is initialized when
    threshold_init_device() is called.
    
    Use the saved block address, if available, rather than trying to
    rediscover it.
    
    This will avoid a call trace, when resuming from suspend, due to the
    rdmsr_safe_on_cpu() call in get_block_address(). The rdmsr_safe_on_cpu()
    call issues an IPI but we're running with interrupts disabled. This
    triggers:
    
        WARNING: CPU: 0 PID: 11523 at kernel/smp.c:291 smp_call_function_single+0xdc/0xe0
    Signed-off-by: default avatarYazen Ghannam <yazen.ghannam@amd.com>
    Signed-off-by: default avatarBorislav Petkov <bp@suse.de>
    Cc: <stable@vger.kernel.org> # 4.14.x
    Cc: Borislav Petkov <bp@alien8.de>
    Cc: Linus Torvalds <torvalds@linux-foundation.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Thomas Gleixner <tglx@linutronix.de>
    Cc: Tony Luck <tony.luck@intel.com>
    Cc: linux-edac <linux-edac@vger.kernel.org>
    Link: http://lkml.kernel.org/r/20180221101900.10326-8-bp@alien8.deSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
    27bd5950
mce_amd.c 34.2 KB