Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752601AbdHNU3w (ORCPT ); Mon, 14 Aug 2017 16:29:52 -0400 Received: from mail-io0-f182.google.com ([209.85.223.182]:33869 "EHLO mail-io0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752309AbdHNU3t (ORCPT ); Mon, 14 Aug 2017 16:29:49 -0400 Date: Mon, 14 Aug 2017 14:29:47 -0600 From: Tycho Andersen To: Kees Cook Cc: LKML , Linux-MM , "kernel-hardening@lists.openwall.com" , Marco Benatto , Juerg Haefliger Subject: Re: [PATCH v5 10/10] lkdtm: Add test for XPFO Message-ID: <20170814202947.er7uparyhplm77ei@smitten> References: <20170809200755.11234-1-tycho@docker.com> <20170809200755.11234-11-tycho@docker.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 810 Lines: 20 On Mon, Aug 14, 2017 at 12:10:47PM -0700, Kees Cook wrote: > On Wed, Aug 9, 2017 at 1:07 PM, Tycho Andersen wrote: > > From: Juerg Haefliger > > > > This test simply reads from userspace memory via the kernel's linear > > map. > > > > hugepages is only supported on x86 right now, hence the ifdef. > > I'd prefer that the #ifdef is handled in the .c file. The result is > that all architectures will have the XPFO_READ_USER_HUGE test, but it > can just fail when not available. This means no changes are needed for > lkdtm in the future and the test provides an actual test of hugepages > coverage. If failing tests is okay, I think we can just drop that hunk entirely. Everything compiles fine, it just doesn't work :). I'll do that for the next version. Tycho