On Thu, Oct 1, 2020 at 7:58 PM wrote:
>
> On Fri, Sep 25, 2020 at 12:50AM +0200, Andrey Konovalov wrote:
> > Hardware tag-based KASAN has granules of MTE_GRANULE_SIZE. Define
> > KASAN_GRANULE_SIZE to MTE_GRANULE_SIZE for CONFIG_KASAN_HW_TAGS.
> >
> > Signed-off-by
On Thu, Oct 1, 2020 at 8:03 PM wrote:
>
> On Fri, Sep 25, 2020 at 12:50AM +0200, Andrey Konovalov wrote:
> > SLUB allocator accesses metadata for slab objects, that may lie
> > out-of-bounds of the object itself, or be accessed when an object is freed.
> > Such acc
Don't mention "GNU General Public License version 2" text explicitly,
as it's already covered by the SPDX-License-Identifier.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: If0a2690042a2aa0fca70cea601ae9aabe72fa233
---
for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: Ic1c32ce72d4649848e9e6a1f2c8dd269c77673f2
---
mm/kasan/Makefile | 6 +-
mm/kasan/common.c | 486 +---
mm/kasan/shadow.c | 505
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
The new mode won't be using shadow memory, so only build init.c that
contains shadow initialization code for software modes.
No functional changes for software modes.
Signed-off-by: Andrey
Rename generic_report.c to report_generic.c and tags_report.c to
report_sw_tags.c, as their content is more relevant to report.c file.
Also rename tags.c to sw_tags.c to better reflect that this file contains
code for software tag-based mode.
No functional changes.
Signed-off-by: Andrey
changes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: Iac733e2248aa9d29f6fc425d8946ba07cca73ecf
---
Documentation/dev-tools/kasan.rst | 2 +-
lib/test_kasan.c | 2 +-
mm/kasan/common.c | 39
Define KASAN_GRANULE_PAGE as (KASAN_GRANULE_SIZE << PAGE_SHIFT), which is
the same as (KASAN_GRANULE_SIZE * PAGE_SIZE), and use it across KASAN code
to simplify it.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Cha
.
No functional changes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: Ia359f32815242c4704e49a5f1639ca2d2f8cba69
---
include/linux/kasan.h | 6 +++---
kernel/fork.c | 4 ++--
mm/kasan/common.c | 38
arch/arm64/kernel/entry.S.
- Mark gcr_kernel_excl as __ro_after_init.
- Use GENMASK() in mte_init_tags().
Andrey Konovalov (32):
kasan: drop unnecessary GPL text from comment headers
kasan: KASAN_VMALLOC depends on KASAN_GENERIC
kasan: group vmalloc code
kasan: shadow declarations only for sof
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Group all vmalloc-related function declarations in include/linux/kasan.h,
and their implementations in mm/kasan/common.c.
No functional changes.
Signed-off-by: Andrey Konovalov
Signed-off
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Group shadow-related KASAN function declarations and only define them
for the two existing software modes.
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't be using shadow memory, but will reuse
this function. Rename "shadow" to implementation-neutral "metadata".
No functional changes.
S
().
Also simplify the code for software tag-based mode.
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: I5fae9531c9fc948eb4d4e0c589744032fc5a0789
---
mm/kasan/common.c | 19
Currently only generic KASAN mode supports vmalloc, reflect that
in the config.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: I1889e5b3bed28cc5d607802fb6ae43ba461c0dc1
---
lib/Kconfig.kasan | 2 +-
1 file changed, 1 insertion(+), 1
Software tag-based KASAN provides its own tag checking machinery that
can conflict with MTE. Don't allow enabling software tag-based KASAN
when MTE is enabled.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Catalin Marinas
---
Change-Id
-based KASAN support for other architectures in the future by defining
the appropriate arch_*() macros.
Signed-off-by: Andrey Konovalov
Co-developed-by: Vincenzo Frascino
Signed-off-by: Vincenzo Frascino
Reviewed-by: Catalin Marinas
---
Change-Id: I42b0795a28067872f8308e00c6f0195bca435c2a
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't be using shadow memory, but will reuse
this function. Rename "shadow" to implementation-neutral "metadata".
No functional changes.
S
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't be using shadow memory. Only initialize
it when one of the software KASAN modes are enabled.
No functional changes for software modes.
Signed-off-by: Andrey
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't use kasan_depth. Only define and use it
when one of the software KASAN modes are enabled.
No functional changes for software modes.
Signed-off-by: Andrey
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't be using shadow memory, but will reuse
these macros. Rename "SHADOW" to implementation-neutral "META".
No functional changes.
Signed-off-
Both KASAN_GENERIC and KASAN_SW_TAGS have common dependencies, move
those to KASAN.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: I77e475802e8f1750b9154fe4a6e6da4456054fcd
---
lib/Kconfig.kasan | 8 ++--
1 file changed, 2
Decoding routines aren't needed when CONFIG_KASAN_STACK_ENABLE is not
enabled. Currently only generic KASAN mode implements stack error
reporting.
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id
-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: Icc9f5ef100a2e86f3a4214a0c3131a68266181b2
---
mm/kasan/report.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/mm/kasan/report.c b/mm/kasan/report.c
index 9e4d539d62f4
-developed-by: Andrey Konovalov
Signed-off-by: Andrey Konovalov
---
Change-Id: I91944903bc9c9c9044f0d50e74bcd6b9971d21ff
---
arch/arm64/mm/proc.S | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/mm/proc.S b/arch/arm64/mm/proc.S
index 6c1a6621d769..7c3304fb15d9 100644
Frascino
Signed-off-by: Andrey Konovalov
Reviewed-by: Catalin Marinas
---
Change-Id: I172e15e4c189f073e4c14a10276b276092e76536
---
arch/arm64/Kconfig | 4
arch/arm64/Makefile | 5 +
2 files changed, 9 insertions(+)
diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
index e875db8e1c86
fault handler for kernel addresses is currently empty and will be
filled in by a future commit.
Signed-off-by: Vincenzo Frascino
Co-developed-by: Andrey Konovalov
Signed-off-by: Andrey Konovalov
Reviewed-by: Catalin Marinas
---
Change-Id: I9b8aa79567f7c45f4d6a1290efcf34567e620717
---
arch/arm64
Hardware tag-based KASAN uses the memory tagging approach, which requires
all allocations to be aligned to the memory granule size. Align the
allocations to MTE_GRANULE_SIZE via ARCH_SLAB_MINALIGN when
CONFIG_KASAN_HW_TAGS is enabled.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo
-based KASAN will provide
its own implementation that doesn't use shadow memory.
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: I5b0ed1d079ea776e620beca6a529a861e7dced95
---
mm/kasan/kasan.h
implementation
has to make sure that the GCR_EL1 setting for the kernel does not affect
the userspace processes and viceversa.
Save and restore the kernel/user mask in GCR_EL1 in kernel entry and exit.
Signed-off-by: Vincenzo Frascino
Signed-off-by: Andrey Konovalov
---
Change-Id
This patch adds a configuration option for a new KASAN mode called
hardware tag-based KASAN. This mode uses the memory tagging approach
like the software tag-based mode, but relies on arm64 Memory Tagging
Extension feature for tag management and access checking.
Signed-off-by: Andrey Konovalov
-by: Andrey Konovalov
Signed-off-by: Andrey Konovalov
---
Change-Id: I1b5230254f90dc21a913447cb17f07fea7944ece
---
arch/arm64/include/asm/esr.h | 1 +
arch/arm64/include/asm/mte-def.h | 15
arch/arm64/include/asm/mte-kasan.h | 56 ++
arch/arm64/include/asm
-by: Andrey Konovalov
Reviewed-by: Catalin Marinas
---
Change-Id: Id15c0b47582fb51594bb26fb8353d78c7d0953c1
---
arch/arm64/include/asm/processor.h | 2 +-
arch/arm64/kernel/mte.c| 29 +++--
2 files changed, 16 insertions(+), 15 deletions(-)
diff --git a/arch
in a
page.
Note: For MTE, the TCF bit field in SCTLR_EL1 affects only EL1 in a
similar way as TCF0 affects EL0.
Signed-off-by: Vincenzo Frascino
Signed-off-by: Andrey Konovalov
---
Change-Id: I4d67497268bb7f0c2fc5dcacefa1e273df4af71d
---
arch/arm64/kernel/cpufeature.c | 7 +++
arch/arm64/mm/proc.S
Add documentation for hardware tag-based KASAN mode and also add some
clarifications for software tag-based mode.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Marco Elver
---
Change-Id: Ib46cb444cfdee44054628940a82f5139e10d0258
---
Documentation/dev-tools
code to handle this case.
Signed-off-by: Andrey Konovalov
Co-developed-by: Vincenzo Frascino
Signed-off-by: Vincenzo Frascino
Reviewed-by: Catalin Marinas
---
Change-Id: I3780fe7db6e075dff2937d3d8508f55c9322b095
---
arch/arm64/mm/fault.c | 14 ++
mm/kasan/report.c | 11
Some #ifdef CONFIG_KASAN checks are only relevant for software KASAN
modes (either related to shadow memory or compiler instrumentation).
Expand those into CONFIG_KASAN_GENERIC || CONFIG_KASAN_SW_TAGS.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
Reviewed-by: Catalin Marinas
On Tue, Oct 13, 2020 at 7:28 PM Shuah Khan wrote:
>
> On 10/12/20 11:10 AM, Andrey Konovalov wrote:
> > From: Nazime Hande Harputluoglu
> >
> > Add kcov_remote_start()/kcov_remote_stop() annotations to the
> > vhci_rx_loop() function, which is responsible for par
before kcov_remote_start() for usage details. */
> u64 kcov_common_handle(void)
> {
> + if (!in_task())
> + return 0;
> return current->kcov_handle;
> }
> EXPORT_SYMBOL(kcov_common_handle);
> --
> 2.28.0.1011.ga647a8990f-goog
>
Reviewed-by: Andrey Konovalov
Add set_alloc_info() helper and move kasan_set_track() into it. This will
simplify the code for one of the upcoming changes.
No functional changes.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/I0316193cbb4ecc9b87b7c2eee0dd79f8ec908c1a
---
mm/kasan/common.c
Move get_free_info() call into quarantine_put() to simplify the call site.
No functional changes.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/Iab0f04e7ebf8d83247024b7190c67c3c34c7940f
---
mm/kasan/common.c | 2 +-
mm/kasan/kasan.h | 5 ++---
mm
7.pdf
[4]
https://github.com/microsoft/MSRC-Security-Research/blob/master/papers/2020/Security%20analysis%20of%20memory%20tagging.pdf
[5] https://source.android.com/devices/architecture/kernel/generic-kernel-image
[6] https://github.com/qemu/qemu
Andrey Konovalov (8):
kasan: simplif
Rename get_alloc_info() and get_free_info() to kasan_get_alloc_meta()
and kasan_get_free_meta() to better reflect what those do, and avoid
confusion with kasan_set_free_info().
No functional changes.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id
Similarly to kasan_init() mark kasan_init_tags() as __init.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/I8792e22f1ca5a703c5e979969147968a99312558
---
include/linux/kasan.h | 4 ++--
mm/kasan/hw_tags.c| 2 +-
mm/kasan/sw_tags.c| 2 +-
3 files changed
is
enabled.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/If8a891e9fe01ea543e00b576852685afec0887e3
---
arch/arm64/kernel/sleep.S| 2 +-
arch/x86/kernel/acpi/wakeup_64.S | 2 +-
include/linux/kasan.h| 10 ++
mm/kasan/common.c
TODO: no meaningful description here yet, please see the cover letter
for this RFC series.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/If7d37003875b2ed3e0935702c8015c223d6416a4
---
mm/kasan/common.c | 69
Add a helper that exposes information about whether the system supports
memory tagging to be called in generic code.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/Ib4b56a42c57c6293df29a0cdfee334c3ca7bdab4
---
arch/arm64/include/asm/memory.h | 1 +
mm/kasan
t; instead of KBUILD_MODNAME.
Signed-off-by: Andrey Konovalov
Link:
https://linux-review.googlesource.com/id/Idfd1e50625ffdf42dfc3dbf7455b11bd200a0a49
---
arch/arm64/mm/kasan_init.c | 3 +++
mm/kasan/generic.c | 2 --
mm/kasan/hw_tags.c | 4
mm/kasan/sw_tags.c | 4 +++
On Thu, Oct 15, 2020 at 12:23 PM Marco Elver wrote:
>
> On Wed, 14 Oct 2020 at 22:44, Andrey Konovalov wrote:
> >
> > Similarly to kasan_init() mark kasan_init_tags() as __init.
> >
> > Signed-off-by: Andrey Konovalov
> > Link:
> >
On Thu, Oct 15, 2020 at 3:56 PM Marco Elver wrote:
>
> On Wed, 14 Oct 2020 at 22:45, Andrey Konovalov wrote:
> >
[...]
> > @@ -180,6 +182,7 @@ size_t kasan_metadata_size(struct kmem_cache *cache)
> > struct kasan_alloc_meta *kasan_get_alloc_meta(
On Thu, Oct 15, 2020 at 4:41 PM Marco Elver wrote:
>
> On Wed, 14 Oct 2020 at 22:44, Andrey Konovalov wrote:
> > This patchset is not complete (see particular TODOs in the last patch),
> > and I haven't performed any benchmarking yet, but I would like to start the
> >
is fixed.
A potential future improvement would be to support nested remote coverage
collection sections, but this patch doesn't address that.
Signed-off-by: Andrey Konovalov
Acked-by: Marco Elver
---
Changes v3->v4:
- Don't make any kcov changes, do a softirq context check in usb code
inst
On Tue, Oct 13, 2020 at 7:28 PM Shuah Khan wrote:
>
> On 10/12/20 11:10 AM, Andrey Konovalov wrote:
> > From: Nazime Hande Harputluoglu
> >
> > Add kcov_remote_start()/kcov_remote_stop() annotations to the
> > vhci_rx_loop() function, which is responsible for par
On Wed, Oct 14, 2020 at 10:44 PM Andrey Konovalov wrote:
>
> This patchset is not complete (see particular TODOs in the last patch),
> and I haven't performed any benchmarking yet, but I would like to start the
> discussion now and hear people's opinions regarding the questions menti
On Thu, Oct 15, 2020 at 4:41 PM Marco Elver wrote:
>
> On Wed, 14 Oct 2020 at 22:44, Andrey Konovalov wrote:
> > This patchset is not complete (see particular TODOs in the last patch),
> > and I haven't performed any benchmarking yet, but I would like to start the
> >
On Fri, Oct 16, 2020 at 3:31 PM Marco Elver wrote:
>
> On Fri, 16 Oct 2020 at 15:17, 'Andrey Konovalov' via kasan-dev
> wrote:
> [...]
> > > > The intention with this kind of a high level switch is to hide the
> > > > implementation details. Argu
-by: Andrey Konovalov
---
Documentation/dev-tools/kcov.rst | 5 +
drivers/usb/core/hcd.c | 4 ++--
drivers/usb/core/hub.c | 4 ++--
drivers/vhost/vhost.c| 5 +++--
include/linux/kcov.h | 24 ++--
kernel/kcov.c
On Wed, Oct 7, 2020 at 7:30 PM Andrey Konovalov wrote:
>
> Currently there's a KCOV remote coverage collection section in
> __usb_hcd_giveback_urb(). Initially that section was added based on the
> assumption that usb_hcd_giveback_urb() can only be called in interrupt
> conte
On Wed, Oct 7, 2020 at 9:29 PM Alan Stern wrote:
>
> On Wed, Oct 07, 2020 at 07:30:51PM +0200, Andrey Konovalov wrote:
> > Currently there's a KCOV remote coverage collection section in
> > __usb_hcd_giveback_urb(). Initially that section was added based on
On Wed, Oct 7, 2020 at 10:07 PM Alan Stern wrote:
>
> On Wed, Oct 07, 2020 at 09:54:57PM +0200, Andrey Konovalov wrote:
> > On Wed, Oct 7, 2020 at 9:29 PM Alan Stern wrote:
> > >
> > > On Wed, Oct 07, 2020 at 07:30:51PM +0200, Andrey Konovalov wrote:
> >
usb_hcd_giveback_urb() calls
won't be collected, but the WARNING is fixed.
A potential future improvement would be to support nested remote coverage
collection sections, but this patch doesn't address that.
Signed-off-by: Andrey Konovalov
---
Changes v1->v2:
- Fix context checks in kcov_remote_start/s
On Fri, Oct 9, 2020 at 7:13 PM Johannes Berg wrote:
>
>
>
> On 9 October 2020 19:01:59 CEST, Aleksandr Nogikh wrote:
>
> >This patch series conflicts with another proposed patch
> >http://lkml.kernel.org/r/223901affc7bd759b2d6995c2dbfbdd0a29bc88a.1602248029.git.andreyk...@google.com
> >One of
On Sun, Oct 11, 2020 at 8:50 PM Johannes Berg wrote:
>
> On Fri, 2020-10-09 at 17:01 +, Aleksandr Nogikh wrote:
> > From: Aleksandr Nogikh
> >
> > This patch series enables remote KCOV coverage collection during
> > 802.11 frames processing. These changes make it possible to perform
> >
On Sat, Oct 10, 2020 at 8:55 AM Greg Kroah-Hartman
wrote:
>
> On Fri, Oct 09, 2020 at 03:22:55PM +,
> nazimehandeharputluogluhandehar...@gmail.com wrote:
> > From: Nazime Hande Harputluoglu
> >
> > Add kcov_remote_start()/kcov_remote_stop() annotations to the
> > vhci_rx_loop() function,
On Fri, Oct 9, 2020 at 8:55 PM Alan Stern wrote:
>
> To the ath9k_htc maintainers:
>
> This is an attempt to fix a bug detected by the syzbot fuzzer. The bug
> arises when a USB device claims to be an ATH9K but doesn't have the
> expected endpoints. (In this case there was a bulk endpoint where
() calls
won't be collected, but the WARNING is fixed.
A potential future improvement would be to support nested remote coverage
collection sections, but this patch doesn't address that.
Signed-off-by: Andrey Konovalov
---
Changes v2->v3:
- Keep behavoir of existing callbacks the same exc
On Mon, Oct 12, 2020 at 6:08 PM Marco Elver wrote:
>
> On Mon, 12 Oct 2020 at 17:25, Andrey Konovalov wrote:
> >
> > Currently there's a KCOV remote coverage collection section in
> > __usb_hcd_giveback_urb(). Initially that section was added based on the
> > assump
asan: record timer stack
> > workqueue: kasan: record workqueue stack
> > kasan: print timer and workqueue stack
> > lib/test_kasan.c: add timer test case
> > lib/test_kasan.c: add workqueue test case
> > kasan: update documentation for generic kasan
>
> Acked-by: M
On Thu, Aug 27, 2020 at 11:52 AM Vincenzo Frascino
wrote:
>
> Hi Andrey,
>
> On 8/27/20 9:04 AM, Catalin Marinas wrote:
> > On Fri, Aug 14, 2020 at 07:27:01PM +0200, Andrey Konovalov wrote:
> >> Software tag-based KASAN provides its own tag checking machinery that
On Thu, Aug 27, 2020 at 1:05 PM Vincenzo Frascino
wrote:
>
>
>
> On 8/27/20 11:41 AM, Catalin Marinas wrote:
> > On Fri, Aug 14, 2020 at 07:27:10PM +0200, Andrey Konovalov wrote:
> >> Hardware tag-based KASAN has granules of MTE_GRANULE_SIZE. Define
> >> KA
On Thu, Aug 27, 2020 at 1:31 PM Vincenzo Frascino
wrote:
>
> Hi Andrey,
>
> On 8/14/20 6:27 PM, Andrey Konovalov wrote:
> > +config·KASAN_HW_TAGS
> > +» bool·"Hardware·tag-based·mode"
> > +» depends·on·HAVE_ARCH_KASAN_HW_TAGS
> > +» depends·on·
On Thu, Aug 27, 2020 at 12:48 PM Catalin Marinas
wrote:
>
> On Fri, Aug 14, 2020 at 07:27:14PM +0200, Andrey Konovalov wrote:
> > diff --git a/arch/arm64/mm/fault.c b/arch/arm64/mm/fault.c
> > index c62c8ba85c0e..cf00b3942564 100644
> > --- a/arch/arm64/mm/fault.c
> &g
On Thu, Aug 27, 2020 at 1:15 PM Vincenzo Frascino
wrote:
>
>
>
> On 8/27/20 12:13 PM, Catalin Marinas wrote:
> > On Thu, Aug 27, 2020 at 12:05:55PM +0100, Vincenzo Frascino wrote:
> >> On 8/27/20 11:40 AM, Catalin Marinas wrote:
> >>> On Fri, Aug 14, 202
On Thu, Aug 27, 2020 at 11:38 AM Catalin Marinas
wrote:
>
> On Fri, Aug 14, 2020 at 07:27:02PM +0200, Andrey Konovalov wrote:
> > diff --git a/arch/arm64/include/asm/mte.h b/arch/arm64/include/asm/mte.h
> > index 1c99fcadb58c..733be1cb5c95 100644
> > --- a/arch/arm64/inc
On Thu, Aug 27, 2020 at 11:54 AM Catalin Marinas
wrote:
>
> On Fri, Aug 14, 2020 at 07:27:03PM +0200, Andrey Konovalov wrote:
> > diff --git a/arch/arm64/mm/fault.c b/arch/arm64/mm/fault.c
> > index 5e832b3387f1..c62c8ba85c0e 100644
> > --- a/arch/arm64/mm/fault.c
> &g
On Thu, Aug 27, 2020 at 3:10 PM Catalin Marinas wrote:
>
> On Thu, Aug 27, 2020 at 02:31:23PM +0200, Andrey Konovalov wrote:
> > On Thu, Aug 27, 2020 at 11:54 AM Catalin Marinas
> > wrote:
> > > On Fri, Aug 14, 2020 at 07:27:03PM +0200, Andrey Konovalov wrote:
> >
On Thu, Aug 27, 2020 at 3:42 PM Vincenzo Frascino
wrote:
>
> Hi Andrey,
>
> On 8/27/20 1:43 PM, Andrey Konovalov wrote:
> > On Thu, Aug 27, 2020 at 1:15 PM Vincenzo Frascino
> > wrote:
> >>
> >>
> >>
> >> On 8/27/20 12:13 PM, Catalin M
On Thu, Aug 27, 2020 at 12:45 PM Catalin Marinas
wrote:
>
> On Fri, Aug 14, 2020 at 07:27:13PM +0200, Andrey Konovalov wrote:
> > diff --git a/mm/kasan/mte.c b/mm/kasan/mte.c
> > new file mode 100644
> > index ..43b7d74161e5
> > --- /dev/null
>
On Tue, Aug 11, 2020 at 7:39 AM David Gow wrote:
>
> This patchset contains everything needed to integrate KASAN and KUnit.
>
> KUnit will be able to:
> (1) Fail tests when an unexpected KASAN error occurs
> (2) Pass tests when an expected KASAN error occurs
>
> Convert KASAN tests to KUnit with
On Thu, Aug 27, 2020 at 11:38 AM Catalin Marinas
wrote:
>
> On Fri, Aug 14, 2020 at 07:27:02PM +0200, Andrey Konovalov wrote:
> > diff --git a/arch/arm64/include/asm/mte.h b/arch/arm64/include/asm/mte.h
> > index 1c99fcadb58c..733be1cb5c95 100644
> > --- a/arch/arm64/inc
On Thu, Aug 27, 2020 at 12:38 PM Catalin Marinas
wrote:
>
> On Fri, Aug 14, 2020 at 07:27:06PM +0200, Andrey Konovalov wrote:
> > @@ -957,6 +984,7 @@ SYM_FUNC_START(cpu_switch_to)
> > mov sp, x9
> > msr sp_el0, x1
> > ptrauth_keys_
On Mon, Aug 31, 2020 at 8:32 PM Andrew Morton wrote:
>
> On Mon, 31 Aug 2020 17:17:30 + albert.li...@gmail.com wrote:
>
> > The goal of this series is to improve testing of fault-tolerance in
> > usages of user memory access functions, by adding support for fault
> > injection.
>
> Does
On Sat, Aug 1, 2020 at 9:09 AM David Gow wrote:
>
> This patchset contains everything needed to integrate KASAN and KUnit.
>
> KUnit will be able to:
> (1) Fail tests when an unexpected KASAN error occurs
> (2) Pass tests when an expected KASAN error occurs
>
> Convert KASAN tests to KUnit with
queue_work_on+0xf4/0x118
> > kasan_workqueue_uaf+0xfc/0x190
> >
> > Signed-off-by: Walter Wu
> > Cc: Andrey Ryabinin
> > Cc: Dmitry Vyukov
> > Cc: Alexander Potapenko
> > Cc: Matthias Brugger
> > Cc: Andrey Konovalov
> > ---
> >
On Thu, Sep 10, 2020 at 9:03 AM David Gow wrote:
>
> This patchset contains everything needed to integrate KASAN and KUnit.
>
> KUnit will be able to:
> (1) Fail tests when an unexpected KASAN error occurs
> (2) Pass tests when an expected KASAN error occurs
>
> Convert KASAN tests to KUnit with
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Group shadow-related KASAN function declarations and only define them
for the two existing software modes.
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Group all vmalloc-related function declarations in include/linux/kasan.h,
and their implementations in mm/kasan/common.c.
No functional changes.
Signed-off-by: Andrey Konovalov
Signed-off
Currently only generic KASAN mode supports vmalloc, reflect that
in the config.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id: I1889e5b3bed28cc5d607802fb6ae43ba461c0dc1
---
lib/Kconfig.kasan | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
.
No functional changes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id: Ia359f32815242c4704e49a5f1639ca2d2f8cba69
---
include/linux/kasan.h | 6 +++---
kernel/fork.c | 4 ++--
mm/kasan/common.c | 38 +++---
mm/kasan/generic.c
to KASAN_GRANULE_MASK.
Also use MASK when used as a mask, otherwise use SIZE.
No functional changes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id: Iac733e2248aa9d29f6fc425d8946ba07cca73ecf
---
Documentation/dev-tools/kasan.rst | 2 +-
lib/test_kasan.c | 2
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't be using shadow memory. Only initialize
it when one of the software KASAN modes are enabled.
No functional changes for software modes.
Signed-off-by: Andrey
().
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id: I5fae9531c9fc948eb4d4e0c589744032fc5a0789
---
mm/kasan/common.c | 19 +--
mm/kasan/generic.c | 7 +++
mm/kasan/kasan.h | 2 ++
mm/kasan/tags.c
Decoding routines aren't needed when CONFIG_KASAN_STACK_ENABLE is not
enabled. Currently only generic KASAN mode implements stack error
reporting.
No functional changes for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id
Rename generic_report.c to report_generic.c and tags_report.c to
report_tags.c, as their content is more relevant to report.c file,
then to generic.c or tags.c.
No functional changes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id
for software modes.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id: Ic1c32ce72d4649848e9e6a1f2c8dd269c77673f2
---
mm/kasan/Makefile | 6 +-
mm/kasan/common.c | 486 +--
mm/kasan/shadow.c | 509
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
The new mode won't be using shadow memory, so only build init.c that
contains shadow initialization code for software modes.
No functional changes for software modes.
Signed-off-by: Andrey
() and panics.
Signed-off-by: Vincenzo Frascino
Co-developed-by: Andrey Konovalov
Signed-off-by: Andrey Konovalov
---
Change-Id: I9b8aa79567f7c45f4d6a1290efcf34567e620717
---
arch/arm64/mm/fault.c | 36 +++-
1 file changed, 35 insertions(+), 1 deletion(-)
diff --git
This is a preparatory commit for the upcoming addition of a new hardware
tag-based (MTE-based) KASAN mode.
Hardware tag-based KASAN won't be using shadow memory, but will reuse
this function. Rename "shadow" to implementation-neutral "metadata".
No functional changes.
S
Both KASAN_GENERIC and KASAN_SW_TAGS have common dependencies, move
those to KASAN.
Signed-off-by: Andrey Konovalov
Signed-off-by: Vincenzo Frascino
---
Change-Id: I77e475802e8f1750b9154fe4a6e6da4456054fcd
---
lib/Kconfig.kasan | 11 +++
1 file changed, 3 insertions(+), 8 deletions
implementation
has to make sure that the GCR_EL1 setting for the kernel does not affect
the userspace processes and viceversa.
Save and restore the kernel/user mask in GCR_EL1 in kernel entry and exit.
Signed-off-by: Vincenzo Frascino
Signed-off-by: Andrey Konovalov
---
Change-Id
901 - 1000 of 2648 matches
Mail list logo