Received: by 10.213.65.68 with SMTP id h4csp471931imn; Tue, 13 Mar 2018 10:06:29 -0700 (PDT) X-Google-Smtp-Source: AG47ELvpXNNWWCzxsh+rnn3WamdcKgmpsHZApEOgA/B/g0/0zt5E+VKGBoj7zZkkHo5J9wPUebp7 X-Received: by 2002:a17:902:7f0c:: with SMTP id d12-v6mr1182549plm.350.1520960789121; Tue, 13 Mar 2018 10:06:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1520960789; cv=none; d=google.com; s=arc-20160816; b=HOZf2hjcxlXVnLtlIDLIvwmBxfToUt1RicbQ/l81XV7NjhTTAZJa0v7+zIpRakb3jU yl7jFNPdGo3YtnWhZIW5mrFlZ+sEYWtsSDz2N7MRZy2nLSyvdRh5or1pAYL3e4pRNVKV DgHjEiMcNnXzqUytR9GPD8gAvRL/AmdzkMDKGCGvvYCbobF4WBbrr2L/hQWGsKAn+rgF /UwAcXjQNGPXs9yKGN77buucO2Ladrw608t16GMUNMQA46r/M4vld2u6GTEFXprEz90d YUc+8abTMff93L3eYJ7PDdS5FQw/+uq6bsw4r2oVCwdR+OGW8moTdwnqp7GCsf1B1+a4 0ICw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=hnpIy3ew6sNC1yqQs5VQoXFLASFf+CHSjtufYeCV+KA=; b=K7CmCfvDvbTy7TGqHmwyfPDlrqwETnpPcg9MAvy+6K/u+R/ejzC56MCO4BmFkJ7xoI e6wEVVOOKLyRDrzOJ6EvoZo7wHILSf4PXyChHbVAcT6PQZc0x3o7X4enMFOAFRF6Cmze FCRxtENXx+UGSIVKG3QV8RZh7iTmAtlhCJe6JC12aXLQnzTTmv1fCbI0JMbXvNJ9LUZE crbQbwvnQqb+iLnZOSFjT5uNSJOekQ2cd5XUDAkZYymZluxUScRcRC8zZX0AWHJn0dsK Mzci+Hb6vpIJlOLiHXAWdYXW8jAIFOPEkbhkQy9mha2iiTOTFpWOfWu19McLghTItFbp Cdbg== 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 j2si327716pff.214.2018.03.13.10.06.12; Tue, 13 Mar 2018 10:06:29 -0700 (PDT) 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 S933027AbeCMRDw (ORCPT + 99 others); Tue, 13 Mar 2018 13:03:52 -0400 Received: from g4t3427.houston.hpe.com ([15.241.140.73]:34504 "EHLO g4t3427.houston.hpe.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932303AbeCMRDu (ORCPT ); Tue, 13 Mar 2018 13:03:50 -0400 Received: from g4t3433.houston.hpecorp.net (g4t3433.houston.hpecorp.net [16.208.49.245]) by g4t3427.houston.hpe.com (Postfix) with ESMTP id 414B385; Tue, 13 Mar 2018 17:03:50 +0000 (UTC) Received: from misato.americas.hpqcorp.net (misato.americas.hpqcorp.net [10.34.81.122]) by g4t3433.houston.hpecorp.net (Postfix) with ESMTP id 62C08486; Tue, 13 Mar 2018 17:03:49 +0000 (UTC) From: Toshi Kani To: tglx@linutronix.de, mingo@redhat.com, hpa@zytor.com Cc: bp@alien8.de, luto@kernel.org, gratian.crisan@ni.com, x86@kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/2] x86/mm: vmalloc_fault fix for CONFIG_HUGETLBFS off Date: Tue, 13 Mar 2018 11:03:45 -0600 Message-Id: <20180313170347.3829-1-toshi.kani@hpe.com> X-Mailer: git-send-email 2.14.3 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Gratian Crisan reported that vmalloc_fault() crashes when CONFIG_HUGETLBFS is not set since the function inadvertently uses pXn_huge(), which always return 0 in this case. [1] ioremap() does not depend on CONFIG_HUGETLBFS. Patch 01 fixes the issue in vmalloc_fault(). Patch 02 is a clean-up for vmalloc_fault(). [1] https://lkml.org/lkml/2018/3/8/1281 --- Toshi Kani (2): 1/2 x86/mm: fix vmalloc_fault to use pXd_large 2/2 x86/mm: remove pointless checks in vmalloc_fault --- arch/x86/mm/fault.c | 62 +++++++++++++++++------------------------------------ 1 file changed, 20 insertions(+), 42 deletions(-)