Watch
1
Fork
You've already forked kernel_a52xq
0
mirror of https://github.com/a52xq-dev/kernel.git synced 2026-10-18 21:58:11 +07:00
kernel_a52xq/drivers/misc/sgi-gru
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Gustavo A. R. Silva 3e31936ba0 drivers/misc/sgi-gru: fix Spectre v1 vulnerability
commit fee05f455ceb5c670cbe48e2f9454ebc4a388554 upstream.

req.gid can be indirectly controlled by user-space, hence leading to
a potential exploitation of the Spectre variant 1 vulnerability.

This issue was detected with the help of Smatch:

vers/misc/sgi-gru/grukdump.c:200 gru_dump_chiplet_request() warn:
potential spectre issue 'gru_base' [w]

Fix this by sanitizing req.gid before calling macro GID_TO_GRU, which
uses it to index gru_base.

Notice that given that speculation windows are large, the policy is
to kill the speculation on the first load and not worry if it can be
completed with a dependent load/store [1].

[1] https://marc.info/?l=linux-kernel&m=152449131114778&w=2

Cc: stable@vger.kernel.org
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-11-27 16:13:10 +01:00
..
gru.h gru: improve GRU TLB dropin statistics 2009-12-16 07:20:17 -08:00
gru_instructions.h Add #includes needed to permit the removal of asm/system.h 2012-03-28 18:30:03 +01:00
grufault.c mm: convert generic code to 5-level paging 2017-03-09 11:48:47 -08:00
grufile.c x86/UV: Fix conditional in gru_exit() 2014-04-01 12:10:45 +02:00
gruhandles.c misc: sgi-gru: gruhandles.c: Remove unused function 2015-10-04 12:55:59 +01:00
gruhandles.h misc: sgi-gru: gruhandles.c: Remove unused function 2015-10-04 12:55:59 +01:00
grukdump.c drivers/misc/sgi-gru: fix Spectre v1 vulnerability 2018-11-27 16:13:10 +01:00
grukservices.c x86/platform/UV: Remove Obsolete GRU MMR address translation 2016-05-04 08:48:51 +02:00
grukservices.h X86: uv: implement a gru_read_gpa kernel function 2009-12-16 07:20:13 -08:00
grulib.h gru: improve GRU TLB dropin statistics 2009-12-16 07:20:17 -08:00
grumain.c misc: sgi-gru: Change return type to vm_fault_t 2018-05-14 16:25:52 +02:00
gruprocfs.c sgi-gru: simplify procfs code 2018-05-16 07:24:30 +02:00
grutables.h misc: sgi-gru: Change return type to vm_fault_t 2018-05-14 16:25:52 +02:00
grutlbpurge.c mm, oom: distinguish blockable mode for mmu notifiers 2018-08-22 10:52:44 -07:00
Makefile misc: change to new flag variable 2011-03-17 14:05:34 +01:00