Re: [PATCH 7/8] cpufreq: Add support for x86 cpuinfo auto loading v3

From: Thomas Renninger
Date: Wed Dec 21 2011 - 06:03:34 EST


On Tuesday, December 20, 2011 12:46:33 AM Andi Kleen wrote:
> From: Andi Kleen <ak@xxxxxxxxxxxxxxx>
>
> This marks all the x86 cpuinfo tables to the CPU specific device drivers,
> to allow auto loading by udev. This should simplify the distribution
> startup scripts for this greatly.
>
> I didn't add MODULE_DEVICE_IDs to the centrino and p4-clockmod drivers,
> because those probably shouldn't be auto loaded and the acpi driver
> be used instead (not fully sure on that, would appreciate feedback)
>
> The old nforce drivers autoload based on the PCI ID.
>
> ACPI cpufreq is autoloaded in another patch.
>
> v3: Autoload gx based on PCI IDs only. Remove cpu check (Dave Jones)
> Cc: davej@xxxxxxxxxx
> Cc: trenn@xxxxxxx
> Cc: kay.sievers@xxxxxxxx
> Cc: hpa@xxxxxxxxx
> Signed-off-by: Andi Kleen <ak@xxxxxxxxxxxxxxx>
...
> diff --git a/drivers/cpufreq/powernow-k8.c b/drivers/cpufreq/powernow-k8.c
> index bce576d..c87fabb 100644
> --- a/drivers/cpufreq/powernow-k8.c
> +++ b/drivers/cpufreq/powernow-k8.c
> @@ -37,6 +37,7 @@
> #include <linux/delay.h>
>
> #include <asm/msr.h>
> +#include <asm/cpu_device_id.h>
>
> #include <linux/acpi.h>
> #include <linux/mutex.h>
> @@ -514,6 +515,18 @@ static int core_voltage_post_transition(struct powernow_k8_data *data,
> return 0;
> }
>
> +static const struct x86_cpu_id powernow_k8_ids[] = {
> + { X86_VENDOR_AMD, 0xf, },
> + { X86_VENDOR_AMD, 0x10, },
> + { X86_VENDOR_AMD, 0x11, },
> + { X86_VENDOR_AMD, 0x12, },
> + { X86_VENDOR_AMD, 0x13, },
> + { X86_VENDOR_AMD, 0x14, },
{ X86_VENDOR_AMD, 0x15, },

Should also have BullDozer family included.

> + /* Add more here? */
> + {}

Thomas
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/