lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-1b59562d3ab09dcef188eb8055d05f0336380394@git.kernel.org>
Date:   Mon, 29 Apr 2019 11:33:22 -0700
From:   tip-bot for Thomas Gleixner <tipbot@...or.com>
To:     linux-tip-commits@...r.kernel.org
Cc:     jthumshirn@...e.de, mbenes@...e.cz, dvyukov@...gle.com, clm@...com,
        josef@...icpanda.com, snitzer@...hat.com, cl@...ux.com,
        linux-kernel@...r.kernel.org, jpoimboe@...hat.com,
        dsterba@...e.com, mingo@...nel.org, akpm@...ux-foundation.org,
        robin.murphy@....com, rppt@...ux.vnet.ibm.com, airlied@...ux.ie,
        rientjes@...gle.com, penberg@...nel.org, hpa@...or.com,
        daniel@...ll.ch, glider@...gle.com, akinobu.mita@...il.com,
        catalin.marinas@....com, jani.nikula@...ux.intel.com,
        luto@...nel.org, m.szyprowski@...sung.com, adobriyan@...il.com,
        hch@....de, rodrigo.vivi@...el.com,
        joonas.lahtinen@...ux.intel.com, tom.zanussi@...ux.intel.com,
        agk@...hat.com, rostedt@...dmis.org,
        maarten.lankhorst@...ux.intel.com, aryabinin@...tuozzo.com,
        tglx@...utronix.de
Subject: [tip:core/stacktrace] backtrace-test: Simplify stack trace handling

Commit-ID:  1b59562d3ab09dcef188eb8055d05f0336380394
Gitweb:     https://git.kernel.org/tip/1b59562d3ab09dcef188eb8055d05f0336380394
Author:     Thomas Gleixner <tglx@...utronix.de>
AuthorDate: Thu, 25 Apr 2019 11:44:57 +0200
Committer:  Thomas Gleixner <tglx@...utronix.de>
CommitDate: Mon, 29 Apr 2019 12:37:47 +0200

backtrace-test: Simplify stack trace handling

Replace the indirection through struct stack_trace by using the storage
array based interfaces.

Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Reviewed-by: Josh Poimboeuf <jpoimboe@...hat.com>
Cc: Andy Lutomirski <luto@...nel.org>
Cc: Steven Rostedt <rostedt@...dmis.org>
Cc: Alexander Potapenko <glider@...gle.com>
Cc: Alexey Dobriyan <adobriyan@...il.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>
Cc: Christoph Lameter <cl@...ux.com>
Cc: Pekka Enberg <penberg@...nel.org>
Cc: linux-mm@...ck.org
Cc: David Rientjes <rientjes@...gle.com>
Cc: Catalin Marinas <catalin.marinas@....com>
Cc: Dmitry Vyukov <dvyukov@...gle.com>
Cc: Andrey Ryabinin <aryabinin@...tuozzo.com>
Cc: kasan-dev@...glegroups.com
Cc: Mike Rapoport <rppt@...ux.vnet.ibm.com>
Cc: Akinobu Mita <akinobu.mita@...il.com>
Cc: Christoph Hellwig <hch@....de>
Cc: iommu@...ts.linux-foundation.org
Cc: Robin Murphy <robin.murphy@....com>
Cc: Marek Szyprowski <m.szyprowski@...sung.com>
Cc: Johannes Thumshirn <jthumshirn@...e.de>
Cc: David Sterba <dsterba@...e.com>
Cc: Chris Mason <clm@...com>
Cc: Josef Bacik <josef@...icpanda.com>
Cc: linux-btrfs@...r.kernel.org
Cc: dm-devel@...hat.com
Cc: Mike Snitzer <snitzer@...hat.com>
Cc: Alasdair Kergon <agk@...hat.com>
Cc: Daniel Vetter <daniel@...ll.ch>
Cc: intel-gfx@...ts.freedesktop.org
Cc: Joonas Lahtinen <joonas.lahtinen@...ux.intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>
Cc: dri-devel@...ts.freedesktop.org
Cc: David Airlie <airlied@...ux.ie>
Cc: Jani Nikula <jani.nikula@...ux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@...el.com>
Cc: Tom Zanussi <tom.zanussi@...ux.intel.com>
Cc: Miroslav Benes <mbenes@...e.cz>
Cc: linux-arch@...r.kernel.org
Link: https://lkml.kernel.org/r/20190425094801.501919093@linutronix.de

---
 kernel/backtracetest.c | 11 +++--------
 1 file changed, 3 insertions(+), 8 deletions(-)

diff --git a/kernel/backtracetest.c b/kernel/backtracetest.c
index 1323360d90e3..a563c8fdad0d 100644
--- a/kernel/backtracetest.c
+++ b/kernel/backtracetest.c
@@ -48,19 +48,14 @@ static void backtrace_test_irq(void)
 #ifdef CONFIG_STACKTRACE
 static void backtrace_test_saved(void)
 {
-	struct stack_trace trace;
 	unsigned long entries[8];
+	unsigned int nr_entries;
 
 	pr_info("Testing a saved backtrace.\n");
 	pr_info("The following trace is a kernel self test and not a bug!\n");
 
-	trace.nr_entries = 0;
-	trace.max_entries = ARRAY_SIZE(entries);
-	trace.entries = entries;
-	trace.skip = 0;
-
-	save_stack_trace(&trace);
-	print_stack_trace(&trace, 0);
+	nr_entries = stack_trace_save(entries, ARRAY_SIZE(entries), 0);
+	stack_trace_print(entries, nr_entries, 0);
 }
 #else
 static void backtrace_test_saved(void)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ