Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932433AbbG0Xc0 (ORCPT ); Mon, 27 Jul 2015 19:32:26 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39418 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932125AbbG0XcX (ORCPT ); Mon, 27 Jul 2015 19:32:23 -0400 Date: Tue, 28 Jul 2015 07:32:19 +0800 From: Baoquan He To: Yinghai Lu Cc: Dave Young , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Borislav Petkov , Andrew Morton , Jiri Kosina , Vivek Goyal , Linux Kernel Mailing List Subject: Re: [PATCH v2] Do not reserve crashkernel high memory if crashkernel low memory reserving failed Message-ID: <20150727233219.GA1720@dhcp-17-102.nay.redhat.com> References: <1437304064-9916-1-git-send-email-bhe@redhat.com> <20150719145320.GB9968@dhcp-17-102.nay.redhat.com> <20150721073123.GA30649@dhcp-129-220.nay.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1151 Lines: 38 On 07/27/15 at 11:31am, Yinghai Lu wrote: > >> #else > >> static void __init reserve_crashkernel(void) > > No, you can not move the calling position for reserve_crashkernel_low(). > > old sequence: > > memblock_find_in_range for high > memblock_reserve for high > memblock_find_in_range for low > memblock_reserve for low > > now you change to: > memblock_find_in_range for high > memblock_find_in_range for low > memblock_reserve for low > memblock_reserve for high > > during memblock_reserve, we would double the memblock reserve array. > So there is possibility that new membock reserve array is overlapped with > range for crashdump high. > > so you should keep the old sequence, and if reserve_crashkernel_low fail, > just call memblock_free to free high range that is reserved before. Right, memblock_double_array need avoid the required region. Will repost. > > Thanks > > Yinghai -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/