diff options
119 files changed, 648 insertions, 265 deletions
diff --git a/Documentation/devicetree/bindings/gpio/led.txt b/Documentation/devicetree/bindings/gpio/led.txt index 141087cf3107..fd2bd56e7195 100644 --- a/Documentation/devicetree/bindings/gpio/led.txt +++ b/Documentation/devicetree/bindings/gpio/led.txt | |||
@@ -7,9 +7,9 @@ Each LED is represented as a sub-node of the gpio-leds device. Each | |||
7 | node's name represents the name of the corresponding LED. | 7 | node's name represents the name of the corresponding LED. |
8 | 8 | ||
9 | LED sub-node properties: | 9 | LED sub-node properties: |
10 | - gpios : Should specify the LED's GPIO, see "Specifying GPIO information | 10 | - gpios : Should specify the LED's GPIO, see "gpios property" in |
11 | for devices" in Documentation/devicetree/booting-without-of.txt. Active | 11 | Documentation/devicetree/gpio.txt. Active low LEDs should be |
12 | low LEDs should be indicated using flags in the GPIO specifier. | 12 | indicated using flags in the GPIO specifier. |
13 | - label : (optional) The label for this LED. If omitted, the label is | 13 | - label : (optional) The label for this LED. If omitted, the label is |
14 | taken from the node name (excluding the unit address). | 14 | taken from the node name (excluding the unit address). |
15 | - linux,default-trigger : (optional) This parameter, if present, is a | 15 | - linux,default-trigger : (optional) This parameter, if present, is a |
diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt b/Documentation/devicetree/bindings/vendor-prefixes.txt index ecc6a6cd26c1..a20008ab319a 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.txt +++ b/Documentation/devicetree/bindings/vendor-prefixes.txt | |||
@@ -30,6 +30,7 @@ national National Semiconductor | |||
30 | nintendo Nintendo | 30 | nintendo Nintendo |
31 | nvidia NVIDIA | 31 | nvidia NVIDIA |
32 | nxp NXP Semiconductors | 32 | nxp NXP Semiconductors |
33 | picochip Picochip Ltd | ||
33 | powervr Imagination Technologies | 34 | powervr Imagination Technologies |
34 | qcom Qualcomm, Inc. | 35 | qcom Qualcomm, Inc. |
35 | ramtron Ramtron International | 36 | ramtron Ramtron International |
diff --git a/Documentation/hwmon/jc42 b/Documentation/hwmon/jc42 index a22ecf48f255..52729a756c1b 100644 --- a/Documentation/hwmon/jc42 +++ b/Documentation/hwmon/jc42 | |||
@@ -7,21 +7,29 @@ Supported chips: | |||
7 | Addresses scanned: I2C 0x18 - 0x1f | 7 | Addresses scanned: I2C 0x18 - 0x1f |
8 | Datasheets: | 8 | Datasheets: |
9 | http://www.analog.com/static/imported-files/data_sheets/ADT7408.pdf | 9 | http://www.analog.com/static/imported-files/data_sheets/ADT7408.pdf |
10 | * IDT TSE2002B3, TS3000B3 | 10 | * Atmel AT30TS00 |
11 | Prefix: 'tse2002b3', 'ts3000b3' | 11 | Prefix: 'at30ts00' |
12 | Addresses scanned: I2C 0x18 - 0x1f | 12 | Addresses scanned: I2C 0x18 - 0x1f |
13 | Datasheets: | 13 | Datasheets: |
14 | http://www.idt.com/products/getdoc.cfm?docid=18715691 | 14 | http://www.atmel.com/Images/doc8585.pdf |
15 | http://www.idt.com/products/getdoc.cfm?docid=18715692 | 15 | * IDT TSE2002B3, TSE2002GB2, TS3000B3, TS3000GB2 |
16 | Prefix: 'tse2002', 'ts3000' | ||
17 | Addresses scanned: I2C 0x18 - 0x1f | ||
18 | Datasheets: | ||
19 | http://www.idt.com/sites/default/files/documents/IDT_TSE2002B3C_DST_20100512_120303152056.pdf | ||
20 | http://www.idt.com/sites/default/files/documents/IDT_TSE2002GB2A1_DST_20111107_120303145914.pdf | ||
21 | http://www.idt.com/sites/default/files/documents/IDT_TS3000B3A_DST_20101129_120303152013.pdf | ||
22 | http://www.idt.com/sites/default/files/documents/IDT_TS3000GB2A1_DST_20111104_120303151012.pdf | ||
16 | * Maxim MAX6604 | 23 | * Maxim MAX6604 |
17 | Prefix: 'max6604' | 24 | Prefix: 'max6604' |
18 | Addresses scanned: I2C 0x18 - 0x1f | 25 | Addresses scanned: I2C 0x18 - 0x1f |
19 | Datasheets: | 26 | Datasheets: |
20 | http://datasheets.maxim-ic.com/en/ds/MAX6604.pdf | 27 | http://datasheets.maxim-ic.com/en/ds/MAX6604.pdf |
21 | * Microchip MCP9805, MCP98242, MCP98243, MCP9843 | 28 | * Microchip MCP9804, MCP9805, MCP98242, MCP98243, MCP9843 |
22 | Prefixes: 'mcp9805', 'mcp98242', 'mcp98243', 'mcp9843' | 29 | Prefixes: 'mcp9804', 'mcp9805', 'mcp98242', 'mcp98243', 'mcp9843' |
23 | Addresses scanned: I2C 0x18 - 0x1f | 30 | Addresses scanned: I2C 0x18 - 0x1f |
24 | Datasheets: | 31 | Datasheets: |
32 | http://ww1.microchip.com/downloads/en/DeviceDoc/22203C.pdf | ||
25 | http://ww1.microchip.com/downloads/en/DeviceDoc/21977b.pdf | 33 | http://ww1.microchip.com/downloads/en/DeviceDoc/21977b.pdf |
26 | http://ww1.microchip.com/downloads/en/DeviceDoc/21996a.pdf | 34 | http://ww1.microchip.com/downloads/en/DeviceDoc/21996a.pdf |
27 | http://ww1.microchip.com/downloads/en/DeviceDoc/22153c.pdf | 35 | http://ww1.microchip.com/downloads/en/DeviceDoc/22153c.pdf |
@@ -48,6 +56,12 @@ Supported chips: | |||
48 | Datasheets: | 56 | Datasheets: |
49 | http://www.st.com/stonline/products/literature/ds/13447/stts424.pdf | 57 | http://www.st.com/stonline/products/literature/ds/13447/stts424.pdf |
50 | http://www.st.com/stonline/products/literature/ds/13448/stts424e02.pdf | 58 | http://www.st.com/stonline/products/literature/ds/13448/stts424e02.pdf |
59 | * ST Microelectronics STTS2002, STTS3000 | ||
60 | Prefix: 'stts2002', 'stts3000' | ||
61 | Addresses scanned: I2C 0x18 - 0x1f | ||
62 | Datasheets: | ||
63 | http://www.st.com/internet/com/TECHNICAL_RESOURCES/TECHNICAL_LITERATURE/DATASHEET/CD00225278.pdf | ||
64 | http://www.st.com/internet/com/TECHNICAL_RESOURCES/TECHNICAL_LITERATURE/DATA_BRIEF/CD00270920.pdf | ||
51 | * JEDEC JC 42.4 compliant temperature sensor chips | 65 | * JEDEC JC 42.4 compliant temperature sensor chips |
52 | Prefix: 'jc42' | 66 | Prefix: 'jc42' |
53 | Addresses scanned: I2C 0x18 - 0x1f | 67 | Addresses scanned: I2C 0x18 - 0x1f |
diff --git a/Documentation/input/alps.txt b/Documentation/input/alps.txt index f274c28b5103..2f95308251d4 100644 --- a/Documentation/input/alps.txt +++ b/Documentation/input/alps.txt | |||
@@ -13,7 +13,8 @@ Detection | |||
13 | 13 | ||
14 | All ALPS touchpads should respond to the "E6 report" command sequence: | 14 | All ALPS touchpads should respond to the "E6 report" command sequence: |
15 | E8-E6-E6-E6-E9. An ALPS touchpad should respond with either 00-00-0A or | 15 | E8-E6-E6-E6-E9. An ALPS touchpad should respond with either 00-00-0A or |
16 | 00-00-64. | 16 | 00-00-64 if no buttons are pressed. The bits 0-2 of the first byte will be 1s |
17 | if some buttons are pressed. | ||
17 | 18 | ||
18 | If the E6 report is successful, the touchpad model is identified using the "E7 | 19 | If the E6 report is successful, the touchpad model is identified using the "E7 |
19 | report" sequence: E8-E7-E7-E7-E9. The response is the model signature and is | 20 | report" sequence: E8-E7-E7-E7-E9. The response is the model signature and is |
diff --git a/MAINTAINERS b/MAINTAINERS index dd6decd3d14c..0d01192651ef 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
@@ -962,7 +962,7 @@ F: drivers/tty/serial/msm_serial.c | |||
962 | F: drivers/platform/msm/ | 962 | F: drivers/platform/msm/ |
963 | F: drivers/*/pm8???-* | 963 | F: drivers/*/pm8???-* |
964 | F: include/linux/mfd/pm8xxx/ | 964 | F: include/linux/mfd/pm8xxx/ |
965 | T: git git://codeaurora.org/quic/kernel/davidb/linux-msm.git | 965 | T: git git://git.kernel.org/pub/scm/linux/kernel/git/davidb/linux-msm.git |
966 | S: Maintained | 966 | S: Maintained |
967 | 967 | ||
968 | ARM/TOSA MACHINE SUPPORT | 968 | ARM/TOSA MACHINE SUPPORT |
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index a48aecc17eac..dfb0312f4e73 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
@@ -1280,7 +1280,7 @@ config ARM_ERRATA_743622 | |||
1280 | depends on CPU_V7 | 1280 | depends on CPU_V7 |
1281 | help | 1281 | help |
1282 | This option enables the workaround for the 743622 Cortex-A9 | 1282 | This option enables the workaround for the 743622 Cortex-A9 |
1283 | (r2p0..r2p2) erratum. Under very rare conditions, a faulty | 1283 | (r2p*) erratum. Under very rare conditions, a faulty |
1284 | optimisation in the Cortex-A9 Store Buffer may lead to data | 1284 | optimisation in the Cortex-A9 Store Buffer may lead to data |
1285 | corruption. This workaround sets a specific bit in the diagnostic | 1285 | corruption. This workaround sets a specific bit in the diagnostic |
1286 | register of the Cortex-A9 which disables the Store Buffer | 1286 | register of the Cortex-A9 which disables the Store Buffer |
diff --git a/arch/arm/boot/.gitignore b/arch/arm/boot/.gitignore index ce1c5ff746e7..3c79f85975aa 100644 --- a/arch/arm/boot/.gitignore +++ b/arch/arm/boot/.gitignore | |||
@@ -3,3 +3,4 @@ zImage | |||
3 | xipImage | 3 | xipImage |
4 | bootpImage | 4 | bootpImage |
5 | uImage | 5 | uImage |
6 | *.dtb | ||
diff --git a/arch/arm/include/asm/pmu.h b/arch/arm/include/asm/pmu.h index b5a5be2536c1..90114faa9f3c 100644 --- a/arch/arm/include/asm/pmu.h +++ b/arch/arm/include/asm/pmu.h | |||
@@ -134,7 +134,7 @@ int __init armpmu_register(struct arm_pmu *armpmu, char *name, int type); | |||
134 | 134 | ||
135 | u64 armpmu_event_update(struct perf_event *event, | 135 | u64 armpmu_event_update(struct perf_event *event, |
136 | struct hw_perf_event *hwc, | 136 | struct hw_perf_event *hwc, |
137 | int idx, int overflow); | 137 | int idx); |
138 | 138 | ||
139 | int armpmu_event_set_period(struct perf_event *event, | 139 | int armpmu_event_set_period(struct perf_event *event, |
140 | struct hw_perf_event *hwc, | 140 | struct hw_perf_event *hwc, |
diff --git a/arch/arm/kernel/ecard.c b/arch/arm/kernel/ecard.c index 4dd0edab6a65..1651d4950744 100644 --- a/arch/arm/kernel/ecard.c +++ b/arch/arm/kernel/ecard.c | |||
@@ -242,6 +242,7 @@ static void ecard_init_pgtables(struct mm_struct *mm) | |||
242 | 242 | ||
243 | memcpy(dst_pgd, src_pgd, sizeof(pgd_t) * (EASI_SIZE / PGDIR_SIZE)); | 243 | memcpy(dst_pgd, src_pgd, sizeof(pgd_t) * (EASI_SIZE / PGDIR_SIZE)); |
244 | 244 | ||
245 | vma.vm_flags = VM_EXEC; | ||
245 | vma.vm_mm = mm; | 246 | vma.vm_mm = mm; |
246 | 247 | ||
247 | flush_tlb_range(&vma, IO_START, IO_START + IO_SIZE); | 248 | flush_tlb_range(&vma, IO_START, IO_START + IO_SIZE); |
diff --git a/arch/arm/kernel/perf_event.c b/arch/arm/kernel/perf_event.c index 5bb91bf3d47f..b2abfa18f137 100644 --- a/arch/arm/kernel/perf_event.c +++ b/arch/arm/kernel/perf_event.c | |||
@@ -180,7 +180,7 @@ armpmu_event_set_period(struct perf_event *event, | |||
180 | u64 | 180 | u64 |
181 | armpmu_event_update(struct perf_event *event, | 181 | armpmu_event_update(struct perf_event *event, |
182 | struct hw_perf_event *hwc, | 182 | struct hw_perf_event *hwc, |
183 | int idx, int overflow) | 183 | int idx) |
184 | { | 184 | { |
185 | struct arm_pmu *armpmu = to_arm_pmu(event->pmu); | 185 | struct arm_pmu *armpmu = to_arm_pmu(event->pmu); |
186 | u64 delta, prev_raw_count, new_raw_count; | 186 | u64 delta, prev_raw_count, new_raw_count; |
@@ -193,13 +193,7 @@ again: | |||
193 | new_raw_count) != prev_raw_count) | 193 | new_raw_count) != prev_raw_count) |
194 | goto again; | 194 | goto again; |
195 | 195 | ||
196 | new_raw_count &= armpmu->max_period; | 196 | delta = (new_raw_count - prev_raw_count) & armpmu->max_period; |
197 | prev_raw_count &= armpmu->max_period; | ||
198 | |||
199 | if (overflow) | ||
200 | delta = armpmu->max_period - prev_raw_count + new_raw_count + 1; | ||
201 | else | ||
202 | delta = new_raw_count - prev_raw_count; | ||
203 | 197 | ||
204 | local64_add(delta, &event->count); | 198 | local64_add(delta, &event->count); |
205 | local64_sub(delta, &hwc->period_left); | 199 | local64_sub(delta, &hwc->period_left); |
@@ -216,7 +210,7 @@ armpmu_read(struct perf_event *event) | |||
216 | if (hwc->idx < 0) | 210 | if (hwc->idx < 0) |
217 | return; | 211 | return; |
218 | 212 | ||
219 | armpmu_event_update(event, hwc, hwc->idx, 0); | 213 | armpmu_event_update(event, hwc, hwc->idx); |
220 | } | 214 | } |
221 | 215 | ||
222 | static void | 216 | static void |
@@ -232,7 +226,7 @@ armpmu_stop(struct perf_event *event, int flags) | |||
232 | if (!(hwc->state & PERF_HES_STOPPED)) { | 226 | if (!(hwc->state & PERF_HES_STOPPED)) { |
233 | armpmu->disable(hwc, hwc->idx); | 227 | armpmu->disable(hwc, hwc->idx); |
234 | barrier(); /* why? */ | 228 | barrier(); /* why? */ |
235 | armpmu_event_update(event, hwc, hwc->idx, 0); | 229 | armpmu_event_update(event, hwc, hwc->idx); |
236 | hwc->state |= PERF_HES_STOPPED | PERF_HES_UPTODATE; | 230 | hwc->state |= PERF_HES_STOPPED | PERF_HES_UPTODATE; |
237 | } | 231 | } |
238 | } | 232 | } |
@@ -518,7 +512,13 @@ __hw_perf_event_init(struct perf_event *event) | |||
518 | hwc->config_base |= (unsigned long)mapping; | 512 | hwc->config_base |= (unsigned long)mapping; |
519 | 513 | ||
520 | if (!hwc->sample_period) { | 514 | if (!hwc->sample_period) { |
521 | hwc->sample_period = armpmu->max_period; | 515 | /* |
516 | * For non-sampling runs, limit the sample_period to half | ||
517 | * of the counter width. That way, the new counter value | ||
518 | * is far less likely to overtake the previous one unless | ||
519 | * you have some serious IRQ latency issues. | ||
520 | */ | ||
521 | hwc->sample_period = armpmu->max_period >> 1; | ||
522 | hwc->last_period = hwc->sample_period; | 522 | hwc->last_period = hwc->sample_period; |
523 | local64_set(&hwc->period_left, hwc->sample_period); | 523 | local64_set(&hwc->period_left, hwc->sample_period); |
524 | } | 524 | } |
@@ -680,6 +680,28 @@ static void __init cpu_pmu_init(struct arm_pmu *armpmu) | |||
680 | } | 680 | } |
681 | 681 | ||
682 | /* | 682 | /* |
683 | * PMU hardware loses all context when a CPU goes offline. | ||
684 | * When a CPU is hotplugged back in, since some hardware registers are | ||
685 | * UNKNOWN at reset, the PMU must be explicitly reset to avoid reading | ||
686 | * junk values out of them. | ||
687 | */ | ||
688 | static int __cpuinit pmu_cpu_notify(struct notifier_block *b, | ||
689 | unsigned long action, void *hcpu) | ||
690 | { | ||
691 | if ((action & ~CPU_TASKS_FROZEN) != CPU_STARTING) | ||
692 | return NOTIFY_DONE; | ||
693 | |||
694 | if (cpu_pmu && cpu_pmu->reset) | ||
695 | cpu_pmu->reset(NULL); | ||
696 | |||
697 | return NOTIFY_OK; | ||
698 | } | ||
699 | |||
700 | static struct notifier_block __cpuinitdata pmu_cpu_notifier = { | ||
701 | .notifier_call = pmu_cpu_notify, | ||
702 | }; | ||
703 | |||
704 | /* | ||
683 | * CPU PMU identification and registration. | 705 | * CPU PMU identification and registration. |
684 | */ | 706 | */ |
685 | static int __init | 707 | static int __init |
@@ -730,6 +752,7 @@ init_hw_perf_events(void) | |||
730 | pr_info("enabled with %s PMU driver, %d counters available\n", | 752 | pr_info("enabled with %s PMU driver, %d counters available\n", |
731 | cpu_pmu->name, cpu_pmu->num_events); | 753 | cpu_pmu->name, cpu_pmu->num_events); |
732 | cpu_pmu_init(cpu_pmu); | 754 | cpu_pmu_init(cpu_pmu); |
755 | register_cpu_notifier(&pmu_cpu_notifier); | ||
733 | armpmu_register(cpu_pmu, "cpu", PERF_TYPE_RAW); | 756 | armpmu_register(cpu_pmu, "cpu", PERF_TYPE_RAW); |
734 | } else { | 757 | } else { |
735 | pr_info("no hardware support available\n"); | 758 | pr_info("no hardware support available\n"); |
diff --git a/arch/arm/kernel/perf_event_v6.c b/arch/arm/kernel/perf_event_v6.c index 533be9930ec2..b78af0cc6ef3 100644 --- a/arch/arm/kernel/perf_event_v6.c +++ b/arch/arm/kernel/perf_event_v6.c | |||
@@ -467,23 +467,6 @@ armv6pmu_enable_event(struct hw_perf_event *hwc, | |||
467 | raw_spin_unlock_irqrestore(&events->pmu_lock, flags); | 467 | raw_spin_unlock_irqrestore(&events->pmu_lock, flags); |
468 | } | 468 | } |
469 | 469 | ||
470 | static int counter_is_active(unsigned long pmcr, int idx) | ||
471 | { | ||
472 | unsigned long mask = 0; | ||
473 | if (idx == ARMV6_CYCLE_COUNTER) | ||
474 | mask = ARMV6_PMCR_CCOUNT_IEN; | ||
475 | else if (idx == ARMV6_COUNTER0) | ||
476 | mask = ARMV6_PMCR_COUNT0_IEN; | ||
477 | else if (idx == ARMV6_COUNTER1) | ||
478 | mask = ARMV6_PMCR_COUNT1_IEN; | ||
479 | |||
480 | if (mask) | ||
481 | return pmcr & mask; | ||
482 | |||
483 | WARN_ONCE(1, "invalid counter number (%d)\n", idx); | ||
484 | return 0; | ||
485 | } | ||
486 | |||
487 | static irqreturn_t | 470 | static irqreturn_t |
488 | armv6pmu_handle_irq(int irq_num, | 471 | armv6pmu_handle_irq(int irq_num, |
489 | void *dev) | 472 | void *dev) |
@@ -513,7 +496,8 @@ armv6pmu_handle_irq(int irq_num, | |||
513 | struct perf_event *event = cpuc->events[idx]; | 496 | struct perf_event *event = cpuc->events[idx]; |
514 | struct hw_perf_event *hwc; | 497 | struct hw_perf_event *hwc; |
515 | 498 | ||
516 | if (!counter_is_active(pmcr, idx)) | 499 | /* Ignore if we don't have an event. */ |
500 | if (!event) | ||
517 | continue; | 501 | continue; |
518 | 502 | ||
519 | /* | 503 | /* |
@@ -524,7 +508,7 @@ armv6pmu_handle_irq(int irq_num, | |||
524 | continue; | 508 | continue; |
525 | 509 | ||
526 | hwc = &event->hw; | 510 | hwc = &event->hw; |
527 | armpmu_event_update(event, hwc, idx, 1); | 511 | armpmu_event_update(event, hwc, idx); |
528 | data.period = event->hw.last_period; | 512 | data.period = event->hw.last_period; |
529 | if (!armpmu_event_set_period(event, hwc, idx)) | 513 | if (!armpmu_event_set_period(event, hwc, idx)) |
530 | continue; | 514 | continue; |
diff --git a/arch/arm/kernel/perf_event_v7.c b/arch/arm/kernel/perf_event_v7.c index 6933244c68f9..4d7095af2ab3 100644 --- a/arch/arm/kernel/perf_event_v7.c +++ b/arch/arm/kernel/perf_event_v7.c | |||
@@ -809,6 +809,11 @@ static inline int armv7_pmnc_disable_intens(int idx) | |||
809 | 809 | ||
810 | counter = ARMV7_IDX_TO_COUNTER(idx); | 810 | counter = ARMV7_IDX_TO_COUNTER(idx); |
811 | asm volatile("mcr p15, 0, %0, c9, c14, 2" : : "r" (BIT(counter))); | 811 | asm volatile("mcr p15, 0, %0, c9, c14, 2" : : "r" (BIT(counter))); |
812 | isb(); | ||
813 | /* Clear the overflow flag in case an interrupt is pending. */ | ||
814 | asm volatile("mcr p15, 0, %0, c9, c12, 3" : : "r" (BIT(counter))); | ||
815 | isb(); | ||
816 | |||
812 | return idx; | 817 | return idx; |
813 | } | 818 | } |
814 | 819 | ||
@@ -955,6 +960,10 @@ static irqreturn_t armv7pmu_handle_irq(int irq_num, void *dev) | |||
955 | struct perf_event *event = cpuc->events[idx]; | 960 | struct perf_event *event = cpuc->events[idx]; |
956 | struct hw_perf_event *hwc; | 961 | struct hw_perf_event *hwc; |
957 | 962 | ||
963 | /* Ignore if we don't have an event. */ | ||
964 | if (!event) | ||
965 | continue; | ||
966 | |||
958 | /* | 967 | /* |
959 | * We have a single interrupt for all counters. Check that | 968 | * We have a single interrupt for all counters. Check that |
960 | * each counter has overflowed before we process it. | 969 | * each counter has overflowed before we process it. |
@@ -963,7 +972,7 @@ static irqreturn_t armv7pmu_handle_irq(int irq_num, void *dev) | |||
963 | continue; | 972 | continue; |
964 | 973 | ||
965 | hwc = &event->hw; | 974 | hwc = &event->hw; |
966 | armpmu_event_update(event, hwc, idx, 1); | 975 | armpmu_event_update(event, hwc, idx); |
967 | data.period = event->hw.last_period; | 976 | data.period = event->hw.last_period; |
968 | if (!armpmu_event_set_period(event, hwc, idx)) | 977 | if (!armpmu_event_set_period(event, hwc, idx)) |
969 | continue; | 978 | continue; |
diff --git a/arch/arm/kernel/perf_event_xscale.c b/arch/arm/kernel/perf_event_xscale.c index 3b99d8269829..71a21e6712f5 100644 --- a/arch/arm/kernel/perf_event_xscale.c +++ b/arch/arm/kernel/perf_event_xscale.c | |||
@@ -255,11 +255,14 @@ xscale1pmu_handle_irq(int irq_num, void *dev) | |||
255 | struct perf_event *event = cpuc->events[idx]; | 255 | struct perf_event *event = cpuc->events[idx]; |
256 | struct hw_perf_event *hwc; | 256 | struct hw_perf_event *hwc; |
257 | 257 | ||
258 | if (!event) | ||
259 | continue; | ||
260 | |||
258 | if (!xscale1_pmnc_counter_has_overflowed(pmnc, idx)) | 261 | if (!xscale1_pmnc_counter_has_overflowed(pmnc, idx)) |
259 | continue; | 262 | continue; |
260 | 263 | ||
261 | hwc = &event->hw; | 264 | hwc = &event->hw; |
262 | armpmu_event_update(event, hwc, idx, 1); | 265 | armpmu_event_update(event, hwc, idx); |
263 | data.period = event->hw.last_period; | 266 | data.period = event->hw.last_period; |
264 | if (!armpmu_event_set_period(event, hwc, idx)) | 267 | if (!armpmu_event_set_period(event, hwc, idx)) |
265 | continue; | 268 | continue; |
@@ -592,11 +595,14 @@ xscale2pmu_handle_irq(int irq_num, void *dev) | |||
592 | struct perf_event *event = cpuc->events[idx]; | 595 | struct perf_event *event = cpuc->events[idx]; |
593 | struct hw_perf_event *hwc; | 596 | struct hw_perf_event *hwc; |
594 | 597 | ||
595 | if (!xscale2_pmnc_counter_has_overflowed(pmnc, idx)) | 598 | if (!event) |
599 | continue; | ||
600 | |||
601 | if (!xscale2_pmnc_counter_has_overflowed(of_flags, idx)) | ||
596 | continue; | 602 | continue; |
597 | 603 | ||
598 | hwc = &event->hw; | 604 | hwc = &event->hw; |
599 | armpmu_event_update(event, hwc, idx, 1); | 605 | armpmu_event_update(event, hwc, idx); |
600 | data.period = event->hw.last_period; | 606 | data.period = event->hw.last_period; |
601 | if (!armpmu_event_set_period(event, hwc, idx)) | 607 | if (!armpmu_event_set_period(event, hwc, idx)) |
602 | continue; | 608 | continue; |
@@ -663,7 +669,7 @@ xscale2pmu_enable_event(struct hw_perf_event *hwc, int idx) | |||
663 | static void | 669 | static void |
664 | xscale2pmu_disable_event(struct hw_perf_event *hwc, int idx) | 670 | xscale2pmu_disable_event(struct hw_perf_event *hwc, int idx) |
665 | { | 671 | { |
666 | unsigned long flags, ien, evtsel; | 672 | unsigned long flags, ien, evtsel, of_flags; |
667 | struct pmu_hw_events *events = cpu_pmu->get_hw_events(); | 673 | struct pmu_hw_events *events = cpu_pmu->get_hw_events(); |
668 | 674 | ||
669 | ien = xscale2pmu_read_int_enable(); | 675 | ien = xscale2pmu_read_int_enable(); |
@@ -672,26 +678,31 @@ xscale2pmu_disable_event(struct hw_perf_event *hwc, int idx) | |||
672 | switch (idx) { | 678 | switch (idx) { |
673 | case XSCALE_CYCLE_COUNTER: | 679 | case XSCALE_CYCLE_COUNTER: |
674 | ien &= ~XSCALE2_CCOUNT_INT_EN; | 680 | ien &= ~XSCALE2_CCOUNT_INT_EN; |
681 | of_flags = XSCALE2_CCOUNT_OVERFLOW; | ||
675 | break; | 682 | break; |
676 | case XSCALE_COUNTER0: | 683 | case XSCALE_COUNTER0: |
677 | ien &= ~XSCALE2_COUNT0_INT_EN; | 684 | ien &= ~XSCALE2_COUNT0_INT_EN; |
678 | evtsel &= ~XSCALE2_COUNT0_EVT_MASK; | 685 | evtsel &= ~XSCALE2_COUNT0_EVT_MASK; |
679 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT0_EVT_SHFT; | 686 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT0_EVT_SHFT; |
687 | of_flags = XSCALE2_COUNT0_OVERFLOW; | ||
680 | break; | 688 | break; |
681 | case XSCALE_COUNTER1: | 689 | case XSCALE_COUNTER1: |
682 | ien &= ~XSCALE2_COUNT1_INT_EN; | 690 | ien &= ~XSCALE2_COUNT1_INT_EN; |
683 | evtsel &= ~XSCALE2_COUNT1_EVT_MASK; | 691 | evtsel &= ~XSCALE2_COUNT1_EVT_MASK; |
684 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT1_EVT_SHFT; | 692 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT1_EVT_SHFT; |
693 | of_flags = XSCALE2_COUNT1_OVERFLOW; | ||
685 | break; | 694 | break; |
686 | case XSCALE_COUNTER2: | 695 | case XSCALE_COUNTER2: |
687 | ien &= ~XSCALE2_COUNT2_INT_EN; | 696 | ien &= ~XSCALE2_COUNT2_INT_EN; |
688 | evtsel &= ~XSCALE2_COUNT2_EVT_MASK; | 697 | evtsel &= ~XSCALE2_COUNT2_EVT_MASK; |
689 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT2_EVT_SHFT; | 698 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT2_EVT_SHFT; |
699 | of_flags = XSCALE2_COUNT2_OVERFLOW; | ||
690 | break; | 700 | break; |
691 | case XSCALE_COUNTER3: | 701 | case XSCALE_COUNTER3: |
692 | ien &= ~XSCALE2_COUNT3_INT_EN; | 702 | ien &= ~XSCALE2_COUNT3_INT_EN; |
693 | evtsel &= ~XSCALE2_COUNT3_EVT_MASK; | 703 | evtsel &= ~XSCALE2_COUNT3_EVT_MASK; |
694 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT3_EVT_SHFT; | 704 | evtsel |= XSCALE_PERFCTR_UNUSED << XSCALE2_COUNT3_EVT_SHFT; |
705 | of_flags = XSCALE2_COUNT3_OVERFLOW; | ||
695 | break; | 706 | break; |
696 | default: | 707 | default: |
697 | WARN_ONCE(1, "invalid counter number (%d)\n", idx); | 708 | WARN_ONCE(1, "invalid counter number (%d)\n", idx); |
@@ -701,6 +712,7 @@ xscale2pmu_disable_event(struct hw_perf_event *hwc, int idx) | |||
701 | raw_spin_lock_irqsave(&events->pmu_lock, flags); | 712 | raw_spin_lock_irqsave(&events->pmu_lock, flags); |
702 | xscale2pmu_write_event_select(evtsel); | 713 | xscale2pmu_write_event_select(evtsel); |
703 | xscale2pmu_write_int_enable(ien); | 714 | xscale2pmu_write_int_enable(ien); |
715 | xscale2pmu_write_overflow_flags(of_flags); | ||
704 | raw_spin_unlock_irqrestore(&events->pmu_lock, flags); | 716 | raw_spin_unlock_irqrestore(&events->pmu_lock, flags); |
705 | } | 717 | } |
706 | 718 | ||
diff --git a/arch/arm/mach-at91/at91sam9g45_devices.c b/arch/arm/mach-at91/at91sam9g45_devices.c index b7582dd10dc3..96e2adcd5a84 100644 --- a/arch/arm/mach-at91/at91sam9g45_devices.c +++ b/arch/arm/mach-at91/at91sam9g45_devices.c | |||
@@ -38,10 +38,6 @@ | |||
38 | #if defined(CONFIG_AT_HDMAC) || defined(CONFIG_AT_HDMAC_MODULE) | 38 | #if defined(CONFIG_AT_HDMAC) || defined(CONFIG_AT_HDMAC_MODULE) |
39 | static u64 hdmac_dmamask = DMA_BIT_MASK(32); | 39 | static u64 hdmac_dmamask = DMA_BIT_MASK(32); |
40 | 40 | ||
41 | static struct at_dma_platform_data atdma_pdata = { | ||
42 | .nr_channels = 8, | ||
43 | }; | ||
44 | |||
45 | static struct resource hdmac_resources[] = { | 41 | static struct resource hdmac_resources[] = { |
46 | [0] = { | 42 | [0] = { |
47 | .start = AT91SAM9G45_BASE_DMA, | 43 | .start = AT91SAM9G45_BASE_DMA, |
@@ -56,12 +52,11 @@ static struct resource hdmac_resources[] = { | |||
56 | }; | 52 | }; |
57 | 53 | ||
58 | static struct platform_device at_hdmac_device = { | 54 | static struct platform_device at_hdmac_device = { |
59 | .name = "at_hdmac", | 55 | .name = "at91sam9g45_dma", |
60 | .id = -1, | 56 | .id = -1, |
61 | .dev = { | 57 | .dev = { |
62 | .dma_mask = &hdmac_dmamask, | 58 | .dma_mask = &hdmac_dmamask, |
63 | .coherent_dma_mask = DMA_BIT_MASK(32), | 59 | .coherent_dma_mask = DMA_BIT_MASK(32), |
64 | .platform_data = &atdma_pdata, | ||
65 | }, | 60 | }, |
66 | .resource = hdmac_resources, | 61 | .resource = hdmac_resources, |
67 | .num_resources = ARRAY_SIZE(hdmac_resources), | 62 | .num_resources = ARRAY_SIZE(hdmac_resources), |
@@ -69,9 +64,15 @@ static struct platform_device at_hdmac_device = { | |||
69 | 64 | ||
70 | void __init at91_add_device_hdmac(void) | 65 | void __init at91_add_device_hdmac(void) |
71 | { | 66 | { |
72 | dma_cap_set(DMA_MEMCPY, atdma_pdata.cap_mask); | 67 | #if defined(CONFIG_OF) |
73 | dma_cap_set(DMA_SLAVE, atdma_pdata.cap_mask); | 68 | struct device_node *of_node = |
74 | platform_device_register(&at_hdmac_device); | 69 | of_find_node_by_name(NULL, "dma-controller"); |
70 | |||
71 | if (of_node) | ||
72 | of_node_put(of_node); | ||
73 | else | ||
74 | #endif | ||
75 | platform_device_register(&at_hdmac_device); | ||
75 | } | 76 | } |
76 | #else | 77 | #else |
77 | void __init at91_add_device_hdmac(void) {} | 78 | void __init at91_add_device_hdmac(void) {} |
diff --git a/arch/arm/mach-at91/at91sam9rl_devices.c b/arch/arm/mach-at91/at91sam9rl_devices.c index 61908dce9784..9be71c11d0f0 100644 --- a/arch/arm/mach-at91/at91sam9rl_devices.c +++ b/arch/arm/mach-at91/at91sam9rl_devices.c | |||
@@ -33,10 +33,6 @@ | |||
33 | #if defined(CONFIG_AT_HDMAC) || defined(CONFIG_AT_HDMAC_MODULE) | 33 | #if defined(CONFIG_AT_HDMAC) || defined(CONFIG_AT_HDMAC_MODULE) |
34 | static u64 hdmac_dmamask = DMA_BIT_MASK(32); | 34 | static u64 hdmac_dmamask = DMA_BIT_MASK(32); |
35 | 35 | ||
36 | static struct at_dma_platform_data atdma_pdata = { | ||
37 | .nr_channels = 2, | ||
38 | }; | ||
39 | |||
40 | static struct resource hdmac_resources[] = { | 36 | static struct resource hdmac_resources[] = { |
41 | [0] = { | 37 | [0] = { |
42 | .start = AT91SAM9RL_BASE_DMA, | 38 | .start = AT91SAM9RL_BASE_DMA, |
@@ -51,12 +47,11 @@ static struct resource hdmac_resources[] = { | |||
51 | }; | 47 | }; |
52 | 48 | ||
53 | static struct platform_device at_hdmac_device = { | 49 | static struct platform_device at_hdmac_device = { |
54 | .name = "at_hdmac", | 50 | .name = "at91sam9rl_dma", |
55 | .id = -1, | 51 | .id = -1, |
56 | .dev = { | 52 | .dev = { |
57 | .dma_mask = &hdmac_dmamask, | 53 | .dma_mask = &hdmac_dmamask, |
58 | .coherent_dma_mask = DMA_BIT_MASK(32), | 54 | .coherent_dma_mask = DMA_BIT_MASK(32), |
59 | .platform_data = &atdma_pdata, | ||
60 | }, | 55 | }, |
61 | .resource = hdmac_resources, | 56 | .resource = hdmac_resources, |
62 | .num_resources = ARRAY_SIZE(hdmac_resources), | 57 | .num_resources = ARRAY_SIZE(hdmac_resources), |
@@ -64,7 +59,6 @@ static struct platform_device at_hdmac_device = { | |||
64 | 59 | ||
65 | void __init at91_add_device_hdmac(void) | 60 | void __init at91_add_device_hdmac(void) |
66 | { | 61 | { |
67 | dma_cap_set(DMA_MEMCPY, atdma_pdata.cap_mask); | ||
68 | platform_device_register(&at_hdmac_device); | 62 | platform_device_register(&at_hdmac_device); |
69 | } | 63 | } |
70 | #else | 64 | #else |
diff --git a/arch/arm/mach-ep93xx/vision_ep9307.c b/arch/arm/mach-ep93xx/vision_ep9307.c index d5fb44f16d31..d67d0b4feb6f 100644 --- a/arch/arm/mach-ep93xx/vision_ep9307.c +++ b/arch/arm/mach-ep93xx/vision_ep9307.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <mach/ep93xx_spi.h> | 34 | #include <mach/ep93xx_spi.h> |
35 | #include <mach/gpio-ep93xx.h> | 35 | #include <mach/gpio-ep93xx.h> |
36 | 36 | ||
37 | #include <asm/hardware/vic.h> | ||
37 | #include <asm/mach-types.h> | 38 | #include <asm/mach-types.h> |
38 | #include <asm/mach/map.h> | 39 | #include <asm/mach/map.h> |
39 | #include <asm/mach/arch.h> | 40 | #include <asm/mach/arch.h> |
@@ -361,6 +362,7 @@ MACHINE_START(VISION_EP9307, "Vision Engraving Systems EP9307") | |||
361 | .atag_offset = 0x100, | 362 | .atag_offset = 0x100, |
362 | .map_io = vision_map_io, | 363 | .map_io = vision_map_io, |
363 | .init_irq = ep93xx_init_irq, | 364 | .init_irq = ep93xx_init_irq, |
365 | .handle_irq = vic_handle_irq, | ||
364 | .timer = &ep93xx_timer, | 366 | .timer = &ep93xx_timer, |
365 | .init_machine = vision_init_machine, | 367 | .init_machine = vision_init_machine, |
366 | .restart = ep93xx_restart, | 368 | .restart = ep93xx_restart, |
diff --git a/arch/arm/mach-exynos/mach-universal_c210.c b/arch/arm/mach-exynos/mach-universal_c210.c index 0fc65ffde8ff..38939956c34f 100644 --- a/arch/arm/mach-exynos/mach-universal_c210.c +++ b/arch/arm/mach-exynos/mach-universal_c210.c | |||
@@ -13,6 +13,7 @@ | |||
13 | #include <linux/i2c.h> | 13 | #include <linux/i2c.h> |
14 | #include <linux/gpio_keys.h> | 14 | #include <linux/gpio_keys.h> |
15 | #include <linux/gpio.h> | 15 | #include <linux/gpio.h> |
16 | #include <linux/interrupt.h> | ||
16 | #include <linux/fb.h> | 17 | #include <linux/fb.h> |
17 | #include <linux/mfd/max8998.h> | 18 | #include <linux/mfd/max8998.h> |
18 | #include <linux/regulator/machine.h> | 19 | #include <linux/regulator/machine.h> |
@@ -595,6 +596,7 @@ static struct mxt_platform_data qt602240_platform_data = { | |||
595 | .threshold = 0x28, | 596 | .threshold = 0x28, |
596 | .voltage = 2800000, /* 2.8V */ | 597 | .voltage = 2800000, /* 2.8V */ |
597 | .orient = MXT_DIAGONAL, | 598 | .orient = MXT_DIAGONAL, |
599 | .irqflags = IRQF_TRIGGER_FALLING, | ||
598 | }; | 600 | }; |
599 | 601 | ||
600 | static struct i2c_board_info i2c3_devs[] __initdata = { | 602 | static struct i2c_board_info i2c3_devs[] __initdata = { |
diff --git a/arch/arm/mach-omap2/id.c b/arch/arm/mach-omap2/id.c index 6c5826605eae..719ee423abe2 100644 --- a/arch/arm/mach-omap2/id.c +++ b/arch/arm/mach-omap2/id.c | |||
@@ -343,6 +343,7 @@ static void __init omap3_check_revision(const char **cpu_rev) | |||
343 | case 0xb944: | 343 | case 0xb944: |
344 | omap_revision = AM335X_REV_ES1_0; | 344 | omap_revision = AM335X_REV_ES1_0; |
345 | *cpu_rev = "1.0"; | 345 | *cpu_rev = "1.0"; |
346 | break; | ||
346 | case 0xb8f2: | 347 | case 0xb8f2: |
347 | switch (rev) { | 348 | switch (rev) { |
348 | case 0: | 349 | case 0: |
diff --git a/arch/arm/mach-omap2/mailbox.c b/arch/arm/mach-omap2/mailbox.c index 2cc1aa004b94..415a6f1cf419 100644 --- a/arch/arm/mach-omap2/mailbox.c +++ b/arch/arm/mach-omap2/mailbox.c | |||
@@ -420,8 +420,7 @@ static void __exit omap2_mbox_exit(void) | |||
420 | platform_driver_unregister(&omap2_mbox_driver); | 420 | platform_driver_unregister(&omap2_mbox_driver); |
421 | } | 421 | } |
422 | 422 | ||
423 | /* must be ready before omap3isp is probed */ | 423 | module_init(omap2_mbox_init); |
424 | subsys_initcall(omap2_mbox_init); | ||
425 | module_exit(omap2_mbox_exit); | 424 | module_exit(omap2_mbox_exit); |
426 | 425 | ||
427 | MODULE_LICENSE("GPL v2"); | 426 | MODULE_LICENSE("GPL v2"); |
diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c index b8822048e409..ac49384d0285 100644 --- a/arch/arm/mach-omap2/omap-iommu.c +++ b/arch/arm/mach-omap2/omap-iommu.c | |||
@@ -150,7 +150,8 @@ err_out: | |||
150 | platform_device_put(omap_iommu_pdev[i]); | 150 | platform_device_put(omap_iommu_pdev[i]); |
151 | return err; | 151 | return err; |
152 | } | 152 | } |
153 | module_init(omap_iommu_init); | 153 | /* must be ready before omap3isp is probed */ |
154 | subsys_initcall(omap_iommu_init); | ||
154 | 155 | ||
155 | static void __exit omap_iommu_exit(void) | 156 | static void __exit omap_iommu_exit(void) |
156 | { | 157 | { |
diff --git a/arch/arm/mach-omap2/omap4-common.c b/arch/arm/mach-omap2/omap4-common.c index ebc595091312..70de277f5c15 100644 --- a/arch/arm/mach-omap2/omap4-common.c +++ b/arch/arm/mach-omap2/omap4-common.c | |||
@@ -31,6 +31,7 @@ | |||
31 | 31 | ||
32 | #include "common.h" | 32 | #include "common.h" |
33 | #include "omap4-sar-layout.h" | 33 | #include "omap4-sar-layout.h" |
34 | #include <linux/export.h> | ||
34 | 35 | ||
35 | #ifdef CONFIG_CACHE_L2X0 | 36 | #ifdef CONFIG_CACHE_L2X0 |
36 | static void __iomem *l2cache_base; | 37 | static void __iomem *l2cache_base; |
@@ -55,6 +56,7 @@ void omap_bus_sync(void) | |||
55 | isb(); | 56 | isb(); |
56 | } | 57 | } |
57 | } | 58 | } |
59 | EXPORT_SYMBOL(omap_bus_sync); | ||
58 | 60 | ||
59 | /* Steal one page physical memory for barrier implementation */ | 61 | /* Steal one page physical memory for barrier implementation */ |
60 | int __init omap_barrier_reserve_memblock(void) | 62 | int __init omap_barrier_reserve_memblock(void) |
diff --git a/arch/arm/mach-omap2/twl-common.c b/arch/arm/mach-omap2/twl-common.c index 10b20c652e5d..4b57757bf9d1 100644 --- a/arch/arm/mach-omap2/twl-common.c +++ b/arch/arm/mach-omap2/twl-common.c | |||
@@ -270,7 +270,6 @@ static struct regulator_init_data omap4_vusb_idata = { | |||
270 | .constraints = { | 270 | .constraints = { |
271 | .min_uV = 3300000, | 271 | .min_uV = 3300000, |
272 | .max_uV = 3300000, | 272 | .max_uV = 3300000, |
273 | .apply_uV = true, | ||
274 | .valid_modes_mask = REGULATOR_MODE_NORMAL | 273 | .valid_modes_mask = REGULATOR_MODE_NORMAL |
275 | | REGULATOR_MODE_STANDBY, | 274 | | REGULATOR_MODE_STANDBY, |
276 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 275 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
diff --git a/arch/arm/mach-pxa/generic.h b/arch/arm/mach-pxa/generic.h index 0d729e6619df..42d5cca66257 100644 --- a/arch/arm/mach-pxa/generic.h +++ b/arch/arm/mach-pxa/generic.h | |||
@@ -49,7 +49,6 @@ extern unsigned pxa3xx_get_clk_frequency_khz(int); | |||
49 | #endif | 49 | #endif |
50 | 50 | ||
51 | extern struct syscore_ops pxa_irq_syscore_ops; | 51 | extern struct syscore_ops pxa_irq_syscore_ops; |
52 | extern struct syscore_ops pxa_gpio_syscore_ops; | ||
53 | extern struct syscore_ops pxa2xx_mfp_syscore_ops; | 52 | extern struct syscore_ops pxa2xx_mfp_syscore_ops; |
54 | extern struct syscore_ops pxa3xx_mfp_syscore_ops; | 53 | extern struct syscore_ops pxa3xx_mfp_syscore_ops; |
55 | 54 | ||
diff --git a/arch/arm/mach-pxa/mfp-pxa2xx.c b/arch/arm/mach-pxa/mfp-pxa2xx.c index f14775536b83..29b62afc6f7c 100644 --- a/arch/arm/mach-pxa/mfp-pxa2xx.c +++ b/arch/arm/mach-pxa/mfp-pxa2xx.c | |||
@@ -226,6 +226,12 @@ static void __init pxa25x_mfp_init(void) | |||
226 | { | 226 | { |
227 | int i; | 227 | int i; |
228 | 228 | ||
229 | /* running before pxa_gpio_probe() */ | ||
230 | #ifdef CONFIG_CPU_PXA26x | ||
231 | pxa_last_gpio = 89; | ||
232 | #else | ||
233 | pxa_last_gpio = 84; | ||
234 | #endif | ||
229 | for (i = 0; i <= pxa_last_gpio; i++) | 235 | for (i = 0; i <= pxa_last_gpio; i++) |
230 | gpio_desc[i].valid = 1; | 236 | gpio_desc[i].valid = 1; |
231 | 237 | ||
@@ -295,6 +301,7 @@ static void __init pxa27x_mfp_init(void) | |||
295 | { | 301 | { |
296 | int i, gpio; | 302 | int i, gpio; |
297 | 303 | ||
304 | pxa_last_gpio = 120; /* running before pxa_gpio_probe() */ | ||
298 | for (i = 0; i <= pxa_last_gpio; i++) { | 305 | for (i = 0; i <= pxa_last_gpio; i++) { |
299 | /* skip GPIO2, 5, 6, 7, 8, they are not | 306 | /* skip GPIO2, 5, 6, 7, 8, they are not |
300 | * valid pins allow configuration | 307 | * valid pins allow configuration |
diff --git a/arch/arm/mach-pxa/pxa25x.c b/arch/arm/mach-pxa/pxa25x.c index 00d6eacab8e4..3352b37b60cf 100644 --- a/arch/arm/mach-pxa/pxa25x.c +++ b/arch/arm/mach-pxa/pxa25x.c | |||
@@ -208,6 +208,7 @@ static struct clk_lookup pxa25x_clkregs[] = { | |||
208 | INIT_CLKREG(&clk_pxa25x_gpio11, NULL, "GPIO11_CLK"), | 208 | INIT_CLKREG(&clk_pxa25x_gpio11, NULL, "GPIO11_CLK"), |
209 | INIT_CLKREG(&clk_pxa25x_gpio12, NULL, "GPIO12_CLK"), | 209 | INIT_CLKREG(&clk_pxa25x_gpio12, NULL, "GPIO12_CLK"), |
210 | INIT_CLKREG(&clk_pxa25x_mem, "pxa2xx-pcmcia", NULL), | 210 | INIT_CLKREG(&clk_pxa25x_mem, "pxa2xx-pcmcia", NULL), |
211 | INIT_CLKREG(&clk_dummy, "pxa-gpio", NULL), | ||
211 | }; | 212 | }; |
212 | 213 | ||
213 | static struct clk_lookup pxa25x_hwuart_clkreg = | 214 | static struct clk_lookup pxa25x_hwuart_clkreg = |
@@ -367,7 +368,6 @@ static int __init pxa25x_init(void) | |||
367 | 368 | ||
368 | register_syscore_ops(&pxa_irq_syscore_ops); | 369 | register_syscore_ops(&pxa_irq_syscore_ops); |
369 | register_syscore_ops(&pxa2xx_mfp_syscore_ops); | 370 | register_syscore_ops(&pxa2xx_mfp_syscore_ops); |
370 | register_syscore_ops(&pxa_gpio_syscore_ops); | ||
371 | register_syscore_ops(&pxa2xx_clock_syscore_ops); | 371 | register_syscore_ops(&pxa2xx_clock_syscore_ops); |
372 | 372 | ||
373 | ret = platform_add_devices(pxa25x_devices, | 373 | ret = platform_add_devices(pxa25x_devices, |
diff --git a/arch/arm/mach-pxa/pxa27x.c b/arch/arm/mach-pxa/pxa27x.c index c1673b3441d4..6bce78edce7a 100644 --- a/arch/arm/mach-pxa/pxa27x.c +++ b/arch/arm/mach-pxa/pxa27x.c | |||
@@ -229,6 +229,7 @@ static struct clk_lookup pxa27x_clkregs[] = { | |||
229 | INIT_CLKREG(&clk_pxa27x_im, NULL, "IMCLK"), | 229 | INIT_CLKREG(&clk_pxa27x_im, NULL, "IMCLK"), |
230 | INIT_CLKREG(&clk_pxa27x_memc, NULL, "MEMCLK"), | 230 | INIT_CLKREG(&clk_pxa27x_memc, NULL, "MEMCLK"), |
231 | INIT_CLKREG(&clk_pxa27x_mem, "pxa2xx-pcmcia", NULL), | 231 | INIT_CLKREG(&clk_pxa27x_mem, "pxa2xx-pcmcia", NULL), |
232 | INIT_CLKREG(&clk_dummy, "pxa-gpio", NULL), | ||
232 | }; | 233 | }; |
233 | 234 | ||
234 | #ifdef CONFIG_PM | 235 | #ifdef CONFIG_PM |
@@ -455,7 +456,6 @@ static int __init pxa27x_init(void) | |||
455 | 456 | ||
456 | register_syscore_ops(&pxa_irq_syscore_ops); | 457 | register_syscore_ops(&pxa_irq_syscore_ops); |
457 | register_syscore_ops(&pxa2xx_mfp_syscore_ops); | 458 | register_syscore_ops(&pxa2xx_mfp_syscore_ops); |
458 | register_syscore_ops(&pxa_gpio_syscore_ops); | ||
459 | register_syscore_ops(&pxa2xx_clock_syscore_ops); | 459 | register_syscore_ops(&pxa2xx_clock_syscore_ops); |
460 | 460 | ||
461 | ret = platform_add_devices(devices, ARRAY_SIZE(devices)); | 461 | ret = platform_add_devices(devices, ARRAY_SIZE(devices)); |
diff --git a/arch/arm/mach-pxa/pxa3xx.c b/arch/arm/mach-pxa/pxa3xx.c index 4f402afa6609..3918a672238e 100644 --- a/arch/arm/mach-pxa/pxa3xx.c +++ b/arch/arm/mach-pxa/pxa3xx.c | |||
@@ -462,7 +462,6 @@ static int __init pxa3xx_init(void) | |||
462 | 462 | ||
463 | register_syscore_ops(&pxa_irq_syscore_ops); | 463 | register_syscore_ops(&pxa_irq_syscore_ops); |
464 | register_syscore_ops(&pxa3xx_mfp_syscore_ops); | 464 | register_syscore_ops(&pxa3xx_mfp_syscore_ops); |
465 | register_syscore_ops(&pxa_gpio_syscore_ops); | ||
466 | register_syscore_ops(&pxa3xx_clock_syscore_ops); | 465 | register_syscore_ops(&pxa3xx_clock_syscore_ops); |
467 | 466 | ||
468 | ret = platform_add_devices(devices, ARRAY_SIZE(devices)); | 467 | ret = platform_add_devices(devices, ARRAY_SIZE(devices)); |
diff --git a/arch/arm/mach-pxa/pxa95x.c b/arch/arm/mach-pxa/pxa95x.c index d082a583df78..5ce434b95e87 100644 --- a/arch/arm/mach-pxa/pxa95x.c +++ b/arch/arm/mach-pxa/pxa95x.c | |||
@@ -283,7 +283,6 @@ static int __init pxa95x_init(void) | |||
283 | return ret; | 283 | return ret; |
284 | 284 | ||
285 | register_syscore_ops(&pxa_irq_syscore_ops); | 285 | register_syscore_ops(&pxa_irq_syscore_ops); |
286 | register_syscore_ops(&pxa_gpio_syscore_ops); | ||
287 | register_syscore_ops(&pxa3xx_clock_syscore_ops); | 286 | register_syscore_ops(&pxa3xx_clock_syscore_ops); |
288 | 287 | ||
289 | ret = platform_add_devices(devices, ARRAY_SIZE(devices)); | 288 | ret = platform_add_devices(devices, ARRAY_SIZE(devices)); |
diff --git a/arch/arm/mach-s3c2440/common.h b/arch/arm/mach-s3c2440/common.h index db8a98ac68c5..0c1eb1dfc534 100644 --- a/arch/arm/mach-s3c2440/common.h +++ b/arch/arm/mach-s3c2440/common.h | |||
@@ -12,6 +12,6 @@ | |||
12 | #ifndef __ARCH_ARM_MACH_S3C2440_COMMON_H | 12 | #ifndef __ARCH_ARM_MACH_S3C2440_COMMON_H |
13 | #define __ARCH_ARM_MACH_S3C2440_COMMON_H | 13 | #define __ARCH_ARM_MACH_S3C2440_COMMON_H |
14 | 14 | ||
15 | void s3c2440_restart(char mode, const char *cmd); | 15 | void s3c244x_restart(char mode, const char *cmd); |
16 | 16 | ||
17 | #endif /* __ARCH_ARM_MACH_S3C2440_COMMON_H */ | 17 | #endif /* __ARCH_ARM_MACH_S3C2440_COMMON_H */ |
diff --git a/arch/arm/mach-s3c2440/mach-anubis.c b/arch/arm/mach-s3c2440/mach-anubis.c index 24569550de1a..19b577bc09b8 100644 --- a/arch/arm/mach-s3c2440/mach-anubis.c +++ b/arch/arm/mach-s3c2440/mach-anubis.c | |||
@@ -487,5 +487,5 @@ MACHINE_START(ANUBIS, "Simtec-Anubis") | |||
487 | .init_machine = anubis_init, | 487 | .init_machine = anubis_init, |
488 | .init_irq = s3c24xx_init_irq, | 488 | .init_irq = s3c24xx_init_irq, |
489 | .timer = &s3c24xx_timer, | 489 | .timer = &s3c24xx_timer, |
490 | .restart = s3c2440_restart, | 490 | .restart = s3c244x_restart, |
491 | MACHINE_END | 491 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-at2440evb.c b/arch/arm/mach-s3c2440/mach-at2440evb.c index d6a9763110cd..d7ae49c90118 100644 --- a/arch/arm/mach-s3c2440/mach-at2440evb.c +++ b/arch/arm/mach-s3c2440/mach-at2440evb.c | |||
@@ -222,5 +222,5 @@ MACHINE_START(AT2440EVB, "AT2440EVB") | |||
222 | .init_machine = at2440evb_init, | 222 | .init_machine = at2440evb_init, |
223 | .init_irq = s3c24xx_init_irq, | 223 | .init_irq = s3c24xx_init_irq, |
224 | .timer = &s3c24xx_timer, | 224 | .timer = &s3c24xx_timer, |
225 | .restart = s3c2440_restart, | 225 | .restart = s3c244x_restart, |
226 | MACHINE_END | 226 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-gta02.c b/arch/arm/mach-s3c2440/mach-gta02.c index 5859e609d28c..9a4a5bc008e6 100644 --- a/arch/arm/mach-s3c2440/mach-gta02.c +++ b/arch/arm/mach-s3c2440/mach-gta02.c | |||
@@ -601,5 +601,5 @@ MACHINE_START(NEO1973_GTA02, "GTA02") | |||
601 | .init_irq = s3c24xx_init_irq, | 601 | .init_irq = s3c24xx_init_irq, |
602 | .init_machine = gta02_machine_init, | 602 | .init_machine = gta02_machine_init, |
603 | .timer = &s3c24xx_timer, | 603 | .timer = &s3c24xx_timer, |
604 | .restart = s3c2440_restart, | 604 | .restart = s3c244x_restart, |
605 | MACHINE_END | 605 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-mini2440.c b/arch/arm/mach-s3c2440/mach-mini2440.c index adbbb85bc4cd..5d66fb218a41 100644 --- a/arch/arm/mach-s3c2440/mach-mini2440.c +++ b/arch/arm/mach-s3c2440/mach-mini2440.c | |||
@@ -701,5 +701,5 @@ MACHINE_START(MINI2440, "MINI2440") | |||
701 | .init_machine = mini2440_init, | 701 | .init_machine = mini2440_init, |
702 | .init_irq = s3c24xx_init_irq, | 702 | .init_irq = s3c24xx_init_irq, |
703 | .timer = &s3c24xx_timer, | 703 | .timer = &s3c24xx_timer, |
704 | .restart = s3c2440_restart, | 704 | .restart = s3c244x_restart, |
705 | MACHINE_END | 705 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-nexcoder.c b/arch/arm/mach-s3c2440/mach-nexcoder.c index 40eaf844bc1f..5198e3e1c5be 100644 --- a/arch/arm/mach-s3c2440/mach-nexcoder.c +++ b/arch/arm/mach-s3c2440/mach-nexcoder.c | |||
@@ -158,5 +158,5 @@ MACHINE_START(NEXCODER_2440, "NexVision - Nexcoder 2440") | |||
158 | .init_machine = nexcoder_init, | 158 | .init_machine = nexcoder_init, |
159 | .init_irq = s3c24xx_init_irq, | 159 | .init_irq = s3c24xx_init_irq, |
160 | .timer = &s3c24xx_timer, | 160 | .timer = &s3c24xx_timer, |
161 | .restart = s3c2440_restart, | 161 | .restart = s3c244x_restart, |
162 | MACHINE_END | 162 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-osiris.c b/arch/arm/mach-s3c2440/mach-osiris.c index 4c480ef734f6..c5daeb612a88 100644 --- a/arch/arm/mach-s3c2440/mach-osiris.c +++ b/arch/arm/mach-s3c2440/mach-osiris.c | |||
@@ -436,5 +436,5 @@ MACHINE_START(OSIRIS, "Simtec-OSIRIS") | |||
436 | .init_irq = s3c24xx_init_irq, | 436 | .init_irq = s3c24xx_init_irq, |
437 | .init_machine = osiris_init, | 437 | .init_machine = osiris_init, |
438 | .timer = &s3c24xx_timer, | 438 | .timer = &s3c24xx_timer, |
439 | .restart = s3c2440_restart, | 439 | .restart = s3c244x_restart, |
440 | MACHINE_END | 440 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-rx1950.c b/arch/arm/mach-s3c2440/mach-rx1950.c index 80077f6472ee..6f68abf44fab 100644 --- a/arch/arm/mach-s3c2440/mach-rx1950.c +++ b/arch/arm/mach-s3c2440/mach-rx1950.c | |||
@@ -822,5 +822,5 @@ MACHINE_START(RX1950, "HP iPAQ RX1950") | |||
822 | .init_irq = s3c24xx_init_irq, | 822 | .init_irq = s3c24xx_init_irq, |
823 | .init_machine = rx1950_init_machine, | 823 | .init_machine = rx1950_init_machine, |
824 | .timer = &s3c24xx_timer, | 824 | .timer = &s3c24xx_timer, |
825 | .restart = s3c2440_restart, | 825 | .restart = s3c244x_restart, |
826 | MACHINE_END | 826 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-rx3715.c b/arch/arm/mach-s3c2440/mach-rx3715.c index 20103bafbd4b..56af35447598 100644 --- a/arch/arm/mach-s3c2440/mach-rx3715.c +++ b/arch/arm/mach-s3c2440/mach-rx3715.c | |||
@@ -213,5 +213,5 @@ MACHINE_START(RX3715, "IPAQ-RX3715") | |||
213 | .init_irq = rx3715_init_irq, | 213 | .init_irq = rx3715_init_irq, |
214 | .init_machine = rx3715_init_machine, | 214 | .init_machine = rx3715_init_machine, |
215 | .timer = &s3c24xx_timer, | 215 | .timer = &s3c24xx_timer, |
216 | .restart = s3c2440_restart, | 216 | .restart = s3c244x_restart, |
217 | MACHINE_END | 217 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/mach-smdk2440.c b/arch/arm/mach-s3c2440/mach-smdk2440.c index 1deb60d12a60..83a1036d7dcb 100644 --- a/arch/arm/mach-s3c2440/mach-smdk2440.c +++ b/arch/arm/mach-s3c2440/mach-smdk2440.c | |||
@@ -183,5 +183,5 @@ MACHINE_START(S3C2440, "SMDK2440") | |||
183 | .map_io = smdk2440_map_io, | 183 | .map_io = smdk2440_map_io, |
184 | .init_machine = smdk2440_machine_init, | 184 | .init_machine = smdk2440_machine_init, |
185 | .timer = &s3c24xx_timer, | 185 | .timer = &s3c24xx_timer, |
186 | .restart = s3c2440_restart, | 186 | .restart = s3c244x_restart, |
187 | MACHINE_END | 187 | MACHINE_END |
diff --git a/arch/arm/mach-s3c2440/s3c2440.c b/arch/arm/mach-s3c2440/s3c2440.c index 517623a09fc5..2b3dddb49af7 100644 --- a/arch/arm/mach-s3c2440/s3c2440.c +++ b/arch/arm/mach-s3c2440/s3c2440.c | |||
@@ -35,7 +35,6 @@ | |||
35 | #include <plat/cpu.h> | 35 | #include <plat/cpu.h> |
36 | #include <plat/s3c244x.h> | 36 | #include <plat/s3c244x.h> |
37 | #include <plat/pm.h> | 37 | #include <plat/pm.h> |
38 | #include <plat/watchdog-reset.h> | ||
39 | 38 | ||
40 | #include <plat/gpio-core.h> | 39 | #include <plat/gpio-core.h> |
41 | #include <plat/gpio-cfg.h> | 40 | #include <plat/gpio-cfg.h> |
@@ -74,15 +73,3 @@ void __init s3c2440_map_io(void) | |||
74 | s3c24xx_gpiocfg_default.set_pull = s3c24xx_gpio_setpull_1up; | 73 | s3c24xx_gpiocfg_default.set_pull = s3c24xx_gpio_setpull_1up; |
75 | s3c24xx_gpiocfg_default.get_pull = s3c24xx_gpio_getpull_1up; | 74 | s3c24xx_gpiocfg_default.get_pull = s3c24xx_gpio_getpull_1up; |
76 | } | 75 | } |
77 | |||
78 | void s3c2440_restart(char mode, const char *cmd) | ||
79 | { | ||
80 | if (mode == 's') { | ||
81 | soft_restart(0); | ||
82 | } | ||
83 | |||
84 | arch_wdt_reset(); | ||
85 | |||
86 | /* we'll take a jump through zero as a poor second */ | ||
87 | soft_restart(0); | ||
88 | } | ||
diff --git a/arch/arm/mach-s3c2440/s3c244x.c b/arch/arm/mach-s3c2440/s3c244x.c index 36bc60f61d0a..d15852f642b7 100644 --- a/arch/arm/mach-s3c2440/s3c244x.c +++ b/arch/arm/mach-s3c2440/s3c244x.c | |||
@@ -46,6 +46,7 @@ | |||
46 | #include <plat/pm.h> | 46 | #include <plat/pm.h> |
47 | #include <plat/pll.h> | 47 | #include <plat/pll.h> |
48 | #include <plat/nand-core.h> | 48 | #include <plat/nand-core.h> |
49 | #include <plat/watchdog-reset.h> | ||
49 | 50 | ||
50 | static struct map_desc s3c244x_iodesc[] __initdata = { | 51 | static struct map_desc s3c244x_iodesc[] __initdata = { |
51 | IODESC_ENT(CLKPWR), | 52 | IODESC_ENT(CLKPWR), |
@@ -196,3 +197,14 @@ struct syscore_ops s3c244x_pm_syscore_ops = { | |||
196 | .suspend = s3c244x_suspend, | 197 | .suspend = s3c244x_suspend, |
197 | .resume = s3c244x_resume, | 198 | .resume = s3c244x_resume, |
198 | }; | 199 | }; |
200 | |||
201 | void s3c244x_restart(char mode, const char *cmd) | ||
202 | { | ||
203 | if (mode == 's') | ||
204 | soft_restart(0); | ||
205 | |||
206 | arch_wdt_reset(); | ||
207 | |||
208 | /* we'll take a jump through zero as a poor second */ | ||
209 | soft_restart(0); | ||
210 | } | ||
diff --git a/arch/arm/mach-ux500/Kconfig b/arch/arm/mach-ux500/Kconfig index 52af00446a63..c59e8b892d6b 100644 --- a/arch/arm/mach-ux500/Kconfig +++ b/arch/arm/mach-ux500/Kconfig | |||
@@ -5,7 +5,7 @@ config UX500_SOC_COMMON | |||
5 | default y | 5 | default y |
6 | select ARM_GIC | 6 | select ARM_GIC |
7 | select HAS_MTU | 7 | select HAS_MTU |
8 | select ARM_ERRATA_753970 | 8 | select PL310_ERRATA_753970 |
9 | select ARM_ERRATA_754322 | 9 | select ARM_ERRATA_754322 |
10 | select ARM_ERRATA_764369 | 10 | select ARM_ERRATA_764369 |
11 | 11 | ||
diff --git a/arch/arm/mach-vexpress/Kconfig b/arch/arm/mach-vexpress/Kconfig index 9b3d0fbaee72..88c3ba151e87 100644 --- a/arch/arm/mach-vexpress/Kconfig +++ b/arch/arm/mach-vexpress/Kconfig | |||
@@ -7,7 +7,7 @@ config ARCH_VEXPRESS_CA9X4 | |||
7 | select ARM_GIC | 7 | select ARM_GIC |
8 | select ARM_ERRATA_720789 | 8 | select ARM_ERRATA_720789 |
9 | select ARM_ERRATA_751472 | 9 | select ARM_ERRATA_751472 |
10 | select ARM_ERRATA_753970 | 10 | select PL310_ERRATA_753970 |
11 | select HAVE_SMP | 11 | select HAVE_SMP |
12 | select MIGHT_HAVE_CACHE_L2X0 | 12 | select MIGHT_HAVE_CACHE_L2X0 |
13 | 13 | ||
diff --git a/arch/arm/mm/proc-v7.S b/arch/arm/mm/proc-v7.S index 0404ccbb8aa3..f1c8486f7501 100644 --- a/arch/arm/mm/proc-v7.S +++ b/arch/arm/mm/proc-v7.S | |||
@@ -230,9 +230,7 @@ __v7_setup: | |||
230 | mcreq p15, 0, r10, c15, c0, 1 @ write diagnostic register | 230 | mcreq p15, 0, r10, c15, c0, 1 @ write diagnostic register |
231 | #endif | 231 | #endif |
232 | #ifdef CONFIG_ARM_ERRATA_743622 | 232 | #ifdef CONFIG_ARM_ERRATA_743622 |
233 | teq r6, #0x20 @ present in r2p0 | 233 | teq r5, #0x00200000 @ only present in r2p* |
234 | teqne r6, #0x21 @ present in r2p1 | ||
235 | teqne r6, #0x22 @ present in r2p2 | ||
236 | mrceq p15, 0, r10, c15, c0, 1 @ read diagnostic register | 234 | mrceq p15, 0, r10, c15, c0, 1 @ read diagnostic register |
237 | orreq r10, r10, #1 << 6 @ set bit #6 | 235 | orreq r10, r10, #1 << 6 @ set bit #6 |
238 | mcreq p15, 0, r10, c15, c0, 1 @ write diagnostic register | 236 | mcreq p15, 0, r10, c15, c0, 1 @ write diagnostic register |
diff --git a/arch/arm/plat-omap/include/plat/irqs.h b/arch/arm/plat-omap/include/plat/irqs.h index 2efd6454bce0..37bbbbb981b2 100644 --- a/arch/arm/plat-omap/include/plat/irqs.h +++ b/arch/arm/plat-omap/include/plat/irqs.h | |||
@@ -428,8 +428,16 @@ | |||
428 | #define OMAP_GPMC_NR_IRQS 8 | 428 | #define OMAP_GPMC_NR_IRQS 8 |
429 | #define OMAP_GPMC_IRQ_END (OMAP_GPMC_IRQ_BASE + OMAP_GPMC_NR_IRQS) | 429 | #define OMAP_GPMC_IRQ_END (OMAP_GPMC_IRQ_BASE + OMAP_GPMC_NR_IRQS) |
430 | 430 | ||
431 | /* PRCM IRQ handler */ | ||
432 | #ifdef CONFIG_ARCH_OMAP2PLUS | ||
433 | #define OMAP_PRCM_IRQ_BASE (OMAP_GPMC_IRQ_END) | ||
434 | #define OMAP_PRCM_NR_IRQS 64 | ||
435 | #define OMAP_PRCM_IRQ_END (OMAP_PRCM_IRQ_BASE + OMAP_PRCM_NR_IRQS) | ||
436 | #else | ||
437 | #define OMAP_PRCM_IRQ_END OMAP_GPMC_IRQ_END | ||
438 | #endif | ||
431 | 439 | ||
432 | #define NR_IRQS OMAP_GPMC_IRQ_END | 440 | #define NR_IRQS OMAP_PRCM_IRQ_END |
433 | 441 | ||
434 | #define OMAP_IRQ_BIT(irq) (1 << ((irq) % 32)) | 442 | #define OMAP_IRQ_BIT(irq) (1 << ((irq) % 32)) |
435 | 443 | ||
diff --git a/arch/arm/plat-s3c24xx/dma.c b/arch/arm/plat-s3c24xx/dma.c index 9fe35348e03b..2bab4c99a234 100644 --- a/arch/arm/plat-s3c24xx/dma.c +++ b/arch/arm/plat-s3c24xx/dma.c | |||
@@ -1249,7 +1249,7 @@ static void s3c2410_dma_resume(void) | |||
1249 | struct s3c2410_dma_chan *cp = s3c2410_chans + dma_channels - 1; | 1249 | struct s3c2410_dma_chan *cp = s3c2410_chans + dma_channels - 1; |
1250 | int channel; | 1250 | int channel; |
1251 | 1251 | ||
1252 | for (channel = dma_channels - 1; channel >= 0; cp++, channel--) | 1252 | for (channel = dma_channels - 1; channel >= 0; cp--, channel--) |
1253 | s3c2410_dma_resume_chan(cp); | 1253 | s3c2410_dma_resume_chan(cp); |
1254 | } | 1254 | } |
1255 | 1255 | ||
diff --git a/arch/arm/plat-samsung/devs.c b/arch/arm/plat-samsung/devs.c index f10768e988d4..d21d744e4d99 100644 --- a/arch/arm/plat-samsung/devs.c +++ b/arch/arm/plat-samsung/devs.c | |||
@@ -1409,7 +1409,7 @@ void __init s5p_ehci_set_platdata(struct s5p_ehci_platdata *pd) | |||
1409 | 1409 | ||
1410 | #ifdef CONFIG_S3C_DEV_USB_HSOTG | 1410 | #ifdef CONFIG_S3C_DEV_USB_HSOTG |
1411 | static struct resource s3c_usb_hsotg_resources[] = { | 1411 | static struct resource s3c_usb_hsotg_resources[] = { |
1412 | [0] = DEFINE_RES_MEM(S3C_PA_USB_HSOTG, SZ_16K), | 1412 | [0] = DEFINE_RES_MEM(S3C_PA_USB_HSOTG, SZ_128K), |
1413 | [1] = DEFINE_RES_IRQ(IRQ_OTG), | 1413 | [1] = DEFINE_RES_IRQ(IRQ_OTG), |
1414 | }; | 1414 | }; |
1415 | 1415 | ||
diff --git a/arch/arm/plat-spear/time.c b/arch/arm/plat-spear/time.c index 0c77e4298675..abb5bdecd509 100644 --- a/arch/arm/plat-spear/time.c +++ b/arch/arm/plat-spear/time.c | |||
@@ -145,11 +145,13 @@ static void clockevent_set_mode(enum clock_event_mode mode, | |||
145 | static int clockevent_next_event(unsigned long cycles, | 145 | static int clockevent_next_event(unsigned long cycles, |
146 | struct clock_event_device *clk_event_dev) | 146 | struct clock_event_device *clk_event_dev) |
147 | { | 147 | { |
148 | u16 val; | 148 | u16 val = readw(gpt_base + CR(CLKEVT)); |
149 | |||
150 | if (val & CTRL_ENABLE) | ||
151 | writew(val & ~CTRL_ENABLE, gpt_base + CR(CLKEVT)); | ||
149 | 152 | ||
150 | writew(cycles, gpt_base + LOAD(CLKEVT)); | 153 | writew(cycles, gpt_base + LOAD(CLKEVT)); |
151 | 154 | ||
152 | val = readw(gpt_base + CR(CLKEVT)); | ||
153 | val |= CTRL_ENABLE | CTRL_INT_ENABLE; | 155 | val |= CTRL_ENABLE | CTRL_INT_ENABLE; |
154 | writew(val, gpt_base + CR(CLKEVT)); | 156 | writew(val, gpt_base + CR(CLKEVT)); |
155 | 157 | ||
diff --git a/arch/c6x/include/asm/processor.h b/arch/c6x/include/asm/processor.h index 8154c4ee8c9c..77ecbded1f37 100644 --- a/arch/c6x/include/asm/processor.h +++ b/arch/c6x/include/asm/processor.h | |||
@@ -122,8 +122,8 @@ extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); | |||
122 | 122 | ||
123 | extern unsigned long get_wchan(struct task_struct *p); | 123 | extern unsigned long get_wchan(struct task_struct *p); |
124 | 124 | ||
125 | #define KSTK_EIP(tsk) (task_pt_regs(task)->pc) | 125 | #define KSTK_EIP(task) (task_pt_regs(task)->pc) |
126 | #define KSTK_ESP(tsk) (task_pt_regs(task)->sp) | 126 | #define KSTK_ESP(task) (task_pt_regs(task)->sp) |
127 | 127 | ||
128 | #define cpu_relax() do { } while (0) | 128 | #define cpu_relax() do { } while (0) |
129 | 129 | ||
diff --git a/arch/x86/lib/delay.c b/arch/x86/lib/delay.c index fc45ba887d05..e395693abdb1 100644 --- a/arch/x86/lib/delay.c +++ b/arch/x86/lib/delay.c | |||
@@ -48,9 +48,9 @@ static void delay_loop(unsigned long loops) | |||
48 | } | 48 | } |
49 | 49 | ||
50 | /* TSC based delay: */ | 50 | /* TSC based delay: */ |
51 | static void delay_tsc(unsigned long loops) | 51 | static void delay_tsc(unsigned long __loops) |
52 | { | 52 | { |
53 | unsigned long bclock, now; | 53 | u32 bclock, now, loops = __loops; |
54 | int cpu; | 54 | int cpu; |
55 | 55 | ||
56 | preempt_disable(); | 56 | preempt_disable(); |
diff --git a/arch/x86/mm/hugetlbpage.c b/arch/x86/mm/hugetlbpage.c index f581a18c0d4d..8ecbb4bba4b3 100644 --- a/arch/x86/mm/hugetlbpage.c +++ b/arch/x86/mm/hugetlbpage.c | |||
@@ -333,13 +333,15 @@ try_again: | |||
333 | * Lookup failure means no vma is above this address, | 333 | * Lookup failure means no vma is above this address, |
334 | * i.e. return with success: | 334 | * i.e. return with success: |
335 | */ | 335 | */ |
336 | if (!(vma = find_vma_prev(mm, addr, &prev_vma))) | 336 | vma = find_vma(mm, addr); |
337 | if (!vma) | ||
337 | return addr; | 338 | return addr; |
338 | 339 | ||
339 | /* | 340 | /* |
340 | * new region fits between prev_vma->vm_end and | 341 | * new region fits between prev_vma->vm_end and |
341 | * vma->vm_start, use it: | 342 | * vma->vm_start, use it: |
342 | */ | 343 | */ |
344 | prev_vma = vma->vm_prev; | ||
343 | if (addr + len <= vma->vm_start && | 345 | if (addr + len <= vma->vm_start && |
344 | (!prev_vma || (addr >= prev_vma->vm_end))) { | 346 | (!prev_vma || (addr >= prev_vma->vm_end))) { |
345 | /* remember the address as a hint for next time */ | 347 | /* remember the address as a hint for next time */ |
diff --git a/drivers/gpu/drm/radeon/r600.c b/drivers/gpu/drm/radeon/r600.c index fbcd84803b60..17ca72ce3027 100644 --- a/drivers/gpu/drm/radeon/r600.c +++ b/drivers/gpu/drm/radeon/r600.c | |||
@@ -2362,6 +2362,9 @@ void r600_semaphore_ring_emit(struct radeon_device *rdev, | |||
2362 | uint64_t addr = semaphore->gpu_addr; | 2362 | uint64_t addr = semaphore->gpu_addr; |
2363 | unsigned sel = emit_wait ? PACKET3_SEM_SEL_WAIT : PACKET3_SEM_SEL_SIGNAL; | 2363 | unsigned sel = emit_wait ? PACKET3_SEM_SEL_WAIT : PACKET3_SEM_SEL_SIGNAL; |
2364 | 2364 | ||
2365 | if (rdev->family < CHIP_CAYMAN) | ||
2366 | sel |= PACKET3_SEM_WAIT_ON_SIGNAL; | ||
2367 | |||
2365 | radeon_ring_write(ring, PACKET3(PACKET3_MEM_SEMAPHORE, 1)); | 2368 | radeon_ring_write(ring, PACKET3(PACKET3_MEM_SEMAPHORE, 1)); |
2366 | radeon_ring_write(ring, addr & 0xffffffff); | 2369 | radeon_ring_write(ring, addr & 0xffffffff); |
2367 | radeon_ring_write(ring, (upper_32_bits(addr) & 0xff) | sel); | 2370 | radeon_ring_write(ring, (upper_32_bits(addr) & 0xff) | sel); |
diff --git a/drivers/gpu/drm/radeon/r600_blit_shaders.c b/drivers/gpu/drm/radeon/r600_blit_shaders.c index 2d1f6c5ee2a7..73e2c7c6edbc 100644 --- a/drivers/gpu/drm/radeon/r600_blit_shaders.c +++ b/drivers/gpu/drm/radeon/r600_blit_shaders.c | |||
@@ -314,6 +314,10 @@ const u32 r6xx_default_state[] = | |||
314 | 0x00000000, /* VGT_VTX_CNT_EN */ | 314 | 0x00000000, /* VGT_VTX_CNT_EN */ |
315 | 315 | ||
316 | 0xc0016900, | 316 | 0xc0016900, |
317 | 0x000000d4, | ||
318 | 0x00000000, /* SX_MISC */ | ||
319 | |||
320 | 0xc0016900, | ||
317 | 0x000002c8, | 321 | 0x000002c8, |
318 | 0x00000000, /* VGT_STRMOUT_BUFFER_EN */ | 322 | 0x00000000, /* VGT_STRMOUT_BUFFER_EN */ |
319 | 323 | ||
@@ -626,6 +630,10 @@ const u32 r7xx_default_state[] = | |||
626 | 0x00000000, /* VGT_VTX_CNT_EN */ | 630 | 0x00000000, /* VGT_VTX_CNT_EN */ |
627 | 631 | ||
628 | 0xc0016900, | 632 | 0xc0016900, |
633 | 0x000000d4, | ||
634 | 0x00000000, /* SX_MISC */ | ||
635 | |||
636 | 0xc0016900, | ||
629 | 0x000002c8, | 637 | 0x000002c8, |
630 | 0x00000000, /* VGT_STRMOUT_BUFFER_EN */ | 638 | 0x00000000, /* VGT_STRMOUT_BUFFER_EN */ |
631 | 639 | ||
diff --git a/drivers/gpu/drm/radeon/r600d.h b/drivers/gpu/drm/radeon/r600d.h index 3ee1fd7ef394..9b23670716f1 100644 --- a/drivers/gpu/drm/radeon/r600d.h +++ b/drivers/gpu/drm/radeon/r600d.h | |||
@@ -831,6 +831,7 @@ | |||
831 | #define PACKET3_STRMOUT_BUFFER_UPDATE 0x34 | 831 | #define PACKET3_STRMOUT_BUFFER_UPDATE 0x34 |
832 | #define PACKET3_INDIRECT_BUFFER_MP 0x38 | 832 | #define PACKET3_INDIRECT_BUFFER_MP 0x38 |
833 | #define PACKET3_MEM_SEMAPHORE 0x39 | 833 | #define PACKET3_MEM_SEMAPHORE 0x39 |
834 | # define PACKET3_SEM_WAIT_ON_SIGNAL (0x1 << 12) | ||
834 | # define PACKET3_SEM_SEL_SIGNAL (0x6 << 29) | 835 | # define PACKET3_SEM_SEL_SIGNAL (0x6 << 29) |
835 | # define PACKET3_SEM_SEL_WAIT (0x7 << 29) | 836 | # define PACKET3_SEM_SEL_WAIT (0x7 << 29) |
836 | #define PACKET3_MPEG_INDEX 0x3A | 837 | #define PACKET3_MPEG_INDEX 0x3A |
diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gpu/drm/radeon/radeon_connectors.c index 8b3d8ed52ff6..8c9a8115b632 100644 --- a/drivers/gpu/drm/radeon/radeon_connectors.c +++ b/drivers/gpu/drm/radeon/radeon_connectors.c | |||
@@ -1057,7 +1057,7 @@ static int radeon_dvi_mode_valid(struct drm_connector *connector, | |||
1057 | (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_HDMI_TYPE_B)) | 1057 | (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_HDMI_TYPE_B)) |
1058 | return MODE_OK; | 1058 | return MODE_OK; |
1059 | else if (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_HDMI_TYPE_A) { | 1059 | else if (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_HDMI_TYPE_A) { |
1060 | if (ASIC_IS_DCE3(rdev)) { | 1060 | if (0) { |
1061 | /* HDMI 1.3+ supports max clock of 340 Mhz */ | 1061 | /* HDMI 1.3+ supports max clock of 340 Mhz */ |
1062 | if (mode->clock > 340000) | 1062 | if (mode->clock > 340000) |
1063 | return MODE_CLOCK_HIGH; | 1063 | return MODE_CLOCK_HIGH; |
diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/radeon/radeon_display.c index 8c49fef1ce78..3d314338d843 100644 --- a/drivers/gpu/drm/radeon/radeon_display.c +++ b/drivers/gpu/drm/radeon/radeon_display.c | |||
@@ -1078,15 +1078,21 @@ static const struct drm_framebuffer_funcs radeon_fb_funcs = { | |||
1078 | .create_handle = radeon_user_framebuffer_create_handle, | 1078 | .create_handle = radeon_user_framebuffer_create_handle, |
1079 | }; | 1079 | }; |
1080 | 1080 | ||
1081 | void | 1081 | int |
1082 | radeon_framebuffer_init(struct drm_device *dev, | 1082 | radeon_framebuffer_init(struct drm_device *dev, |
1083 | struct radeon_framebuffer *rfb, | 1083 | struct radeon_framebuffer *rfb, |
1084 | struct drm_mode_fb_cmd2 *mode_cmd, | 1084 | struct drm_mode_fb_cmd2 *mode_cmd, |
1085 | struct drm_gem_object *obj) | 1085 | struct drm_gem_object *obj) |
1086 | { | 1086 | { |
1087 | int ret; | ||
1087 | rfb->obj = obj; | 1088 | rfb->obj = obj; |
1088 | drm_framebuffer_init(dev, &rfb->base, &radeon_fb_funcs); | 1089 | ret = drm_framebuffer_init(dev, &rfb->base, &radeon_fb_funcs); |
1090 | if (ret) { | ||
1091 | rfb->obj = NULL; | ||
1092 | return ret; | ||
1093 | } | ||
1089 | drm_helper_mode_fill_fb_struct(&rfb->base, mode_cmd); | 1094 | drm_helper_mode_fill_fb_struct(&rfb->base, mode_cmd); |
1095 | return 0; | ||
1090 | } | 1096 | } |
1091 | 1097 | ||
1092 | static struct drm_framebuffer * | 1098 | static struct drm_framebuffer * |
@@ -1096,6 +1102,7 @@ radeon_user_framebuffer_create(struct drm_device *dev, | |||
1096 | { | 1102 | { |
1097 | struct drm_gem_object *obj; | 1103 | struct drm_gem_object *obj; |
1098 | struct radeon_framebuffer *radeon_fb; | 1104 | struct radeon_framebuffer *radeon_fb; |
1105 | int ret; | ||
1099 | 1106 | ||
1100 | obj = drm_gem_object_lookup(dev, file_priv, mode_cmd->handles[0]); | 1107 | obj = drm_gem_object_lookup(dev, file_priv, mode_cmd->handles[0]); |
1101 | if (obj == NULL) { | 1108 | if (obj == NULL) { |
@@ -1108,7 +1115,12 @@ radeon_user_framebuffer_create(struct drm_device *dev, | |||
1108 | if (radeon_fb == NULL) | 1115 | if (radeon_fb == NULL) |
1109 | return ERR_PTR(-ENOMEM); | 1116 | return ERR_PTR(-ENOMEM); |
1110 | 1117 | ||
1111 | radeon_framebuffer_init(dev, radeon_fb, mode_cmd, obj); | 1118 | ret = radeon_framebuffer_init(dev, radeon_fb, mode_cmd, obj); |
1119 | if (ret) { | ||
1120 | kfree(radeon_fb); | ||
1121 | drm_gem_object_unreference_unlocked(obj); | ||
1122 | return NULL; | ||
1123 | } | ||
1112 | 1124 | ||
1113 | return &radeon_fb->base; | 1125 | return &radeon_fb->base; |
1114 | } | 1126 | } |
diff --git a/drivers/gpu/drm/radeon/radeon_encoders.c b/drivers/gpu/drm/radeon/radeon_encoders.c index 9419c51bcf50..26e92708d114 100644 --- a/drivers/gpu/drm/radeon/radeon_encoders.c +++ b/drivers/gpu/drm/radeon/radeon_encoders.c | |||
@@ -307,8 +307,6 @@ void radeon_panel_mode_fixup(struct drm_encoder *encoder, | |||
307 | bool radeon_dig_monitor_is_duallink(struct drm_encoder *encoder, | 307 | bool radeon_dig_monitor_is_duallink(struct drm_encoder *encoder, |
308 | u32 pixel_clock) | 308 | u32 pixel_clock) |
309 | { | 309 | { |
310 | struct drm_device *dev = encoder->dev; | ||
311 | struct radeon_device *rdev = dev->dev_private; | ||
312 | struct drm_connector *connector; | 310 | struct drm_connector *connector; |
313 | struct radeon_connector *radeon_connector; | 311 | struct radeon_connector *radeon_connector; |
314 | struct radeon_connector_atom_dig *dig_connector; | 312 | struct radeon_connector_atom_dig *dig_connector; |
@@ -326,7 +324,7 @@ bool radeon_dig_monitor_is_duallink(struct drm_encoder *encoder, | |||
326 | case DRM_MODE_CONNECTOR_HDMIB: | 324 | case DRM_MODE_CONNECTOR_HDMIB: |
327 | if (radeon_connector->use_digital) { | 325 | if (radeon_connector->use_digital) { |
328 | /* HDMI 1.3 supports up to 340 Mhz over single link */ | 326 | /* HDMI 1.3 supports up to 340 Mhz over single link */ |
329 | if (ASIC_IS_DCE3(rdev) && drm_detect_hdmi_monitor(radeon_connector->edid)) { | 327 | if (0 && drm_detect_hdmi_monitor(radeon_connector->edid)) { |
330 | if (pixel_clock > 340000) | 328 | if (pixel_clock > 340000) |
331 | return true; | 329 | return true; |
332 | else | 330 | else |
@@ -348,7 +346,7 @@ bool radeon_dig_monitor_is_duallink(struct drm_encoder *encoder, | |||
348 | return false; | 346 | return false; |
349 | else { | 347 | else { |
350 | /* HDMI 1.3 supports up to 340 Mhz over single link */ | 348 | /* HDMI 1.3 supports up to 340 Mhz over single link */ |
351 | if (ASIC_IS_DCE3(rdev) && drm_detect_hdmi_monitor(radeon_connector->edid)) { | 349 | if (0 && drm_detect_hdmi_monitor(radeon_connector->edid)) { |
352 | if (pixel_clock > 340000) | 350 | if (pixel_clock > 340000) |
353 | return true; | 351 | return true; |
354 | else | 352 | else |
diff --git a/drivers/gpu/drm/radeon/radeon_fb.c b/drivers/gpu/drm/radeon/radeon_fb.c index cf2bf35b56b8..195471cf65d3 100644 --- a/drivers/gpu/drm/radeon/radeon_fb.c +++ b/drivers/gpu/drm/radeon/radeon_fb.c | |||
@@ -209,6 +209,11 @@ static int radeonfb_create(struct radeon_fbdev *rfbdev, | |||
209 | sizes->surface_depth); | 209 | sizes->surface_depth); |
210 | 210 | ||
211 | ret = radeonfb_create_pinned_object(rfbdev, &mode_cmd, &gobj); | 211 | ret = radeonfb_create_pinned_object(rfbdev, &mode_cmd, &gobj); |
212 | if (ret) { | ||
213 | DRM_ERROR("failed to create fbcon object %d\n", ret); | ||
214 | return ret; | ||
215 | } | ||
216 | |||
212 | rbo = gem_to_radeon_bo(gobj); | 217 | rbo = gem_to_radeon_bo(gobj); |
213 | 218 | ||
214 | /* okay we have an object now allocate the framebuffer */ | 219 | /* okay we have an object now allocate the framebuffer */ |
@@ -220,7 +225,11 @@ static int radeonfb_create(struct radeon_fbdev *rfbdev, | |||
220 | 225 | ||
221 | info->par = rfbdev; | 226 | info->par = rfbdev; |
222 | 227 | ||
223 | radeon_framebuffer_init(rdev->ddev, &rfbdev->rfb, &mode_cmd, gobj); | 228 | ret = radeon_framebuffer_init(rdev->ddev, &rfbdev->rfb, &mode_cmd, gobj); |
229 | if (ret) { | ||
230 | DRM_ERROR("failed to initalise framebuffer %d\n", ret); | ||
231 | goto out_unref; | ||
232 | } | ||
224 | 233 | ||
225 | fb = &rfbdev->rfb.base; | 234 | fb = &rfbdev->rfb.base; |
226 | 235 | ||
diff --git a/drivers/gpu/drm/radeon/radeon_mode.h b/drivers/gpu/drm/radeon/radeon_mode.h index 4330e3253573..8a85598fb242 100644 --- a/drivers/gpu/drm/radeon/radeon_mode.h +++ b/drivers/gpu/drm/radeon/radeon_mode.h | |||
@@ -649,7 +649,7 @@ extern void radeon_crtc_fb_gamma_set(struct drm_crtc *crtc, u16 red, u16 green, | |||
649 | u16 blue, int regno); | 649 | u16 blue, int regno); |
650 | extern void radeon_crtc_fb_gamma_get(struct drm_crtc *crtc, u16 *red, u16 *green, | 650 | extern void radeon_crtc_fb_gamma_get(struct drm_crtc *crtc, u16 *red, u16 *green, |
651 | u16 *blue, int regno); | 651 | u16 *blue, int regno); |
652 | void radeon_framebuffer_init(struct drm_device *dev, | 652 | int radeon_framebuffer_init(struct drm_device *dev, |
653 | struct radeon_framebuffer *rfb, | 653 | struct radeon_framebuffer *rfb, |
654 | struct drm_mode_fb_cmd2 *mode_cmd, | 654 | struct drm_mode_fb_cmd2 *mode_cmd, |
655 | struct drm_gem_object *obj); | 655 | struct drm_gem_object *obj); |
diff --git a/drivers/hwmon/Kconfig b/drivers/hwmon/Kconfig index 02260406b9e4..dad895fec62a 100644 --- a/drivers/hwmon/Kconfig +++ b/drivers/hwmon/Kconfig | |||
@@ -497,8 +497,9 @@ config SENSORS_JC42 | |||
497 | If you say yes here, you get support for JEDEC JC42.4 compliant | 497 | If you say yes here, you get support for JEDEC JC42.4 compliant |
498 | temperature sensors, which are used on many DDR3 memory modules for | 498 | temperature sensors, which are used on many DDR3 memory modules for |
499 | mobile devices and servers. Support will include, but not be limited | 499 | mobile devices and servers. Support will include, but not be limited |
500 | to, ADT7408, CAT34TS02, CAT6095, MAX6604, MCP9805, MCP98242, MCP98243, | 500 | to, ADT7408, AT30TS00, CAT34TS02, CAT6095, MAX6604, MCP9804, MCP9805, |
501 | MCP9843, SE97, SE98, STTS424(E), TSE2002B3, and TS3000B3. | 501 | MCP98242, MCP98243, MCP9843, SE97, SE98, STTS424(E), STTS2002, |
502 | STTS3000, TSE2002B3, TSE2002GB2, TS3000B3, and TS3000GB2. | ||
502 | 503 | ||
503 | This driver can also be built as a module. If so, the module | 504 | This driver can also be built as a module. If so, the module |
504 | will be called jc42. | 505 | will be called jc42. |
diff --git a/drivers/hwmon/jc42.c b/drivers/hwmon/jc42.c index 28c09eead36b..b927ee5ccdd7 100644 --- a/drivers/hwmon/jc42.c +++ b/drivers/hwmon/jc42.c | |||
@@ -64,6 +64,7 @@ static const unsigned short normal_i2c[] = { | |||
64 | 64 | ||
65 | /* Manufacturer IDs */ | 65 | /* Manufacturer IDs */ |
66 | #define ADT_MANID 0x11d4 /* Analog Devices */ | 66 | #define ADT_MANID 0x11d4 /* Analog Devices */ |
67 | #define ATMEL_MANID 0x001f /* Atmel */ | ||
67 | #define MAX_MANID 0x004d /* Maxim */ | 68 | #define MAX_MANID 0x004d /* Maxim */ |
68 | #define IDT_MANID 0x00b3 /* IDT */ | 69 | #define IDT_MANID 0x00b3 /* IDT */ |
69 | #define MCP_MANID 0x0054 /* Microchip */ | 70 | #define MCP_MANID 0x0054 /* Microchip */ |
@@ -77,15 +78,25 @@ static const unsigned short normal_i2c[] = { | |||
77 | #define ADT7408_DEVID 0x0801 | 78 | #define ADT7408_DEVID 0x0801 |
78 | #define ADT7408_DEVID_MASK 0xffff | 79 | #define ADT7408_DEVID_MASK 0xffff |
79 | 80 | ||
81 | /* Atmel */ | ||
82 | #define AT30TS00_DEVID 0x8201 | ||
83 | #define AT30TS00_DEVID_MASK 0xffff | ||
84 | |||
80 | /* IDT */ | 85 | /* IDT */ |
81 | #define TS3000B3_DEVID 0x2903 /* Also matches TSE2002B3 */ | 86 | #define TS3000B3_DEVID 0x2903 /* Also matches TSE2002B3 */ |
82 | #define TS3000B3_DEVID_MASK 0xffff | 87 | #define TS3000B3_DEVID_MASK 0xffff |
83 | 88 | ||
89 | #define TS3000GB2_DEVID 0x2912 /* Also matches TSE2002GB2 */ | ||
90 | #define TS3000GB2_DEVID_MASK 0xffff | ||
91 | |||
84 | /* Maxim */ | 92 | /* Maxim */ |
85 | #define MAX6604_DEVID 0x3e00 | 93 | #define MAX6604_DEVID 0x3e00 |
86 | #define MAX6604_DEVID_MASK 0xffff | 94 | #define MAX6604_DEVID_MASK 0xffff |
87 | 95 | ||
88 | /* Microchip */ | 96 | /* Microchip */ |
97 | #define MCP9804_DEVID 0x0200 | ||
98 | #define MCP9804_DEVID_MASK 0xfffc | ||
99 | |||
89 | #define MCP98242_DEVID 0x2000 | 100 | #define MCP98242_DEVID 0x2000 |
90 | #define MCP98242_DEVID_MASK 0xfffc | 101 | #define MCP98242_DEVID_MASK 0xfffc |
91 | 102 | ||
@@ -113,6 +124,12 @@ static const unsigned short normal_i2c[] = { | |||
113 | #define STTS424E_DEVID 0x0000 | 124 | #define STTS424E_DEVID 0x0000 |
114 | #define STTS424E_DEVID_MASK 0xfffe | 125 | #define STTS424E_DEVID_MASK 0xfffe |
115 | 126 | ||
127 | #define STTS2002_DEVID 0x0300 | ||
128 | #define STTS2002_DEVID_MASK 0xffff | ||
129 | |||
130 | #define STTS3000_DEVID 0x0200 | ||
131 | #define STTS3000_DEVID_MASK 0xffff | ||
132 | |||
116 | static u16 jc42_hysteresis[] = { 0, 1500, 3000, 6000 }; | 133 | static u16 jc42_hysteresis[] = { 0, 1500, 3000, 6000 }; |
117 | 134 | ||
118 | struct jc42_chips { | 135 | struct jc42_chips { |
@@ -123,8 +140,11 @@ struct jc42_chips { | |||
123 | 140 | ||
124 | static struct jc42_chips jc42_chips[] = { | 141 | static struct jc42_chips jc42_chips[] = { |
125 | { ADT_MANID, ADT7408_DEVID, ADT7408_DEVID_MASK }, | 142 | { ADT_MANID, ADT7408_DEVID, ADT7408_DEVID_MASK }, |
143 | { ATMEL_MANID, AT30TS00_DEVID, AT30TS00_DEVID_MASK }, | ||
126 | { IDT_MANID, TS3000B3_DEVID, TS3000B3_DEVID_MASK }, | 144 | { IDT_MANID, TS3000B3_DEVID, TS3000B3_DEVID_MASK }, |
145 | { IDT_MANID, TS3000GB2_DEVID, TS3000GB2_DEVID_MASK }, | ||
127 | { MAX_MANID, MAX6604_DEVID, MAX6604_DEVID_MASK }, | 146 | { MAX_MANID, MAX6604_DEVID, MAX6604_DEVID_MASK }, |
147 | { MCP_MANID, MCP9804_DEVID, MCP9804_DEVID_MASK }, | ||
128 | { MCP_MANID, MCP98242_DEVID, MCP98242_DEVID_MASK }, | 148 | { MCP_MANID, MCP98242_DEVID, MCP98242_DEVID_MASK }, |
129 | { MCP_MANID, MCP98243_DEVID, MCP98243_DEVID_MASK }, | 149 | { MCP_MANID, MCP98243_DEVID, MCP98243_DEVID_MASK }, |
130 | { MCP_MANID, MCP9843_DEVID, MCP9843_DEVID_MASK }, | 150 | { MCP_MANID, MCP9843_DEVID, MCP9843_DEVID_MASK }, |
@@ -133,6 +153,8 @@ static struct jc42_chips jc42_chips[] = { | |||
133 | { NXP_MANID, SE98_DEVID, SE98_DEVID_MASK }, | 153 | { NXP_MANID, SE98_DEVID, SE98_DEVID_MASK }, |
134 | { STM_MANID, STTS424_DEVID, STTS424_DEVID_MASK }, | 154 | { STM_MANID, STTS424_DEVID, STTS424_DEVID_MASK }, |
135 | { STM_MANID, STTS424E_DEVID, STTS424E_DEVID_MASK }, | 155 | { STM_MANID, STTS424E_DEVID, STTS424E_DEVID_MASK }, |
156 | { STM_MANID, STTS2002_DEVID, STTS2002_DEVID_MASK }, | ||
157 | { STM_MANID, STTS3000_DEVID, STTS3000_DEVID_MASK }, | ||
136 | }; | 158 | }; |
137 | 159 | ||
138 | /* Each client has this additional data */ | 160 | /* Each client has this additional data */ |
@@ -159,10 +181,12 @@ static struct jc42_data *jc42_update_device(struct device *dev); | |||
159 | 181 | ||
160 | static const struct i2c_device_id jc42_id[] = { | 182 | static const struct i2c_device_id jc42_id[] = { |
161 | { "adt7408", 0 }, | 183 | { "adt7408", 0 }, |
184 | { "at30ts00", 0 }, | ||
162 | { "cat94ts02", 0 }, | 185 | { "cat94ts02", 0 }, |
163 | { "cat6095", 0 }, | 186 | { "cat6095", 0 }, |
164 | { "jc42", 0 }, | 187 | { "jc42", 0 }, |
165 | { "max6604", 0 }, | 188 | { "max6604", 0 }, |
189 | { "mcp9804", 0 }, | ||
166 | { "mcp9805", 0 }, | 190 | { "mcp9805", 0 }, |
167 | { "mcp98242", 0 }, | 191 | { "mcp98242", 0 }, |
168 | { "mcp98243", 0 }, | 192 | { "mcp98243", 0 }, |
@@ -171,8 +195,10 @@ static const struct i2c_device_id jc42_id[] = { | |||
171 | { "se97b", 0 }, | 195 | { "se97b", 0 }, |
172 | { "se98", 0 }, | 196 | { "se98", 0 }, |
173 | { "stts424", 0 }, | 197 | { "stts424", 0 }, |
174 | { "tse2002b3", 0 }, | 198 | { "stts2002", 0 }, |
175 | { "ts3000b3", 0 }, | 199 | { "stts3000", 0 }, |
200 | { "tse2002", 0 }, | ||
201 | { "ts3000", 0 }, | ||
176 | { } | 202 | { } |
177 | }; | 203 | }; |
178 | MODULE_DEVICE_TABLE(i2c, jc42_id); | 204 | MODULE_DEVICE_TABLE(i2c, jc42_id); |
diff --git a/drivers/hwmon/pmbus/pmbus_core.c b/drivers/hwmon/pmbus/pmbus_core.c index 00460d8d8423..d89b33967a85 100644 --- a/drivers/hwmon/pmbus/pmbus_core.c +++ b/drivers/hwmon/pmbus/pmbus_core.c | |||
@@ -54,7 +54,8 @@ | |||
54 | lcrit_alarm, crit_alarm */ | 54 | lcrit_alarm, crit_alarm */ |
55 | #define PMBUS_IOUT_BOOLEANS_PER_PAGE 3 /* alarm, lcrit_alarm, | 55 | #define PMBUS_IOUT_BOOLEANS_PER_PAGE 3 /* alarm, lcrit_alarm, |
56 | crit_alarm */ | 56 | crit_alarm */ |
57 | #define PMBUS_POUT_BOOLEANS_PER_PAGE 2 /* alarm, crit_alarm */ | 57 | #define PMBUS_POUT_BOOLEANS_PER_PAGE 3 /* cap_alarm, alarm, crit_alarm |
58 | */ | ||
58 | #define PMBUS_MAX_BOOLEANS_PER_FAN 2 /* alarm, fault */ | 59 | #define PMBUS_MAX_BOOLEANS_PER_FAN 2 /* alarm, fault */ |
59 | #define PMBUS_MAX_BOOLEANS_PER_TEMP 4 /* min_alarm, max_alarm, | 60 | #define PMBUS_MAX_BOOLEANS_PER_TEMP 4 /* min_alarm, max_alarm, |
60 | lcrit_alarm, crit_alarm */ | 61 | lcrit_alarm, crit_alarm */ |
diff --git a/drivers/hwmon/pmbus/zl6100.c b/drivers/hwmon/pmbus/zl6100.c index 48c7b4a716ae..880b90cf4d32 100644 --- a/drivers/hwmon/pmbus/zl6100.c +++ b/drivers/hwmon/pmbus/zl6100.c | |||
@@ -33,6 +33,7 @@ enum chips { zl2004, zl2005, zl2006, zl2008, zl2105, zl2106, zl6100, zl6105 }; | |||
33 | struct zl6100_data { | 33 | struct zl6100_data { |
34 | int id; | 34 | int id; |
35 | ktime_t access; /* chip access time */ | 35 | ktime_t access; /* chip access time */ |
36 | int delay; /* Delay between chip accesses in uS */ | ||
36 | struct pmbus_driver_info info; | 37 | struct pmbus_driver_info info; |
37 | }; | 38 | }; |
38 | 39 | ||
@@ -52,10 +53,10 @@ MODULE_PARM_DESC(delay, "Delay between chip accesses in uS"); | |||
52 | /* Some chips need a delay between accesses */ | 53 | /* Some chips need a delay between accesses */ |
53 | static inline void zl6100_wait(const struct zl6100_data *data) | 54 | static inline void zl6100_wait(const struct zl6100_data *data) |
54 | { | 55 | { |
55 | if (delay) { | 56 | if (data->delay) { |
56 | s64 delta = ktime_us_delta(ktime_get(), data->access); | 57 | s64 delta = ktime_us_delta(ktime_get(), data->access); |
57 | if (delta < delay) | 58 | if (delta < data->delay) |
58 | udelay(delay - delta); | 59 | udelay(data->delay - delta); |
59 | } | 60 | } |
60 | } | 61 | } |
61 | 62 | ||
@@ -207,8 +208,9 @@ static int zl6100_probe(struct i2c_client *client, | |||
207 | * can be cleared later for additional chips if tests show that it | 208 | * can be cleared later for additional chips if tests show that it |
208 | * is not needed (in other words, better be safe than sorry). | 209 | * is not needed (in other words, better be safe than sorry). |
209 | */ | 210 | */ |
211 | data->delay = delay; | ||
210 | if (data->id == zl2004 || data->id == zl6105) | 212 | if (data->id == zl2004 || data->id == zl6105) |
211 | delay = 0; | 213 | data->delay = 0; |
212 | 214 | ||
213 | /* | 215 | /* |
214 | * Since there was a direct I2C device access above, wait before | 216 | * Since there was a direct I2C device access above, wait before |
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index afc166fcc3d9..7df5bfef2624 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
@@ -332,7 +332,7 @@ static ssize_t evdev_write(struct file *file, const char __user *buffer, | |||
332 | struct evdev_client *client = file->private_data; | 332 | struct evdev_client *client = file->private_data; |
333 | struct evdev *evdev = client->evdev; | 333 | struct evdev *evdev = client->evdev; |
334 | struct input_event event; | 334 | struct input_event event; |
335 | int retval; | 335 | int retval = 0; |
336 | 336 | ||
337 | if (count < input_event_size()) | 337 | if (count < input_event_size()) |
338 | return -EINVAL; | 338 | return -EINVAL; |
diff --git a/drivers/input/misc/twl4030-vibra.c b/drivers/input/misc/twl4030-vibra.c index 37651373a95b..f3bc4189a7ba 100644 --- a/drivers/input/misc/twl4030-vibra.c +++ b/drivers/input/misc/twl4030-vibra.c | |||
@@ -172,7 +172,7 @@ static void twl4030_vibra_close(struct input_dev *input) | |||
172 | } | 172 | } |
173 | 173 | ||
174 | /*** Module ***/ | 174 | /*** Module ***/ |
175 | #if CONFIG_PM | 175 | #if CONFIG_PM_SLEEP |
176 | static int twl4030_vibra_suspend(struct device *dev) | 176 | static int twl4030_vibra_suspend(struct device *dev) |
177 | { | 177 | { |
178 | struct platform_device *pdev = to_platform_device(dev); | 178 | struct platform_device *pdev = to_platform_device(dev); |
@@ -189,10 +189,10 @@ static int twl4030_vibra_resume(struct device *dev) | |||
189 | vibra_disable_leds(); | 189 | vibra_disable_leds(); |
190 | return 0; | 190 | return 0; |
191 | } | 191 | } |
192 | #endif | ||
192 | 193 | ||
193 | static SIMPLE_DEV_PM_OPS(twl4030_vibra_pm_ops, | 194 | static SIMPLE_DEV_PM_OPS(twl4030_vibra_pm_ops, |
194 | twl4030_vibra_suspend, twl4030_vibra_resume); | 195 | twl4030_vibra_suspend, twl4030_vibra_resume); |
195 | #endif | ||
196 | 196 | ||
197 | static int __devinit twl4030_vibra_probe(struct platform_device *pdev) | 197 | static int __devinit twl4030_vibra_probe(struct platform_device *pdev) |
198 | { | 198 | { |
@@ -273,9 +273,7 @@ static struct platform_driver twl4030_vibra_driver = { | |||
273 | .driver = { | 273 | .driver = { |
274 | .name = "twl4030-vibra", | 274 | .name = "twl4030-vibra", |
275 | .owner = THIS_MODULE, | 275 | .owner = THIS_MODULE, |
276 | #ifdef CONFIG_PM | ||
277 | .pm = &twl4030_vibra_pm_ops, | 276 | .pm = &twl4030_vibra_pm_ops, |
278 | #endif | ||
279 | }, | 277 | }, |
280 | }; | 278 | }; |
281 | module_platform_driver(twl4030_vibra_driver); | 279 | module_platform_driver(twl4030_vibra_driver); |
diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c index bd87380bd879..4c6a72d3d48c 100644 --- a/drivers/input/mouse/alps.c +++ b/drivers/input/mouse/alps.c | |||
@@ -952,7 +952,9 @@ static const struct alps_model_info *alps_get_model(struct psmouse *psmouse, int | |||
952 | 952 | ||
953 | /* | 953 | /* |
954 | * First try "E6 report". | 954 | * First try "E6 report". |
955 | * ALPS should return 0,0,10 or 0,0,100 | 955 | * ALPS should return 0,0,10 or 0,0,100 if no buttons are pressed. |
956 | * The bits 0-2 of the first byte will be 1s if some buttons are | ||
957 | * pressed. | ||
956 | */ | 958 | */ |
957 | param[0] = 0; | 959 | param[0] = 0; |
958 | if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES) || | 960 | if (ps2_command(ps2dev, param, PSMOUSE_CMD_SETRES) || |
@@ -968,7 +970,8 @@ static const struct alps_model_info *alps_get_model(struct psmouse *psmouse, int | |||
968 | psmouse_dbg(psmouse, "E6 report: %2.2x %2.2x %2.2x", | 970 | psmouse_dbg(psmouse, "E6 report: %2.2x %2.2x %2.2x", |
969 | param[0], param[1], param[2]); | 971 | param[0], param[1], param[2]); |
970 | 972 | ||
971 | if (param[0] != 0 || param[1] != 0 || (param[2] != 10 && param[2] != 100)) | 973 | if ((param[0] & 0xf8) != 0 || param[1] != 0 || |
974 | (param[2] != 10 && param[2] != 100)) | ||
972 | return NULL; | 975 | return NULL; |
973 | 976 | ||
974 | /* | 977 | /* |
diff --git a/drivers/input/tablet/Kconfig b/drivers/input/tablet/Kconfig index 58a87755b936..e53f4081a586 100644 --- a/drivers/input/tablet/Kconfig +++ b/drivers/input/tablet/Kconfig | |||
@@ -77,6 +77,8 @@ config TABLET_USB_WACOM | |||
77 | tristate "Wacom Intuos/Graphire tablet support (USB)" | 77 | tristate "Wacom Intuos/Graphire tablet support (USB)" |
78 | depends on USB_ARCH_HAS_HCD | 78 | depends on USB_ARCH_HAS_HCD |
79 | select USB | 79 | select USB |
80 | select NEW_LEDS | ||
81 | select LEDS_CLASS | ||
80 | help | 82 | help |
81 | Say Y here if you want to use the USB version of the Wacom Intuos | 83 | Say Y here if you want to use the USB version of the Wacom Intuos |
82 | or Graphire tablet. Make sure to say Y to "Mouse support" | 84 | or Graphire tablet. Make sure to say Y to "Mouse support" |
diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c index 88672ec296c1..cd3ed29e0801 100644 --- a/drivers/input/tablet/wacom_wac.c +++ b/drivers/input/tablet/wacom_wac.c | |||
@@ -926,7 +926,7 @@ static int wacom_bpt3_touch(struct wacom_wac *wacom) | |||
926 | { | 926 | { |
927 | struct input_dev *input = wacom->input; | 927 | struct input_dev *input = wacom->input; |
928 | unsigned char *data = wacom->data; | 928 | unsigned char *data = wacom->data; |
929 | int count = data[1] & 0x03; | 929 | int count = data[1] & 0x07; |
930 | int i; | 930 | int i; |
931 | 931 | ||
932 | if (data[0] != 0x02) | 932 | if (data[0] != 0x02) |
diff --git a/drivers/iommu/amd_iommu_init.c b/drivers/iommu/amd_iommu_init.c index bdea288dc185..a35e98ad9725 100644 --- a/drivers/iommu/amd_iommu_init.c +++ b/drivers/iommu/amd_iommu_init.c | |||
@@ -275,7 +275,7 @@ static void iommu_set_exclusion_range(struct amd_iommu *iommu) | |||
275 | } | 275 | } |
276 | 276 | ||
277 | /* Programs the physical address of the device table into the IOMMU hardware */ | 277 | /* Programs the physical address of the device table into the IOMMU hardware */ |
278 | static void __init iommu_set_device_table(struct amd_iommu *iommu) | 278 | static void iommu_set_device_table(struct amd_iommu *iommu) |
279 | { | 279 | { |
280 | u64 entry; | 280 | u64 entry; |
281 | 281 | ||
diff --git a/drivers/md/dm-flakey.c b/drivers/md/dm-flakey.c index 9fb18c147825..b280c433e4a0 100644 --- a/drivers/md/dm-flakey.c +++ b/drivers/md/dm-flakey.c | |||
@@ -323,7 +323,7 @@ static int flakey_end_io(struct dm_target *ti, struct bio *bio, | |||
323 | * Corrupt successful READs while in down state. | 323 | * Corrupt successful READs while in down state. |
324 | * If flags were specified, only corrupt those that match. | 324 | * If flags were specified, only corrupt those that match. |
325 | */ | 325 | */ |
326 | if (!error && bio_submitted_while_down && | 326 | if (fc->corrupt_bio_byte && !error && bio_submitted_while_down && |
327 | (bio_data_dir(bio) == READ) && (fc->corrupt_bio_rw == READ) && | 327 | (bio_data_dir(bio) == READ) && (fc->corrupt_bio_rw == READ) && |
328 | all_corrupt_bio_flags_match(bio, fc)) | 328 | all_corrupt_bio_flags_match(bio, fc)) |
329 | corrupt_bio_data(bio, fc); | 329 | corrupt_bio_data(bio, fc); |
diff --git a/drivers/md/dm-io.c b/drivers/md/dm-io.c index ad2eba40e319..ea5dd289fe2a 100644 --- a/drivers/md/dm-io.c +++ b/drivers/md/dm-io.c | |||
@@ -296,6 +296,8 @@ static void do_region(int rw, unsigned region, struct dm_io_region *where, | |||
296 | unsigned offset; | 296 | unsigned offset; |
297 | unsigned num_bvecs; | 297 | unsigned num_bvecs; |
298 | sector_t remaining = where->count; | 298 | sector_t remaining = where->count; |
299 | struct request_queue *q = bdev_get_queue(where->bdev); | ||
300 | sector_t discard_sectors; | ||
299 | 301 | ||
300 | /* | 302 | /* |
301 | * where->count may be zero if rw holds a flush and we need to | 303 | * where->count may be zero if rw holds a flush and we need to |
@@ -305,9 +307,12 @@ static void do_region(int rw, unsigned region, struct dm_io_region *where, | |||
305 | /* | 307 | /* |
306 | * Allocate a suitably sized-bio. | 308 | * Allocate a suitably sized-bio. |
307 | */ | 309 | */ |
308 | num_bvecs = dm_sector_div_up(remaining, | 310 | if (rw & REQ_DISCARD) |
309 | (PAGE_SIZE >> SECTOR_SHIFT)); | 311 | num_bvecs = 1; |
310 | num_bvecs = min_t(int, bio_get_nr_vecs(where->bdev), num_bvecs); | 312 | else |
313 | num_bvecs = min_t(int, bio_get_nr_vecs(where->bdev), | ||
314 | dm_sector_div_up(remaining, (PAGE_SIZE >> SECTOR_SHIFT))); | ||
315 | |||
311 | bio = bio_alloc_bioset(GFP_NOIO, num_bvecs, io->client->bios); | 316 | bio = bio_alloc_bioset(GFP_NOIO, num_bvecs, io->client->bios); |
312 | bio->bi_sector = where->sector + (where->count - remaining); | 317 | bio->bi_sector = where->sector + (where->count - remaining); |
313 | bio->bi_bdev = where->bdev; | 318 | bio->bi_bdev = where->bdev; |
@@ -315,10 +320,14 @@ static void do_region(int rw, unsigned region, struct dm_io_region *where, | |||
315 | bio->bi_destructor = dm_bio_destructor; | 320 | bio->bi_destructor = dm_bio_destructor; |
316 | store_io_and_region_in_bio(bio, io, region); | 321 | store_io_and_region_in_bio(bio, io, region); |
317 | 322 | ||
318 | /* | 323 | if (rw & REQ_DISCARD) { |
319 | * Try and add as many pages as possible. | 324 | discard_sectors = min_t(sector_t, q->limits.max_discard_sectors, remaining); |
320 | */ | 325 | bio->bi_size = discard_sectors << SECTOR_SHIFT; |
321 | while (remaining) { | 326 | remaining -= discard_sectors; |
327 | } else while (remaining) { | ||
328 | /* | ||
329 | * Try and add as many pages as possible. | ||
330 | */ | ||
322 | dp->get_page(dp, &page, &len, &offset); | 331 | dp->get_page(dp, &page, &len, &offset); |
323 | len = min(len, to_bytes(remaining)); | 332 | len = min(len, to_bytes(remaining)); |
324 | if (!bio_add_page(bio, page, len, offset)) | 333 | if (!bio_add_page(bio, page, len, offset)) |
diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c index 31c2dc25886d..1ce84ed0b765 100644 --- a/drivers/md/dm-ioctl.c +++ b/drivers/md/dm-ioctl.c | |||
@@ -1437,7 +1437,7 @@ static int target_message(struct dm_ioctl *param, size_t param_size) | |||
1437 | 1437 | ||
1438 | if (!argc) { | 1438 | if (!argc) { |
1439 | DMWARN("Empty message received."); | 1439 | DMWARN("Empty message received."); |
1440 | goto out; | 1440 | goto out_argv; |
1441 | } | 1441 | } |
1442 | 1442 | ||
1443 | table = dm_get_live_table(md); | 1443 | table = dm_get_live_table(md); |
diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c index 86cb7e5d83d5..787022c18187 100644 --- a/drivers/md/dm-raid.c +++ b/drivers/md/dm-raid.c | |||
@@ -668,7 +668,14 @@ static int super_load(struct md_rdev *rdev, struct md_rdev *refdev) | |||
668 | return ret; | 668 | return ret; |
669 | 669 | ||
670 | sb = page_address(rdev->sb_page); | 670 | sb = page_address(rdev->sb_page); |
671 | if (sb->magic != cpu_to_le32(DM_RAID_MAGIC)) { | 671 | |
672 | /* | ||
673 | * Two cases that we want to write new superblocks and rebuild: | ||
674 | * 1) New device (no matching magic number) | ||
675 | * 2) Device specified for rebuild (!In_sync w/ offset == 0) | ||
676 | */ | ||
677 | if ((sb->magic != cpu_to_le32(DM_RAID_MAGIC)) || | ||
678 | (!test_bit(In_sync, &rdev->flags) && !rdev->recovery_offset)) { | ||
672 | super_sync(rdev->mddev, rdev); | 679 | super_sync(rdev->mddev, rdev); |
673 | 680 | ||
674 | set_bit(FirstUse, &rdev->flags); | 681 | set_bit(FirstUse, &rdev->flags); |
@@ -745,11 +752,8 @@ static int super_init_validation(struct mddev *mddev, struct md_rdev *rdev) | |||
745 | */ | 752 | */ |
746 | rdev_for_each(r, t, mddev) { | 753 | rdev_for_each(r, t, mddev) { |
747 | if (!test_bit(In_sync, &r->flags)) { | 754 | if (!test_bit(In_sync, &r->flags)) { |
748 | if (!test_bit(FirstUse, &r->flags)) | 755 | DMINFO("Device %d specified for rebuild: " |
749 | DMERR("Superblock area of " | 756 | "Clearing superblock", r->raid_disk); |
750 | "rebuild device %d should have been " | ||
751 | "cleared.", r->raid_disk); | ||
752 | set_bit(FirstUse, &r->flags); | ||
753 | rebuilds++; | 757 | rebuilds++; |
754 | } else if (test_bit(FirstUse, &r->flags)) | 758 | } else if (test_bit(FirstUse, &r->flags)) |
755 | new_devs++; | 759 | new_devs++; |
@@ -971,6 +975,7 @@ static int raid_ctr(struct dm_target *ti, unsigned argc, char **argv) | |||
971 | 975 | ||
972 | INIT_WORK(&rs->md.event_work, do_table_event); | 976 | INIT_WORK(&rs->md.event_work, do_table_event); |
973 | ti->private = rs; | 977 | ti->private = rs; |
978 | ti->num_flush_requests = 1; | ||
974 | 979 | ||
975 | mutex_lock(&rs->md.reconfig_mutex); | 980 | mutex_lock(&rs->md.reconfig_mutex); |
976 | ret = md_run(&rs->md); | 981 | ret = md_run(&rs->md); |
diff --git a/drivers/md/dm-thin-metadata.c b/drivers/md/dm-thin-metadata.c index 59c4f0446ffa..237571af77fd 100644 --- a/drivers/md/dm-thin-metadata.c +++ b/drivers/md/dm-thin-metadata.c | |||
@@ -385,6 +385,7 @@ static int init_pmd(struct dm_pool_metadata *pmd, | |||
385 | data_sm = dm_sm_disk_create(tm, nr_blocks); | 385 | data_sm = dm_sm_disk_create(tm, nr_blocks); |
386 | if (IS_ERR(data_sm)) { | 386 | if (IS_ERR(data_sm)) { |
387 | DMERR("sm_disk_create failed"); | 387 | DMERR("sm_disk_create failed"); |
388 | dm_tm_unlock(tm, sblock); | ||
388 | r = PTR_ERR(data_sm); | 389 | r = PTR_ERR(data_sm); |
389 | goto bad; | 390 | goto bad; |
390 | } | 391 | } |
@@ -789,6 +790,11 @@ int dm_pool_metadata_close(struct dm_pool_metadata *pmd) | |||
789 | return 0; | 790 | return 0; |
790 | } | 791 | } |
791 | 792 | ||
793 | /* | ||
794 | * __open_device: Returns @td corresponding to device with id @dev, | ||
795 | * creating it if @create is set and incrementing @td->open_count. | ||
796 | * On failure, @td is undefined. | ||
797 | */ | ||
792 | static int __open_device(struct dm_pool_metadata *pmd, | 798 | static int __open_device(struct dm_pool_metadata *pmd, |
793 | dm_thin_id dev, int create, | 799 | dm_thin_id dev, int create, |
794 | struct dm_thin_device **td) | 800 | struct dm_thin_device **td) |
@@ -799,10 +805,16 @@ static int __open_device(struct dm_pool_metadata *pmd, | |||
799 | struct disk_device_details details_le; | 805 | struct disk_device_details details_le; |
800 | 806 | ||
801 | /* | 807 | /* |
802 | * Check the device isn't already open. | 808 | * If the device is already open, return it. |
803 | */ | 809 | */ |
804 | list_for_each_entry(td2, &pmd->thin_devices, list) | 810 | list_for_each_entry(td2, &pmd->thin_devices, list) |
805 | if (td2->id == dev) { | 811 | if (td2->id == dev) { |
812 | /* | ||
813 | * May not create an already-open device. | ||
814 | */ | ||
815 | if (create) | ||
816 | return -EEXIST; | ||
817 | |||
806 | td2->open_count++; | 818 | td2->open_count++; |
807 | *td = td2; | 819 | *td = td2; |
808 | return 0; | 820 | return 0; |
@@ -817,6 +829,9 @@ static int __open_device(struct dm_pool_metadata *pmd, | |||
817 | if (r != -ENODATA || !create) | 829 | if (r != -ENODATA || !create) |
818 | return r; | 830 | return r; |
819 | 831 | ||
832 | /* | ||
833 | * Create new device. | ||
834 | */ | ||
820 | changed = 1; | 835 | changed = 1; |
821 | details_le.mapped_blocks = 0; | 836 | details_le.mapped_blocks = 0; |
822 | details_le.transaction_id = cpu_to_le64(pmd->trans_id); | 837 | details_le.transaction_id = cpu_to_le64(pmd->trans_id); |
@@ -882,12 +897,10 @@ static int __create_thin(struct dm_pool_metadata *pmd, | |||
882 | 897 | ||
883 | r = __open_device(pmd, dev, 1, &td); | 898 | r = __open_device(pmd, dev, 1, &td); |
884 | if (r) { | 899 | if (r) { |
885 | __close_device(td); | ||
886 | dm_btree_remove(&pmd->tl_info, pmd->root, &key, &pmd->root); | 900 | dm_btree_remove(&pmd->tl_info, pmd->root, &key, &pmd->root); |
887 | dm_btree_del(&pmd->bl_info, dev_root); | 901 | dm_btree_del(&pmd->bl_info, dev_root); |
888 | return r; | 902 | return r; |
889 | } | 903 | } |
890 | td->changed = 1; | ||
891 | __close_device(td); | 904 | __close_device(td); |
892 | 905 | ||
893 | return r; | 906 | return r; |
@@ -967,14 +980,14 @@ static int __create_snap(struct dm_pool_metadata *pmd, | |||
967 | goto bad; | 980 | goto bad; |
968 | 981 | ||
969 | r = __set_snapshot_details(pmd, td, origin, pmd->time); | 982 | r = __set_snapshot_details(pmd, td, origin, pmd->time); |
983 | __close_device(td); | ||
984 | |||
970 | if (r) | 985 | if (r) |
971 | goto bad; | 986 | goto bad; |
972 | 987 | ||
973 | __close_device(td); | ||
974 | return 0; | 988 | return 0; |
975 | 989 | ||
976 | bad: | 990 | bad: |
977 | __close_device(td); | ||
978 | dm_btree_remove(&pmd->tl_info, pmd->root, &key, &pmd->root); | 991 | dm_btree_remove(&pmd->tl_info, pmd->root, &key, &pmd->root); |
979 | dm_btree_remove(&pmd->details_info, pmd->details_root, | 992 | dm_btree_remove(&pmd->details_info, pmd->details_root, |
980 | &key, &pmd->details_root); | 993 | &key, &pmd->details_root); |
@@ -1211,6 +1224,8 @@ static int __remove(struct dm_thin_device *td, dm_block_t block) | |||
1211 | if (r) | 1224 | if (r) |
1212 | return r; | 1225 | return r; |
1213 | 1226 | ||
1227 | td->mapped_blocks--; | ||
1228 | td->changed = 1; | ||
1214 | pmd->need_commit = 1; | 1229 | pmd->need_commit = 1; |
1215 | 1230 | ||
1216 | return 0; | 1231 | return 0; |
diff --git a/drivers/net/caif/caif_hsi.c b/drivers/net/caif/caif_hsi.c index c8afd62239e9..9a66e2a910ae 100644 --- a/drivers/net/caif/caif_hsi.c +++ b/drivers/net/caif/caif_hsi.c | |||
@@ -1031,7 +1031,7 @@ static void cfhsi_setup(struct net_device *dev) | |||
1031 | dev->netdev_ops = &cfhsi_ops; | 1031 | dev->netdev_ops = &cfhsi_ops; |
1032 | dev->type = ARPHRD_CAIF; | 1032 | dev->type = ARPHRD_CAIF; |
1033 | dev->flags = IFF_POINTOPOINT | IFF_NOARP; | 1033 | dev->flags = IFF_POINTOPOINT | IFF_NOARP; |
1034 | dev->mtu = CFHSI_MAX_PAYLOAD_SZ; | 1034 | dev->mtu = CFHSI_MAX_CAIF_FRAME_SZ; |
1035 | dev->tx_queue_len = 0; | 1035 | dev->tx_queue_len = 0; |
1036 | dev->destructor = free_netdev; | 1036 | dev->destructor = free_netdev; |
1037 | skb_queue_head_init(&cfhsi->qhead); | 1037 | skb_queue_head_init(&cfhsi->qhead); |
diff --git a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c index 0f21a9b4cdd4..1ef0c9275dee 100644 --- a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c +++ b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c | |||
@@ -1711,7 +1711,7 @@ static irqreturn_t atl1c_intr(int irq, void *data) | |||
1711 | "atl1c hardware error (status = 0x%x)\n", | 1711 | "atl1c hardware error (status = 0x%x)\n", |
1712 | status & ISR_ERROR); | 1712 | status & ISR_ERROR); |
1713 | /* reset MAC */ | 1713 | /* reset MAC */ |
1714 | adapter->work_event |= ATL1C_WORK_EVENT_RESET; | 1714 | set_bit(ATL1C_WORK_EVENT_RESET, &adapter->work_event); |
1715 | schedule_work(&adapter->common_task); | 1715 | schedule_work(&adapter->common_task); |
1716 | return IRQ_HANDLED; | 1716 | return IRQ_HANDLED; |
1717 | } | 1717 | } |
diff --git a/drivers/net/ethernet/broadcom/tg3.c b/drivers/net/ethernet/broadcom/tg3.c index bc236b6a7a91..b0657466041d 100644 --- a/drivers/net/ethernet/broadcom/tg3.c +++ b/drivers/net/ethernet/broadcom/tg3.c | |||
@@ -5595,7 +5595,7 @@ static void tg3_tx(struct tg3_napi *tnapi) | |||
5595 | } | 5595 | } |
5596 | } | 5596 | } |
5597 | 5597 | ||
5598 | netdev_completed_queue(tp->dev, pkts_compl, bytes_compl); | 5598 | netdev_tx_completed_queue(txq, pkts_compl, bytes_compl); |
5599 | 5599 | ||
5600 | tnapi->tx_cons = sw_idx; | 5600 | tnapi->tx_cons = sw_idx; |
5601 | 5601 | ||
@@ -6971,7 +6971,7 @@ static netdev_tx_t tg3_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
6971 | } | 6971 | } |
6972 | 6972 | ||
6973 | skb_tx_timestamp(skb); | 6973 | skb_tx_timestamp(skb); |
6974 | netdev_sent_queue(tp->dev, skb->len); | 6974 | netdev_tx_sent_queue(txq, skb->len); |
6975 | 6975 | ||
6976 | /* Sync BD data before updating mailbox */ | 6976 | /* Sync BD data before updating mailbox */ |
6977 | wmb(); | 6977 | wmb(); |
@@ -7396,8 +7396,8 @@ static void tg3_free_rings(struct tg3 *tp) | |||
7396 | 7396 | ||
7397 | dev_kfree_skb_any(skb); | 7397 | dev_kfree_skb_any(skb); |
7398 | } | 7398 | } |
7399 | netdev_tx_reset_queue(netdev_get_tx_queue(tp->dev, j)); | ||
7399 | } | 7400 | } |
7400 | netdev_reset_queue(tp->dev); | ||
7401 | } | 7401 | } |
7402 | 7402 | ||
7403 | /* Initialize tx/rx rings for packet processing. | 7403 | /* Initialize tx/rx rings for packet processing. |
diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c index 1d889427073f..05ff076af06d 100644 --- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c +++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | |||
@@ -196,6 +196,8 @@ static DEFINE_PCI_DEVICE_TABLE(cxgb4_pci_tbl) = { | |||
196 | CH_DEVICE(0x4408, 4), | 196 | CH_DEVICE(0x4408, 4), |
197 | CH_DEVICE(0x4409, 4), | 197 | CH_DEVICE(0x4409, 4), |
198 | CH_DEVICE(0x440a, 4), | 198 | CH_DEVICE(0x440a, 4), |
199 | CH_DEVICE(0x440d, 4), | ||
200 | CH_DEVICE(0x440e, 4), | ||
199 | { 0, } | 201 | { 0, } |
200 | }; | 202 | }; |
201 | 203 | ||
diff --git a/drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c b/drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c index 3f580c0c28a6..25e3308fc9d8 100644 --- a/drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c +++ b/drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c | |||
@@ -2890,6 +2890,8 @@ static struct pci_device_id cxgb4vf_pci_tbl[] = { | |||
2890 | CH_DEVICE(0x4808, 0), /* T420-cx */ | 2890 | CH_DEVICE(0x4808, 0), /* T420-cx */ |
2891 | CH_DEVICE(0x4809, 0), /* T420-bt */ | 2891 | CH_DEVICE(0x4809, 0), /* T420-bt */ |
2892 | CH_DEVICE(0x480a, 0), /* T404-bt */ | 2892 | CH_DEVICE(0x480a, 0), /* T404-bt */ |
2893 | CH_DEVICE(0x480d, 0), /* T480-cr */ | ||
2894 | CH_DEVICE(0x480e, 0), /* T440-lp-cr */ | ||
2893 | { 0, } | 2895 | { 0, } |
2894 | }; | 2896 | }; |
2895 | 2897 | ||
diff --git a/drivers/net/ethernet/ibm/ehea/ehea_main.c b/drivers/net/ethernet/ibm/ehea/ehea_main.c index 8b73dd472475..3516e17a399d 100644 --- a/drivers/net/ethernet/ibm/ehea/ehea_main.c +++ b/drivers/net/ethernet/ibm/ehea/ehea_main.c | |||
@@ -336,7 +336,9 @@ static struct rtnl_link_stats64 *ehea_get_stats64(struct net_device *dev, | |||
336 | stats->tx_bytes = tx_bytes; | 336 | stats->tx_bytes = tx_bytes; |
337 | stats->rx_packets = rx_packets; | 337 | stats->rx_packets = rx_packets; |
338 | 338 | ||
339 | return &port->stats; | 339 | stats->multicast = port->stats.multicast; |
340 | stats->rx_errors = port->stats.rx_errors; | ||
341 | return stats; | ||
340 | } | 342 | } |
341 | 343 | ||
342 | static void ehea_update_stats(struct work_struct *work) | 344 | static void ehea_update_stats(struct work_struct *work) |
diff --git a/drivers/net/ethernet/mellanox/mlx4/qp.c b/drivers/net/ethernet/mellanox/mlx4/qp.c index 738f950a1ce5..fb2b36759cbf 100644 --- a/drivers/net/ethernet/mellanox/mlx4/qp.c +++ b/drivers/net/ethernet/mellanox/mlx4/qp.c | |||
@@ -151,11 +151,6 @@ static int __mlx4_qp_modify(struct mlx4_dev *dev, struct mlx4_mtt *mtt, | |||
151 | context->log_page_size = mtt->page_shift - MLX4_ICM_PAGE_SHIFT; | 151 | context->log_page_size = mtt->page_shift - MLX4_ICM_PAGE_SHIFT; |
152 | } | 152 | } |
153 | 153 | ||
154 | port = ((context->pri_path.sched_queue >> 6) & 1) + 1; | ||
155 | if (dev->caps.port_type[port] == MLX4_PORT_TYPE_ETH) | ||
156 | context->pri_path.sched_queue = (context->pri_path.sched_queue & | ||
157 | 0xc3); | ||
158 | |||
159 | *(__be32 *) mailbox->buf = cpu_to_be32(optpar); | 154 | *(__be32 *) mailbox->buf = cpu_to_be32(optpar); |
160 | memcpy(mailbox->buf + 8, context, sizeof *context); | 155 | memcpy(mailbox->buf + 8, context, sizeof *context); |
161 | 156 | ||
diff --git a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c index bfdb7af19e49..8752e6e08169 100644 --- a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c +++ b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c | |||
@@ -2255,8 +2255,7 @@ int mlx4_MODIFY_CQ_wrapper(struct mlx4_dev *dev, int slave, | |||
2255 | 2255 | ||
2256 | if (vhcr->op_modifier == 0) { | 2256 | if (vhcr->op_modifier == 0) { |
2257 | err = handle_resize(dev, slave, vhcr, inbox, outbox, cmd, cq); | 2257 | err = handle_resize(dev, slave, vhcr, inbox, outbox, cmd, cq); |
2258 | if (err) | 2258 | goto ex_put; |
2259 | goto ex_put; | ||
2260 | } | 2259 | } |
2261 | 2260 | ||
2262 | err = mlx4_DMA_wrapper(dev, slave, vhcr, inbox, outbox, cmd); | 2261 | err = mlx4_DMA_wrapper(dev, slave, vhcr, inbox, outbox, cmd); |
diff --git a/drivers/net/ethernet/realtek/r8169.c b/drivers/net/ethernet/realtek/r8169.c index 817302c86069..c04df3d2b2a9 100644 --- a/drivers/net/ethernet/realtek/r8169.c +++ b/drivers/net/ethernet/realtek/r8169.c | |||
@@ -6292,6 +6292,9 @@ static void rtl_shutdown(struct pci_dev *pdev) | |||
6292 | { | 6292 | { |
6293 | struct net_device *dev = pci_get_drvdata(pdev); | 6293 | struct net_device *dev = pci_get_drvdata(pdev); |
6294 | struct rtl8169_private *tp = netdev_priv(dev); | 6294 | struct rtl8169_private *tp = netdev_priv(dev); |
6295 | struct device *d = &pdev->dev; | ||
6296 | |||
6297 | pm_runtime_get_sync(d); | ||
6295 | 6298 | ||
6296 | rtl8169_net_suspend(dev); | 6299 | rtl8169_net_suspend(dev); |
6297 | 6300 | ||
@@ -6309,6 +6312,8 @@ static void rtl_shutdown(struct pci_dev *pdev) | |||
6309 | pci_wake_from_d3(pdev, true); | 6312 | pci_wake_from_d3(pdev, true); |
6310 | pci_set_power_state(pdev, PCI_D3hot); | 6313 | pci_set_power_state(pdev, PCI_D3hot); |
6311 | } | 6314 | } |
6315 | |||
6316 | pm_runtime_put_noidle(d); | ||
6312 | } | 6317 | } |
6313 | 6318 | ||
6314 | static struct pci_driver rtl8169_pci_driver = { | 6319 | static struct pci_driver rtl8169_pci_driver = { |
diff --git a/drivers/net/hyperv/netvsc_drv.c b/drivers/net/hyperv/netvsc_drv.c index 0ae7a1a6aeb0..217dfedbba20 100644 --- a/drivers/net/hyperv/netvsc_drv.c +++ b/drivers/net/hyperv/netvsc_drv.c | |||
@@ -310,7 +310,7 @@ int netvsc_recv_callback(struct hv_device *device_obj, | |||
310 | static void netvsc_get_drvinfo(struct net_device *net, | 310 | static void netvsc_get_drvinfo(struct net_device *net, |
311 | struct ethtool_drvinfo *info) | 311 | struct ethtool_drvinfo *info) |
312 | { | 312 | { |
313 | strcpy(info->driver, "hv_netvsc"); | 313 | strcpy(info->driver, KBUILD_MODNAME); |
314 | strcpy(info->version, HV_DRV_VERSION); | 314 | strcpy(info->version, HV_DRV_VERSION); |
315 | strcpy(info->fw_version, "N/A"); | 315 | strcpy(info->fw_version, "N/A"); |
316 | } | 316 | } |
@@ -482,7 +482,7 @@ MODULE_DEVICE_TABLE(vmbus, id_table); | |||
482 | 482 | ||
483 | /* The one and only one */ | 483 | /* The one and only one */ |
484 | static struct hv_driver netvsc_drv = { | 484 | static struct hv_driver netvsc_drv = { |
485 | .name = "netvsc", | 485 | .name = KBUILD_MODNAME, |
486 | .id_table = id_table, | 486 | .id_table = id_table, |
487 | .probe = netvsc_probe, | 487 | .probe = netvsc_probe, |
488 | .remove = netvsc_remove, | 488 | .remove = netvsc_remove, |
diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c index b924f46c963c..83dcc530618e 100644 --- a/drivers/net/usb/usbnet.c +++ b/drivers/net/usb/usbnet.c | |||
@@ -589,6 +589,7 @@ static int unlink_urbs (struct usbnet *dev, struct sk_buff_head *q) | |||
589 | entry = (struct skb_data *) skb->cb; | 589 | entry = (struct skb_data *) skb->cb; |
590 | urb = entry->urb; | 590 | urb = entry->urb; |
591 | 591 | ||
592 | spin_unlock_irqrestore(&q->lock, flags); | ||
592 | // during some PM-driven resume scenarios, | 593 | // during some PM-driven resume scenarios, |
593 | // these (async) unlinks complete immediately | 594 | // these (async) unlinks complete immediately |
594 | retval = usb_unlink_urb (urb); | 595 | retval = usb_unlink_urb (urb); |
@@ -596,6 +597,7 @@ static int unlink_urbs (struct usbnet *dev, struct sk_buff_head *q) | |||
596 | netdev_dbg(dev->net, "unlink urb err, %d\n", retval); | 597 | netdev_dbg(dev->net, "unlink urb err, %d\n", retval); |
597 | else | 598 | else |
598 | count++; | 599 | count++; |
600 | spin_lock_irqsave(&q->lock, flags); | ||
599 | } | 601 | } |
600 | spin_unlock_irqrestore (&q->lock, flags); | 602 | spin_unlock_irqrestore (&q->lock, flags); |
601 | return count; | 603 | return count; |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-lib.c b/drivers/net/wireless/iwlwifi/iwl-agn-lib.c index 915183a3a873..f98baaba0c2a 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-lib.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-lib.c | |||
@@ -1237,7 +1237,7 @@ int iwlagn_suspend(struct iwl_priv *priv, struct cfg80211_wowlan *wowlan) | |||
1237 | .flags = CMD_SYNC, | 1237 | .flags = CMD_SYNC, |
1238 | .data[0] = key_data.rsc_tsc, | 1238 | .data[0] = key_data.rsc_tsc, |
1239 | .dataflags[0] = IWL_HCMD_DFL_NOCOPY, | 1239 | .dataflags[0] = IWL_HCMD_DFL_NOCOPY, |
1240 | .len[0] = sizeof(key_data.rsc_tsc), | 1240 | .len[0] = sizeof(*key_data.rsc_tsc), |
1241 | }; | 1241 | }; |
1242 | 1242 | ||
1243 | ret = iwl_dvm_send_cmd(priv, &rsc_tsc_cmd); | 1243 | ret = iwl_dvm_send_cmd(priv, &rsc_tsc_cmd); |
diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c index ea2bd1be2640..91a375fb6ae6 100644 --- a/drivers/of/fdt.c +++ b/drivers/of/fdt.c | |||
@@ -23,7 +23,6 @@ | |||
23 | #include <asm/machdep.h> | 23 | #include <asm/machdep.h> |
24 | #endif /* CONFIG_PPC */ | 24 | #endif /* CONFIG_PPC */ |
25 | 25 | ||
26 | #include <asm/setup.h> | ||
27 | #include <asm/page.h> | 26 | #include <asm/page.h> |
28 | 27 | ||
29 | char *of_fdt_get_string(struct boot_param_header *blob, u32 offset) | 28 | char *of_fdt_get_string(struct boot_param_header *blob, u32 offset) |
diff --git a/drivers/of/of_mdio.c b/drivers/of/of_mdio.c index 980c079e4443..483c0adcad87 100644 --- a/drivers/of/of_mdio.c +++ b/drivers/of/of_mdio.c | |||
@@ -182,7 +182,7 @@ struct phy_device *of_phy_connect_fixed_link(struct net_device *dev, | |||
182 | if (!phy_id || sz < sizeof(*phy_id)) | 182 | if (!phy_id || sz < sizeof(*phy_id)) |
183 | return NULL; | 183 | return NULL; |
184 | 184 | ||
185 | sprintf(bus_id, PHY_ID_FMT, "0", be32_to_cpu(phy_id[0])); | 185 | sprintf(bus_id, PHY_ID_FMT, "fixed-0", be32_to_cpu(phy_id[0])); |
186 | 186 | ||
187 | phy = phy_connect(dev, bus_id, hndlr, 0, iface); | 187 | phy = phy_connect(dev, bus_id, hndlr, 0, iface); |
188 | return IS_ERR(phy) ? NULL : phy; | 188 | return IS_ERR(phy) ? NULL : phy; |
diff --git a/drivers/regulator/da9052-regulator.c b/drivers/regulator/da9052-regulator.c index 3767364452fd..ea4d8f575ac6 100644 --- a/drivers/regulator/da9052-regulator.c +++ b/drivers/regulator/da9052-regulator.c | |||
@@ -260,8 +260,8 @@ static int da9052_set_ldo5_6_voltage(struct regulator_dev *rdev, | |||
260 | * the LDO activate bit to implment the changes on the | 260 | * the LDO activate bit to implment the changes on the |
261 | * LDO output. | 261 | * LDO output. |
262 | */ | 262 | */ |
263 | return da9052_reg_update(regulator->da9052, DA9052_SUPPLY_REG, 0, | 263 | return da9052_reg_update(regulator->da9052, DA9052_SUPPLY_REG, |
264 | info->activate_bit); | 264 | info->activate_bit, info->activate_bit); |
265 | } | 265 | } |
266 | 266 | ||
267 | static int da9052_set_dcdc_voltage(struct regulator_dev *rdev, | 267 | static int da9052_set_dcdc_voltage(struct regulator_dev *rdev, |
@@ -280,8 +280,8 @@ static int da9052_set_dcdc_voltage(struct regulator_dev *rdev, | |||
280 | * the DCDC activate bit to implment the changes on the | 280 | * the DCDC activate bit to implment the changes on the |
281 | * DCDC output. | 281 | * DCDC output. |
282 | */ | 282 | */ |
283 | return da9052_reg_update(regulator->da9052, DA9052_SUPPLY_REG, 0, | 283 | return da9052_reg_update(regulator->da9052, DA9052_SUPPLY_REG, |
284 | info->activate_bit); | 284 | info->activate_bit, info->activate_bit); |
285 | } | 285 | } |
286 | 286 | ||
287 | static int da9052_get_regulator_voltage_sel(struct regulator_dev *rdev) | 287 | static int da9052_get_regulator_voltage_sel(struct regulator_dev *rdev) |
diff --git a/drivers/regulator/tps65910-regulator.c b/drivers/regulator/tps65910-regulator.c index 5c15ba01e9c7..40ecf5165899 100644 --- a/drivers/regulator/tps65910-regulator.c +++ b/drivers/regulator/tps65910-regulator.c | |||
@@ -662,7 +662,7 @@ static int tps65910_set_voltage_dcdc(struct regulator_dev *dev, | |||
662 | tps65910_reg_write(pmic, TPS65910_VDD2_OP, vsel); | 662 | tps65910_reg_write(pmic, TPS65910_VDD2_OP, vsel); |
663 | break; | 663 | break; |
664 | case TPS65911_REG_VDDCTRL: | 664 | case TPS65911_REG_VDDCTRL: |
665 | vsel = selector; | 665 | vsel = selector + 3; |
666 | tps65910_reg_write(pmic, TPS65911_VDDCTRL_OP, vsel); | 666 | tps65910_reg_write(pmic, TPS65911_VDDCTRL_OP, vsel); |
667 | } | 667 | } |
668 | 668 | ||
diff --git a/drivers/s390/cio/qdio_main.c b/drivers/s390/cio/qdio_main.c index 3ef8d071c64a..770a740a393c 100644 --- a/drivers/s390/cio/qdio_main.c +++ b/drivers/s390/cio/qdio_main.c | |||
@@ -167,7 +167,7 @@ again: | |||
167 | DBF_ERROR("%4x EQBS ERROR", SCH_NO(q)); | 167 | DBF_ERROR("%4x EQBS ERROR", SCH_NO(q)); |
168 | DBF_ERROR("%3d%3d%2d", count, tmp_count, nr); | 168 | DBF_ERROR("%3d%3d%2d", count, tmp_count, nr); |
169 | q->handler(q->irq_ptr->cdev, QDIO_ERROR_ACTIVATE_CHECK_CONDITION, | 169 | q->handler(q->irq_ptr->cdev, QDIO_ERROR_ACTIVATE_CHECK_CONDITION, |
170 | 0, -1, -1, q->irq_ptr->int_parm); | 170 | q->nr, q->first_to_kick, count, q->irq_ptr->int_parm); |
171 | return 0; | 171 | return 0; |
172 | } | 172 | } |
173 | 173 | ||
@@ -215,7 +215,7 @@ again: | |||
215 | DBF_ERROR("%4x SQBS ERROR", SCH_NO(q)); | 215 | DBF_ERROR("%4x SQBS ERROR", SCH_NO(q)); |
216 | DBF_ERROR("%3d%3d%2d", count, tmp_count, nr); | 216 | DBF_ERROR("%3d%3d%2d", count, tmp_count, nr); |
217 | q->handler(q->irq_ptr->cdev, QDIO_ERROR_ACTIVATE_CHECK_CONDITION, | 217 | q->handler(q->irq_ptr->cdev, QDIO_ERROR_ACTIVATE_CHECK_CONDITION, |
218 | 0, -1, -1, q->irq_ptr->int_parm); | 218 | q->nr, q->first_to_kick, count, q->irq_ptr->int_parm); |
219 | return 0; | 219 | return 0; |
220 | } | 220 | } |
221 | 221 | ||
diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c index 2f9cb43a2398..f37ad2271ad5 100644 --- a/drivers/spi/spi-pl022.c +++ b/drivers/spi/spi-pl022.c | |||
@@ -1083,7 +1083,7 @@ err_alloc_rx_sg: | |||
1083 | return -ENOMEM; | 1083 | return -ENOMEM; |
1084 | } | 1084 | } |
1085 | 1085 | ||
1086 | static int __init pl022_dma_probe(struct pl022 *pl022) | 1086 | static int __devinit pl022_dma_probe(struct pl022 *pl022) |
1087 | { | 1087 | { |
1088 | dma_cap_mask_t mask; | 1088 | dma_cap_mask_t mask; |
1089 | 1089 | ||
diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c index 63a196b97d50..bc7e24420ac0 100644 --- a/fs/cifs/dir.c +++ b/fs/cifs/dir.c | |||
@@ -584,10 +584,26 @@ cifs_lookup(struct inode *parent_dir_inode, struct dentry *direntry, | |||
584 | * If either that or op not supported returned, follow | 584 | * If either that or op not supported returned, follow |
585 | * the normal lookup. | 585 | * the normal lookup. |
586 | */ | 586 | */ |
587 | if ((rc == 0) || (rc == -ENOENT)) | 587 | switch (rc) { |
588 | case 0: | ||
589 | /* | ||
590 | * The server may allow us to open things like | ||
591 | * FIFOs, but the client isn't set up to deal | ||
592 | * with that. If it's not a regular file, just | ||
593 | * close it and proceed as if it were a normal | ||
594 | * lookup. | ||
595 | */ | ||
596 | if (newInode && !S_ISREG(newInode->i_mode)) { | ||
597 | CIFSSMBClose(xid, pTcon, fileHandle); | ||
598 | break; | ||
599 | } | ||
600 | case -ENOENT: | ||
588 | posix_open = true; | 601 | posix_open = true; |
589 | else if ((rc == -EINVAL) || (rc != -EOPNOTSUPP)) | 602 | case -EOPNOTSUPP: |
603 | break; | ||
604 | default: | ||
590 | pTcon->broken_posix_open = true; | 605 | pTcon->broken_posix_open = true; |
606 | } | ||
591 | } | 607 | } |
592 | if (!posix_open) | 608 | if (!posix_open) |
593 | rc = cifs_get_inode_info_unix(&newInode, full_path, | 609 | rc = cifs_get_inode_info_unix(&newInode, full_path, |
diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c index a5f54b7d9822..745da3d0653e 100644 --- a/fs/cifs/inode.c +++ b/fs/cifs/inode.c | |||
@@ -534,6 +534,11 @@ cifs_all_info_to_fattr(struct cifs_fattr *fattr, FILE_ALL_INFO *info, | |||
534 | if (fattr->cf_cifsattrs & ATTR_DIRECTORY) { | 534 | if (fattr->cf_cifsattrs & ATTR_DIRECTORY) { |
535 | fattr->cf_mode = S_IFDIR | cifs_sb->mnt_dir_mode; | 535 | fattr->cf_mode = S_IFDIR | cifs_sb->mnt_dir_mode; |
536 | fattr->cf_dtype = DT_DIR; | 536 | fattr->cf_dtype = DT_DIR; |
537 | /* | ||
538 | * Server can return wrong NumberOfLinks value for directories | ||
539 | * when Unix extensions are disabled - fake it. | ||
540 | */ | ||
541 | fattr->cf_nlink = 2; | ||
537 | } else { | 542 | } else { |
538 | fattr->cf_mode = S_IFREG | cifs_sb->mnt_file_mode; | 543 | fattr->cf_mode = S_IFREG | cifs_sb->mnt_file_mode; |
539 | fattr->cf_dtype = DT_REG; | 544 | fattr->cf_dtype = DT_REG; |
@@ -541,9 +546,9 @@ cifs_all_info_to_fattr(struct cifs_fattr *fattr, FILE_ALL_INFO *info, | |||
541 | /* clear write bits if ATTR_READONLY is set */ | 546 | /* clear write bits if ATTR_READONLY is set */ |
542 | if (fattr->cf_cifsattrs & ATTR_READONLY) | 547 | if (fattr->cf_cifsattrs & ATTR_READONLY) |
543 | fattr->cf_mode &= ~(S_IWUGO); | 548 | fattr->cf_mode &= ~(S_IWUGO); |
544 | } | ||
545 | 549 | ||
546 | fattr->cf_nlink = le32_to_cpu(info->NumberOfLinks); | 550 | fattr->cf_nlink = le32_to_cpu(info->NumberOfLinks); |
551 | } | ||
547 | 552 | ||
548 | fattr->cf_uid = cifs_sb->mnt_uid; | 553 | fattr->cf_uid = cifs_sb->mnt_uid; |
549 | fattr->cf_gid = cifs_sb->mnt_gid; | 554 | fattr->cf_gid = cifs_sb->mnt_gid; |
@@ -1322,7 +1327,6 @@ int cifs_mkdir(struct inode *inode, struct dentry *direntry, umode_t mode) | |||
1322 | } | 1327 | } |
1323 | /*BB check (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID ) to see if need | 1328 | /*BB check (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID ) to see if need |
1324 | to set uid/gid */ | 1329 | to set uid/gid */ |
1325 | inc_nlink(inode); | ||
1326 | 1330 | ||
1327 | cifs_unix_basic_to_fattr(&fattr, pInfo, cifs_sb); | 1331 | cifs_unix_basic_to_fattr(&fattr, pInfo, cifs_sb); |
1328 | cifs_fill_uniqueid(inode->i_sb, &fattr); | 1332 | cifs_fill_uniqueid(inode->i_sb, &fattr); |
@@ -1355,7 +1359,6 @@ mkdir_retry_old: | |||
1355 | d_drop(direntry); | 1359 | d_drop(direntry); |
1356 | } else { | 1360 | } else { |
1357 | mkdir_get_info: | 1361 | mkdir_get_info: |
1358 | inc_nlink(inode); | ||
1359 | if (pTcon->unix_ext) | 1362 | if (pTcon->unix_ext) |
1360 | rc = cifs_get_inode_info_unix(&newinode, full_path, | 1363 | rc = cifs_get_inode_info_unix(&newinode, full_path, |
1361 | inode->i_sb, xid); | 1364 | inode->i_sb, xid); |
@@ -1436,6 +1439,11 @@ mkdir_get_info: | |||
1436 | } | 1439 | } |
1437 | } | 1440 | } |
1438 | mkdir_out: | 1441 | mkdir_out: |
1442 | /* | ||
1443 | * Force revalidate to get parent dir info when needed since cached | ||
1444 | * attributes are invalid now. | ||
1445 | */ | ||
1446 | CIFS_I(inode)->time = 0; | ||
1439 | kfree(full_path); | 1447 | kfree(full_path); |
1440 | FreeXid(xid); | 1448 | FreeXid(xid); |
1441 | cifs_put_tlink(tlink); | 1449 | cifs_put_tlink(tlink); |
@@ -1475,7 +1483,6 @@ int cifs_rmdir(struct inode *inode, struct dentry *direntry) | |||
1475 | cifs_put_tlink(tlink); | 1483 | cifs_put_tlink(tlink); |
1476 | 1484 | ||
1477 | if (!rc) { | 1485 | if (!rc) { |
1478 | drop_nlink(inode); | ||
1479 | spin_lock(&direntry->d_inode->i_lock); | 1486 | spin_lock(&direntry->d_inode->i_lock); |
1480 | i_size_write(direntry->d_inode, 0); | 1487 | i_size_write(direntry->d_inode, 0); |
1481 | clear_nlink(direntry->d_inode); | 1488 | clear_nlink(direntry->d_inode); |
@@ -1483,12 +1490,15 @@ int cifs_rmdir(struct inode *inode, struct dentry *direntry) | |||
1483 | } | 1490 | } |
1484 | 1491 | ||
1485 | cifsInode = CIFS_I(direntry->d_inode); | 1492 | cifsInode = CIFS_I(direntry->d_inode); |
1486 | cifsInode->time = 0; /* force revalidate to go get info when | 1493 | /* force revalidate to go get info when needed */ |
1487 | needed */ | 1494 | cifsInode->time = 0; |
1488 | 1495 | ||
1489 | cifsInode = CIFS_I(inode); | 1496 | cifsInode = CIFS_I(inode); |
1490 | cifsInode->time = 0; /* force revalidate to get parent dir info | 1497 | /* |
1491 | since cached search results now invalid */ | 1498 | * Force revalidate to get parent dir info when needed since cached |
1499 | * attributes are invalid now. | ||
1500 | */ | ||
1501 | cifsInode->time = 0; | ||
1492 | 1502 | ||
1493 | direntry->d_inode->i_ctime = inode->i_ctime = inode->i_mtime = | 1503 | direntry->d_inode->i_ctime = inode->i_ctime = inode->i_mtime = |
1494 | current_fs_time(inode->i_sb); | 1504 | current_fs_time(inode->i_sb); |
diff --git a/include/linux/amba/serial.h b/include/linux/amba/serial.h index 514ed45c462e..d117b29d1062 100644 --- a/include/linux/amba/serial.h +++ b/include/linux/amba/serial.h | |||
@@ -23,6 +23,8 @@ | |||
23 | #ifndef ASM_ARM_HARDWARE_SERIAL_AMBA_H | 23 | #ifndef ASM_ARM_HARDWARE_SERIAL_AMBA_H |
24 | #define ASM_ARM_HARDWARE_SERIAL_AMBA_H | 24 | #define ASM_ARM_HARDWARE_SERIAL_AMBA_H |
25 | 25 | ||
26 | #include <linux/types.h> | ||
27 | |||
26 | /* ------------------------------------------------------------------------------- | 28 | /* ------------------------------------------------------------------------------- |
27 | * From AMBA UART (PL010) Block Specification | 29 | * From AMBA UART (PL010) Block Specification |
28 | * ------------------------------------------------------------------------------- | 30 | * ------------------------------------------------------------------------------- |
diff --git a/include/linux/of.h b/include/linux/of.h index a75a831e2057..92cf6ad35e0e 100644 --- a/include/linux/of.h +++ b/include/linux/of.h | |||
@@ -281,6 +281,14 @@ static inline struct property *of_find_property(const struct device_node *np, | |||
281 | return NULL; | 281 | return NULL; |
282 | } | 282 | } |
283 | 283 | ||
284 | static inline struct device_node *of_find_compatible_node( | ||
285 | struct device_node *from, | ||
286 | const char *type, | ||
287 | const char *compat) | ||
288 | { | ||
289 | return NULL; | ||
290 | } | ||
291 | |||
284 | static inline int of_property_read_u32_array(const struct device_node *np, | 292 | static inline int of_property_read_u32_array(const struct device_node *np, |
285 | const char *propname, | 293 | const char *propname, |
286 | u32 *out_values, size_t sz) | 294 | u32 *out_values, size_t sz) |
diff --git a/include/net/inetpeer.h b/include/net/inetpeer.h index 06b795dd5906..b94765e38e80 100644 --- a/include/net/inetpeer.h +++ b/include/net/inetpeer.h | |||
@@ -35,12 +35,12 @@ struct inet_peer { | |||
35 | 35 | ||
36 | u32 metrics[RTAX_MAX]; | 36 | u32 metrics[RTAX_MAX]; |
37 | u32 rate_tokens; /* rate limiting for ICMP */ | 37 | u32 rate_tokens; /* rate limiting for ICMP */ |
38 | int redirect_genid; | ||
39 | unsigned long rate_last; | 38 | unsigned long rate_last; |
40 | unsigned long pmtu_expires; | 39 | unsigned long pmtu_expires; |
41 | u32 pmtu_orig; | 40 | u32 pmtu_orig; |
42 | u32 pmtu_learned; | 41 | u32 pmtu_learned; |
43 | struct inetpeer_addr_base redirect_learned; | 42 | struct inetpeer_addr_base redirect_learned; |
43 | struct list_head gc_list; | ||
44 | /* | 44 | /* |
45 | * Once inet_peer is queued for deletion (refcnt == -1), following fields | 45 | * Once inet_peer is queued for deletion (refcnt == -1), following fields |
46 | * are not available: rid, ip_id_count, tcp_ts, tcp_ts_stamp | 46 | * are not available: rid, ip_id_count, tcp_ts, tcp_ts_stamp |
@@ -96,6 +96,8 @@ static inline struct inet_peer *inet_getpeer_v6(const struct in6_addr *v6daddr, | |||
96 | extern void inet_putpeer(struct inet_peer *p); | 96 | extern void inet_putpeer(struct inet_peer *p); |
97 | extern bool inet_peer_xrlim_allow(struct inet_peer *peer, int timeout); | 97 | extern bool inet_peer_xrlim_allow(struct inet_peer *peer, int timeout); |
98 | 98 | ||
99 | extern void inetpeer_invalidate_tree(int family); | ||
100 | |||
99 | /* | 101 | /* |
100 | * temporary check to make sure we dont access rid, ip_id_count, tcp_ts, | 102 | * temporary check to make sure we dont access rid, ip_id_count, tcp_ts, |
101 | * tcp_ts_stamp if no refcount is taken on inet_peer | 103 | * tcp_ts_stamp if no refcount is taken on inet_peer |
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index 32313c084442..0f0d4704ddd8 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c | |||
@@ -985,6 +985,11 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new) | |||
985 | 985 | ||
986 | /* add new interrupt at end of irq queue */ | 986 | /* add new interrupt at end of irq queue */ |
987 | do { | 987 | do { |
988 | /* | ||
989 | * Or all existing action->thread_mask bits, | ||
990 | * so we can find the next zero bit for this | ||
991 | * new action. | ||
992 | */ | ||
988 | thread_mask |= old->thread_mask; | 993 | thread_mask |= old->thread_mask; |
989 | old_ptr = &old->next; | 994 | old_ptr = &old->next; |
990 | old = *old_ptr; | 995 | old = *old_ptr; |
@@ -993,14 +998,41 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new) | |||
993 | } | 998 | } |
994 | 999 | ||
995 | /* | 1000 | /* |
996 | * Setup the thread mask for this irqaction. Unlikely to have | 1001 | * Setup the thread mask for this irqaction for ONESHOT. For |
997 | * 32 resp 64 irqs sharing one line, but who knows. | 1002 | * !ONESHOT irqs the thread mask is 0 so we can avoid a |
1003 | * conditional in irq_wake_thread(). | ||
998 | */ | 1004 | */ |
999 | if (new->flags & IRQF_ONESHOT && thread_mask == ~0UL) { | 1005 | if (new->flags & IRQF_ONESHOT) { |
1000 | ret = -EBUSY; | 1006 | /* |
1001 | goto out_mask; | 1007 | * Unlikely to have 32 resp 64 irqs sharing one line, |
1008 | * but who knows. | ||
1009 | */ | ||
1010 | if (thread_mask == ~0UL) { | ||
1011 | ret = -EBUSY; | ||
1012 | goto out_mask; | ||
1013 | } | ||
1014 | /* | ||
1015 | * The thread_mask for the action is or'ed to | ||
1016 | * desc->thread_active to indicate that the | ||
1017 | * IRQF_ONESHOT thread handler has been woken, but not | ||
1018 | * yet finished. The bit is cleared when a thread | ||
1019 | * completes. When all threads of a shared interrupt | ||
1020 | * line have completed desc->threads_active becomes | ||
1021 | * zero and the interrupt line is unmasked. See | ||
1022 | * handle.c:irq_wake_thread() for further information. | ||
1023 | * | ||
1024 | * If no thread is woken by primary (hard irq context) | ||
1025 | * interrupt handlers, then desc->threads_active is | ||
1026 | * also checked for zero to unmask the irq line in the | ||
1027 | * affected hard irq flow handlers | ||
1028 | * (handle_[fasteoi|level]_irq). | ||
1029 | * | ||
1030 | * The new action gets the first zero bit of | ||
1031 | * thread_mask assigned. See the loop above which or's | ||
1032 | * all existing action->thread_mask bits. | ||
1033 | */ | ||
1034 | new->thread_mask = 1 << ffz(thread_mask); | ||
1002 | } | 1035 | } |
1003 | new->thread_mask = 1 << ffz(thread_mask); | ||
1004 | 1036 | ||
1005 | if (!shared) { | 1037 | if (!shared) { |
1006 | init_waitqueue_head(&desc->wait_for_threads); | 1038 | init_waitqueue_head(&desc->wait_for_threads); |
diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 33a0676ea744..b342f57879e6 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c | |||
@@ -6728,7 +6728,7 @@ int __init sched_create_sysfs_power_savings_entries(struct device *dev) | |||
6728 | static int cpuset_cpu_active(struct notifier_block *nfb, unsigned long action, | 6728 | static int cpuset_cpu_active(struct notifier_block *nfb, unsigned long action, |
6729 | void *hcpu) | 6729 | void *hcpu) |
6730 | { | 6730 | { |
6731 | switch (action) { | 6731 | switch (action & ~CPU_TASKS_FROZEN) { |
6732 | case CPU_ONLINE: | 6732 | case CPU_ONLINE: |
6733 | case CPU_DOWN_FAILED: | 6733 | case CPU_DOWN_FAILED: |
6734 | cpuset_update_active_cpus(); | 6734 | cpuset_update_active_cpus(); |
@@ -6741,7 +6741,7 @@ static int cpuset_cpu_active(struct notifier_block *nfb, unsigned long action, | |||
6741 | static int cpuset_cpu_inactive(struct notifier_block *nfb, unsigned long action, | 6741 | static int cpuset_cpu_inactive(struct notifier_block *nfb, unsigned long action, |
6742 | void *hcpu) | 6742 | void *hcpu) |
6743 | { | 6743 | { |
6744 | switch (action) { | 6744 | switch (action & ~CPU_TASKS_FROZEN) { |
6745 | case CPU_DOWN_PREPARE: | 6745 | case CPU_DOWN_PREPARE: |
6746 | cpuset_update_active_cpus(); | 6746 | cpuset_update_active_cpus(); |
6747 | return NOTIFY_OK; | 6747 | return NOTIFY_OK; |
diff --git a/lib/vsprintf.c b/lib/vsprintf.c index 8e75003d62f6..38e612e66da5 100644 --- a/lib/vsprintf.c +++ b/lib/vsprintf.c | |||
@@ -891,9 +891,15 @@ char *pointer(const char *fmt, char *buf, char *end, void *ptr, | |||
891 | case 'U': | 891 | case 'U': |
892 | return uuid_string(buf, end, ptr, spec, fmt); | 892 | return uuid_string(buf, end, ptr, spec, fmt); |
893 | case 'V': | 893 | case 'V': |
894 | return buf + vsnprintf(buf, end > buf ? end - buf : 0, | 894 | { |
895 | ((struct va_format *)ptr)->fmt, | 895 | va_list va; |
896 | *(((struct va_format *)ptr)->va)); | 896 | |
897 | va_copy(va, *((struct va_format *)ptr)->va); | ||
898 | buf += vsnprintf(buf, end > buf ? end - buf : 0, | ||
899 | ((struct va_format *)ptr)->fmt, va); | ||
900 | va_end(va); | ||
901 | return buf; | ||
902 | } | ||
897 | case 'K': | 903 | case 'K': |
898 | /* | 904 | /* |
899 | * %pK cannot be used in IRQ context because its test | 905 | * %pK cannot be used in IRQ context because its test |
diff --git a/mm/mempolicy.c b/mm/mempolicy.c index 06b145fb64ab..47296fee23db 100644 --- a/mm/mempolicy.c +++ b/mm/mempolicy.c | |||
@@ -640,10 +640,11 @@ static int mbind_range(struct mm_struct *mm, unsigned long start, | |||
640 | unsigned long vmstart; | 640 | unsigned long vmstart; |
641 | unsigned long vmend; | 641 | unsigned long vmend; |
642 | 642 | ||
643 | vma = find_vma_prev(mm, start, &prev); | 643 | vma = find_vma(mm, start); |
644 | if (!vma || vma->vm_start > start) | 644 | if (!vma || vma->vm_start > start) |
645 | return -EFAULT; | 645 | return -EFAULT; |
646 | 646 | ||
647 | prev = vma->vm_prev; | ||
647 | if (start > vma->vm_start) | 648 | if (start > vma->vm_start) |
648 | prev = vma; | 649 | prev = vma; |
649 | 650 | ||
diff --git a/mm/mlock.c b/mm/mlock.c index 4f4f53bdc65d..ef726e8aa8e9 100644 --- a/mm/mlock.c +++ b/mm/mlock.c | |||
@@ -385,10 +385,11 @@ static int do_mlock(unsigned long start, size_t len, int on) | |||
385 | return -EINVAL; | 385 | return -EINVAL; |
386 | if (end == start) | 386 | if (end == start) |
387 | return 0; | 387 | return 0; |
388 | vma = find_vma_prev(current->mm, start, &prev); | 388 | vma = find_vma(current->mm, start); |
389 | if (!vma || vma->vm_start > start) | 389 | if (!vma || vma->vm_start > start) |
390 | return -ENOMEM; | 390 | return -ENOMEM; |
391 | 391 | ||
392 | prev = vma->vm_prev; | ||
392 | if (start > vma->vm_start) | 393 | if (start > vma->vm_start) |
393 | prev = vma; | 394 | prev = vma; |
394 | 395 | ||
@@ -1266,8 +1266,9 @@ munmap_back: | |||
1266 | vma->vm_pgoff = pgoff; | 1266 | vma->vm_pgoff = pgoff; |
1267 | INIT_LIST_HEAD(&vma->anon_vma_chain); | 1267 | INIT_LIST_HEAD(&vma->anon_vma_chain); |
1268 | 1268 | ||
1269 | error = -EINVAL; /* when rejecting VM_GROWSDOWN|VM_GROWSUP */ | ||
1270 | |||
1269 | if (file) { | 1271 | if (file) { |
1270 | error = -EINVAL; | ||
1271 | if (vm_flags & (VM_GROWSDOWN|VM_GROWSUP)) | 1272 | if (vm_flags & (VM_GROWSDOWN|VM_GROWSUP)) |
1272 | goto free_vma; | 1273 | goto free_vma; |
1273 | if (vm_flags & VM_DENYWRITE) { | 1274 | if (vm_flags & VM_DENYWRITE) { |
@@ -1607,7 +1608,6 @@ EXPORT_SYMBOL(find_vma); | |||
1607 | 1608 | ||
1608 | /* | 1609 | /* |
1609 | * Same as find_vma, but also return a pointer to the previous VMA in *pprev. | 1610 | * Same as find_vma, but also return a pointer to the previous VMA in *pprev. |
1610 | * Note: pprev is set to NULL when return value is NULL. | ||
1611 | */ | 1611 | */ |
1612 | struct vm_area_struct * | 1612 | struct vm_area_struct * |
1613 | find_vma_prev(struct mm_struct *mm, unsigned long addr, | 1613 | find_vma_prev(struct mm_struct *mm, unsigned long addr, |
@@ -1616,7 +1616,16 @@ find_vma_prev(struct mm_struct *mm, unsigned long addr, | |||
1616 | struct vm_area_struct *vma; | 1616 | struct vm_area_struct *vma; |
1617 | 1617 | ||
1618 | vma = find_vma(mm, addr); | 1618 | vma = find_vma(mm, addr); |
1619 | *pprev = vma ? vma->vm_prev : NULL; | 1619 | if (vma) { |
1620 | *pprev = vma->vm_prev; | ||
1621 | } else { | ||
1622 | struct rb_node *rb_node = mm->mm_rb.rb_node; | ||
1623 | *pprev = NULL; | ||
1624 | while (rb_node) { | ||
1625 | *pprev = rb_entry(rb_node, struct vm_area_struct, vm_rb); | ||
1626 | rb_node = rb_node->rb_right; | ||
1627 | } | ||
1628 | } | ||
1620 | return vma; | 1629 | return vma; |
1621 | } | 1630 | } |
1622 | 1631 | ||
diff --git a/mm/mprotect.c b/mm/mprotect.c index 5a688a2756be..f437d054c3bf 100644 --- a/mm/mprotect.c +++ b/mm/mprotect.c | |||
@@ -262,10 +262,11 @@ SYSCALL_DEFINE3(mprotect, unsigned long, start, size_t, len, | |||
262 | 262 | ||
263 | down_write(¤t->mm->mmap_sem); | 263 | down_write(¤t->mm->mmap_sem); |
264 | 264 | ||
265 | vma = find_vma_prev(current->mm, start, &prev); | 265 | vma = find_vma(current->mm, start); |
266 | error = -ENOMEM; | 266 | error = -ENOMEM; |
267 | if (!vma) | 267 | if (!vma) |
268 | goto out; | 268 | goto out; |
269 | prev = vma->vm_prev; | ||
269 | if (unlikely(grows & PROT_GROWSDOWN)) { | 270 | if (unlikely(grows & PROT_GROWSDOWN)) { |
270 | if (vma->vm_start >= end) | 271 | if (vma->vm_start >= end) |
271 | goto out; | 272 | goto out; |
diff --git a/mm/page_cgroup.c b/mm/page_cgroup.c index de1616aa9b1e..1ccbd714059c 100644 --- a/mm/page_cgroup.c +++ b/mm/page_cgroup.c | |||
@@ -379,13 +379,15 @@ static struct swap_cgroup *lookup_swap_cgroup(swp_entry_t ent, | |||
379 | pgoff_t offset = swp_offset(ent); | 379 | pgoff_t offset = swp_offset(ent); |
380 | struct swap_cgroup_ctrl *ctrl; | 380 | struct swap_cgroup_ctrl *ctrl; |
381 | struct page *mappage; | 381 | struct page *mappage; |
382 | struct swap_cgroup *sc; | ||
382 | 383 | ||
383 | ctrl = &swap_cgroup_ctrl[swp_type(ent)]; | 384 | ctrl = &swap_cgroup_ctrl[swp_type(ent)]; |
384 | if (ctrlp) | 385 | if (ctrlp) |
385 | *ctrlp = ctrl; | 386 | *ctrlp = ctrl; |
386 | 387 | ||
387 | mappage = ctrl->map[offset / SC_PER_PAGE]; | 388 | mappage = ctrl->map[offset / SC_PER_PAGE]; |
388 | return page_address(mappage) + offset % SC_PER_PAGE; | 389 | sc = page_address(mappage); |
390 | return sc + offset % SC_PER_PAGE; | ||
389 | } | 391 | } |
390 | 392 | ||
391 | /** | 393 | /** |
diff --git a/net/bridge/br_netfilter.c b/net/bridge/br_netfilter.c index 84122472656c..dec4f3817133 100644 --- a/net/bridge/br_netfilter.c +++ b/net/bridge/br_netfilter.c | |||
@@ -62,6 +62,15 @@ static int brnf_filter_pppoe_tagged __read_mostly = 0; | |||
62 | #define brnf_filter_pppoe_tagged 0 | 62 | #define brnf_filter_pppoe_tagged 0 |
63 | #endif | 63 | #endif |
64 | 64 | ||
65 | #define IS_IP(skb) \ | ||
66 | (!vlan_tx_tag_present(skb) && skb->protocol == htons(ETH_P_IP)) | ||
67 | |||
68 | #define IS_IPV6(skb) \ | ||
69 | (!vlan_tx_tag_present(skb) && skb->protocol == htons(ETH_P_IPV6)) | ||
70 | |||
71 | #define IS_ARP(skb) \ | ||
72 | (!vlan_tx_tag_present(skb) && skb->protocol == htons(ETH_P_ARP)) | ||
73 | |||
65 | static inline __be16 vlan_proto(const struct sk_buff *skb) | 74 | static inline __be16 vlan_proto(const struct sk_buff *skb) |
66 | { | 75 | { |
67 | if (vlan_tx_tag_present(skb)) | 76 | if (vlan_tx_tag_present(skb)) |
@@ -639,8 +648,7 @@ static unsigned int br_nf_pre_routing(unsigned int hook, struct sk_buff *skb, | |||
639 | return NF_DROP; | 648 | return NF_DROP; |
640 | br = p->br; | 649 | br = p->br; |
641 | 650 | ||
642 | if (skb->protocol == htons(ETH_P_IPV6) || IS_VLAN_IPV6(skb) || | 651 | if (IS_IPV6(skb) || IS_VLAN_IPV6(skb) || IS_PPPOE_IPV6(skb)) { |
643 | IS_PPPOE_IPV6(skb)) { | ||
644 | if (!brnf_call_ip6tables && !br->nf_call_ip6tables) | 652 | if (!brnf_call_ip6tables && !br->nf_call_ip6tables) |
645 | return NF_ACCEPT; | 653 | return NF_ACCEPT; |
646 | 654 | ||
@@ -651,8 +659,7 @@ static unsigned int br_nf_pre_routing(unsigned int hook, struct sk_buff *skb, | |||
651 | if (!brnf_call_iptables && !br->nf_call_iptables) | 659 | if (!brnf_call_iptables && !br->nf_call_iptables) |
652 | return NF_ACCEPT; | 660 | return NF_ACCEPT; |
653 | 661 | ||
654 | if (skb->protocol != htons(ETH_P_IP) && !IS_VLAN_IP(skb) && | 662 | if (!IS_IP(skb) && !IS_VLAN_IP(skb) && !IS_PPPOE_IP(skb)) |
655 | !IS_PPPOE_IP(skb)) | ||
656 | return NF_ACCEPT; | 663 | return NF_ACCEPT; |
657 | 664 | ||
658 | nf_bridge_pull_encap_header_rcsum(skb); | 665 | nf_bridge_pull_encap_header_rcsum(skb); |
@@ -701,7 +708,7 @@ static int br_nf_forward_finish(struct sk_buff *skb) | |||
701 | struct nf_bridge_info *nf_bridge = skb->nf_bridge; | 708 | struct nf_bridge_info *nf_bridge = skb->nf_bridge; |
702 | struct net_device *in; | 709 | struct net_device *in; |
703 | 710 | ||
704 | if (skb->protocol != htons(ETH_P_ARP) && !IS_VLAN_ARP(skb)) { | 711 | if (!IS_ARP(skb) && !IS_VLAN_ARP(skb)) { |
705 | in = nf_bridge->physindev; | 712 | in = nf_bridge->physindev; |
706 | if (nf_bridge->mask & BRNF_PKT_TYPE) { | 713 | if (nf_bridge->mask & BRNF_PKT_TYPE) { |
707 | skb->pkt_type = PACKET_OTHERHOST; | 714 | skb->pkt_type = PACKET_OTHERHOST; |
@@ -718,6 +725,7 @@ static int br_nf_forward_finish(struct sk_buff *skb) | |||
718 | return 0; | 725 | return 0; |
719 | } | 726 | } |
720 | 727 | ||
728 | |||
721 | /* This is the 'purely bridged' case. For IP, we pass the packet to | 729 | /* This is the 'purely bridged' case. For IP, we pass the packet to |
722 | * netfilter with indev and outdev set to the bridge device, | 730 | * netfilter with indev and outdev set to the bridge device, |
723 | * but we are still able to filter on the 'real' indev/outdev | 731 | * but we are still able to filter on the 'real' indev/outdev |
@@ -744,11 +752,9 @@ static unsigned int br_nf_forward_ip(unsigned int hook, struct sk_buff *skb, | |||
744 | if (!parent) | 752 | if (!parent) |
745 | return NF_DROP; | 753 | return NF_DROP; |
746 | 754 | ||
747 | if (skb->protocol == htons(ETH_P_IP) || IS_VLAN_IP(skb) || | 755 | if (IS_IP(skb) || IS_VLAN_IP(skb) || IS_PPPOE_IP(skb)) |
748 | IS_PPPOE_IP(skb)) | ||
749 | pf = PF_INET; | 756 | pf = PF_INET; |
750 | else if (skb->protocol == htons(ETH_P_IPV6) || IS_VLAN_IPV6(skb) || | 757 | else if (IS_IPV6(skb) || IS_VLAN_IPV6(skb) || IS_PPPOE_IPV6(skb)) |
751 | IS_PPPOE_IPV6(skb)) | ||
752 | pf = PF_INET6; | 758 | pf = PF_INET6; |
753 | else | 759 | else |
754 | return NF_ACCEPT; | 760 | return NF_ACCEPT; |
@@ -795,7 +801,7 @@ static unsigned int br_nf_forward_arp(unsigned int hook, struct sk_buff *skb, | |||
795 | if (!brnf_call_arptables && !br->nf_call_arptables) | 801 | if (!brnf_call_arptables && !br->nf_call_arptables) |
796 | return NF_ACCEPT; | 802 | return NF_ACCEPT; |
797 | 803 | ||
798 | if (skb->protocol != htons(ETH_P_ARP)) { | 804 | if (!IS_ARP(skb)) { |
799 | if (!IS_VLAN_ARP(skb)) | 805 | if (!IS_VLAN_ARP(skb)) |
800 | return NF_ACCEPT; | 806 | return NF_ACCEPT; |
801 | nf_bridge_pull_encap_header(skb); | 807 | nf_bridge_pull_encap_header(skb); |
@@ -853,11 +859,9 @@ static unsigned int br_nf_post_routing(unsigned int hook, struct sk_buff *skb, | |||
853 | if (!realoutdev) | 859 | if (!realoutdev) |
854 | return NF_DROP; | 860 | return NF_DROP; |
855 | 861 | ||
856 | if (skb->protocol == htons(ETH_P_IP) || IS_VLAN_IP(skb) || | 862 | if (IS_IP(skb) || IS_VLAN_IP(skb) || IS_PPPOE_IP(skb)) |
857 | IS_PPPOE_IP(skb)) | ||
858 | pf = PF_INET; | 863 | pf = PF_INET; |
859 | else if (skb->protocol == htons(ETH_P_IPV6) || IS_VLAN_IPV6(skb) || | 864 | else if (IS_IPV6(skb) || IS_VLAN_IPV6(skb) || IS_PPPOE_IPV6(skb)) |
860 | IS_PPPOE_IPV6(skb)) | ||
861 | pf = PF_INET6; | 865 | pf = PF_INET6; |
862 | else | 866 | else |
863 | return NF_ACCEPT; | 867 | return NF_ACCEPT; |
diff --git a/net/bridge/br_stp.c b/net/bridge/br_stp.c index 6751ed4e0c07..8c836d96ba76 100644 --- a/net/bridge/br_stp.c +++ b/net/bridge/br_stp.c | |||
@@ -31,7 +31,7 @@ static const char *const br_port_state_names[] = { | |||
31 | 31 | ||
32 | void br_log_state(const struct net_bridge_port *p) | 32 | void br_log_state(const struct net_bridge_port *p) |
33 | { | 33 | { |
34 | br_info(p->br, "port %u(%s) entering %s state\n", | 34 | br_info(p->br, "port %u(%s) entered %s state\n", |
35 | (unsigned) p->port_no, p->dev->name, | 35 | (unsigned) p->port_no, p->dev->name, |
36 | br_port_state_names[p->state]); | 36 | br_port_state_names[p->state]); |
37 | } | 37 | } |
diff --git a/net/bridge/br_stp_if.c b/net/bridge/br_stp_if.c index 19308e305d85..f494496373d6 100644 --- a/net/bridge/br_stp_if.c +++ b/net/bridge/br_stp_if.c | |||
@@ -98,14 +98,13 @@ void br_stp_disable_port(struct net_bridge_port *p) | |||
98 | struct net_bridge *br = p->br; | 98 | struct net_bridge *br = p->br; |
99 | int wasroot; | 99 | int wasroot; |
100 | 100 | ||
101 | br_log_state(p); | ||
102 | |||
103 | wasroot = br_is_root_bridge(br); | 101 | wasroot = br_is_root_bridge(br); |
104 | br_become_designated_port(p); | 102 | br_become_designated_port(p); |
105 | p->state = BR_STATE_DISABLED; | 103 | p->state = BR_STATE_DISABLED; |
106 | p->topology_change_ack = 0; | 104 | p->topology_change_ack = 0; |
107 | p->config_pending = 0; | 105 | p->config_pending = 0; |
108 | 106 | ||
107 | br_log_state(p); | ||
109 | br_ifinfo_notify(RTM_NEWLINK, p); | 108 | br_ifinfo_notify(RTM_NEWLINK, p); |
110 | 109 | ||
111 | del_timer(&p->message_age_timer); | 110 | del_timer(&p->message_age_timer); |
diff --git a/net/bridge/netfilter/ebtables.c b/net/bridge/netfilter/ebtables.c index 8aa4ad0e06af..5fe2ff3b01ef 100644 --- a/net/bridge/netfilter/ebtables.c +++ b/net/bridge/netfilter/ebtables.c | |||
@@ -1335,7 +1335,12 @@ static inline int ebt_make_matchname(const struct ebt_entry_match *m, | |||
1335 | const char *base, char __user *ubase) | 1335 | const char *base, char __user *ubase) |
1336 | { | 1336 | { |
1337 | char __user *hlp = ubase + ((char *)m - base); | 1337 | char __user *hlp = ubase + ((char *)m - base); |
1338 | if (copy_to_user(hlp, m->u.match->name, EBT_FUNCTION_MAXNAMELEN)) | 1338 | char name[EBT_FUNCTION_MAXNAMELEN] = {}; |
1339 | |||
1340 | /* ebtables expects 32 bytes long names but xt_match names are 29 bytes | ||
1341 | long. Copy 29 bytes and fill remaining bytes with zeroes. */ | ||
1342 | strncpy(name, m->u.match->name, sizeof(name)); | ||
1343 | if (copy_to_user(hlp, name, EBT_FUNCTION_MAXNAMELEN)) | ||
1339 | return -EFAULT; | 1344 | return -EFAULT; |
1340 | return 0; | 1345 | return 0; |
1341 | } | 1346 | } |
@@ -1344,7 +1349,10 @@ static inline int ebt_make_watchername(const struct ebt_entry_watcher *w, | |||
1344 | const char *base, char __user *ubase) | 1349 | const char *base, char __user *ubase) |
1345 | { | 1350 | { |
1346 | char __user *hlp = ubase + ((char *)w - base); | 1351 | char __user *hlp = ubase + ((char *)w - base); |
1347 | if (copy_to_user(hlp , w->u.watcher->name, EBT_FUNCTION_MAXNAMELEN)) | 1352 | char name[EBT_FUNCTION_MAXNAMELEN] = {}; |
1353 | |||
1354 | strncpy(name, w->u.watcher->name, sizeof(name)); | ||
1355 | if (copy_to_user(hlp , name, EBT_FUNCTION_MAXNAMELEN)) | ||
1348 | return -EFAULT; | 1356 | return -EFAULT; |
1349 | return 0; | 1357 | return 0; |
1350 | } | 1358 | } |
@@ -1355,6 +1363,7 @@ ebt_make_names(struct ebt_entry *e, const char *base, char __user *ubase) | |||
1355 | int ret; | 1363 | int ret; |
1356 | char __user *hlp; | 1364 | char __user *hlp; |
1357 | const struct ebt_entry_target *t; | 1365 | const struct ebt_entry_target *t; |
1366 | char name[EBT_FUNCTION_MAXNAMELEN] = {}; | ||
1358 | 1367 | ||
1359 | if (e->bitmask == 0) | 1368 | if (e->bitmask == 0) |
1360 | return 0; | 1369 | return 0; |
@@ -1368,7 +1377,8 @@ ebt_make_names(struct ebt_entry *e, const char *base, char __user *ubase) | |||
1368 | ret = EBT_WATCHER_ITERATE(e, ebt_make_watchername, base, ubase); | 1377 | ret = EBT_WATCHER_ITERATE(e, ebt_make_watchername, base, ubase); |
1369 | if (ret != 0) | 1378 | if (ret != 0) |
1370 | return ret; | 1379 | return ret; |
1371 | if (copy_to_user(hlp, t->u.target->name, EBT_FUNCTION_MAXNAMELEN)) | 1380 | strncpy(name, t->u.target->name, sizeof(name)); |
1381 | if (copy_to_user(hlp, name, EBT_FUNCTION_MAXNAMELEN)) | ||
1372 | return -EFAULT; | 1382 | return -EFAULT; |
1373 | return 0; | 1383 | return 0; |
1374 | } | 1384 | } |
diff --git a/net/ipv4/inetpeer.c b/net/ipv4/inetpeer.c index bf4a9c4808e1..d4d61b694fab 100644 --- a/net/ipv4/inetpeer.c +++ b/net/ipv4/inetpeer.c | |||
@@ -17,6 +17,7 @@ | |||
17 | #include <linux/kernel.h> | 17 | #include <linux/kernel.h> |
18 | #include <linux/mm.h> | 18 | #include <linux/mm.h> |
19 | #include <linux/net.h> | 19 | #include <linux/net.h> |
20 | #include <linux/workqueue.h> | ||
20 | #include <net/ip.h> | 21 | #include <net/ip.h> |
21 | #include <net/inetpeer.h> | 22 | #include <net/inetpeer.h> |
22 | #include <net/secure_seq.h> | 23 | #include <net/secure_seq.h> |
@@ -66,6 +67,11 @@ | |||
66 | 67 | ||
67 | static struct kmem_cache *peer_cachep __read_mostly; | 68 | static struct kmem_cache *peer_cachep __read_mostly; |
68 | 69 | ||
70 | static LIST_HEAD(gc_list); | ||
71 | static const int gc_delay = 60 * HZ; | ||
72 | static struct delayed_work gc_work; | ||
73 | static DEFINE_SPINLOCK(gc_lock); | ||
74 | |||
69 | #define node_height(x) x->avl_height | 75 | #define node_height(x) x->avl_height |
70 | 76 | ||
71 | #define peer_avl_empty ((struct inet_peer *)&peer_fake_node) | 77 | #define peer_avl_empty ((struct inet_peer *)&peer_fake_node) |
@@ -102,6 +108,50 @@ int inet_peer_threshold __read_mostly = 65536 + 128; /* start to throw entries m | |||
102 | int inet_peer_minttl __read_mostly = 120 * HZ; /* TTL under high load: 120 sec */ | 108 | int inet_peer_minttl __read_mostly = 120 * HZ; /* TTL under high load: 120 sec */ |
103 | int inet_peer_maxttl __read_mostly = 10 * 60 * HZ; /* usual time to live: 10 min */ | 109 | int inet_peer_maxttl __read_mostly = 10 * 60 * HZ; /* usual time to live: 10 min */ |
104 | 110 | ||
111 | static void inetpeer_gc_worker(struct work_struct *work) | ||
112 | { | ||
113 | struct inet_peer *p, *n; | ||
114 | LIST_HEAD(list); | ||
115 | |||
116 | spin_lock_bh(&gc_lock); | ||
117 | list_replace_init(&gc_list, &list); | ||
118 | spin_unlock_bh(&gc_lock); | ||
119 | |||
120 | if (list_empty(&list)) | ||
121 | return; | ||
122 | |||
123 | list_for_each_entry_safe(p, n, &list, gc_list) { | ||
124 | |||
125 | if(need_resched()) | ||
126 | cond_resched(); | ||
127 | |||
128 | if (p->avl_left != peer_avl_empty) { | ||
129 | list_add_tail(&p->avl_left->gc_list, &list); | ||
130 | p->avl_left = peer_avl_empty; | ||
131 | } | ||
132 | |||
133 | if (p->avl_right != peer_avl_empty) { | ||
134 | list_add_tail(&p->avl_right->gc_list, &list); | ||
135 | p->avl_right = peer_avl_empty; | ||
136 | } | ||
137 | |||
138 | n = list_entry(p->gc_list.next, struct inet_peer, gc_list); | ||
139 | |||
140 | if (!atomic_read(&p->refcnt)) { | ||
141 | list_del(&p->gc_list); | ||
142 | kmem_cache_free(peer_cachep, p); | ||
143 | } | ||
144 | } | ||
145 | |||
146 | if (list_empty(&list)) | ||
147 | return; | ||
148 | |||
149 | spin_lock_bh(&gc_lock); | ||
150 | list_splice(&list, &gc_list); | ||
151 | spin_unlock_bh(&gc_lock); | ||
152 | |||
153 | schedule_delayed_work(&gc_work, gc_delay); | ||
154 | } | ||
105 | 155 | ||
106 | /* Called from ip_output.c:ip_init */ | 156 | /* Called from ip_output.c:ip_init */ |
107 | void __init inet_initpeers(void) | 157 | void __init inet_initpeers(void) |
@@ -126,6 +176,7 @@ void __init inet_initpeers(void) | |||
126 | 0, SLAB_HWCACHE_ALIGN | SLAB_PANIC, | 176 | 0, SLAB_HWCACHE_ALIGN | SLAB_PANIC, |
127 | NULL); | 177 | NULL); |
128 | 178 | ||
179 | INIT_DELAYED_WORK_DEFERRABLE(&gc_work, inetpeer_gc_worker); | ||
129 | } | 180 | } |
130 | 181 | ||
131 | static int addr_compare(const struct inetpeer_addr *a, | 182 | static int addr_compare(const struct inetpeer_addr *a, |
@@ -447,9 +498,8 @@ relookup: | |||
447 | p->rate_last = 0; | 498 | p->rate_last = 0; |
448 | p->pmtu_expires = 0; | 499 | p->pmtu_expires = 0; |
449 | p->pmtu_orig = 0; | 500 | p->pmtu_orig = 0; |
450 | p->redirect_genid = 0; | ||
451 | memset(&p->redirect_learned, 0, sizeof(p->redirect_learned)); | 501 | memset(&p->redirect_learned, 0, sizeof(p->redirect_learned)); |
452 | 502 | INIT_LIST_HEAD(&p->gc_list); | |
453 | 503 | ||
454 | /* Link the node. */ | 504 | /* Link the node. */ |
455 | link_to_pool(p, base); | 505 | link_to_pool(p, base); |
@@ -509,3 +559,30 @@ bool inet_peer_xrlim_allow(struct inet_peer *peer, int timeout) | |||
509 | return rc; | 559 | return rc; |
510 | } | 560 | } |
511 | EXPORT_SYMBOL(inet_peer_xrlim_allow); | 561 | EXPORT_SYMBOL(inet_peer_xrlim_allow); |
562 | |||
563 | void inetpeer_invalidate_tree(int family) | ||
564 | { | ||
565 | struct inet_peer *old, *new, *prev; | ||
566 | struct inet_peer_base *base = family_to_base(family); | ||
567 | |||
568 | write_seqlock_bh(&base->lock); | ||
569 | |||
570 | old = base->root; | ||
571 | if (old == peer_avl_empty_rcu) | ||
572 | goto out; | ||
573 | |||
574 | new = peer_avl_empty_rcu; | ||
575 | |||
576 | prev = cmpxchg(&base->root, old, new); | ||
577 | if (prev == old) { | ||
578 | base->total = 0; | ||
579 | spin_lock(&gc_lock); | ||
580 | list_add_tail(&prev->gc_list, &gc_list); | ||
581 | spin_unlock(&gc_lock); | ||
582 | schedule_delayed_work(&gc_work, gc_delay); | ||
583 | } | ||
584 | |||
585 | out: | ||
586 | write_sequnlock_bh(&base->lock); | ||
587 | } | ||
588 | EXPORT_SYMBOL(inetpeer_invalidate_tree); | ||
diff --git a/net/ipv4/route.c b/net/ipv4/route.c index 0489cedc1671..815989b90dea 100644 --- a/net/ipv4/route.c +++ b/net/ipv4/route.c | |||
@@ -132,7 +132,6 @@ static int ip_rt_mtu_expires __read_mostly = 10 * 60 * HZ; | |||
132 | static int ip_rt_min_pmtu __read_mostly = 512 + 20 + 20; | 132 | static int ip_rt_min_pmtu __read_mostly = 512 + 20 + 20; |
133 | static int ip_rt_min_advmss __read_mostly = 256; | 133 | static int ip_rt_min_advmss __read_mostly = 256; |
134 | static int rt_chain_length_max __read_mostly = 20; | 134 | static int rt_chain_length_max __read_mostly = 20; |
135 | static int redirect_genid; | ||
136 | 135 | ||
137 | static struct delayed_work expires_work; | 136 | static struct delayed_work expires_work; |
138 | static unsigned long expires_ljiffies; | 137 | static unsigned long expires_ljiffies; |
@@ -937,7 +936,7 @@ static void rt_cache_invalidate(struct net *net) | |||
937 | 936 | ||
938 | get_random_bytes(&shuffle, sizeof(shuffle)); | 937 | get_random_bytes(&shuffle, sizeof(shuffle)); |
939 | atomic_add(shuffle + 1U, &net->ipv4.rt_genid); | 938 | atomic_add(shuffle + 1U, &net->ipv4.rt_genid); |
940 | redirect_genid++; | 939 | inetpeer_invalidate_tree(AF_INET); |
941 | } | 940 | } |
942 | 941 | ||
943 | /* | 942 | /* |
@@ -1490,10 +1489,8 @@ void ip_rt_redirect(__be32 old_gw, __be32 daddr, __be32 new_gw, | |||
1490 | 1489 | ||
1491 | peer = rt->peer; | 1490 | peer = rt->peer; |
1492 | if (peer) { | 1491 | if (peer) { |
1493 | if (peer->redirect_learned.a4 != new_gw || | 1492 | if (peer->redirect_learned.a4 != new_gw) { |
1494 | peer->redirect_genid != redirect_genid) { | ||
1495 | peer->redirect_learned.a4 = new_gw; | 1493 | peer->redirect_learned.a4 = new_gw; |
1496 | peer->redirect_genid = redirect_genid; | ||
1497 | atomic_inc(&__rt_peer_genid); | 1494 | atomic_inc(&__rt_peer_genid); |
1498 | } | 1495 | } |
1499 | check_peer_redir(&rt->dst, peer); | 1496 | check_peer_redir(&rt->dst, peer); |
@@ -1798,8 +1795,6 @@ static void ipv4_validate_peer(struct rtable *rt) | |||
1798 | if (peer) { | 1795 | if (peer) { |
1799 | check_peer_pmtu(&rt->dst, peer); | 1796 | check_peer_pmtu(&rt->dst, peer); |
1800 | 1797 | ||
1801 | if (peer->redirect_genid != redirect_genid) | ||
1802 | peer->redirect_learned.a4 = 0; | ||
1803 | if (peer->redirect_learned.a4 && | 1798 | if (peer->redirect_learned.a4 && |
1804 | peer->redirect_learned.a4 != rt->rt_gateway) | 1799 | peer->redirect_learned.a4 != rt->rt_gateway) |
1805 | check_peer_redir(&rt->dst, peer); | 1800 | check_peer_redir(&rt->dst, peer); |
@@ -1963,8 +1958,7 @@ static void rt_init_metrics(struct rtable *rt, const struct flowi4 *fl4, | |||
1963 | dst_init_metrics(&rt->dst, peer->metrics, false); | 1958 | dst_init_metrics(&rt->dst, peer->metrics, false); |
1964 | 1959 | ||
1965 | check_peer_pmtu(&rt->dst, peer); | 1960 | check_peer_pmtu(&rt->dst, peer); |
1966 | if (peer->redirect_genid != redirect_genid) | 1961 | |
1967 | peer->redirect_learned.a4 = 0; | ||
1968 | if (peer->redirect_learned.a4 && | 1962 | if (peer->redirect_learned.a4 && |
1969 | peer->redirect_learned.a4 != rt->rt_gateway) { | 1963 | peer->redirect_learned.a4 != rt->rt_gateway) { |
1970 | rt->rt_gateway = peer->redirect_learned.a4; | 1964 | rt->rt_gateway = peer->redirect_learned.a4; |
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index d9b83d198c3d..b5e315f13641 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -1585,6 +1585,10 @@ static struct sk_buff *tcp_shift_skb_data(struct sock *sk, struct sk_buff *skb, | |||
1585 | } | 1585 | } |
1586 | } | 1586 | } |
1587 | 1587 | ||
1588 | /* tcp_sacktag_one() won't SACK-tag ranges below snd_una */ | ||
1589 | if (!after(TCP_SKB_CB(skb)->seq + len, tp->snd_una)) | ||
1590 | goto fallback; | ||
1591 | |||
1588 | if (!skb_shift(prev, skb, len)) | 1592 | if (!skb_shift(prev, skb, len)) |
1589 | goto fallback; | 1593 | goto fallback; |
1590 | if (!tcp_shifted_skb(sk, skb, state, pcount, len, mss, dup_sack)) | 1594 | if (!tcp_shifted_skb(sk, skb, state, pcount, len, mss, dup_sack)) |
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index c02280a4d126..6b8ebc5da0e1 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
@@ -434,6 +434,10 @@ static struct inet6_dev * ipv6_add_dev(struct net_device *dev) | |||
434 | /* Join all-node multicast group */ | 434 | /* Join all-node multicast group */ |
435 | ipv6_dev_mc_inc(dev, &in6addr_linklocal_allnodes); | 435 | ipv6_dev_mc_inc(dev, &in6addr_linklocal_allnodes); |
436 | 436 | ||
437 | /* Join all-router multicast group if forwarding is set */ | ||
438 | if (ndev->cnf.forwarding && dev && (dev->flags & IFF_MULTICAST)) | ||
439 | ipv6_dev_mc_inc(dev, &in6addr_linklocal_allrouters); | ||
440 | |||
437 | return ndev; | 441 | return ndev; |
438 | } | 442 | } |
439 | 443 | ||
diff --git a/net/netfilter/nf_conntrack_core.c b/net/netfilter/nf_conntrack_core.c index 81e2aa4ca1fe..7b48035826ee 100644 --- a/net/netfilter/nf_conntrack_core.c +++ b/net/netfilter/nf_conntrack_core.c | |||
@@ -636,8 +636,12 @@ static noinline int early_drop(struct net *net, unsigned int hash) | |||
636 | 636 | ||
637 | if (del_timer(&ct->timeout)) { | 637 | if (del_timer(&ct->timeout)) { |
638 | death_by_timeout((unsigned long)ct); | 638 | death_by_timeout((unsigned long)ct); |
639 | dropped = 1; | 639 | /* Check if we indeed killed this entry. Reliable event |
640 | NF_CT_STAT_INC_ATOMIC(net, early_drop); | 640 | delivery may have inserted it into the dying list. */ |
641 | if (test_bit(IPS_DYING_BIT, &ct->status)) { | ||
642 | dropped = 1; | ||
643 | NF_CT_STAT_INC_ATOMIC(net, early_drop); | ||
644 | } | ||
641 | } | 645 | } |
642 | nf_ct_put(ct); | 646 | nf_ct_put(ct); |
643 | return dropped; | 647 | return dropped; |
diff --git a/net/netfilter/nf_conntrack_netlink.c b/net/netfilter/nf_conntrack_netlink.c index c1ea64c6c70d..2124977ac31d 100644 --- a/net/netfilter/nf_conntrack_netlink.c +++ b/net/netfilter/nf_conntrack_netlink.c | |||
@@ -1084,16 +1084,13 @@ ctnetlink_parse_nat_setup(struct nf_conn *ct, | |||
1084 | if (!parse_nat_setup) { | 1084 | if (!parse_nat_setup) { |
1085 | #ifdef CONFIG_MODULES | 1085 | #ifdef CONFIG_MODULES |
1086 | rcu_read_unlock(); | 1086 | rcu_read_unlock(); |
1087 | spin_unlock_bh(&nf_conntrack_lock); | ||
1088 | nfnl_unlock(); | 1087 | nfnl_unlock(); |
1089 | if (request_module("nf-nat-ipv4") < 0) { | 1088 | if (request_module("nf-nat-ipv4") < 0) { |
1090 | nfnl_lock(); | 1089 | nfnl_lock(); |
1091 | spin_lock_bh(&nf_conntrack_lock); | ||
1092 | rcu_read_lock(); | 1090 | rcu_read_lock(); |
1093 | return -EOPNOTSUPP; | 1091 | return -EOPNOTSUPP; |
1094 | } | 1092 | } |
1095 | nfnl_lock(); | 1093 | nfnl_lock(); |
1096 | spin_lock_bh(&nf_conntrack_lock); | ||
1097 | rcu_read_lock(); | 1094 | rcu_read_lock(); |
1098 | if (nfnetlink_parse_nat_setup_hook) | 1095 | if (nfnetlink_parse_nat_setup_hook) |
1099 | return -EAGAIN; | 1096 | return -EAGAIN; |
diff --git a/net/openvswitch/actions.c b/net/openvswitch/actions.c index 2725d1bdf291..48badffaafc1 100644 --- a/net/openvswitch/actions.c +++ b/net/openvswitch/actions.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2007-2011 Nicira Networks. | 2 | * Copyright (c) 2007-2012 Nicira Networks. |
3 | * | 3 | * |
4 | * This program is free software; you can redistribute it and/or | 4 | * This program is free software; you can redistribute it and/or |
5 | * modify it under the terms of version 2 of the GNU General Public | 5 | * modify it under the terms of version 2 of the GNU General Public |
@@ -145,9 +145,16 @@ static void set_ip_addr(struct sk_buff *skb, struct iphdr *nh, | |||
145 | inet_proto_csum_replace4(&tcp_hdr(skb)->check, skb, | 145 | inet_proto_csum_replace4(&tcp_hdr(skb)->check, skb, |
146 | *addr, new_addr, 1); | 146 | *addr, new_addr, 1); |
147 | } else if (nh->protocol == IPPROTO_UDP) { | 147 | } else if (nh->protocol == IPPROTO_UDP) { |
148 | if (likely(transport_len >= sizeof(struct udphdr))) | 148 | if (likely(transport_len >= sizeof(struct udphdr))) { |
149 | inet_proto_csum_replace4(&udp_hdr(skb)->check, skb, | 149 | struct udphdr *uh = udp_hdr(skb); |
150 | *addr, new_addr, 1); | 150 | |
151 | if (uh->check || skb->ip_summed == CHECKSUM_PARTIAL) { | ||
152 | inet_proto_csum_replace4(&uh->check, skb, | ||
153 | *addr, new_addr, 1); | ||
154 | if (!uh->check) | ||
155 | uh->check = CSUM_MANGLED_0; | ||
156 | } | ||
157 | } | ||
151 | } | 158 | } |
152 | 159 | ||
153 | csum_replace4(&nh->check, *addr, new_addr); | 160 | csum_replace4(&nh->check, *addr, new_addr); |
@@ -197,8 +204,22 @@ static void set_tp_port(struct sk_buff *skb, __be16 *port, | |||
197 | skb->rxhash = 0; | 204 | skb->rxhash = 0; |
198 | } | 205 | } |
199 | 206 | ||
200 | static int set_udp_port(struct sk_buff *skb, | 207 | static void set_udp_port(struct sk_buff *skb, __be16 *port, __be16 new_port) |
201 | const struct ovs_key_udp *udp_port_key) | 208 | { |
209 | struct udphdr *uh = udp_hdr(skb); | ||
210 | |||
211 | if (uh->check && skb->ip_summed != CHECKSUM_PARTIAL) { | ||
212 | set_tp_port(skb, port, new_port, &uh->check); | ||
213 | |||
214 | if (!uh->check) | ||
215 | uh->check = CSUM_MANGLED_0; | ||
216 | } else { | ||
217 | *port = new_port; | ||
218 | skb->rxhash = 0; | ||
219 | } | ||
220 | } | ||
221 | |||
222 | static int set_udp(struct sk_buff *skb, const struct ovs_key_udp *udp_port_key) | ||
202 | { | 223 | { |
203 | struct udphdr *uh; | 224 | struct udphdr *uh; |
204 | int err; | 225 | int err; |
@@ -210,16 +231,15 @@ static int set_udp_port(struct sk_buff *skb, | |||
210 | 231 | ||
211 | uh = udp_hdr(skb); | 232 | uh = udp_hdr(skb); |
212 | if (udp_port_key->udp_src != uh->source) | 233 | if (udp_port_key->udp_src != uh->source) |
213 | set_tp_port(skb, &uh->source, udp_port_key->udp_src, &uh->check); | 234 | set_udp_port(skb, &uh->source, udp_port_key->udp_src); |
214 | 235 | ||
215 | if (udp_port_key->udp_dst != uh->dest) | 236 | if (udp_port_key->udp_dst != uh->dest) |
216 | set_tp_port(skb, &uh->dest, udp_port_key->udp_dst, &uh->check); | 237 | set_udp_port(skb, &uh->dest, udp_port_key->udp_dst); |
217 | 238 | ||
218 | return 0; | 239 | return 0; |
219 | } | 240 | } |
220 | 241 | ||
221 | static int set_tcp_port(struct sk_buff *skb, | 242 | static int set_tcp(struct sk_buff *skb, const struct ovs_key_tcp *tcp_port_key) |
222 | const struct ovs_key_tcp *tcp_port_key) | ||
223 | { | 243 | { |
224 | struct tcphdr *th; | 244 | struct tcphdr *th; |
225 | int err; | 245 | int err; |
@@ -328,11 +348,11 @@ static int execute_set_action(struct sk_buff *skb, | |||
328 | break; | 348 | break; |
329 | 349 | ||
330 | case OVS_KEY_ATTR_TCP: | 350 | case OVS_KEY_ATTR_TCP: |
331 | err = set_tcp_port(skb, nla_data(nested_attr)); | 351 | err = set_tcp(skb, nla_data(nested_attr)); |
332 | break; | 352 | break; |
333 | 353 | ||
334 | case OVS_KEY_ATTR_UDP: | 354 | case OVS_KEY_ATTR_UDP: |
335 | err = set_udp_port(skb, nla_data(nested_attr)); | 355 | err = set_udp(skb, nla_data(nested_attr)); |
336 | break; | 356 | break; |
337 | } | 357 | } |
338 | 358 | ||
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c index ce64c18b8c79..2c030505b335 100644 --- a/net/openvswitch/datapath.c +++ b/net/openvswitch/datapath.c | |||
@@ -1521,6 +1521,9 @@ static struct vport *lookup_vport(struct ovs_header *ovs_header, | |||
1521 | vport = ovs_vport_locate(nla_data(a[OVS_VPORT_ATTR_NAME])); | 1521 | vport = ovs_vport_locate(nla_data(a[OVS_VPORT_ATTR_NAME])); |
1522 | if (!vport) | 1522 | if (!vport) |
1523 | return ERR_PTR(-ENODEV); | 1523 | return ERR_PTR(-ENODEV); |
1524 | if (ovs_header->dp_ifindex && | ||
1525 | ovs_header->dp_ifindex != get_dpifindex(vport->dp)) | ||
1526 | return ERR_PTR(-ENODEV); | ||
1524 | return vport; | 1527 | return vport; |
1525 | } else if (a[OVS_VPORT_ATTR_PORT_NO]) { | 1528 | } else if (a[OVS_VPORT_ATTR_PORT_NO]) { |
1526 | u32 port_no = nla_get_u32(a[OVS_VPORT_ATTR_PORT_NO]); | 1529 | u32 port_no = nla_get_u32(a[OVS_VPORT_ATTR_PORT_NO]); |
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index f286bb8fda13..22c73b78ac6f 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -2068,12 +2068,16 @@ static int alc_build_controls(struct hda_codec *codec) | |||
2068 | */ | 2068 | */ |
2069 | 2069 | ||
2070 | static void alc_init_special_input_src(struct hda_codec *codec); | 2070 | static void alc_init_special_input_src(struct hda_codec *codec); |
2071 | static int alc269_fill_coef(struct hda_codec *codec); | ||
2071 | 2072 | ||
2072 | static int alc_init(struct hda_codec *codec) | 2073 | static int alc_init(struct hda_codec *codec) |
2073 | { | 2074 | { |
2074 | struct alc_spec *spec = codec->spec; | 2075 | struct alc_spec *spec = codec->spec; |
2075 | unsigned int i; | 2076 | unsigned int i; |
2076 | 2077 | ||
2078 | if (codec->vendor_id == 0x10ec0269) | ||
2079 | alc269_fill_coef(codec); | ||
2080 | |||
2077 | alc_fix_pll(codec); | 2081 | alc_fix_pll(codec); |
2078 | alc_auto_init_amp(codec, spec->init_amp); | 2082 | alc_auto_init_amp(codec, spec->init_amp); |
2079 | 2083 | ||
@@ -4367,6 +4371,7 @@ enum { | |||
4367 | ALC882_FIXUP_PB_M5210, | 4371 | ALC882_FIXUP_PB_M5210, |
4368 | ALC882_FIXUP_ACER_ASPIRE_7736, | 4372 | ALC882_FIXUP_ACER_ASPIRE_7736, |
4369 | ALC882_FIXUP_ASUS_W90V, | 4373 | ALC882_FIXUP_ASUS_W90V, |
4374 | ALC889_FIXUP_CD, | ||
4370 | ALC889_FIXUP_VAIO_TT, | 4375 | ALC889_FIXUP_VAIO_TT, |
4371 | ALC888_FIXUP_EEE1601, | 4376 | ALC888_FIXUP_EEE1601, |
4372 | ALC882_FIXUP_EAPD, | 4377 | ALC882_FIXUP_EAPD, |
@@ -4494,6 +4499,13 @@ static const struct alc_fixup alc882_fixups[] = { | |||
4494 | { } | 4499 | { } |
4495 | } | 4500 | } |
4496 | }, | 4501 | }, |
4502 | [ALC889_FIXUP_CD] = { | ||
4503 | .type = ALC_FIXUP_PINS, | ||
4504 | .v.pins = (const struct alc_pincfg[]) { | ||
4505 | { 0x1c, 0x993301f0 }, /* CD */ | ||
4506 | { } | ||
4507 | } | ||
4508 | }, | ||
4497 | [ALC889_FIXUP_VAIO_TT] = { | 4509 | [ALC889_FIXUP_VAIO_TT] = { |
4498 | .type = ALC_FIXUP_PINS, | 4510 | .type = ALC_FIXUP_PINS, |
4499 | .v.pins = (const struct alc_pincfg[]) { | 4511 | .v.pins = (const struct alc_pincfg[]) { |
@@ -4650,6 +4662,7 @@ static const struct snd_pci_quirk alc882_fixup_tbl[] = { | |||
4650 | 4662 | ||
4651 | SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD), | 4663 | SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD), |
4652 | SND_PCI_QUIRK_VENDOR(0x1462, "MSI", ALC882_FIXUP_GPIO3), | 4664 | SND_PCI_QUIRK_VENDOR(0x1462, "MSI", ALC882_FIXUP_GPIO3), |
4665 | SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3", ALC889_FIXUP_CD), | ||
4653 | SND_PCI_QUIRK(0x147b, 0x107a, "Abit AW9D-MAX", ALC882_FIXUP_ABIT_AW9D_MAX), | 4666 | SND_PCI_QUIRK(0x147b, 0x107a, "Abit AW9D-MAX", ALC882_FIXUP_ABIT_AW9D_MAX), |
4654 | SND_PCI_QUIRK_VENDOR(0x1558, "Clevo laptop", ALC882_FIXUP_EAPD), | 4667 | SND_PCI_QUIRK_VENDOR(0x1558, "Clevo laptop", ALC882_FIXUP_EAPD), |
4655 | SND_PCI_QUIRK(0x161f, 0x2054, "Medion laptop", ALC883_FIXUP_EAPD), | 4668 | SND_PCI_QUIRK(0x161f, 0x2054, "Medion laptop", ALC883_FIXUP_EAPD), |
@@ -5467,8 +5480,12 @@ static const struct alc_model_fixup alc269_fixup_models[] = { | |||
5467 | 5480 | ||
5468 | static int alc269_fill_coef(struct hda_codec *codec) | 5481 | static int alc269_fill_coef(struct hda_codec *codec) |
5469 | { | 5482 | { |
5483 | struct alc_spec *spec = codec->spec; | ||
5470 | int val; | 5484 | int val; |
5471 | 5485 | ||
5486 | if (spec->codec_variant != ALC269_TYPE_ALC269VB) | ||
5487 | return 0; | ||
5488 | |||
5472 | if ((alc_get_coef0(codec) & 0x00ff) < 0x015) { | 5489 | if ((alc_get_coef0(codec) & 0x00ff) < 0x015) { |
5473 | alc_write_coef_idx(codec, 0xf, 0x960b); | 5490 | alc_write_coef_idx(codec, 0xf, 0x960b); |
5474 | alc_write_coef_idx(codec, 0xe, 0x8817); | 5491 | alc_write_coef_idx(codec, 0xe, 0x8817); |
diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c index cc9f6c83d661..bc030a2088da 100644 --- a/sound/pci/rme9652/hdspm.c +++ b/sound/pci/rme9652/hdspm.c | |||
@@ -6333,6 +6333,7 @@ static int __devinit snd_hdspm_create_hwdep(struct snd_card *card, | |||
6333 | 6333 | ||
6334 | hw->ops.open = snd_hdspm_hwdep_dummy_op; | 6334 | hw->ops.open = snd_hdspm_hwdep_dummy_op; |
6335 | hw->ops.ioctl = snd_hdspm_hwdep_ioctl; | 6335 | hw->ops.ioctl = snd_hdspm_hwdep_ioctl; |
6336 | hw->ops.ioctl_compat = snd_hdspm_hwdep_ioctl; | ||
6336 | hw->ops.release = snd_hdspm_hwdep_dummy_op; | 6337 | hw->ops.release = snd_hdspm_hwdep_dummy_op; |
6337 | 6338 | ||
6338 | return 0; | 6339 | return 0; |
diff --git a/sound/soc/samsung/neo1973_wm8753.c b/sound/soc/samsung/neo1973_wm8753.c index c6012ff5bd3e..d23b19a59d83 100644 --- a/sound/soc/samsung/neo1973_wm8753.c +++ b/sound/soc/samsung/neo1973_wm8753.c | |||
@@ -367,7 +367,7 @@ static struct snd_soc_dai_link neo1973_dai[] = { | |||
367 | .platform_name = "samsung-audio", | 367 | .platform_name = "samsung-audio", |
368 | .cpu_dai_name = "s3c24xx-iis", | 368 | .cpu_dai_name = "s3c24xx-iis", |
369 | .codec_dai_name = "wm8753-hifi", | 369 | .codec_dai_name = "wm8753-hifi", |
370 | .codec_name = "wm8753-codec.0-001a", | 370 | .codec_name = "wm8753.0-001a", |
371 | .init = neo1973_wm8753_init, | 371 | .init = neo1973_wm8753_init, |
372 | .ops = &neo1973_hifi_ops, | 372 | .ops = &neo1973_hifi_ops, |
373 | }, | 373 | }, |
@@ -376,7 +376,7 @@ static struct snd_soc_dai_link neo1973_dai[] = { | |||
376 | .stream_name = "Voice", | 376 | .stream_name = "Voice", |
377 | .cpu_dai_name = "dfbmcs320-pcm", | 377 | .cpu_dai_name = "dfbmcs320-pcm", |
378 | .codec_dai_name = "wm8753-voice", | 378 | .codec_dai_name = "wm8753-voice", |
379 | .codec_name = "wm8753-codec.0-001a", | 379 | .codec_name = "wm8753.0-001a", |
380 | .ops = &neo1973_voice_ops, | 380 | .ops = &neo1973_voice_ops, |
381 | }, | 381 | }, |
382 | }; | 382 | }; |