History

Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus

Pull more MIPS updates from Ralf Baechle: "This is the secondnd batch of MIPS patches for 4.7. Summary: CPS: - Copy EVA configuration when starting secondary VPs. EIC: - Clear Status IPL. Lasat: - Fix a few off by one bugs. lib: - Mark intrinsics notrace. Not only are the intrinsics uninteresting, it would cause infinite recursion. MAINTAINERS: - Add file patterns for MIPS BRCM device tree bindings. - Add file patterns for mips device tree bindings. MT7628: - Fix MT7628 pinmux typos. - wled_an pinmux gpio. - EPHY LEDs pinmux support. Pistachio: - Enable KASLR VDSO: - Build microMIPS VDSO for microMIPS kernels. - Fix aliasing warning by building with `-fno-strict-aliasing' for debugging but also tracing them might result in recursion. Misc: - Add missing FROZEN hotplug notifier transitions. - Fix clk binding example for varioius PIC32 devices. - Fix cpu interrupt controller node-names in the DT files. - Fix XPA CPU feature separation. - Fix write_gc0_* macros when writing zero. - Add inline asm encoding helpers. - Add missing VZ accessor microMIPS encodings. - Fix little endian microMIPS MSA encodings. - Add 64-bit HTW fields and fix its configuration. - Fix sigreturn via VDSO on microMIPS kernel. - Lots of typo fixes. - Add definitions of SegCtl registers and use them" * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (49 commits) MIPS: Add missing FROZEN hotplug notifier transitions MIPS: Build microMIPS VDSO for microMIPS kernels MIPS: Fix sigreturn via VDSO on microMIPS kernel MIPS: devicetree: fix cpu interrupt controller node-names MIPS: VDSO: Build with `-fno-strict-aliasing' MIPS: Pistachio: Enable KASLR MIPS: lib: Mark intrinsics notrace MIPS: Fix 64-bit HTW configuration MIPS: Add 64-bit HTW fields MAINTAINERS: Add file patterns for mips device tree bindings MAINTAINERS: Add file patterns for mips brcm device tree bindings MIPS: Simplify DSP instruction encoding macros MIPS: Add missing tlbinvf/XPA microMIPS encodings MIPS: Fix little endian microMIPS MSA encodings MIPS: Add missing VZ accessor microMIPS encodings MIPS: Add inline asm encoding helpers MIPS: Spelling fix lets -> let's MIPS: VR41xx: Fix typo MIPS: oprofile: Fix typo MIPS: math-emu: Fix typo ...

Linus Torvalds committed 10 years ago

Commit 40296322 parents d66492b a8c5ddf67 files · +373 −258Browse files

Unified · Split

67 files
  1. Documentation/devicetree/bindings/gpio/microchip,pic32-gpio.txt +1 −1
  2. Documentation/devicetree/bindings/mips/cpu_irq.txt +1 −1
  3. Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.txt +1 −1
  4. Documentation/devicetree/bindings/pinctrl/microchip,pic32-pinctrl.txt +1 −1
  5. Documentation/devicetree/bindings/serial/microchip,pic32-uart.txt +1 −1
  6. Documentation/devicetree/bindings/watchdog/microchip,pic32-dmt.txt +2 −2
  7. Documentation/devicetree/bindings/watchdog/microchip,pic32-wdt.txt +2 −2
  8. MAINTAINERS +2 −0
  9. arch/mips/Kconfig +1 −0
  10. arch/mips/boot/dts/ingenic/jz4740.dtsi +1 −1
  11. arch/mips/boot/dts/ralink/mt7620a.dtsi +1 −1
  12. arch/mips/boot/dts/ralink/rt2880.dtsi +1 −1
  13. arch/mips/boot/dts/ralink/rt3050.dtsi +1 −1
  14. arch/mips/boot/dts/ralink/rt3883.dtsi +1 −1
  15. arch/mips/boot/dts/xilfpga/nexys4ddr.dts +1 −1
  16. arch/mips/cavium-octeon/smp.c +1 −1
  17. arch/mips/include/asm/asmmacro.h +50 −49
  18. arch/mips/include/asm/hazards.h +4 −4
  19. arch/mips/include/asm/mach-au1x00/au1xxx_dbdma.h +1 −1
  20. arch/mips/include/asm/mach-au1x00/gpio-au1300.h +1 −1
  21. arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_enet.h +1 −1
  22. arch/mips/include/asm/mach-ip27/dma-coherence.h +1 −1
  23. arch/mips/include/asm/mach-ip32/dma-coherence.h +1 −1
  24. arch/mips/include/asm/mach-lantiq/falcon/lantiq_soc.h +1 −1
  25. arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h +1 −1
  26. arch/mips/include/asm/mach-loongson64/loongson_hwmon.h +1 −1
  27. arch/mips/include/asm/mach-malta/kernel-entry-init.h +3 −3
  28. arch/mips/include/asm/mips_mt.h +1 −1
  29. arch/mips/include/asm/mipsregs.h +82 −106
  30. arch/mips/include/asm/msa.h +8 −13
  31. arch/mips/include/asm/octeon/cvmx-cmd-queue.h +1 −1
  32. arch/mips/include/asm/octeon/cvmx-helper-board.h +1 −1
  33. arch/mips/include/asm/octeon/cvmx-ipd.h +1 −1
  34. arch/mips/include/asm/octeon/cvmx-pow.h +1 −1
  35. arch/mips/include/asm/sgi/hpc3.h +1 −1
  36. arch/mips/kernel/branch.c +2 −2
  37. arch/mips/kernel/cps-vec.S +15 −0
  38. arch/mips/kernel/cpu-probe.c +1 −3
  39. arch/mips/kernel/elf.c +1 −1
  40. arch/mips/kernel/irq.c +3 −0
  41. arch/mips/kernel/mips-r2-to-r6-emul.c +1 −1
  42. arch/mips/kernel/process.c +1 −1
  43. arch/mips/kernel/signal.c +0 −8
  44. arch/mips/kernel/smp-cps.c +6 −2
  45. arch/mips/lasat/picvue_proc.c +2 −2
  46. arch/mips/lib/ashldi3.c +1 −1
  47. arch/mips/lib/ashrdi3.c +1 −1
  48. arch/mips/lib/bswapdi.c +1 −1
  49. arch/mips/lib/bswapsi.c +1 −1
  50. arch/mips/lib/cmpdi2.c +1 −1
  51. arch/mips/lib/lshrdi3.c +1 −1
  52. arch/mips/lib/memcpy.S +1 −1
  53. arch/mips/lib/ucmpdi2.c +1 −1
  54. arch/mips/loongson64/loongson-3/hpet.c +1 −1
  55. arch/mips/math-emu/dsemul.c +2 −2
  56. arch/mips/mm/tlbex.c +18 −4
  57. arch/mips/oprofile/op_impl.h +1 −1
  58. arch/mips/pci/ops-bridge.c +2 −2
  59. arch/mips/pistachio/init.c +6 −2
  60. arch/mips/ralink/mt7620.c +106 −6
  61. arch/mips/sgi-ip27/ip27-hubio.c +1 −1
  62. arch/mips/sgi-ip27/ip27-nmi.c +1 −1
  63. arch/mips/sgi-ip27/ip27-xtalk.c +1 −1
  64. arch/mips/sni/rm200.c +1 −1
  65. arch/mips/vdso/Makefile +3 −1
  66. arch/mips/vr41xx/common/cmu.c +1 −1
  67. drivers/irqchip/irq-mips-gic.c +9 −1
Documentation/devicetree/bindings/gpio/microchip,pic32-gpio.txt+1−1
@@ -33,7 +33,7 @@ gpio0: gpio0@1f860000 { · 32 unmodified lines
3333 gpio-controller;
3434 interrupt-controller;
3535 #interrupt-cells = <2>;
36− clocks = <&PBCLK4>;
36+ clocks = <&rootclk PB4CLK>;
3737 microchip,gpio-bank = <0>;
3838 gpio-ranges = <&pic32_pinctrl 0 0 16>;
3939 };
Documentation/devicetree/bindings/mips/cpu_irq.txt+1−1
@@ -13,7 +13,7 @@ Required properties: · 12 unmodified lines
1313 - compatible : Should be "mti,cpu-interrupt-controller"
1414
1515 Example devicetree:
16− cpu-irq: cpu-irq@0 {
16+ cpu-irq: cpu-irq {
1717 #address-cells = <0>;
1818
1919 interrupt-controller;
Documentation/devicetree/bindings/mmc/microchip,sdhci-pic32.txt+1−1
@@ -20,7 +20,7 @@ Example: · 19 unmodified lines
2020 compatible = "microchip,pic32mzda-sdhci";
2121 reg = <0x1f8ec000 0x100>;
2222 interrupts = <191 IRQ_TYPE_LEVEL_HIGH>;
23− clocks = <&REFCLKO4>, <&PBCLK5>;
23+ clocks = <&rootclk REF4CLK>, <&rootclk PB5CLK>;
2424 clock-names = "base_clk", "sys_clk";
2525 bus-width = <4>;
2626 cap-sd-highspeed;
Documentation/devicetree/bindings/pinctrl/microchip,pic32-pinctrl.txt+1−1
@@ -34,7 +34,7 @@ pic32_pinctrl: pinctrl@1f801400{ · 33 unmodified lines
3434 #size-cells = <1>;
3535 compatible = "microchip,pic32mzda-pinctrl";
3636 reg = <0x1f801400 0x400>;
37− clocks = <&PBCLK1>;
37+ clocks = <&rootclk PB1CLK>;
3838
3939 pinctrl_uart2: pinctrl_uart2 {
4040 uart2-tx {
Documentation/devicetree/bindings/serial/microchip,pic32-uart.txt+1−1
@@ -20,7 +20,7 @@ Example: · 19 unmodified lines
2020 interrupts = <112 IRQ_TYPE_LEVEL_HIGH>,
2121 <113 IRQ_TYPE_LEVEL_HIGH>,
2222 <114 IRQ_TYPE_LEVEL_HIGH>;
23− clocks = <&PBCLK2>;
23+ clocks = <&rootclk PB2CLK>;
2424 pinctrl-names = "default";
2525 pinctrl-0 = <&pinctrl_uart1
2626 &pinctrl_uart1_cts
Documentation/devicetree/bindings/watchdog/microchip,pic32-dmt.txt+2−2
@@ -8,12 +8,12 @@ Required properties: · 7 unmodified lines
88 - compatible: must be "microchip,pic32mzda-dmt".
99 - reg: physical base address of the controller and length of memory mapped
1010 region.
11−- clocks: phandle of parent clock (should be &PBCLK7).
11+- clocks: phandle of source clk. Should be <&rootclk PB7CLK>.
1212
1313 Example:
1414
1515 watchdog@1f800a00 {
1616 compatible = "microchip,pic32mzda-dmt";
1717 reg = <0x1f800a00 0x80>;
18− clocks = <&PBCLK7>;
18+ clocks = <&rootclk PB7CLK>;
1919 };
Documentation/devicetree/bindings/watchdog/microchip,pic32-wdt.txt+2−2
@@ -7,12 +7,12 @@ Required properties: · 6 unmodified lines
77 - compatible: must be "microchip,pic32mzda-wdt".
88 - reg: physical base address of the controller and length of memory mapped
99 region.
10−- clocks: phandle of source clk. should be <&LPRC> clk.
10+- clocks: phandle of source clk. Should be <&rootclk LPRCCLK>.
1111
1212 Example:
1313
1414 watchdog@1f800800 {
1515 compatible = "microchip,pic32mzda-wdt";
1616 reg = <0x1f800800 0x200>;
17− clocks = <&LPRC>;
17+ clocks = <&rootclk LPRCCLK>;
1818 };
MAINTAINERS+2−0
@@ -2505,6 +2505,7 @@ M: Hauke Mehrtens <hauke@hauke-m.de> · 2504 unmodified lines
25052505 M: Rafał Miłecki <zajec5@gmail.com>
25062506 L: linux-mips@linux-mips.org
25072507 S: Maintained
2508+F: Documentation/devicetree/bindings/mips/brcm/
25082509 F: arch/mips/bcm47xx/*
25092510 F: arch/mips/include/asm/mach-bcm47xx/*
25102511
@@ -7521,6 +7522,7 @@ W: http://www.linux-mips.org/ · 5010 unmodified lines
75217522 T: git git://git.linux-mips.org/pub/scm/ralf/linux.git
75227523 Q: http://patchwork.linux-mips.org/project/linux-mips/list/
75237524 S: Supported
7525+F: Documentation/devicetree/bindings/mips/
75247526 F: Documentation/mips/
75257527 F: arch/mips/
75267528
arch/mips/Kconfig+1−0
@@ -398,6 +398,7 @@ config MACH_PISTACHIO · 397 unmodified lines
398398 select SYS_SUPPORTS_LITTLE_ENDIAN
399399 select SYS_SUPPORTS_MIPS_CPS
400400 select SYS_SUPPORTS_MULTITHREADING
401+ select SYS_SUPPORTS_RELOCATABLE
401402 select SYS_SUPPORTS_ZBOOT
402403 select SYS_HAS_EARLY_PRINTK
403404 select USE_GENERIC_EARLY_PRINTK_8250
arch/mips/boot/dts/ingenic/jz4740.dtsi+1−1
@@ -5,7 +5,7 @@ · 4 unmodified lines
55 #size-cells = <1>;
66 compatible = "ingenic,jz4740";
77
8− cpuintc: interrupt-controller@0 {
8+ cpuintc: interrupt-controller {
99 #address-cells = <0>;
1010 #interrupt-cells = <1>;
1111 interrupt-controller;
arch/mips/boot/dts/ralink/mt7620a.dtsi+1−1
@@ -9,7 +9,7 @@ · 8 unmodified lines
99 };
1010 };
1111
12− cpuintc: cpuintc@0 {
12+ cpuintc: cpuintc {
1313 #address-cells = <0>;
1414 #interrupt-cells = <1>;
1515 interrupt-controller;
arch/mips/boot/dts/ralink/rt2880.dtsi+1−1
@@ -9,7 +9,7 @@ · 8 unmodified lines
99 };
1010 };
1111
12− cpuintc: cpuintc@0 {
12+ cpuintc: cpuintc {
1313 #address-cells = <0>;
1414 #interrupt-cells = <1>;
1515 interrupt-controller;
arch/mips/boot/dts/ralink/rt3050.dtsi+1−1
@@ -9,7 +9,7 @@ · 8 unmodified lines
99 };
1010 };
1111
12− cpuintc: cpuintc@0 {
12+ cpuintc: cpuintc {
1313 #address-cells = <0>;
1414 #interrupt-cells = <1>;
1515 interrupt-controller;
arch/mips/boot/dts/ralink/rt3883.dtsi+1−1
@@ -9,7 +9,7 @@ · 8 unmodified lines
99 };
1010 };
1111
12− cpuintc: cpuintc@0 {
12+ cpuintc: cpuintc {
1313 #address-cells = <0>;
1414 #interrupt-cells = <1>;
1515 interrupt-controller;
arch/mips/boot/dts/xilfpga/nexys4ddr.dts+1−1
@@ -10,7 +10,7 @@ · 9 unmodified lines
1010 reg = <0x0 0x08000000>;
1111 };
1212
13− cpuintc: interrupt-controller@0 {
13+ cpuintc: interrupt-controller {
1414 #address-cells = <0>;
1515 #interrupt-cells = <1>;
1616 interrupt-controller;
arch/mips/cavium-octeon/smp.c+1−1
@@ -384,7 +384,7 @@ static int octeon_cpu_callback(struct notifier_block *nfb, · 383 unmodified lines
384384 {
385385 unsigned int cpu = (unsigned long)hcpu;
386386
387− switch (action) {
387+ switch (action & ~CPU_TASKS_FROZEN) {
388388 case CPU_UP_PREPARE:
389389 octeon_update_boot_vector(cpu);
390390 break;
arch/mips/include/asm/asmmacro.h+50−49
@@ -19,6 +19,28 @@ · 18 unmodified lines
1919 #include <asm/asmmacro-64.h>
2020 #endif
2121
22+/*
23+ * Helper macros for generating raw instruction encodings.
24+ */
25+#ifdef CONFIG_CPU_MICROMIPS
26+ .macro insn32_if_mm enc
27+ .insn
28+ .hword ((\enc) >> 16)
29+ .hword ((\enc) & 0xffff)
30+ .endm
31+
32+ .macro insn_if_mips enc
33+ .endm
34+#else
35+ .macro insn32_if_mm enc
36+ .endm
37+
38+ .macro insn_if_mips enc
39+ .insn
40+ .word (\enc)
41+ .endm
42+#endif
43+
2244 #if defined(CONFIG_CPU_MIPSR2) || defined(CONFIG_CPU_MIPSR6)
2345 .macro local_irq_enable reg=t0
2446 ei
@@ -341,38 +363,6 @@ · 316 unmodified lines
341363 .endm
342364 #else
343365
344−#ifdef CONFIG_CPU_MICROMIPS
345−#define CFC_MSA_INSN 0x587e0056
346−#define CTC_MSA_INSN 0x583e0816
347−#define LDB_MSA_INSN 0x58000807
348−#define LDH_MSA_INSN 0x58000817
349−#define LDW_MSA_INSN 0x58000827
350−#define LDD_MSA_INSN 0x58000837
351−#define STB_MSA_INSN 0x5800080f
352−#define STH_MSA_INSN 0x5800081f
353−#define STW_MSA_INSN 0x5800082f
354−#define STD_MSA_INSN 0x5800083f
355−#define COPY_SW_MSA_INSN 0x58b00056
356−#define COPY_SD_MSA_INSN 0x58b80056
357−#define INSERT_W_MSA_INSN 0x59300816
358−#define INSERT_D_MSA_INSN 0x59380816
359−#else
360−#define CFC_MSA_INSN 0x787e0059
361−#define CTC_MSA_INSN 0x783e0819
362−#define LDB_MSA_INSN 0x78000820
363−#define LDH_MSA_INSN 0x78000821
364−#define LDW_MSA_INSN 0x78000822
365−#define LDD_MSA_INSN 0x78000823
366−#define STB_MSA_INSN 0x78000824
367−#define STH_MSA_INSN 0x78000825
368−#define STW_MSA_INSN 0x78000826
369−#define STD_MSA_INSN 0x78000827
370−#define COPY_SW_MSA_INSN 0x78b00059
371−#define COPY_SD_MSA_INSN 0x78b80059
372−#define INSERT_W_MSA_INSN 0x79300819
373−#define INSERT_D_MSA_INSN 0x79380819
374−#endif
375−
376366 /*
377367 * Temporary until all toolchains in use include MSA support.
378368 */
@@ -380,8 +370,8 @@ · 1 unmodified line
380370 .set push
381371 .set noat
382372 SET_HARDFLOAT
383− .insn
384− .word CFC_MSA_INSN | (\cs << 11)
373+ insn_if_mips 0x787e0059 | (\cs << 11)
374+ insn32_if_mm 0x587e0056 | (\cs << 11)
385375 move \rd, $1
386376 .set pop
387377 .endm
@@ -391,7 +381,8 @@ · 3 unmodified lines
391381 .set noat
392382 SET_HARDFLOAT
393383 move $1, \rs
394− .word CTC_MSA_INSN | (\cd << 6)
384+ insn_if_mips 0x783e0819 | (\cd << 6)
385+ insn32_if_mm 0x583e0816 | (\cd << 6)
395386 .set pop
396387 .endm
397388
@@ -400,7 +391,8 @@ · 2 unmodified lines
400391 .set noat
401392 SET_HARDFLOAT
402393 PTR_ADDU $1, \base, \off
403− .word LDB_MSA_INSN | (\wd << 6)
394+ insn_if_mips 0x78000820 | (\wd << 6)
395+ insn32_if_mm 0x58000807 | (\wd << 6)
404396 .set pop
405397 .endm
406398
@@ -409,7 +401,8 @@ · 2 unmodified lines
409401 .set noat
410402 SET_HARDFLOAT
411403 PTR_ADDU $1, \base, \off
412− .word LDH_MSA_INSN | (\wd << 6)
404+ insn_if_mips 0x78000821 | (\wd << 6)
405+ insn32_if_mm 0x58000817 | (\wd << 6)
413406 .set pop
414407 .endm
415408
@@ -418,7 +411,8 @@ · 2 unmodified lines
418411 .set noat
419412 SET_HARDFLOAT
420413 PTR_ADDU $1, \base, \off
421− .word LDW_MSA_INSN | (\wd << 6)
414+ insn_if_mips 0x78000822 | (\wd << 6)
415+ insn32_if_mm 0x58000827 | (\wd << 6)
422416 .set pop
423417 .endm
424418
@@ -427,7 +421,8 @@ · 2 unmodified lines
427421 .set noat
428422 SET_HARDFLOAT
429423 PTR_ADDU $1, \base, \off
430− .word LDD_MSA_INSN | (\wd << 6)
424+ insn_if_mips 0x78000823 | (\wd << 6)
425+ insn32_if_mm 0x58000837 | (\wd << 6)
431426 .set pop
432427 .endm
433428
@@ -436,7 +431,8 @@ · 2 unmodified lines
436431 .set noat
437432 SET_HARDFLOAT
438433 PTR_ADDU $1, \base, \off
439− .word STB_MSA_INSN | (\wd << 6)
434+ insn_if_mips 0x78000824 | (\wd << 6)
435+ insn32_if_mm 0x5800080f | (\wd << 6)
440436 .set pop
441437 .endm
442438
@@ -445,7 +441,8 @@ · 2 unmodified lines
445441 .set noat
446442 SET_HARDFLOAT
447443 PTR_ADDU $1, \base, \off
448− .word STH_MSA_INSN | (\wd << 6)
444+ insn_if_mips 0x78000825 | (\wd << 6)
445+ insn32_if_mm 0x5800081f | (\wd << 6)
449446 .set pop
450447 .endm
451448
@@ -454,7 +451,8 @@ · 2 unmodified lines
454451 .set noat
455452 SET_HARDFLOAT
456453 PTR_ADDU $1, \base, \off
457− .word STW_MSA_INSN | (\wd << 6)
454+ insn_if_mips 0x78000826 | (\wd << 6)
455+ insn32_if_mm 0x5800082f | (\wd << 6)
458456 .set pop
459457 .endm
460458
@@ -463,7 +461,8 @@ · 2 unmodified lines
463461 .set noat
464462 SET_HARDFLOAT
465463 PTR_ADDU $1, \base, \off
466− .word STD_MSA_INSN | (\wd << 6)
464+ insn_if_mips 0x78000827 | (\wd << 6)
465+ insn32_if_mm 0x5800083f | (\wd << 6)
467466 .set pop
468467 .endm
469468
@@ -471,8 +470,8 @@ · 1 unmodified line
471470 .set push
472471 .set noat
473472 SET_HARDFLOAT
474− .insn
475− .word COPY_SW_MSA_INSN | (\n << 16) | (\ws << 11)
473+ insn_if_mips 0x78b00059 | (\n << 16) | (\ws << 11)
474+ insn32_if_mm 0x58b00056 | (\n << 16) | (\ws << 11)
476475 .set pop
477476 .endm
478477
@@ -480,8 +479,8 @@ · 1 unmodified line
480479 .set push
481480 .set noat
482481 SET_HARDFLOAT
483− .insn
484− .word COPY_SD_MSA_INSN | (\n << 16) | (\ws << 11)
482+ insn_if_mips 0x78b80059 | (\n << 16) | (\ws << 11)
483+ insn32_if_mm 0x58b80056 | (\n << 16) | (\ws << 11)
485484 .set pop
486485 .endm
487486
@@ -489,7 +488,8 @@ · 1 unmodified line
489488 .set push
490489 .set noat
491490 SET_HARDFLOAT
492− .word INSERT_W_MSA_INSN | (\n << 16) | (\wd << 6)
491+ insn_if_mips 0x79300819 | (\n << 16) | (\wd << 6)
492+ insn32_if_mm 0x59300816 | (\n << 16) | (\wd << 6)
493493 .set pop
494494 .endm
495495
@@ -497,7 +497,8 @@ · 1 unmodified line
497497 .set push
498498 .set noat
499499 SET_HARDFLOAT
500− .word INSERT_D_MSA_INSN | (\n << 16) | (\wd << 6)
500+ insn_if_mips 0x79380819 | (\n << 16) | (\wd << 6)
501+ insn32_if_mm 0x59380816 | (\n << 16) | (\wd << 6)
501502 .set pop
502503 .endm
503504 #endif
arch/mips/include/asm/hazards.h+4−4
@@ -58,8 +58,8 @@ · 57 unmodified lines
5858 * address of a label as argument to inline assembler. Gas otoh has the
5959 * annoying difference between la and dla which are only usable for 32-bit
6060 * rsp. 64-bit code, so can't be used without conditional compilation.
61− * The alterantive is switching the assembler to 64-bit code which happens
62− * to work right even for 32-bit code ...
61+ * The alternative is switching the assembler to 64-bit code which happens
62+ * to work right even for 32-bit code...
6363 */
6464 #define instruction_hazard() \
6565 do { \
@@ -133,8 +133,8 @@ do { \ · 67 unmodified lines
133133 * address of a label as argument to inline assembler. Gas otoh has the
134134 * annoying difference between la and dla which are only usable for 32-bit
135135 * rsp. 64-bit code, so can't be used without conditional compilation.
136− * The alterantive is switching the assembler to 64-bit code which happens
137− * to work right even for 32-bit code ...
136+ * The alternative is switching the assembler to 64-bit code which happens
137+ * to work right even for 32-bit code...
138138 */
139139 #define __instruction_hazard() \
140140 do { \
arch/mips/include/asm/mach-au1x00/au1xxx_dbdma.h+1−1
@@ -100,7 +100,7 @@ typedef volatile struct au1xxx_ddma_desc { · 99 unmodified lines
100100 u32 dscr_nxtptr; /* Next descriptor pointer (mostly) */
101101 /*
102102 * First 32 bytes are HW specific!!!
103− * Lets have some SW data following -- make sure it's 32 bytes.
103+ * Let's have some SW data following -- make sure it's 32 bytes.
104104 */
105105 u32 sw_status;
106106 u32 sw_context;
arch/mips/include/asm/mach-au1x00/gpio-au1300.h+1−1
@@ -140,7 +140,7 @@ static inline int au1300_gpio_getinitlvl(unsigned int gpio) · 139 unmodified lines
140140 * Cases 1 and 3 are intended for boards which want to provide their own
141141 * GPIO namespace and -operations (i.e. for example you have 8 GPIOs
142142 * which are in part provided by spare Au1300 GPIO pins and in part by
143−* an external FPGA but you still want them to be accssible in linux
143+* an external FPGA but you still want them to be accessible in linux
144144 * as gpio0-7. The board can of course use the alchemy_gpioX_* functions
145145 * as required).
146146 */
arch/mips/include/asm/mach-bcm63xx/bcm63xx_dev_enet.h+1−1
@@ -22,7 +22,7 @@ struct bcm63xx_enet_platform_data { · 21 unmodified lines
2222 int has_phy_interrupt;
2323 int phy_interrupt;
2424
25− /* if has_phy, use autonegociated pause parameters or force
25+ /* if has_phy, use autonegotiated pause parameters or force
2626 * them */
2727 int pause_auto;
2828 int pause_rx;
arch/mips/include/asm/mach-ip27/dma-coherence.h+1−1
@@ -64,7 +64,7 @@ static inline void plat_post_dma_flush(struct device *dev) · 63 unmodified lines
6464
6565 static inline int plat_device_is_coherent(struct device *dev)
6666 {
67− return 1; /* IP27 non-cohernet mode is unsupported */
67+ return 1; /* IP27 non-coherent mode is unsupported */
6868 }
6969
7070 #endif /* __ASM_MACH_IP27_DMA_COHERENCE_H */
arch/mips/include/asm/mach-ip32/dma-coherence.h+1−1
@@ -86,7 +86,7 @@ static inline void plat_post_dma_flush(struct device *dev) · 85 unmodified lines
8686
8787 static inline int plat_device_is_coherent(struct device *dev)
8888 {
89− return 0; /* IP32 is non-cohernet */
89+ return 0; /* IP32 is non-coherent */
9090 }
9191
9292 #endif /* __ASM_MACH_IP32_DMA_COHERENCE_H */
arch/mips/include/asm/mach-lantiq/falcon/lantiq_soc.h+1−1
@@ -22,7 +22,7 @@ · 21 unmodified lines
2222
2323 /*
2424 * during early_printk no ioremap possible at this early stage
25− * lets use KSEG1 instead
25+ * let's use KSEG1 instead
2626 */
2727 #define LTQ_ASC0_BASE_ADDR 0x1E100C00
2828 #define LTQ_EARLY_ASC KSEG1ADDR(LTQ_ASC0_BASE_ADDR)
arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h+1−1
@@ -75,7 +75,7 @@ extern __iomem void *ltq_cgu_membase; · 74 unmodified lines
7575
7676 /*
7777 * during early_printk no ioremap is possible
78− * lets use KSEG1 instead
78+ * let's use KSEG1 instead
7979 */
8080 #define LTQ_ASC1_BASE_ADDR 0x1E100C00
8181 #define LTQ_EARLY_ASC KSEG1ADDR(LTQ_ASC1_BASE_ADDR)
arch/mips/include/asm/mach-loongson64/loongson_hwmon.h+1−1
@@ -24,7 +24,7 @@ struct temp_range { · 23 unmodified lines
2424 u8 level;
2525 };
2626
27−#define CONSTANT_SPEED_POLICY 0 /* at constent speed */
27+#define CONSTANT_SPEED_POLICY 0 /* at constant speed */
2828 #define STEP_SPEED_POLICY 1 /* use up/down arrays to describe policy */
2929 #define KERNEL_HELPER_POLICY 2 /* kernel as a helper to fan control */
3030
arch/mips/include/asm/mach-malta/kernel-entry-init.h+3−3
@@ -56,7 +56,7 @@ · 55 unmodified lines
5656 (0 << MIPS_SEGCFG_PA_SHIFT) | \
5757 (1 << MIPS_SEGCFG_EU_SHIFT)) << 16)
5858 or t0, t2
59− mtc0 t0, $5, 2
59+ mtc0 t0, CP0_SEGCTL0
6060
6161 /* SegCtl1 */
6262 li t0, ((MIPS_SEGCFG_MUSUK << MIPS_SEGCFG_AM_SHIFT) | \
@@ -67,7 +67,7 @@ · 4 unmodified lines
6767 (0 << MIPS_SEGCFG_PA_SHIFT) | \
6868 (1 << MIPS_SEGCFG_EU_SHIFT)) << 16)
6969 ins t0, t1, 16, 3
70− mtc0 t0, $5, 3
70+ mtc0 t0, CP0_SEGCTL1
7171
7272 /* SegCtl2 */
7373 li t0, ((MIPS_SEGCFG_MUSUK << MIPS_SEGCFG_AM_SHIFT) | \
@@ -77,7 +77,7 @@ · 3 unmodified lines
7777 (4 << MIPS_SEGCFG_PA_SHIFT) | \
7878 (1 << MIPS_SEGCFG_EU_SHIFT)) << 16)
7979 or t0, t2
80− mtc0 t0, $5, 4
80+ mtc0 t0, CP0_SEGCTL2
8181
8282 jal mips_ihb
8383 mfc0 t0, $16, 5
arch/mips/include/asm/mips_mt.h+1−1
@@ -1,5 +1,5 @@
11 /*
2− * Definitions and decalrations for MIPS MT support that are common between
2+ * Definitions and declarations for MIPS MT support that are common between
33 * the VSMP, and AP/SP kernel models.
44 */
55 #ifndef __ASM_MIPS_MT_H
arch/mips/include/asm/mipsregs.h+82−106
@@ -48,6 +48,9 @@ · 47 unmodified lines
4848 #define CP0_CONF $3
4949 #define CP0_CONTEXT $4
5050 #define CP0_PAGEMASK $5
51+#define CP0_SEGCTL0 $5, 2
52+#define CP0_SEGCTL1 $5, 3
53+#define CP0_SEGCTL2 $5, 4
5154 #define CP0_WIRED $6
5255 #define CP0_INFO $7
5356 #define CP0_HWRENA $7, 0
@@ -726,6 +729,8 @@ · 672 unmodified lines
726729 #define MIPS_PWFIELD_PTEI_SHIFT 0
727730 #define MIPS_PWFIELD_PTEI_MASK 0x0000003f
728731
732+#define MIPS_PWSIZE_PS_SHIFT 30
733+#define MIPS_PWSIZE_PS_MASK 0x40000000
729734 #define MIPS_PWSIZE_GDW_SHIFT 24
730735 #define MIPS_PWSIZE_GDW_MASK 0x3f000000
731736 #define MIPS_PWSIZE_UDW_SHIFT 18
@@ -739,6 +744,12 @@ · 7 unmodified lines
739744
740745 #define MIPS_PWCTL_PWEN_SHIFT 31
741746 #define MIPS_PWCTL_PWEN_MASK 0x80000000
747+#define MIPS_PWCTL_XK_SHIFT 28
748+#define MIPS_PWCTL_XK_MASK 0x10000000
749+#define MIPS_PWCTL_XS_SHIFT 27
750+#define MIPS_PWCTL_XS_MASK 0x08000000
751+#define MIPS_PWCTL_XU_SHIFT 26
752+#define MIPS_PWCTL_XU_MASK 0x04000000
742753 #define MIPS_PWCTL_DPH_SHIFT 7
743754 #define MIPS_PWCTL_DPH_MASK 0x00000080
744755 #define MIPS_PWCTL_HUGEPG_SHIFT 6
@@ -1045,6 +1056,33 @@ static inline int mm_insn_16bit(u16 insn) · 300 unmodified lines
10451056 return (opcode >= 1 && opcode <= 3) ? 1 : 0;
10461057 }
10471058
1059+/*
1060+ * Helper macros for generating raw instruction encodings in inline asm.
1061+ */
1062+#ifdef CONFIG_CPU_MICROMIPS
1063+#define _ASM_INSN16_IF_MM(_enc) \
1064+ ".insn\n\t" \
1065+ ".hword (" #_enc ")\n\t"
1066+#define _ASM_INSN32_IF_MM(_enc) \
1067+ ".insn\n\t" \
1068+ ".hword ((" #_enc ") >> 16)\n\t" \
1069+ ".hword ((" #_enc ") & 0xffff)\n\t"
1070+#else
1071+#define _ASM_INSN_IF_MIPS(_enc) \
1072+ ".insn\n\t" \
1073+ ".word (" #_enc ")\n\t"
1074+#endif
1075+
1076+#ifndef _ASM_INSN16_IF_MM
1077+#define _ASM_INSN16_IF_MM(_enc)
1078+#endif
1079+#ifndef _ASM_INSN32_IF_MM
1080+#define _ASM_INSN32_IF_MM(_enc)
1081+#endif
1082+#ifndef _ASM_INSN_IF_MIPS
1083+#define _ASM_INSN_IF_MIPS(_enc)
1084+#endif
1085+
10481086 /*
10491087 * TLB Invalidate Flush
10501088 */
@@ -1053,7 +1091,9 @@ static inline void tlbinvf(void) · 2 unmodified lines
10531091 __asm__ __volatile__(
10541092 ".set push\n\t"
10551093 ".set noreorder\n\t"
1056− ".word 0x42000004\n\t" /* tlbinvf */
1094+ "# tlbinvf\n\t"
1095+ _ASM_INSN_IF_MIPS(0x42000004)
1096+ _ASM_INSN32_IF_MM(0x0000537c)
10571097 ".set pop");
10581098 }
10591099
@@ -1274,9 +1314,9 @@ do { \ · 214 unmodified lines
12741314 " .set push \n" \
12751315 " .set noat \n" \
12761316 " .set mips32r2 \n" \
1277− " .insn \n" \
12781317 " # mfhc0 $1, %1 \n" \
1279− " .word (0x40410000 | ((%1 & 0x1f) << 11)) \n" \
1318+ _ASM_INSN_IF_MIPS(0x40410000 | ((%1 & 0x1f) << 11)) \
1319+ _ASM_INSN32_IF_MM(0x002000f4 | ((%1 & 0x1f) << 16)) \
12801320 " move %0, $1 \n" \
12811321 " .set pop \n" \
12821322 : "=r" (__res) \
@@ -1292,8 +1332,8 @@ do { \ · 9 unmodified lines
12921332 " .set mips32r2 \n" \
12931333 " move $1, %0 \n" \
12941334 " # mthc0 $1, %1 \n" \
1295− " .insn \n" \
1296− " .word (0x40c10000 | ((%1 & 0x1f) << 11)) \n" \
1335+ _ASM_INSN_IF_MIPS(0x40c10000 | ((%1 & 0x1f) << 11)) \
1336+ _ASM_INSN32_IF_MM(0x002002f4 | ((%1 & 0x1f) << 16)) \
12971337 " .set pop \n" \
12981338 : \
12991339 : "r" (value), "i" (register)); \
@@ -1743,7 +1783,8 @@ do { \ · 443 unmodified lines
17431783 ".set\tpush\n\t" \
17441784 ".set\tnoat\n\t" \
17451785 "# mfgc0\t$1, $%1, %2\n\t" \
1746− ".word\t(0x40610000 | %1 << 11 | %2)\n\t" \
1786+ _ASM_INSN_IF_MIPS(0x40610000 | %1 << 11 | %2) \
1787+ _ASM_INSN32_IF_MM(0x002004fc | %1 << 16 | %2 << 11) \
17471788 "move\t%0, $1\n\t" \
17481789 ".set\tpop" \
17491790 : "=r" (__res) \
@@ -1757,7 +1798,8 @@ do { \ · 7 unmodified lines
17571798 ".set\tpush\n\t" \
17581799 ".set\tnoat\n\t" \
17591800 "# dmfgc0\t$1, $%1, %2\n\t" \
1760− ".word\t(0x40610100 | %1 << 11 | %2)\n\t" \
1801+ _ASM_INSN_IF_MIPS(0x40610100 | %1 << 11 | %2) \
1802+ _ASM_INSN32_IF_MM(0x582004fc | %1 << 16 | %2 << 11) \
17611803 "move\t%0, $1\n\t" \
17621804 ".set\tpop" \
17631805 : "=r" (__res) \
@@ -1770,9 +1812,10 @@ do { \ · 6 unmodified lines
17701812 __asm__ __volatile__( \
17711813 ".set\tpush\n\t" \
17721814 ".set\tnoat\n\t" \
1773− "move\t$1, %0\n\t" \
1815+ "move\t$1, %z0\n\t" \
17741816 "# mtgc0\t$1, $%1, %2\n\t" \
1775− ".word\t(0x40610200 | %1 << 11 | %2)\n\t" \
1817+ _ASM_INSN_IF_MIPS(0x40610200 | %1 << 11 | %2) \
1818+ _ASM_INSN32_IF_MM(0x002006fc | %1 << 16 | %2 << 11) \
17761819 ".set\tpop" \
17771820 : : "Jr" ((unsigned int)(value)), \
17781821 "i" (register), "i" (sel)); \
@@ -1783,9 +1826,10 @@ do { \ · 4 unmodified lines
17831826 __asm__ __volatile__( \
17841827 ".set\tpush\n\t" \
17851828 ".set\tnoat\n\t" \
1786− "move\t$1, %0\n\t" \
1829+ "move\t$1, %z0\n\t" \
17871830 "# dmtgc0\t$1, $%1, %2\n\t" \
1788− ".word\t(0x40610300 | %1 << 11 | %2)\n\t" \
1831+ _ASM_INSN_IF_MIPS(0x40610300 | %1 << 11 | %2) \
1832+ _ASM_INSN32_IF_MM(0x582006fc | %1 << 16 | %2 << 11) \
17891833 ".set\tpop" \
17901834 : : "Jr" (value), \
17911835 "i" (register), "i" (sel)); \
@@ -2246,7 +2290,6 @@ do { \ · 454 unmodified lines
22462290
22472291 #else
22482292
2249−#ifdef CONFIG_CPU_MICROMIPS
22502293 #define rddsp(mask) \
22512294 ({ \
22522295 unsigned int __res; \
@@ -2255,8 +2298,8 @@ do { \ · 2 unmodified lines
22552298 " .set push \n" \
22562299 " .set noat \n" \
22572300 " # rddsp $1, %x1 \n" \
2258− " .hword ((0x0020067c | (%x1 << 14)) >> 16) \n" \
2259− " .hword ((0x0020067c | (%x1 << 14)) & 0xffff) \n" \
2301+ _ASM_INSN_IF_MIPS(0x7c000cb8 | (%x1 << 16)) \
2302+ _ASM_INSN32_IF_MM(0x0020067c | (%x1 << 14)) \
22602303 " move %0, $1 \n" \
22612304 " .set pop \n" \
22622305 : "=r" (__res) \
@@ -2271,22 +2314,22 @@ do { \ · 8 unmodified lines
22712314 " .set noat \n" \
22722315 " move $1, %0 \n" \
22732316 " # wrdsp $1, %x1 \n" \
2274− " .hword ((0x0020167c | (%x1 << 14)) >> 16) \n" \
2275− " .hword ((0x0020167c | (%x1 << 14)) & 0xffff) \n" \
2317+ _ASM_INSN_IF_MIPS(0x7c2004f8 | (%x1 << 11)) \
2318+ _ASM_INSN32_IF_MM(0x0020167c | (%x1 << 14)) \
22762319 " .set pop \n" \
22772320 : \
22782321 : "r" (val), "i" (mask)); \
22792322 } while (0)
22802323
2281−#define _umips_dsp_mfxxx(ins) \
2324+#define _dsp_mfxxx(ins) \
22822325 ({ \
22832326 unsigned long __treg; \
22842327 \
22852328 __asm__ __volatile__( \
22862329 " .set push \n" \
22872330 " .set noat \n" \
2288− " .hword 0x0001 \n" \
2289− " .hword %x1 \n" \
2331+ _ASM_INSN_IF_MIPS(0x00000810 | %X1) \
2332+ _ASM_INSN32_IF_MM(0x0001007c | %x1) \
22902333 " move %0, $1 \n" \
22912334 " .set pop \n" \
22922335 : "=r" (__treg) \
@@ -2294,101 +2337,28 @@ do { \ · 1 unmodified line
22942337 __treg; \
22952338 })
22962339
2297−#define _umips_dsp_mtxxx(val, ins) \
2340+#define _dsp_mtxxx(val, ins) \
22982341 do { \
22992342 __asm__ __volatile__( \
23002343 " .set push \n" \
23012344 " .set noat \n" \
23022345 " move $1, %0 \n" \
2303− " .hword 0x0001 \n" \
2304− " .hword %x1 \n" \
2346+ _ASM_INSN_IF_MIPS(0x00200011 | %X1) \
2347+ _ASM_INSN32_IF_MM(0x0001207c | %x1) \
23052348 " .set pop \n" \
23062349 : \
23072350 : "r" (val), "i" (ins)); \
23082351 } while (0)
23092352
2310−#define _umips_dsp_mflo(reg) _umips_dsp_mfxxx((reg << 14) | 0x107c)
2311−#define _umips_dsp_mfhi(reg) _umips_dsp_mfxxx((reg << 14) | 0x007c)
2312−
2313−#define _umips_dsp_mtlo(val, reg) _umips_dsp_mtxxx(val, ((reg << 14) | 0x307c))
2314−#define _umips_dsp_mthi(val, reg) _umips_dsp_mtxxx(val, ((reg << 14) | 0x207c))
2315−
2316−#define mflo0() _umips_dsp_mflo(0)
2317−#define mflo1() _umips_dsp_mflo(1)
2318−#define mflo2() _umips_dsp_mflo(2)
2319−#define mflo3() _umips_dsp_mflo(3)
2320−
2321−#define mfhi0() _umips_dsp_mfhi(0)
2322−#define mfhi1() _umips_dsp_mfhi(1)
2323−#define mfhi2() _umips_dsp_mfhi(2)
2324−#define mfhi3() _umips_dsp_mfhi(3)
2353+#ifdef CONFIG_CPU_MICROMIPS
23252354
2326−#define mtlo0(x) _umips_dsp_mtlo(x, 0)
2327−#define mtlo1(x) _umips_dsp_mtlo(x, 1)
2328−#define mtlo2(x) _umips_dsp_mtlo(x, 2)
2329−#define mtlo3(x) _umips_dsp_mtlo(x, 3)
2355+#define _dsp_mflo(reg) _dsp_mfxxx((reg << 14) | 0x1000)
2356+#define _dsp_mfhi(reg) _dsp_mfxxx((reg << 14) | 0x0000)
23302357
2331−#define mthi0(x) _umips_dsp_mthi(x, 0)
2332−#define mthi1(x) _umips_dsp_mthi(x, 1)
2333−#define mthi2(x) _umips_dsp_mthi(x, 2)
2334−#define mthi3(x) _umips_dsp_mthi(x, 3)
2358+#define _dsp_mtlo(val, reg) _dsp_mtxxx(val, ((reg << 14) | 0x1000))
2359+#define _dsp_mthi(val, reg) _dsp_mtxxx(val, ((reg << 14) | 0x0000))
23352360
23362361 #else /* !CONFIG_CPU_MICROMIPS */
2337−#define rddsp(mask) \
2338−({ \
2339− unsigned int __res; \
2340− \
2341− __asm__ __volatile__( \
2342− " .set push \n" \
2343− " .set noat \n" \
2344− " # rddsp $1, %x1 \n" \
2345− " .word 0x7c000cb8 | (%x1 << 16) \n" \
2346− " move %0, $1 \n" \
2347− " .set pop \n" \
2348− : "=r" (__res) \
2349− : "i" (mask)); \
2350− __res; \
2351−})
2352−
2353−#define wrdsp(val, mask) \
2354−do { \
2355− __asm__ __volatile__( \
2356− " .set push \n" \
2357− " .set noat \n" \
2358− " move $1, %0 \n" \
2359− " # wrdsp $1, %x1 \n" \
2360− " .word 0x7c2004f8 | (%x1 << 11) \n" \
2361− " .set pop \n" \
2362− : \
2363− : "r" (val), "i" (mask)); \
2364−} while (0)
2365−
2366−#define _dsp_mfxxx(ins) \
2367−({ \
2368− unsigned long __treg; \
2369− \
2370− __asm__ __volatile__( \
2371− " .set push \n" \
2372− " .set noat \n" \
2373− " .word (0x00000810 | %1) \n" \
2374− " move %0, $1 \n" \
2375− " .set pop \n" \
2376− : "=r" (__treg) \
2377− : "i" (ins)); \
2378− __treg; \
2379−})
2380−
2381−#define _dsp_mtxxx(val, ins) \
2382−do { \
2383− __asm__ __volatile__( \
2384− " .set push \n" \
2385− " .set noat \n" \
2386− " move $1, %0 \n" \
2387− " .word (0x00200011 | %1) \n" \
2388− " .set pop \n" \
2389− : \
2390− : "r" (val), "i" (ins)); \
2391−} while (0)
23922362
23932363 #define _dsp_mflo(reg) _dsp_mfxxx((reg << 21) | 0x0002)
23942364 #define _dsp_mfhi(reg) _dsp_mfxxx((reg << 21) | 0x0000)
@@ -2396,6 +2366,8 @@ do { \ · 1 unmodified line
23962366 #define _dsp_mtlo(val, reg) _dsp_mtxxx(val, ((reg << 11) | 0x0002))
23972367 #define _dsp_mthi(val, reg) _dsp_mtxxx(val, ((reg << 11) | 0x0000))
23982368
2369+#endif /* CONFIG_CPU_MICROMIPS */
2370+
23992371 #define mflo0() _dsp_mflo(0)
24002372 #define mflo1() _dsp_mflo(1)
24012373 #define mflo2() _dsp_mflo(2)
@@ -2416,7 +2388,6 @@ do { \ · 14 unmodified lines
24162388 #define mthi2(x) _dsp_mthi(x, 2)
24172389 #define mthi3(x) _dsp_mthi(x, 3)
24182390
2419−#endif /* CONFIG_CPU_MICROMIPS */
24202391 #endif
24212392
24222393 /*
@@ -2556,28 +2527,32 @@ static inline void guest_tlb_probe(void) · 133 unmodified lines
25562527 {
25572528 __asm__ __volatile__(
25582529 "# tlbgp\n\t"
2559− ".word 0x42000010");
2530+ _ASM_INSN_IF_MIPS(0x42000010)
2531+ _ASM_INSN32_IF_MM(0x0000017c));
25602532 }
25612533
25622534 static inline void guest_tlb_read(void)
25632535 {
25642536 __asm__ __volatile__(
25652537 "# tlbgr\n\t"
2566− ".word 0x42000009");
2538+ _ASM_INSN_IF_MIPS(0x42000009)
2539+ _ASM_INSN32_IF_MM(0x0000117c));
25672540 }
25682541
25692542 static inline void guest_tlb_write_indexed(void)
25702543 {
25712544 __asm__ __volatile__(
25722545 "# tlbgwi\n\t"
2573− ".word 0x4200000a");
2546+ _ASM_INSN_IF_MIPS(0x4200000a)
2547+ _ASM_INSN32_IF_MM(0x0000217c));
25742548 }
25752549
25762550 static inline void guest_tlb_write_random(void)
25772551 {
25782552 __asm__ __volatile__(
25792553 "# tlbgwr\n\t"
2580− ".word 0x4200000e");
2554+ _ASM_INSN_IF_MIPS(0x4200000e)
2555+ _ASM_INSN32_IF_MM(0x0000317c));
25812556 }
25822557
25832558 /*
@@ -2587,7 +2562,8 @@ static inline void guest_tlbinvf(void) · 3 unmodified lines
25872562 {
25882563 __asm__ __volatile__(
25892564 "# tlbginvf\n\t"
2590− ".word 0x4200000c");
2565+ _ASM_INSN_IF_MIPS(0x4200000c)
2566+ _ASM_INSN32_IF_MM(0x0000517c));
25912567 }
25922568
25932569 #endif /* !TOOLCHAIN_SUPPORTS_VIRT */
arch/mips/include/asm/msa.h+8−13
@@ -192,13 +192,6 @@ static inline void write_msa_##name(unsigned int val) \ · 191 unmodified lines
192192 * allow compilation with toolchains that do not support MSA. Once all
193193 * toolchains in use support MSA these can be removed.
194194 */
195−#ifdef CONFIG_CPU_MICROMIPS
196−#define CFC_MSA_INSN 0x587e0056
197−#define CTC_MSA_INSN 0x583e0816
198−#else
199−#define CFC_MSA_INSN 0x787e0059
200−#define CTC_MSA_INSN 0x783e0819
201−#endif
202195
203196 #define __BUILD_MSA_CTL_REG(name, cs) \
204197 static inline unsigned int read_msa_##name(void) \
@@ -207,11 +200,12 @@ static inline unsigned int read_msa_##name(void) \ · 2 unmodified lines
207200 __asm__ __volatile__( \
208201 " .set push\n" \
209202 " .set noat\n" \
210− " .insn\n" \
211− " .word %1 | (" #cs " << 11)\n" \
203+ " # cfcmsa $1, $%1\n" \
204+ _ASM_INSN_IF_MIPS(0x787e0059 | %1 << 11) \
205+ _ASM_INSN32_IF_MM(0x587e0056 | %1 << 11) \
212206 " move %0, $1\n" \
213207 " .set pop\n" \
214− : "=r"(reg) : "i"(CFC_MSA_INSN)); \
208+ : "=r"(reg) : "i"(cs)); \
215209 return reg; \
216210 } \
217211 \
@@ -221,10 +215,11 @@ static inline void write_msa_##name(unsigned int val) \ · 3 unmodified lines
221215 " .set push\n" \
222216 " .set noat\n" \
223217 " move $1, %0\n" \
224− " .insn\n" \
225− " .word %1 | (" #cs " << 6)\n" \
218+ " # ctcmsa $%1, $1\n" \
219+ _ASM_INSN_IF_MIPS(0x783e0819 | %1 << 6) \
220+ _ASM_INSN32_IF_MM(0x583e0816 | %1 << 6) \
226221 " .set pop\n" \
227− : : "r"(val), "i"(CTC_MSA_INSN)); \
222+ : : "r"(val), "i"(cs)); \
228223 }
229224
230225 #endif /* !TOOLCHAIN_SUPPORTS_MSA */
arch/mips/include/asm/octeon/cvmx-cmd-queue.h+1−1
@@ -146,7 +146,7 @@ typedef struct { · 145 unmodified lines
146146 * This structure contains the global state of all command queues.
147147 * It is stored in a bootmem named block and shared by all
148148 * applications running on Octeon. Tickets are stored in a differnet
149− * cahce line that queue information to reduce the contention on the
149+ * cache line that queue information to reduce the contention on the
150150 * ll/sc used to get a ticket. If this is not the case, the update
151151 * of queue state causes the ll/sc to fail quite often.
152152 */
arch/mips/include/asm/octeon/cvmx-helper-board.h+1−1
@@ -94,7 +94,7 @@ extern int cvmx_helper_board_get_mii_address(int ipd_port); · 93 unmodified lines
9494 * @phy_addr: The address of the PHY to program
9595 * @link_flags:
9696 * Flags to control autonegotiation. Bit 0 is autonegotiation
97− * enable/disable to maintain backware compatibility.
97+ * enable/disable to maintain backward compatibility.
9898 * @link_info: Link speed to program. If the speed is zero and autonegotiation
9999 * is enabled, all possible negotiation speeds are advertised.
100100 *
arch/mips/include/asm/octeon/cvmx-ipd.h+1−1
@@ -39,7 +39,7 @@ · 38 unmodified lines
3939
4040 enum cvmx_ipd_mode {
4141 CVMX_IPD_OPC_MODE_STT = 0LL, /* All blocks DRAM, not cached in L2 */
42− CVMX_IPD_OPC_MODE_STF = 1LL, /* All bloccks into L2 */
42+ CVMX_IPD_OPC_MODE_STF = 1LL, /* All blocks into L2 */
4343 CVMX_IPD_OPC_MODE_STF1_STT = 2LL, /* 1st block L2, rest DRAM */
4444 CVMX_IPD_OPC_MODE_STF2_STT = 3LL /* 1st, 2nd blocks L2, rest DRAM */
4545 };
arch/mips/include/asm/octeon/cvmx-pow.h+1−1
@@ -2051,7 +2051,7 @@ static inline void cvmx_pow_tag_sw_desched(uint32_t tag, · 2050 unmodified lines
20512051 }
20522052
20532053 /**
2054− * Descchedules the current work queue entry.
2054+ * Deschedules the current work queue entry.
20552055 *
20562056 * @no_sched: no schedule flag value to be set on the work queue
20572057 * entry. If this is set the entry will not be
arch/mips/include/asm/sgi/hpc3.h+1−1
@@ -39,7 +39,7 @@ struct hpc3_pbus_dmacregs { · 38 unmodified lines
3939 volatile u32 pbdma_dptr; /* pbus dma channel desc ptr */
4040 u32 _unused0[0x1000/4 - 2]; /* padding */
4141 volatile u32 pbdma_ctrl; /* pbus dma channel control register has
42− * copletely different meaning for read
42+ * completely different meaning for read
4343 * compared with write */
4444 /* read */
4545 #define HPC3_PDMACTRL_INT 0x00000001 /* interrupt (cleared after read) */
arch/mips/kernel/branch.c+2−2
@@ -481,7 +481,7 @@ int __compute_return_epc_for_insn(struct pt_regs *regs, · 480 unmodified lines
481481 /*
482482 * OK we are here either because we hit a NAL
483483 * instruction or because we are emulating an
484− * old bltzal{,l} one. Lets figure out what the
484+ * old bltzal{,l} one. Let's figure out what the
485485 * case really is.
486486 */
487487 if (!insn.i_format.rs) {
@@ -515,7 +515,7 @@ int __compute_return_epc_for_insn(struct pt_regs *regs, · 27 unmodified lines
515515 /*
516516 * OK we are here either because we hit a BAL
517517 * instruction or because we are emulating an
518− * old bgezal{,l} one. Lets figure out what the
518+ * old bgezal{,l} one. Let's figure out what the
519519 * case really is.
520520 */
521521 if (!insn.i_format.rs) {
arch/mips/kernel/cps-vec.S+15−0
@@ -441,6 +441,21 @@ LEAF(mips_cps_boot_vpes) · 440 unmodified lines
441441 mfc0 t0, CP0_CONFIG
442442 mttc0 t0, CP0_CONFIG
443443
444+ /*
445+ * Copy the EVA config from this VPE if the CPU supports it.
446+ * CONFIG3 must exist to be running MT startup - just read it.
447+ */
448+ mfc0 t0, CP0_CONFIG, 3
449+ and t0, t0, MIPS_CONF3_SC
450+ beqz t0, 3f
451+ nop
452+ mfc0 t0, CP0_SEGCTL0
453+ mttc0 t0, CP0_SEGCTL0
454+ mfc0 t0, CP0_SEGCTL1
455+ mttc0 t0, CP0_SEGCTL1
456+ mfc0 t0, CP0_SEGCTL2
457+ mttc0 t0, CP0_SEGCTL2
458+3:
444459 /* Ensure no software interrupts are pending */
445460 mttc0 zero, CP0_CAUSE
446461 mttc0 zero, CP0_STATUS
arch/mips/kernel/cpu-probe.c+1−3
@@ -833,10 +833,8 @@ static inline unsigned int decode_config5(struct cpuinfo_mips *c) · 832 unmodified lines
833833 c->options |= MIPS_CPU_MAAR;
834834 if (config5 & MIPS_CONF5_LLB)
835835 c->options |= MIPS_CPU_RW_LLB;
836−#ifdef CONFIG_XPA
837836 if (config5 & MIPS_CONF5_MVH)
838− c->options |= MIPS_CPU_XPA;
839−#endif
837+ c->options |= MIPS_CPU_MVH;
840838 if (cpu_has_mips_r6 && (config5 & MIPS_CONF5_VP))
841839 c->options |= MIPS_CPU_VP;
842840
arch/mips/kernel/elf.c+1−1
@@ -88,7 +88,7 @@ int arch_elf_pt_proc(void *_ehdr, void *_phdr, struct file *elf, · 87 unmodified lines
8888 elf32 = ehdr->e32.e_ident[EI_CLASS] == ELFCLASS32;
8989 flags = elf32 ? ehdr->e32.e_flags : ehdr->e64.e_flags;
9090
91− /* Lets see if this is an O32 ELF */
91+ /* Let's see if this is an O32 ELF */
9292 if (elf32) {
9393 if (flags & EF_MIPS_FP64) {
9494 /*
arch/mips/kernel/irq.c+3−0
@@ -54,6 +54,9 @@ void __init init_IRQ(void) · 53 unmodified lines
5454 for (i = 0; i < NR_IRQS; i++)
5555 irq_set_noprobe(i);
5656
57+ if (cpu_has_veic)
58+ clear_c0_status(ST0_IM);
59+
5760 arch_init_irq();
5861 }
5962
arch/mips/kernel/mips-r2-to-r6-emul.c+1−1
@@ -2202,7 +2202,7 @@ fpu_emul: · 2201 unmodified lines
22022202 }
22032203
22042204 /*
2205− * Lets not return to userland just yet. It's constly and
2205+ * Let's not return to userland just yet. It's costly and
22062206 * it's likely we have more R2 instructions to emulate
22072207 */
22082208 if (!err && (pass++ < MIPS_R2_EMUL_TOTAL_PASS)) {
arch/mips/kernel/process.c+1−1
@@ -345,7 +345,7 @@ static int get_frame_info(struct mips_frame_info *info) · 344 unmodified lines
345345 return 0;
346346 if (info->pc_offset < 0) /* leaf */
347347 return 1;
348− /* prologue seems boggus... */
348+ /* prologue seems bogus... */
349349 err:
350350 return -1;
351351 }
arch/mips/kernel/signal.c+0−8
@@ -770,15 +770,7 @@ static void handle_signal(struct ksignal *ksig, struct pt_regs *regs) · 769 unmodified lines
770770 sigset_t *oldset = sigmask_to_save();
771771 int ret;
772772 struct mips_abi *abi = current->thread.abi;
773−#ifdef CONFIG_CPU_MICROMIPS
774− void *vdso;
775− unsigned long tmp = (unsigned long)current->mm->context.vdso;
776−
777− set_isa16_mode(tmp);
778− vdso = (void *)tmp;
779−#else
780773 void *vdso = current->mm->context.vdso;
781−#endif
782774
783775 if (regs->regs[0]) {
784776 switch(regs->regs[2]) {
arch/mips/kernel/smp-cps.c+6−2
@@ -359,8 +359,12 @@ static void cps_init_secondary(void) · 358 unmodified lines
359359 BUG_ON(ident != mips_cm_vp_id(smp_processor_id()));
360360 }
361361
362− change_c0_status(ST0_IM, STATUSF_IP2 | STATUSF_IP3 | STATUSF_IP4 |
363− STATUSF_IP5 | STATUSF_IP6 | STATUSF_IP7);
362+ if (cpu_has_veic)
363+ clear_c0_status(ST0_IM);
364+ else
365+ change_c0_status(ST0_IM, STATUSF_IP2 | STATUSF_IP3 |
366+ STATUSF_IP4 | STATUSF_IP5 |
367+ STATUSF_IP6 | STATUSF_IP7);
364368 }
365369
366370 static void cps_smp_finish(void)
arch/mips/lasat/picvue_proc.c+2−2
@@ -43,7 +43,7 @@ static int pvc_line_proc_show(struct seq_file *m, void *v) · 42 unmodified lines
4343 {
4444 int lineno = *(int *)m->private;
4545
46− if (lineno < 0 || lineno > PVC_NLINES) {
46+ if (lineno < 0 || lineno >= PVC_NLINES) {
4747 printk(KERN_WARNING "proc_read_line: invalid lineno %d\n", lineno);
4848 return 0;
4949 }
@@ -67,7 +67,7 @@ static ssize_t pvc_line_proc_write(struct file *file, const char __user *buf, · 17 unmodified lines
6767 char kbuf[PVC_LINELEN];
6868 size_t len;
6969
70− BUG_ON(lineno < 0 || lineno > PVC_NLINES);
70+ BUG_ON(lineno < 0 || lineno >= PVC_NLINES);
7171
7272 len = min(count, sizeof(kbuf) - 1);
7373 if (copy_from_user(kbuf, buf, len))
arch/mips/lib/ashldi3.c+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22
33 #include "libgcc.h"
44
5−long long __ashldi3(long long u, word_type b)
5+long long notrace __ashldi3(long long u, word_type b)
66 {
77 DWunion uu, w;
88 word_type bm;
arch/mips/lib/ashrdi3.c+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22
33 #include "libgcc.h"
44
5−long long __ashrdi3(long long u, word_type b)
5+long long notrace __ashrdi3(long long u, word_type b)
66 {
77 DWunion uu, w;
88 word_type bm;
arch/mips/lib/bswapdi.c+1−1
@@ -1,6 +1,6 @@
11 #include <linux/module.h>
22
3−unsigned long long __bswapdi2(unsigned long long u)
3+unsigned long long notrace __bswapdi2(unsigned long long u)
44 {
55 return (((u) & 0xff00000000000000ull) >> 56) |
66 (((u) & 0x00ff000000000000ull) >> 40) |
arch/mips/lib/bswapsi.c+1−1
@@ -1,6 +1,6 @@
11 #include <linux/module.h>
22
3−unsigned int __bswapsi2(unsigned int u)
3+unsigned int notrace __bswapsi2(unsigned int u)
44 {
55 return (((u) & 0xff000000) >> 24) |
66 (((u) & 0x00ff0000) >> 8) |
arch/mips/lib/cmpdi2.c+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22
33 #include "libgcc.h"
44
5−word_type __cmpdi2(long long a, long long b)
5+word_type notrace __cmpdi2(long long a, long long b)
66 {
77 const DWunion au = {
88 .ll = a
arch/mips/lib/lshrdi3.c+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22
33 #include "libgcc.h"
44
5−long long __lshrdi3(long long u, word_type b)
5+long long notrace __lshrdi3(long long u, word_type b)
66 {
77 DWunion uu, w;
88 word_type bm;
arch/mips/lib/memcpy.S+1−1
@@ -256,7 +256,7 @@ · 255 unmodified lines
256256
257257 /*
258258 * Macro to build the __copy_user common code
259− * Arguements:
259+ * Arguments:
260260 * mode : LEGACY_MODE or EVA_MODE
261261 * from : Source operand. USEROP or KERNELOP
262262 * to : Destination operand. USEROP or KERNELOP
arch/mips/lib/ucmpdi2.c+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
22
33 #include "libgcc.h"
44
5−word_type __ucmpdi2(unsigned long long a, unsigned long long b)
5+word_type notrace __ucmpdi2(unsigned long long a, unsigned long long b)
66 {
77 const DWunion au = {.ll = a};
88 const DWunion bu = {.ll = b};
arch/mips/loongson64/loongson-3/hpet.c+1−1
@@ -212,7 +212,7 @@ static void hpet_setup(void) · 211 unmodified lines
212212 /* set hpet base address */
213213 smbus_write(SMBUS_PCI_REGB4, HPET_ADDR);
214214
215− /* enable decodeing of access to HPET MMIO*/
215+ /* enable decoding of access to HPET MMIO*/
216216 smbus_enable(SMBUS_PCI_REG40, (1 << 28));
217217
218218 /* HPET irq enable */
arch/mips/math-emu/dsemul.c+2−2
@@ -8,7 +8,7 @@ · 7 unmodified lines
88 #include "ieee754.h"
99
1010 /*
11− * Emulate the arbritrary instruction ir at xcp->cp0_epc. Required when
11+ * Emulate the arbitrary instruction ir at xcp->cp0_epc. Required when
1212 * we have to emulate the instruction in a COP1 branch delay slot. Do
1313 * not change cp0_epc due to the instruction
1414 *
@@ -88,7 +88,7 @@ int mips_dsemul(struct pt_regs *regs, mips_instruction ir, unsigned long cpc) · 73 unmodified lines
8888 fr = (struct emuframe __user *)
8989 ((regs->regs[29] - sizeof(struct emuframe)) & ~0x7);
9090
91− /* Verify that the stack pointer is not competely insane */
91+ /* Verify that the stack pointer is not completely insane */
9292 if (unlikely(!access_ok(VERIFY_WRITE, fr, sizeof(struct emuframe))))
9393 return SIGBUS;
9494
arch/mips/mm/tlbex.c+18−4
@@ -2361,8 +2361,9 @@ static void print_htw_config(void) · 2360 unmodified lines
23612361 (config & MIPS_PWFIELD_PTEI_MASK) >> MIPS_PWFIELD_PTEI_SHIFT);
23622362
23632363 config = read_c0_pwsize();
2364− pr_debug("PWSize (0x%0*lx): GDW: 0x%02lx UDW: 0x%02lx MDW: 0x%02lx PTW: 0x%02lx PTEW: 0x%02lx\n",
2364+ pr_debug("PWSize (0x%0*lx): PS: 0x%lx GDW: 0x%02lx UDW: 0x%02lx MDW: 0x%02lx PTW: 0x%02lx PTEW: 0x%02lx\n",
23652365 field, config,
2366+ (config & MIPS_PWSIZE_PS_MASK) >> MIPS_PWSIZE_PS_SHIFT,
23662367 (config & MIPS_PWSIZE_GDW_MASK) >> MIPS_PWSIZE_GDW_SHIFT,
23672368 (config & MIPS_PWSIZE_UDW_MASK) >> MIPS_PWSIZE_UDW_SHIFT,
23682369 (config & MIPS_PWSIZE_MDW_MASK) >> MIPS_PWSIZE_MDW_SHIFT,
@@ -2370,9 +2371,12 @@ static void print_htw_config(void) · 1 unmodified line
23702371 (config & MIPS_PWSIZE_PTEW_MASK) >> MIPS_PWSIZE_PTEW_SHIFT);
23712372
23722373 pwctl = read_c0_pwctl();
2373− pr_debug("PWCtl (0x%x): PWEn: 0x%x DPH: 0x%x HugePg: 0x%x Psn: 0x%x\n",
2374+ pr_debug("PWCtl (0x%x): PWEn: 0x%x XK: 0x%x XS: 0x%x XU: 0x%x DPH: 0x%x HugePg: 0x%x Psn: 0x%x\n",
23742375 pwctl,
23752376 (pwctl & MIPS_PWCTL_PWEN_MASK) >> MIPS_PWCTL_PWEN_SHIFT,
2377+ (pwctl & MIPS_PWCTL_XK_MASK) >> MIPS_PWCTL_XK_SHIFT,
2378+ (pwctl & MIPS_PWCTL_XS_MASK) >> MIPS_PWCTL_XS_SHIFT,
2379+ (pwctl & MIPS_PWCTL_XU_MASK) >> MIPS_PWCTL_XU_SHIFT,
23762380 (pwctl & MIPS_PWCTL_DPH_MASK) >> MIPS_PWCTL_DPH_SHIFT,
23772381 (pwctl & MIPS_PWCTL_HUGEPG_MASK) >> MIPS_PWCTL_HUGEPG_SHIFT,
23782382 (pwctl & MIPS_PWCTL_PSN_MASK) >> MIPS_PWCTL_PSN_SHIFT);
@@ -2427,15 +2431,25 @@ static void config_htw_params(void) · 48 unmodified lines
24272431 if (CONFIG_PGTABLE_LEVELS >= 3)
24282432 pwsize |= ilog2(PTRS_PER_PMD) << MIPS_PWSIZE_MDW_SHIFT;
24292433
2430− pwsize |= ilog2(sizeof(pte_t)/4) << MIPS_PWSIZE_PTEW_SHIFT;
2434+ /* Set pointer size to size of directory pointers */
2435+ if (config_enabled(CONFIG_64BIT))
2436+ pwsize |= MIPS_PWSIZE_PS_MASK;
2437+ /* PTEs may be multiple pointers long (e.g. with XPA) */
2438+ pwsize |= ((PTE_T_LOG2 - PGD_T_LOG2) << MIPS_PWSIZE_PTEW_SHIFT)
2439+ & MIPS_PWSIZE_PTEW_MASK;
24312440
24322441 write_c0_pwsize(pwsize);
24332442
24342443 /* Make sure everything is set before we enable the HTW */
24352444 back_to_back_c0_hazard();
24362445
2437− /* Enable HTW and disable the rest of the pwctl fields */
2446+ /*
2447+ * Enable HTW (and only for XUSeg on 64-bit), and disable the rest of
2448+ * the pwctl fields.
2449+ */
24382450 config = 1 << MIPS_PWCTL_PWEN_SHIFT;
2451+ if (config_enabled(CONFIG_64BIT))
2452+ config |= MIPS_PWCTL_XU_MASK;
24392453 write_c0_pwctl(config);
24402454 pr_info("Hardware Page Table Walker enabled\n");
24412455
arch/mips/oprofile/op_impl.h+1−1
@@ -24,7 +24,7 @@ struct op_counter_config { · 23 unmodified lines
2424 unsigned long unit_mask;
2525 };
2626
27−/* Per-architecture configury and hooks. */
27+/* Per-architecture configure and hooks. */
2828 struct op_mips_model {
2929 void (*reg_setup) (struct op_counter_config *);
3030 void (*cpu_setup) (void *dummy);
arch/mips/pci/ops-bridge.c+2−2
@@ -33,9 +33,9 @@ static u32 emulate_ioc3_cfg(int where, int size) · 32 unmodified lines
3333 * The Bridge ASIC supports both type 0 and type 1 access. Type 1 is
3434 * not really documented, so right now I can't write code which uses it.
3535 * Therefore we use type 0 accesses for now even though they won't work
36− * correcly for PCI-to-PCI bridges.
36+ * correctly for PCI-to-PCI bridges.
3737 *
38− * The function is complicated by the ultimate brokeness of the IOC3 chip
38+ * The function is complicated by the ultimate brokenness of the IOC3 chip
3939 * which is used in SGI systems. The IOC3 can only handle 32-bit PCI
4040 * accesses and does only decode parts of it's address space.
4141 */
arch/mips/pistachio/init.c+6−2
@@ -83,12 +83,16 @@ static void __init plat_setup_iocoherency(void) · 82 unmodified lines
8383 }
8484 }
8585
86−void __init plat_mem_setup(void)
86+void __init *plat_get_fdt(void)
8787 {
8888 if (fw_arg0 != -2)
8989 panic("Device-tree not present");
90+ return (void *)fw_arg1;
91+}
9092
91− __dt_setup_arch((void *)fw_arg1);
93+void __init plat_mem_setup(void)
94+{
95+ __dt_setup_arch(plat_get_fdt());
9296
9397 plat_setup_iocoherency();
9498 }
arch/mips/ralink/mt7620.c+106−6
@@ -188,6 +188,41 @@ static struct rt2880_pmx_func gpio_grp_mt7628[] = { · 187 unmodified lines
188188 FUNC("gpio", 0, 11, 1),
189189 };
190190
191+static struct rt2880_pmx_func p4led_kn_grp_mt7628[] = {
192+ FUNC("jtag", 3, 30, 1),
193+ FUNC("util", 2, 30, 1),
194+ FUNC("gpio", 1, 30, 1),
195+ FUNC("p4led_kn", 0, 30, 1),
196+};
197+
198+static struct rt2880_pmx_func p3led_kn_grp_mt7628[] = {
199+ FUNC("jtag", 3, 31, 1),
200+ FUNC("util", 2, 31, 1),
201+ FUNC("gpio", 1, 31, 1),
202+ FUNC("p3led_kn", 0, 31, 1),
203+};
204+
205+static struct rt2880_pmx_func p2led_kn_grp_mt7628[] = {
206+ FUNC("jtag", 3, 32, 1),
207+ FUNC("util", 2, 32, 1),
208+ FUNC("gpio", 1, 32, 1),
209+ FUNC("p2led_kn", 0, 32, 1),
210+};
211+
212+static struct rt2880_pmx_func p1led_kn_grp_mt7628[] = {
213+ FUNC("jtag", 3, 33, 1),
214+ FUNC("util", 2, 33, 1),
215+ FUNC("gpio", 1, 33, 1),
216+ FUNC("p1led_kn", 0, 33, 1),
217+};
218+
219+static struct rt2880_pmx_func p0led_kn_grp_mt7628[] = {
220+ FUNC("jtag", 3, 34, 1),
221+ FUNC("rsvd", 2, 34, 1),
222+ FUNC("gpio", 1, 34, 1),
223+ FUNC("p0led_kn", 0, 34, 1),
224+};
225+
191226 static struct rt2880_pmx_func wled_kn_grp_mt7628[] = {
192227 FUNC("rsvd", 3, 35, 1),
193228 FUNC("rsvd", 2, 35, 1),
@@ -195,16 +230,61 @@ static struct rt2880_pmx_func wled_kn_grp_mt7628[] = { · 1 unmodified line
195230 FUNC("wled_kn", 0, 35, 1),
196231 };
197232
233+static struct rt2880_pmx_func p4led_an_grp_mt7628[] = {
234+ FUNC("jtag", 3, 39, 1),
235+ FUNC("util", 2, 39, 1),
236+ FUNC("gpio", 1, 39, 1),
237+ FUNC("p4led_an", 0, 39, 1),
238+};
239+
240+static struct rt2880_pmx_func p3led_an_grp_mt7628[] = {
241+ FUNC("jtag", 3, 40, 1),
242+ FUNC("util", 2, 40, 1),
243+ FUNC("gpio", 1, 40, 1),
244+ FUNC("p3led_an", 0, 40, 1),
245+};
246+
247+static struct rt2880_pmx_func p2led_an_grp_mt7628[] = {
248+ FUNC("jtag", 3, 41, 1),
249+ FUNC("util", 2, 41, 1),
250+ FUNC("gpio", 1, 41, 1),
251+ FUNC("p2led_an", 0, 41, 1),
252+};
253+
254+static struct rt2880_pmx_func p1led_an_grp_mt7628[] = {
255+ FUNC("jtag", 3, 42, 1),
256+ FUNC("util", 2, 42, 1),
257+ FUNC("gpio", 1, 42, 1),
258+ FUNC("p1led_an", 0, 42, 1),
259+};
260+
261+static struct rt2880_pmx_func p0led_an_grp_mt7628[] = {
262+ FUNC("jtag", 3, 43, 1),
263+ FUNC("rsvd", 2, 43, 1),
264+ FUNC("gpio", 1, 43, 1),
265+ FUNC("p0led_an", 0, 43, 1),
266+};
267+
198268 static struct rt2880_pmx_func wled_an_grp_mt7628[] = {
199− FUNC("rsvd", 3, 35, 1),
200− FUNC("rsvd", 2, 35, 1),
201− FUNC("gpio", 1, 35, 1),
202− FUNC("wled_an", 0, 35, 1),
269+ FUNC("rsvd", 3, 44, 1),
270+ FUNC("rsvd", 2, 44, 1),
271+ FUNC("gpio", 1, 44, 1),
272+ FUNC("wled_an", 0, 44, 1),
203273 };
204274
205275 #define MT7628_GPIO_MODE_MASK 0x3
206276
277+#define MT7628_GPIO_MODE_P4LED_KN 58
278+#define MT7628_GPIO_MODE_P3LED_KN 56
279+#define MT7628_GPIO_MODE_P2LED_KN 54
280+#define MT7628_GPIO_MODE_P1LED_KN 52
281+#define MT7628_GPIO_MODE_P0LED_KN 50
207282 #define MT7628_GPIO_MODE_WLED_KN 48
283+#define MT7628_GPIO_MODE_P4LED_AN 42
284+#define MT7628_GPIO_MODE_P3LED_AN 40
285+#define MT7628_GPIO_MODE_P2LED_AN 38
286+#define MT7628_GPIO_MODE_P1LED_AN 36
287+#define MT7628_GPIO_MODE_P0LED_AN 34
208288 #define MT7628_GPIO_MODE_WLED_AN 32
209289 #define MT7628_GPIO_MODE_PWM1 30
210290 #define MT7628_GPIO_MODE_PWM0 28
@@ -223,9 +303,9 @@ static struct rt2880_pmx_func wled_an_grp_mt7628[] = { · 12 unmodified lines
223303 #define MT7628_GPIO_MODE_GPIO 0
224304
225305 static struct rt2880_pmx_group mt7628an_pinmux_data[] = {
226− GRP_G("pmw1", pwm1_grp_mt7628, MT7628_GPIO_MODE_MASK,
306+ GRP_G("pwm1", pwm1_grp_mt7628, MT7628_GPIO_MODE_MASK,
227307 1, MT7628_GPIO_MODE_PWM1),
228− GRP_G("pmw0", pwm0_grp_mt7628, MT7628_GPIO_MODE_MASK,
308+ GRP_G("pwm0", pwm0_grp_mt7628, MT7628_GPIO_MODE_MASK,
229309 1, MT7628_GPIO_MODE_PWM0),
230310 GRP_G("uart2", uart2_grp_mt7628, MT7628_GPIO_MODE_MASK,
231311 1, MT7628_GPIO_MODE_UART2),
@@ -251,8 +331,28 @@ static struct rt2880_pmx_group mt7628an_pinmux_data[] = { · 19 unmodified lines
251331 1, MT7628_GPIO_MODE_GPIO),
252332 GRP_G("wled_an", wled_an_grp_mt7628, MT7628_GPIO_MODE_MASK,
253333 1, MT7628_GPIO_MODE_WLED_AN),
334+ GRP_G("p0led_an", p0led_an_grp_mt7628, MT7628_GPIO_MODE_MASK,
335+ 1, MT7628_GPIO_MODE_P0LED_AN),
336+ GRP_G("p1led_an", p1led_an_grp_mt7628, MT7628_GPIO_MODE_MASK,
337+ 1, MT7628_GPIO_MODE_P1LED_AN),
338+ GRP_G("p2led_an", p2led_an_grp_mt7628, MT7628_GPIO_MODE_MASK,
339+ 1, MT7628_GPIO_MODE_P2LED_AN),
340+ GRP_G("p3led_an", p3led_an_grp_mt7628, MT7628_GPIO_MODE_MASK,
341+ 1, MT7628_GPIO_MODE_P3LED_AN),
342+ GRP_G("p4led_an", p4led_an_grp_mt7628, MT7628_GPIO_MODE_MASK,
343+ 1, MT7628_GPIO_MODE_P4LED_AN),
254344 GRP_G("wled_kn", wled_kn_grp_mt7628, MT7628_GPIO_MODE_MASK,
255345 1, MT7628_GPIO_MODE_WLED_KN),
346+ GRP_G("p0led_kn", p0led_kn_grp_mt7628, MT7628_GPIO_MODE_MASK,
347+ 1, MT7628_GPIO_MODE_P0LED_KN),
348+ GRP_G("p1led_kn", p1led_kn_grp_mt7628, MT7628_GPIO_MODE_MASK,
349+ 1, MT7628_GPIO_MODE_P1LED_KN),
350+ GRP_G("p2led_kn", p2led_kn_grp_mt7628, MT7628_GPIO_MODE_MASK,
351+ 1, MT7628_GPIO_MODE_P2LED_KN),
352+ GRP_G("p3led_kn", p3led_kn_grp_mt7628, MT7628_GPIO_MODE_MASK,
353+ 1, MT7628_GPIO_MODE_P3LED_KN),
354+ GRP_G("p4led_kn", p4led_kn_grp_mt7628, MT7628_GPIO_MODE_MASK,
355+ 1, MT7628_GPIO_MODE_P4LED_KN),
256356 { 0 }
257357 };
258358
arch/mips/sgi-ip27/ip27-hubio.c+1−1
@@ -105,7 +105,7 @@ static void hub_setup_prb(nasid_t nasid, int prbnum, int credits) · 104 unmodified lines
105105 prb.iprb_ff = force_fire_and_forget ? 1 : 0;
106106
107107 /*
108− * Set the appropriate number of PIO cresits for the widget.
108+ * Set the appropriate number of PIO credits for the widget.
109109 */
110110 prb.iprb_xtalkctr = credits;
111111
arch/mips/sgi-ip27/ip27-nmi.c+1−1
@@ -23,7 +23,7 @@ typedef unsigned long machreg_t; · 22 unmodified lines
2323 static arch_spinlock_t nmi_lock = __ARCH_SPIN_LOCK_UNLOCKED;
2424
2525 /*
26− * Lets see what else we need to do here. Set up sp, gp?
26+ * Let's see what else we need to do here. Set up sp, gp?
2727 */
2828 void nmi_dump(void)
2929 {
arch/mips/sgi-ip27/ip27-xtalk.c+1−1
@@ -67,7 +67,7 @@ static int xbow_probe(nasid_t nasid) · 66 unmodified lines
6767 return -ENODEV;
6868
6969 /*
70− * Okay, here's a xbow. Lets arbitrate and find
70+ * Okay, here's a xbow. Let's arbitrate and find
7171 * out if we should initialize it. Set enabled
7272 * hub connected at highest or lowest widget as
7373 * master.
arch/mips/sni/rm200.c+1−1
@@ -263,7 +263,7 @@ spurious_8259A_irq: · 262 unmodified lines
263263 static int spurious_irq_mask;
264264 /*
265265 * At this point we can be sure the IRQ is spurious,
266− * lets ACK and report it. [once per IRQ]
266+ * let's ACK and report it. [once per IRQ]
267267 */
268268 if (!(spurious_irq_mask & irqmask)) {
269269 printk(KERN_DEBUG
arch/mips/vdso/Makefile+3−1
@@ -5,10 +5,12 @@ obj-vdso-y := elf.o gettimeofday.o sigreturn.o · 4 unmodified lines
55 ccflags-vdso := \
66 $(filter -I%,$(KBUILD_CFLAGS)) \
77 $(filter -E%,$(KBUILD_CFLAGS)) \
8+ $(filter -mmicromips,$(KBUILD_CFLAGS)) \
89 $(filter -march=%,$(KBUILD_CFLAGS))
910 cflags-vdso := $(ccflags-vdso) \
1011 $(filter -W%,$(filter-out -Wa$(comma)%,$(KBUILD_CFLAGS))) \
11− -O2 -g -fPIC -fno-common -fno-builtin -G 0 -DDISABLE_BRANCH_PROFILING \
12+ -O2 -g -fPIC -fno-strict-aliasing -fno-common -fno-builtin -G 0 \
13+ -DDISABLE_BRANCH_PROFILING \
1214 $(call cc-option, -fno-stack-protector)
1315 aflags-vdso := $(ccflags-vdso) \
1416 $(filter -I%,$(KBUILD_CFLAGS)) \
arch/mips/vr41xx/common/cmu.c+1−1
@@ -3,7 +3,7 @@ · 2 unmodified lines
33 *
44 * Copyright (C) 2001-2002 MontaVista Software Inc.
55 * Author: Yoichi Yuasa <source@mvista.com>
6− * Copuright (C) 2003-2005 Yoichi Yuasa <yuasa@linux-mips.org>
6+ * Copyright (C) 2003-2005 Yoichi Yuasa <yuasa@linux-mips.org>
77 *
88 * This program is free software; you can redistribute it and/or modify
99 * it under the terms of the GNU General Public License as published by
drivers/irqchip/irq-mips-gic.c+9−1
@@ -968,7 +968,7 @@ static void __init __gic_init(unsigned long gic_base_addr, · 967 unmodified lines
968968 unsigned int cpu_vec, unsigned int irqbase,
969969 struct device_node *node)
970970 {
971− unsigned int gicconfig;
971+ unsigned int gicconfig, cpu;
972972 unsigned int v[2];
973973
974974 __gic_base_addr = gic_base_addr;
@@ -985,6 +985,14 @@ static void __init __gic_init(unsigned long gic_base_addr, · 10 unmodified lines
985985 gic_vpes = gic_vpes + 1;
986986
987987 if (cpu_has_veic) {
988+ /* Set EIC mode for all VPEs */
989+ for_each_present_cpu(cpu) {
990+ gic_write(GIC_REG(VPE_LOCAL, GIC_VPE_OTHER_ADDR),
991+ mips_cm_vp_id(cpu));
992+ gic_write(GIC_REG(VPE_OTHER, GIC_VPE_CTL),
993+ GIC_VPE_CTL_EIC_MODE_MSK);
994+ }
995+
988996 /* Always use vector 1 in EIC mode */
989997 gic_cpu_pin = 0;
990998 timer_cpu_pin = gic_cpu_pin;