diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-03-15 19:40:53 -0700 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-03-15 19:40:53 -0700 |
| commit | 209b6c8fa72e8b726a0cd273a56aded55be22bfa (patch) | |
| tree | 64bb034958516bd6750dfe11efb4168ba8941e29 /arch/x86/kernel/microcode_core.c | |
| parent | 0310e437182568a9e0aa862f2a9d13908069df73 (diff) | |
| parent | 1396fa9cd2e34669253b7ca8c75f12103481f71c (diff) | |
Merge branch 'x86-microcode-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'x86-microcode-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86, microcode, AMD: Fix signedness bug in generic_load_microcode()
x86, microcode, AMD: Extend ucode size verification
x86, microcode, AMD: Cleanup dmesg output
x86, microcode, AMD: Remove unneeded memset call
x86, microcode, AMD: Simplify get_next_ucode
x86, microcode, AMD: Simplify install_equiv_cpu_table
x86, microcode, AMD: Release firmware on error
x86, microcode: Correct sysdev_add error path
Diffstat (limited to 'arch/x86/kernel/microcode_core.c')
| -rw-r--r-- | arch/x86/kernel/microcode_core.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/x86/kernel/microcode_core.c b/arch/x86/kernel/microcode_core.c index 1cca374a2ba..87af68e0e1e 100644 --- a/arch/x86/kernel/microcode_core.c +++ b/arch/x86/kernel/microcode_core.c @@ -417,8 +417,10 @@ static int mc_sysdev_add(struct sys_device *sys_dev) if (err) return err; - if (microcode_init_cpu(cpu) == UCODE_ERROR) - err = -EINVAL; + if (microcode_init_cpu(cpu) == UCODE_ERROR) { + sysfs_remove_group(&sys_dev->kobj, &mc_attr_group); + return -EINVAL; + } return err; } |
