linux-stable/arch/mips
Florian Fainelli 8a2b456665 MIPS: Fixed __debug_virt_addr_valid()
It is permissible for kernel code to call virt_to_phys() against virtual
addresses that are in KSEG0 or KSEG1 and we need to be dealing with both
types. Rewrite the test condition to ensure that the kernel virtual
addresses are above PAGE_OFFSET which they must be, and below KSEG2
where the non-linear mapping starts.

For EVA, there is not much that we can do given the linear address range
that is offered, so just return any virtual address as being valid.

Finally, when HIGHMEM is not enabled, all virtual addresses are assumed
to be valid as well.

Fixes: dfad83cb71 ("MIPS: Add support for CONFIG_DEBUG_VIRTUAL")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Serge Semin <fancer.lancer@gmail.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
2022-07-15 14:22:51 +02:00
..
alchemy MIPS: Alchemy: devboards: Remove duplicate 'the' in two places. 2022-07-05 11:11:36 +02:00
ar7 mips: ar7: convert to CONFIG_COMMON_CLK 2021-06-08 17:00:09 +02:00
ath25 MIPS: ath25: Constify static irq_domain_ops 2022-02-22 09:39:03 +01:00
ath79 MIPS: Remove redundant definitions of device_tree_init() 2022-03-14 15:09:02 +01:00
bcm47xx MIPS: BCM47XX: Add support for Netgear WNR3500L v2 2022-07-15 14:22:47 +02:00
bcm63xx linux-watchdog 5.17-rc1 tag 2022-01-17 08:07:57 +02:00
bmips MIPS: bmips: Fix compiler warning observed on W=1 build 2022-05-23 18:28:03 +02:00
boot MIPS: dts: align gpio-key node names with dtschema 2022-07-14 11:51:11 +02:00
cavium-octeon mips: cavium-octeon: Fix missing of_node_put() in octeon2_usb_clocks_start 2022-07-05 11:16:03 +02:00
cobalt MIPS: Remove empty prom_free_prom_memory functions 2021-01-07 17:11:33 +01:00
configs MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
crypto MIPS: crypto: Fix CRC32 code 2022-04-01 10:19:03 +02:00
dec MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
fw MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
generic arch: mips: generic: Add missing of_node_put() in board-ranchu.c 2022-06-21 17:04:30 +02:00
include MIPS: BCM47XX: Add support for Netgear WNR3500L v2 2022-07-15 14:22:47 +02:00
ingenic MIPS: Kconfig: ingenic: Ensure MACH_INGENIC_GENERIC selects all SoCs 2021-06-01 11:44:47 +02:00
jazz MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
kernel MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
kvm MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
lantiq mips: lantiq: Add missing of_node_put() in irq.c 2022-06-21 22:34:03 +02:00
lib MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
loongson2ef MIPS: Loongson{2ef,64}: Wrap -mno-branch-likely with cc-option 2022-02-07 18:30:12 +01:00
loongson32 MIPS: loongson32: Kconfig: Remove extra space 2022-05-23 11:08:45 +02:00
loongson64 MIPS: Loongson64: Fix section mismatch warning 2022-07-05 11:20:52 +02:00
math-emu MIPS: math-emu: Use the bitmap API to allocate bitmaps 2022-07-11 10:27:50 +02:00
mm MIPS: Fixed __debug_virt_addr_valid() 2022-07-15 14:22:51 +02:00
mti-malta mips: mti-malta: Fix refcount leak in malta-time.c 2022-06-21 17:04:30 +02:00
n64 mips: Add N64 machine type 2021-01-22 11:40:00 +01:00
net MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
pci MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
pic32 mips/pic32/pic32mzda: Fix refcount leak bugs 2022-06-21 17:04:54 +02:00
power
ralink mips: ralink: Fix refcount leak in of.c 2022-06-21 17:04:30 +02:00
rb532 MIPS: rb532: move GPIOD definition into C-files 2022-03-30 20:26:26 +02:00
sgi-ip22 mips: sgi-ip22: Drop redundant check from .remove() 2022-07-05 11:10:17 +02:00
sgi-ip27 MIPS: SGI-IP27: Free some unused memory 2022-04-26 15:06:00 +02:00
sgi-ip30 MIPS: SGI-IP30: Free some unused memory 2022-04-26 15:07:23 +02:00
sgi-ip32 MIPS: Allow modules to set board_be_handler 2021-11-09 16:07:26 +01:00
sibyte Cleanups and fixes 2022-05-30 11:01:50 -07:00
sni MIPS: sni: Fix the build 2021-10-18 18:09:54 +02:00
tools MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
txx9 MIPS: fix typos in comments 2022-05-04 22:22:59 +02:00
vdso mips: Enable KCSAN 2022-02-07 18:31:57 +01:00
Kbuild kbuild: use more subdir- for visiting subdirectories while cleaning 2021-10-24 13:49:46 +09:00
Kbuild.platforms MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
Kconfig MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
Kconfig.debug tracing: Refactor TRACE_IRQFLAGS_SUPPORT in Kconfig 2021-08-16 11:37:21 -04:00
Makefile MIPS: Remove VR41xx support 2022-07-14 11:52:29 +02:00
Makefile.postlink