diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2008-01-27 13:29:20 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-01-27 18:01:39 -0500 |
commit | 404aae5d420ec543e2e8434f7ec0edf5e2d2b0c4 (patch) | |
tree | b60b99780f99776062507c958e1618e8f673f5a7 /arch | |
parent | 4e886c29610f4374d8971ec7a248f011cc3bd73a (diff) |
x86: fix runtime error in arch/x86/kernel/cpu/mcheck/mce_amd_64.c
This problem is due to the kobject rework recently done in this file.
The mce_amd_64.c code uses some wierd forward calls to back out of the
recursive way the code creates kobjects. Because of this, we need to
verify that we have really created a kobject before calling
kobject_uevent().
Many thanks to Yinghai Lu <yhlu.kernel@gmail.com> for reporting the
problem and testing.
Cc: Yinghai Lu <yhlu.kernel@gmail.com>
Cc: Jacob Shin <jacob.shin@amd.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kernel/cpu/mcheck/mce_amd_64.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/x86/kernel/cpu/mcheck/mce_amd_64.c b/arch/x86/kernel/cpu/mcheck/mce_amd_64.c index 753588755fee..073afa7dd89a 100644 --- a/arch/x86/kernel/cpu/mcheck/mce_amd_64.c +++ b/arch/x86/kernel/cpu/mcheck/mce_amd_64.c | |||
@@ -450,7 +450,8 @@ recurse: | |||
450 | if (err) | 450 | if (err) |
451 | goto out_free; | 451 | goto out_free; |
452 | 452 | ||
453 | kobject_uevent(&b->kobj, KOBJ_ADD); | 453 | if (b) |
454 | kobject_uevent(&b->kobj, KOBJ_ADD); | ||
454 | 455 | ||
455 | return err; | 456 | return err; |
456 | 457 | ||