lkml.org 
[lkml]   [2011]   [Dec]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 08/10] x86: autoload microcode driver on Intel and AMD systems
    Date
    From: Andi Kleen <ak@linux.intel.com>

    Don't try to describe the actual models for now.

    Signed-off-by: Andi Kleen <ak@linux.intel.com>
    ---
    arch/x86/kernel/microcode_core.c | 15 +++++++++++++++
    1 files changed, 15 insertions(+), 0 deletions(-)

    diff --git a/arch/x86/kernel/microcode_core.c b/arch/x86/kernel/microcode_core.c
    index 9d46f5e..51016ad 100644
    --- a/arch/x86/kernel/microcode_core.c
    +++ b/arch/x86/kernel/microcode_core.c
    @@ -86,6 +86,7 @@

    #include <asm/microcode.h>
    #include <asm/processor.h>
    +#include <asm/cpu_device_id.h>

    MODULE_DESCRIPTION("Microcode Update Driver");
    MODULE_AUTHOR("Tigran Aivazian <tigran@aivazian.fsnet.co.uk>");
    @@ -502,6 +503,20 @@ static struct notifier_block __refdata mc_cpu_notifier = {
    .notifier_call = mc_cpu_callback,
    };

    +#ifdef MODULE
    +/* Autoload on Intel and AMD systems */
    +static struct x86_cpu_id microcode_id[] = {
    +#ifdef CONFIG_MICROCODE_INTEL
    + { X86_VENDOR_INTEL, X86_VENDOR_ANY, X86_MODEL_ANY, },
    +#endif
    +#ifdef CONFIG_MICROCODE_AMD
    + { X86_VENDOR_AMD, X86_VENDOR_ANY, X86_MODEL_ANY, },
    +#endif
    + {}
    +};
    +MODULE_DEVICE_TABLE(x86cpu, microcode_id);
    +#endif
    +
    static int __init microcode_init(void)
    {
    struct cpuinfo_x86 *c = &cpu_data(0);
    --
    1.7.4.4


    \
     
     \ /
      Last update: 2011-12-08 01:45    [W:0.028 / U:0.084 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site