A few MIPS fixes:
- fallthrough fallout fix - BMIPS fixes - MSA fix to avoid leaking MSA register contents - Loongson perf and cpu feature fix - SNI interrupt fix -----BEGIN PGP SIGNATURE----- iQJOBAABCAA4FiEEbt46xwy6kEcDOXoUeZbBVTGwZHAFAl9SMkAaHHRzYm9nZW5k QGFscGhhLmZyYW5rZW4uZGUACgkQeZbBVTGwZHA/Lw/8Cp19eTYF0ps60u9i2Gen 5e2yY7TlO1gBerdyA4iX/Jd8wKYu0cCBreHAF9JzdFi1z9s7arguB6DWUOYwa/W/ t0q86CW+EddfwJzjdY+H7cnNQWhaLGeKGXUzevI7v2kd3LAAyPvm7vUeR1zYxVol IJ3XyLGo+NN3xLecc2sSDVAWQR+wfy+1pARbVimkh4wlJjZcrvWgl8+jYv15p8u5 DPywG+wgkRJNWV1hX54qh9bxNOtLajFhAsWIluwAVf/mmQCguY0Gd8bcBDYFqyFt HZPuH5Rhmnm8/alqetzcXCFN8Y9IwzjOlOemwENCs1/0O49mdCF08uOd7wp9Sek2 aXlksJBtNB7jVzYZAiwnQcm/L84gXaxkdMjf47jTzTFkMBn+3/lbcGfKDptDc7U0 sNQmOU1y9y69UP2G7cSGH5cOco7LMReTTDB+35X/wWMnthKh5iw5R2nK0vJzCpWS Vq2PD8vIsO+58rlHFwOv6zZmGOQlCb93Nuzk7zx7GQMAEN05Av9nVC91n47MH352 VVwTv2dsBgNBDyhukz7YFpZLF11K9hYz5+661q0SGmRyKe5a4OD8lVV1kqQ6e8hp dlmcgT/B93cEvs9qnx5E13UO5UyPYn9Trbl2qppMvL9zXyc/jdDnoMfH48LK22YP hUbnUmjJAD55PLFJ+dl/EXM= =HWpo -----END PGP SIGNATURE----- Merge tag 'mips_fixes_5.9_1' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux Pull MIPS fixes from Thomas Bogendoerfer: "A few MIPS fixes: - fallthrough fallout fix - BMIPS fixes - MSA fix to avoid leaking MSA register contents - Loongson perf and cpu feature fix - SNI interrupt fix" * tag 'mips_fixes_5.9_1' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux: MIPS: SNI: Fix SCSI interrupt MIPS: add missing MSACSR and upper MSA initialization MIPS: perf: Fix wrong check condition of Loongson event IDs mips/oprofile: Fix fallthrough placement MIPS: Loongson64: Remove unnecessary inclusion of boot_param.h MIPS: BMIPS: Also call bmips_cpu_setup() for secondary cores MIPS: mm: BMIPS5000 has inclusive physical caches MIPS: Loongson64: Do not override watch and ejtag feature
This commit is contained in:
commit
16bf121b2d
|
@ -26,7 +26,6 @@
|
|||
#define cpu_has_counter 1
|
||||
#define cpu_has_dc_aliases (PAGE_SIZE < 0x4000)
|
||||
#define cpu_has_divec 0
|
||||
#define cpu_has_ejtag 0
|
||||
#define cpu_has_inclusive_pcaches 1
|
||||
#define cpu_has_llsc 1
|
||||
#define cpu_has_mcheck 0
|
||||
|
@ -42,7 +41,6 @@
|
|||
#define cpu_has_veic 0
|
||||
#define cpu_has_vint 0
|
||||
#define cpu_has_vtag_icache 0
|
||||
#define cpu_has_watch 1
|
||||
#define cpu_has_wsbh 1
|
||||
#define cpu_has_ic_fills_f_dc 1
|
||||
#define cpu_hwrena_impl_bits 0xc0000000
|
||||
|
|
|
@ -2,8 +2,6 @@
|
|||
#ifndef __ASM_MACH_LOONGSON64_IRQ_H_
|
||||
#define __ASM_MACH_LOONGSON64_IRQ_H_
|
||||
|
||||
#include <boot_param.h>
|
||||
|
||||
/* cpu core interrupt numbers */
|
||||
#define NR_IRQS_LEGACY 16
|
||||
#define NR_MIPS_CPU_IRQS 8
|
||||
|
|
|
@ -9,7 +9,6 @@
|
|||
#ifndef _ASM_MACH_LOONGSON64_MMZONE_H
|
||||
#define _ASM_MACH_LOONGSON64_MMZONE_H
|
||||
|
||||
#include <boot_param.h>
|
||||
#define NODE_ADDRSPACE_SHIFT 44
|
||||
#define NODE0_ADDRSPACE_OFFSET 0x000000000000UL
|
||||
#define NODE1_ADDRSPACE_OFFSET 0x100000000000UL
|
||||
|
|
|
@ -1898,8 +1898,8 @@ static const struct mips_perf_event *mipsxx_pmu_map_raw_event(u64 config)
|
|||
(base_id >= 64 && base_id < 90) ||
|
||||
(base_id >= 128 && base_id < 164) ||
|
||||
(base_id >= 192 && base_id < 200) ||
|
||||
(base_id >= 256 && base_id < 274) ||
|
||||
(base_id >= 320 && base_id < 358) ||
|
||||
(base_id >= 256 && base_id < 275) ||
|
||||
(base_id >= 320 && base_id < 361) ||
|
||||
(base_id >= 384 && base_id < 574))
|
||||
break;
|
||||
|
||||
|
|
|
@ -239,6 +239,8 @@ static int bmips_boot_secondary(int cpu, struct task_struct *idle)
|
|||
*/
|
||||
static void bmips_init_secondary(void)
|
||||
{
|
||||
bmips_cpu_setup();
|
||||
|
||||
switch (current_cpu_type()) {
|
||||
case CPU_BMIPS4350:
|
||||
case CPU_BMIPS4380:
|
||||
|
|
|
@ -1287,6 +1287,18 @@ static int enable_restore_fp_context(int msa)
|
|||
err = own_fpu_inatomic(1);
|
||||
if (msa && !err) {
|
||||
enable_msa();
|
||||
/*
|
||||
* with MSA enabled, userspace can see MSACSR
|
||||
* and MSA regs, but the values in them are from
|
||||
* other task before current task, restore them
|
||||
* from saved fp/msa context
|
||||
*/
|
||||
write_msa_csr(current->thread.fpu.msacsr);
|
||||
/*
|
||||
* own_fpu_inatomic(1) just restore low 64bit,
|
||||
* fix the high 64bit
|
||||
*/
|
||||
init_msa_upper();
|
||||
set_thread_flag(TIF_USEDMSA);
|
||||
set_thread_flag(TIF_MSA_CTX_LIVE);
|
||||
}
|
||||
|
|
|
@ -1712,7 +1712,11 @@ static void setup_scache(void)
|
|||
printk("MIPS secondary cache %ldkB, %s, linesize %d bytes.\n",
|
||||
scache_size >> 10,
|
||||
way_string[c->scache.ways], c->scache.linesz);
|
||||
|
||||
if (current_cpu_type() == CPU_BMIPS5000)
|
||||
c->options |= MIPS_CPU_INCLUSIVE_CACHES;
|
||||
}
|
||||
|
||||
#else
|
||||
if (!(c->scache.flags & MIPS_CACHE_NOT_PRESENT))
|
||||
panic("Dunno how to handle MIPS32 / MIPS64 second level cache");
|
||||
|
|
|
@ -245,7 +245,6 @@ static int mipsxx_perfcount_handler(void)
|
|||
|
||||
switch (counters) {
|
||||
#define HANDLE_COUNTER(n) \
|
||||
fallthrough; \
|
||||
case n + 1: \
|
||||
control = r_c0_perfctrl ## n(); \
|
||||
counter = r_c0_perfcntr ## n(); \
|
||||
|
@ -256,8 +255,11 @@ static int mipsxx_perfcount_handler(void)
|
|||
handled = IRQ_HANDLED; \
|
||||
}
|
||||
HANDLE_COUNTER(3)
|
||||
fallthrough;
|
||||
HANDLE_COUNTER(2)
|
||||
fallthrough;
|
||||
HANDLE_COUNTER(1)
|
||||
fallthrough;
|
||||
HANDLE_COUNTER(0)
|
||||
}
|
||||
|
||||
|
|
|
@ -222,8 +222,8 @@ void __init sni_a20r_irq_init(void)
|
|||
irq_set_chip_and_handler(i, &a20r_irq_type, handle_level_irq);
|
||||
sni_hwint = a20r_hwint;
|
||||
change_c0_status(ST0_IM, IE_IRQ0);
|
||||
if (request_irq(SNI_A20R_IRQ_BASE + 3, sni_isa_irq_handler, 0, "ISA",
|
||||
NULL))
|
||||
if (request_irq(SNI_A20R_IRQ_BASE + 3, sni_isa_irq_handler,
|
||||
IRQF_SHARED, "ISA", sni_isa_irq_handler))
|
||||
pr_err("Failed to register ISA interrupt\n");
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue