From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752755AbcAZXOL (ORCPT ); Tue, 26 Jan 2016 18:14:11 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:34678 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750887AbcAZXOJ (ORCPT ); Tue, 26 Jan 2016 18:14:09 -0500 Date: Tue, 26 Jan 2016 15:14:08 -0800 From: Andrew Morton To: Heiko Carstens Cc: Christian Borntraeger , linux-kernel@vger.kernel.org, Prarit Bhargava Subject: Re: [PATCH] lib/bug: make panic_on_warn available for all architectures Message-Id: <20160126151408.85a48aa035a4e72243d4003c@linux-foundation.org> In-Reply-To: <1453468336-60133-1-git-send-email-heiko.carstens@de.ibm.com> References: <1453468336-60133-1-git-send-email-heiko.carstens@de.ibm.com> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.23; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 22 Jan 2016 14:12:16 +0100 Heiko Carstens wrote: > Christian Borntraeger reported that panic_on_warn doesn't have any > effect on s390. > > The panic_on_warn feature was introduced with 9e3961a09798 ("kernel: > add panic_on_warn"). However it did care only for the case when > WANT_WARN_ON_SLOWPATH is defined. This is turn is only the case for > architectures which do not have an own __WARN_TAINT defined. > > Other architectures which do have __WARN_TAINT defined call > report_bug() for warnings within lib/bug.c which does not call panic() > in case panic_on_warn is set. > > Let's simply enable the panic_on_warn feature by adding the same code > like it was added to warn_slowpath_common() in panic.c. > > This enables panic_on_warn also for arm64, parisc, powerpc, s390 and > sh. > It's a bit sad to do this in two places. You couldn't find a suitable place which is effective for all architectures?