Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'mips_fixes_5.2_2' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux

Pull MIPS fixes from Paul Burton:
"A few more MIPS fixes:

- Fix a silly typo in virt_addr_valid which led to completely bogus
behavior (that happened to stop tripping up hardened usercopy
despite being broken).

- Fix UART parity setup on AR933x systems.

- A build fix for non-Linux build machines.

- Have the 'all' make target build DTBs, primarily to fit in with the
behavior of scripts/package/builddeb.

- Handle an execution hazard in TLB exceptions that use KScratch
registers, which could inadvertently clobber the $1 register on
some generally higher-end out-of-order CPUs.

- A MAINTAINERS update to fix the path to the NAND driver for Ingenic
systems"

* tag 'mips_fixes_5.2_2' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux:
MAINTAINERS: Correct path to moved files
MIPS: Add missing EHB in mtc0 -> mfc0 sequence.
MIPS: have "plain" make calls build dtbs for selected platforms
MIPS: fix build on non-linux hosts
MIPS: ath79: fix ar933x uart parity mode
MIPS: Fix bounds check virt_addr_valid

+29 -15
+1 -1
MAINTAINERS
··· 7810 7810 M: Harvey Hunt <harveyhuntnexus@gmail.com> 7811 7811 L: linux-mtd@lists.infradead.org 7812 7812 S: Maintained 7813 - F: drivers/mtd/nand/raw/jz4780_* 7813 + F: drivers/mtd/nand/raw/ingenic/ 7814 7814 7815 7815 INOTIFY 7816 7816 M: Jan Kara <jack@suse.cz>
+2 -1
arch/mips/Makefile
··· 17 17 $(Q)$(MAKE) $(build)=arch/mips/boot/tools relocs 18 18 19 19 KBUILD_DEFCONFIG := 32r2el_defconfig 20 + KBUILD_DTBS := dtbs 20 21 21 22 # 22 23 # Select the object file format to substitute into the linker script. ··· 385 384 vmlinux.64: vmlinux 386 385 $(call cmd,64) 387 386 388 - all: $(all-y) 387 + all: $(all-y) $(KBUILD_DTBS) 389 388 390 389 # boot 391 390 $(boot-y): $(vmlinux-32) FORCE
+2
arch/mips/boot/compressed/Makefile
··· 78 78 $(obj)/piggy.o: $(obj)/dummy.o $(obj)/vmlinux.bin.z FORCE 79 79 $(call if_changed,objcopy) 80 80 81 + HOSTCFLAGS_calc_vmlinuz_load_addr.o += $(LINUXINCLUDE) 82 + 81 83 # Calculate the load address of the compressed kernel image 82 84 hostprogs-y := calc_vmlinuz_load_addr 83 85
+1 -1
arch/mips/boot/compressed/calc_vmlinuz_load_addr.c
··· 9 9 #include <stdint.h> 10 10 #include <stdio.h> 11 11 #include <stdlib.h> 12 - #include "../../../../include/linux/sizes.h" 12 + #include <linux/sizes.h> 13 13 14 14 int main(int argc, char *argv[]) 15 15 {
+2 -2
arch/mips/include/asm/mach-ath79/ar933x_uart.h
··· 24 24 #define AR933X_UART_CS_PARITY_S 0 25 25 #define AR933X_UART_CS_PARITY_M 0x3 26 26 #define AR933X_UART_CS_PARITY_NONE 0 27 - #define AR933X_UART_CS_PARITY_ODD 1 28 - #define AR933X_UART_CS_PARITY_EVEN 2 27 + #define AR933X_UART_CS_PARITY_ODD 2 28 + #define AR933X_UART_CS_PARITY_EVEN 3 29 29 #define AR933X_UART_CS_IF_MODE_S 2 30 30 #define AR933X_UART_CS_IF_MODE_M 0x3 31 31 #define AR933X_UART_CS_IF_MODE_NONE 0
+1 -1
arch/mips/mm/mmap.c
··· 203 203 204 204 bool __virt_addr_valid(const volatile void *kaddr) 205 205 { 206 - unsigned long vaddr = (unsigned long)vaddr; 206 + unsigned long vaddr = (unsigned long)kaddr; 207 207 208 208 if ((vaddr < PAGE_OFFSET) || (vaddr >= MAP_BASE)) 209 209 return false;
+20 -9
arch/mips/mm/tlbex.c
··· 391 391 static void build_restore_work_registers(u32 **p) 392 392 { 393 393 if (scratch_reg >= 0) { 394 + uasm_i_ehb(p); 394 395 UASM_i_MFC0(p, 1, c0_kscratch(), scratch_reg); 395 396 return; 396 397 } ··· 669 668 uasm_i_mtc0(p, 0, C0_PAGEMASK); 670 669 uasm_il_b(p, r, lid); 671 670 } 672 - if (scratch_reg >= 0) 671 + if (scratch_reg >= 0) { 672 + uasm_i_ehb(p); 673 673 UASM_i_MFC0(p, 1, c0_kscratch(), scratch_reg); 674 - else 674 + } else { 675 675 UASM_i_LW(p, 1, scratchpad_offset(0), 0); 676 + } 676 677 } else { 677 678 /* Reset default page size */ 678 679 if (PM_DEFAULT_MASK >> 16) { ··· 941 938 uasm_i_jr(p, ptr); 942 939 943 940 if (mode == refill_scratch) { 944 - if (scratch_reg >= 0) 941 + if (scratch_reg >= 0) { 942 + uasm_i_ehb(p); 945 943 UASM_i_MFC0(p, 1, c0_kscratch(), scratch_reg); 946 - else 944 + } else { 947 945 UASM_i_LW(p, 1, scratchpad_offset(0), 0); 946 + } 948 947 } else { 949 948 uasm_i_nop(p); 950 949 } ··· 1263 1258 UASM_i_MTC0(p, odd, C0_ENTRYLO1); /* load it */ 1264 1259 1265 1260 if (c0_scratch_reg >= 0) { 1261 + uasm_i_ehb(p); 1266 1262 UASM_i_MFC0(p, scratch, c0_kscratch(), c0_scratch_reg); 1267 1263 build_tlb_write_entry(p, l, r, tlb_random); 1268 1264 uasm_l_leave(l, *p); ··· 1609 1603 uasm_i_dinsm(&p, a0, 0, 29, 64 - 29); 1610 1604 uasm_l_tlbl_goaround1(&l, p); 1611 1605 UASM_i_SLL(&p, a0, a0, 11); 1612 - uasm_i_jr(&p, 31); 1613 1606 UASM_i_MTC0(&p, a0, C0_CONTEXT); 1607 + uasm_i_jr(&p, 31); 1608 + uasm_i_ehb(&p); 1614 1609 } else { 1615 1610 /* PGD in c0_KScratch */ 1616 - uasm_i_jr(&p, 31); 1617 1611 if (cpu_has_ldpte) 1618 1612 UASM_i_MTC0(&p, a0, C0_PWBASE); 1619 1613 else 1620 1614 UASM_i_MTC0(&p, a0, c0_kscratch(), pgd_reg); 1615 + uasm_i_jr(&p, 31); 1616 + uasm_i_ehb(&p); 1621 1617 } 1622 1618 #else 1623 1619 #ifdef CONFIG_SMP ··· 1633 1625 UASM_i_LA_mostly(&p, a2, pgdc); 1634 1626 UASM_i_SW(&p, a0, uasm_rel_lo(pgdc), a2); 1635 1627 #endif /* SMP */ 1636 - uasm_i_jr(&p, 31); 1637 1628 1638 1629 /* if pgd_reg is allocated, save PGD also to scratch register */ 1639 - if (pgd_reg != -1) 1630 + if (pgd_reg != -1) { 1640 1631 UASM_i_MTC0(&p, a0, c0_kscratch(), pgd_reg); 1641 - else 1632 + uasm_i_jr(&p, 31); 1633 + uasm_i_ehb(&p); 1634 + } else { 1635 + uasm_i_jr(&p, 31); 1642 1636 uasm_i_nop(&p); 1637 + } 1643 1638 #endif 1644 1639 if (p >= (u32 *)tlbmiss_handler_setup_pgd_end) 1645 1640 panic("tlbmiss_handler_setup_pgd space exceeded");