History

Merge branches 'powercap' and 'acpi-lpss' with new device IDs

* powercap: powercap / RAPL: add support for ValleyView Soc * acpi-lpss: ACPI: Add BayTrail SoC GPIO and LPSS ACPI IDs

Rafael J. Wysocki committed 12 years ago

Commit bfde19c3 parents 1a67253 ed93b71 f6308b33 files · +13 −2Browse files

Unified · Split

3 files
  1. drivers/acpi/acpi_lpss.c +1 −0
  2. drivers/pinctrl/pinctrl-baytrail.c +1 −0
  3. drivers/powercap/intel_rapl.c +11 −2
drivers/acpi/acpi_lpss.c+1−0
@@ -162,6 +162,7 @@ static const struct acpi_device_id acpi_lpss_device_ids[] = { · 161 unmodified lines
162162 { "80860F14", (unsigned long)&byt_sdio_dev_desc },
163163 { "80860F41", (unsigned long)&byt_i2c_dev_desc },
164164 { "INT33B2", },
165+ { "INT33FC", },
165166
166167 { "INT3430", (unsigned long)&lpt_dev_desc },
167168 { "INT3431", (unsigned long)&lpt_dev_desc },
drivers/pinctrl/pinctrl-baytrail.c+1−0
@@ -512,6 +512,7 @@ static const struct dev_pm_ops byt_gpio_pm_ops = { · 511 unmodified lines
512512
513513 static const struct acpi_device_id byt_gpio_acpi_match[] = {
514514 { "INT33B2", 0 },
515+ { "INT33FC", 0 },
515516 { }
516517 };
517518 MODULE_DEVICE_TABLE(acpi, byt_gpio_acpi_match);
drivers/powercap/intel_rapl.c+11−2
@@ -833,6 +833,11 @@ static int rapl_write_data_raw(struct rapl_domain *rd, · 832 unmodified lines
833833 return 0;
834834 }
835835
836+static const struct x86_cpu_id energy_unit_quirk_ids[] = {
837+ { X86_VENDOR_INTEL, 6, 0x37},/* VLV */
838+ {}
839+};
840+
836841 static int rapl_check_unit(struct rapl_package *rp, int cpu)
837842 {
838843 u64 msr_val;
@@ -853,8 +858,11 @@ static int rapl_check_unit(struct rapl_package *rp, int cpu) · 14 unmodified lines
853858 * time unit: 1/time_unit_divisor Seconds
854859 */
855860 value = (msr_val & ENERGY_UNIT_MASK) >> ENERGY_UNIT_OFFSET;
856− rp->energy_unit_divisor = 1 << value;
857−
861+ /* some CPUs have different way to calculate energy unit */
862+ if (x86_match_cpu(energy_unit_quirk_ids))
863+ rp->energy_unit_divisor = 1000000 / (1 << value);
864+ else
865+ rp->energy_unit_divisor = 1 << value;
858866
859867 value = (msr_val & POWER_UNIT_MASK) >> POWER_UNIT_OFFSET;
860868 rp->power_unit_divisor = 1 << value;
@@ -941,6 +949,7 @@ static void package_power_limit_irq_restore(int package_id) · 80 unmodified lines
941949 static const struct x86_cpu_id rapl_ids[] = {
942950 { X86_VENDOR_INTEL, 6, 0x2a},/* SNB */
943951 { X86_VENDOR_INTEL, 6, 0x2d},/* SNB EP */
952+ { X86_VENDOR_INTEL, 6, 0x37},/* VLV */
944953 { X86_VENDOR_INTEL, 6, 0x3a},/* IVB */
945954 { X86_VENDOR_INTEL, 6, 0x45},/* HSW */
946955 /* TODO: Add more CPU IDs after testing */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t