Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp417097imu; Thu, 8 Nov 2018 23:07:50 -0800 (PST) X-Google-Smtp-Source: AJdET5cHOXiTTQsR+e7kOMjfNcpWjtdR94viyB2WgA5iQttex7TBFx2SnmOWfQQVYOHP7WuwlkO+ X-Received: by 2002:a63:5558:: with SMTP id f24-v6mr6723381pgm.37.1541747270897; Thu, 08 Nov 2018 23:07:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541747270; cv=none; d=google.com; s=arc-20160816; b=o/EbAWOw4nb8g7zn8Fhf4htrLpU5rUe/J95TaabVHNmYqDGdrkFVf4L7MIYDYQzWim KvLKUPE+gI1ifX4VQx2EuyR/HzWI3F0emVZux1d9RJtLGhHn/M1eyMVIglrdoxULAl1i Vjxu+M/RkoZHxiVqr2Xexv6XQrCGumue8Sg1UHZOewKt9eVPLPE5JzRcWBz11q9cE/q+ I1HPaZQ9uf4Tv2xgkN7FxPHLTaQz+nApUQUbWaUTrkmglx8EPeqxy5MsJkF7L63uxM2t Q2EzYIyt/QhoezysGHOavPmoa91IlEta296aQHIK5+98hLyrdiFYQL72Pu70I301CfE1 Uv4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:cc:to:subject:from:message-id; bh=/hqUyQyICV/PT6oj8zhB+gKDvUSwYm/NLEkITN25Ucg=; b=ENf2U1I310NMCrh73+4rSzZVm0qqh1xfWA/g2P7QlUsznw9y9jFZUvKHPqFNpgFkWA M68MxBudBvn2ZsgQMhBhV0gtAcOX/AD5ZE1xtRLkux0o1JvWCRbTLioKQ9kFej3Ax7VO HXZkTwE3C0d+r+1DNTT7XweTKCTJNPPEhfEfVNRI0/Ruu0q/dxzEPbaipFXmapI7f5HO naq0vyyJoKGGR8FpZsm7nRGu/G57fJx6wWoy3DZxmnS5tLLkh5nmlzcB7mnVDcbqQ6YC i0es3saZgEi3BJwcFnB20P9qUEAn1uW3RGhpYyUArxxWo+KAL6KPZt6EeIGo+yD0+lx4 cm6g== ARC-Authentication-Results: i=1; mx.google.com; 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 r13-v6si6101498pgk.127.2018.11.08.23.07.35; Thu, 08 Nov 2018 23:07:50 -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; 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 S1728329AbeKIQpG (ORCPT + 99 others); Fri, 9 Nov 2018 11:45:06 -0500 Received: from pegase1.c-s.fr ([93.17.236.30]:47705 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727845AbeKIQpG (ORCPT ); Fri, 9 Nov 2018 11:45:06 -0500 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 42rrlb1CN4z9ty8r; Fri, 9 Nov 2018 08:05:47 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at c-s.fr Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [192.168.12.234]) (amavisd-new, port 10024) with ESMTP id SMJXeHEkxyHE; Fri, 9 Nov 2018 08:05:47 +0100 (CET) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 42rrlb0kTwz9ttBy; Fri, 9 Nov 2018 08:05:47 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 2CF5E8B878; Fri, 9 Nov 2018 08:05:52 +0100 (CET) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id 2S0QATzhOeK8; Fri, 9 Nov 2018 08:05:52 +0100 (CET) Received: from po14163vm.idsi0.si.c-s.fr (unknown [172.25.231.2]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 0FA248B756; Fri, 9 Nov 2018 08:05:52 +0100 (CET) Received: by po14163vm.idsi0.si.c-s.fr (Postfix, from userid 0) id DE637699D2; Fri, 9 Nov 2018 07:05:51 +0000 (UTC) Message-Id: From: Christophe Leroy Subject: [PATCH] lkdtm: do not depend on CONFIG_BLOCK To: Kees Cook , Arnd Bergmann , Greg Kroah-Hartman Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Date: Fri, 9 Nov 2018 07:05:51 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Most parts of lkdtm don't require CONFIG_BLOCK. This patch limits dependency to CONFIG_BLOCK in order to give embedded platforms which don't select CONFIG_BLOCK the opportunity to use LKDTM. Fixes: fddd9cf82c9f ("make LKDTM depend on BLOCK") Signed-off-by: Christophe Leroy --- drivers/misc/lkdtm/core.c | 7 ++++++- lib/Kconfig.debug | 1 - 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/misc/lkdtm/core.c b/drivers/misc/lkdtm/core.c index 2837dc77478e..bc76756b7eda 100644 --- a/drivers/misc/lkdtm/core.c +++ b/drivers/misc/lkdtm/core.c @@ -40,9 +40,12 @@ #include #include #include -#include #include +#ifdef CONFIG_BLOCK +#include +#endif + #ifdef CONFIG_IDE #include #endif @@ -101,7 +104,9 @@ static struct crashpoint crashpoints[] = { CRASHPOINT("FS_DEVRW", "ll_rw_block"), CRASHPOINT("MEM_SWAPOUT", "shrink_inactive_list"), CRASHPOINT("TIMERADD", "hrtimer_start"), +# ifdef CONFIG_BLOCK CRASHPOINT("SCSI_DISPATCH_CMD", "scsi_dispatch_cmd"), +# endif # ifdef CONFIG_IDE CRASHPOINT("IDE_CORE_CP", "generic_ide_ioctl"), # endif diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index 1af29b8224fd..0dd65b4b2ad2 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -1685,7 +1685,6 @@ if RUNTIME_TESTING_MENU config LKDTM tristate "Linux Kernel Dump Test Tool Module" depends on DEBUG_FS - depends on BLOCK help This module enables testing of the different dumping mechanisms by inducing system failures at predefined crash points. -- 2.13.3