From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,SIGNED_OFF_BY,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7ABB0C10F13 for ; Sun, 14 Apr 2019 20:35:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4C6A72082E for ; Sun, 14 Apr 2019 20:35:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726626AbfDNUfG (ORCPT ); Sun, 14 Apr 2019 16:35:06 -0400 Received: from terminus.zytor.com ([198.137.202.136]:58205 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725797AbfDNUfF (ORCPT ); Sun, 14 Apr 2019 16:35:05 -0400 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTPS id x3EKY8Rx2688771 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Sun, 14 Apr 2019 13:34:08 -0700 Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id x3EKY7Md2688768; Sun, 14 Apr 2019 13:34:07 -0700 Date: Sun, 14 Apr 2019 13:34:07 -0700 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Thomas Gleixner Message-ID: Cc: luto@kernel.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, mingo@kernel.org, rostedt@goodmis.org, peterz@infradead.org, richard@nod.at, hpa@zytor.com, jpoimboe@redhat.com, glider@google.com Reply-To: luto@kernel.org, tglx@linutronix.de, mingo@kernel.org, linux-kernel@vger.kernel.org, rostedt@goodmis.org, peterz@infradead.org, richard@nod.at, hpa@zytor.com, jpoimboe@redhat.com, glider@google.com In-Reply-To: <20190410103643.662853876@linutronix.de> References: <20190410103643.662853876@linutronix.de> To: linux-tip-commits@vger.kernel.org Subject: [tip:core/stacktrace] um/stacktrace: Remove the pointless ULONG_MAX marker Git-Commit-ID: fdc7833964d83b7f7f39a03e2ee48a229ba0291f X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: fdc7833964d83b7f7f39a03e2ee48a229ba0291f Gitweb: https://git.kernel.org/tip/fdc7833964d83b7f7f39a03e2ee48a229ba0291f Author: Thomas Gleixner AuthorDate: Wed, 10 Apr 2019 12:27:55 +0200 Committer: Thomas Gleixner CommitDate: Sun, 14 Apr 2019 19:58:27 +0200 um/stacktrace: Remove the pointless ULONG_MAX marker Terminating the last trace entry with ULONG_MAX is a completely pointless exercise and none of the consumers can rely on it because it's inconsistently implemented across architectures. In fact quite some of the callers remove the entry and adjust stack_trace.nr_entries afterwards. Signed-off-by: Thomas Gleixner Acked-by: Peter Zijlstra (Intel) Cc: Josh Poimboeuf Cc: Andy Lutomirski Cc: Steven Rostedt Cc: Alexander Potapenko Cc: Richard Weinberger Cc: linux-um@lists.infradead.org Link: https://lkml.kernel.org/r/20190410103643.662853876@linutronix.de --- arch/um/kernel/stacktrace.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/arch/um/kernel/stacktrace.c b/arch/um/kernel/stacktrace.c index ebe7bcf62684..bd95e020d509 100644 --- a/arch/um/kernel/stacktrace.c +++ b/arch/um/kernel/stacktrace.c @@ -63,8 +63,6 @@ static const struct stacktrace_ops dump_ops = { static void __save_stack_trace(struct task_struct *tsk, struct stack_trace *trace) { dump_trace(tsk, &dump_ops, trace); - if (trace->nr_entries < trace->max_entries) - trace->entries[trace->nr_entries++] = ULONG_MAX; } void save_stack_trace(struct stack_trace *trace)