Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp6701374imu; Mon, 21 Jan 2019 14:04:11 -0800 (PST) X-Google-Smtp-Source: ALg8bN5HzQBdx/qeFWUp+SLGPfysaAoWAUOif9OI6/3EU6mPBwRWtsTsTNcvYszCvt/FH/dczbAn X-Received: by 2002:a17:902:2868:: with SMTP id e95mr31794198plb.317.1548108251403; Mon, 21 Jan 2019 14:04:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548108251; cv=none; d=google.com; s=arc-20160816; b=psjua3OacYF4N35OdjAlLM0PfqQ0Y9iQkbYLO+dWGFjkvPRNDa5OBJ75yfgdj3HxQK yrTrkM9n7rE/jenaBf8+ezUxVk4Ro2rFa/IPxU6lq8qvbje1kp9K3WKm9+Ta+3ravgrw rHqCpW0UNCzvgxVT0hTbBlRJeVmAy4FxE8bV+qgWnSa2s4W4lf5quMPVqjmJJHN0s5iN tUm3oXWtg9k9q8C3seIOFsj7XbywNYnzwSbeVhfIzXFZIHipH90epqmG3qclY4ae0Pv9 VIN0zxNY3e2/6XV+5N1Z/rVa7HupFBnjDH44++9dCjVeqwL8kjDPNbnOS6+mbfIjp7y4 33kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:feedback-id:mime-version:user-agent :references:message-id:in-reply-to:subject:cc:to:from:date :dkim-signature; bh=OJCgqsaZ+wmR6x0X309IC98tvTtpLA7MmmS/XOpDQfc=; b=AVnbXibdItLwYwd8P4bb9qbXCGgIJAf9BI1MEkad6x92qEznufrCSD6xZBl0Xjg6fK OhBOV/uE8as0IcoPKXharTFRwGKSeEbTVcCPnZiK7zf5tNSRSpk8rq+B2SU8EUFKXRa9 vr0MuhCTRlFVuWkLiAXWIX5cIPBYcMN7aV9azpl8gRM33Uq1sHOiI/BRIkIDIpXYB96K hKFEAsAgn2Z09jStgJ3slRQDH5qSiyc+wjR63HXObueojgxt5AAOXFkDdQsEEt/GkIgy a4aCuydHAxfAbINXokdbmf0drLmMhmXrTFS8Z04B9LaPM7qWPe3HT6F3utG0xwvmuB9j 6sPA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazonses.com header.s=ug7nbtf4gccmlpwj322ax3p6ow6yfsug header.b=GuRKALKV; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z129si9150025pfz.13.2019.01.21.14.03.55; Mon, 21 Jan 2019 14:04:11 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@amazonses.com header.s=ug7nbtf4gccmlpwj322ax3p6ow6yfsug header.b=GuRKALKV; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727338AbfAUWCi (ORCPT + 99 others); Mon, 21 Jan 2019 17:02:38 -0500 Received: from a9-34.smtp-out.amazonses.com ([54.240.9.34]:51214 "EHLO a9-34.smtp-out.amazonses.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725993AbfAUWCh (ORCPT ); Mon, 21 Jan 2019 17:02:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=ug7nbtf4gccmlpwj322ax3p6ow6yfsug; d=amazonses.com; t=1548108156; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:MIME-Version:Content-Type:Feedback-ID; bh=OJCgqsaZ+wmR6x0X309IC98tvTtpLA7MmmS/XOpDQfc=; b=GuRKALKV2VCcr4jAbByx0u0oiNeiB4CSPat1WTFMtNriM8UmrZ/OntXWBFDYRvMe elpi405dUNq+OuDa8zhLri7SlJ3XFdTVKrMt1Z8CWIRgEu8L6W2+Q8ypTqiG8N7yfcN EESFVbiUwIJPQprgTCvW5t0Ar0FRiBrf/RmXa1ik= Date: Mon, 21 Jan 2019 22:02:36 +0000 From: Christopher Lameter X-X-Sender: cl@nuc-kabylake To: Miles Chen cc: Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH] mm/slub: use WARN_ON() for some slab errors In-Reply-To: <1548063490-545-1-git-send-email-miles.chen@mediatek.com> Message-ID: <01000168726fcf15-81d8feb3-26f0-44d6-bbd8-62aa149118b5-000000@email.amazonses.com> References: <1548063490-545-1-git-send-email-miles.chen@mediatek.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-SES-Outgoing: 2019.01.21-54.240.9.34 Feedback-ID: 1.us-east-1.fQZZZ0Xtj2+TD7V5apTT/NrT6QKuPgzCT/IC7XYgDKI=:AmazonSES Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 21 Jan 2019, miles.chen@mediatek.com wrote: > From: Miles Chen > > When debugging with slub.c, sometimes we have to trigger a panic in > order to get the coredump file. To do that, we have to modify slub.c and > rebuild kernel. To make debugging easier, use WARN_ON() for these slab > errors so we can dump stack trace by default or set panic_on_warn to > trigger a panic. These locations really should dump stack and not terminate. There is subsequent processing that should be done. Slub terminates by default. The messages you are modifying are only enabled if the user specified that special debugging should be one (typically via a kernel parameter slub_debug). It does not make sense to terminate the process here.