From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754590AbbGPIsm (ORCPT ); Thu, 16 Jul 2015 04:48:42 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52651 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753958AbbGPIsj (ORCPT ); Thu, 16 Jul 2015 04:48:39 -0400 From: Baoquan He To: linux-kernel@vger.kernel.org, ncroxon@redhat.com, dyoung@redhat.com, mhuang@redhat.com Cc: Baoquan He Subject: [RHEL6.8 Patch 15/19] s390/kdump: Disable mmap for s390 Date: Thu, 16 Jul 2015 16:47:13 +0800 Message-Id: <1437036437-25408-19-git-send-email-bhe@redhat.com> In-Reply-To: <1437036437-25408-1-git-send-email-bhe@redhat.com> References: <1437036437-25408-1-git-send-email-bhe@redhat.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Resolves: bz1097904 https://bugzilla.redhat.com/show_bug.cgi?id=1097904 This is back ported from upstream. commit 5a74953ff56aa870d6913ef4d81934f5c620c59d Author: Michael Holzheu Date: Thu Jul 18 12:17:57 2013 +0200 s390/kdump: Disable mmap for s390 The kdump mmap patch series (git commit 83086978c63afd7c73e1c) directly map the PT_LOADs to memory. On s390 this does not work because the copy_from_oldmem() function swaps [0,crashkernel size] with [crashkernel base, crashkernel base+crashkernel size]. The swap int copy_from_oldmem() was done in order correctly implement /dev/oldmem. See: http://marc.info/?l=kexec&m=136940802511603&w=2 Signed-off-by: Michael Holzheu Signed-off-by: Martin Schwidefsky Signed-off-by: Baoquan He --- fs/proc/vmcore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/proc/vmcore.c b/fs/proc/vmcore.c index f083c15..e93bcf9 100644 --- a/fs/proc/vmcore.c +++ b/fs/proc/vmcore.c @@ -219,7 +219,7 @@ static inline char *alloc_elfnotes_buf(size_t notes_sz) * regions in the 1st kernel pointed to by PT_LOAD entries) into * virtually contiguous user-space in ELF layout. */ -#ifdef CONFIG_MMU +#if defined(CONFIG_MMU) && !defined(CONFIG_S390) static int mmap_vmcore(struct file *file, struct vm_area_struct *vma) { size_t size = vma->vm_end - vma->vm_start; -- 2.1.0