Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.1 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1A029C433E1 for ; Wed, 15 Jul 2020 12:24:49 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 6747820720 for ; Wed, 15 Jul 2020 12:24:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=ellerman.id.au header.i=@ellerman.id.au header.b="mybKQfP/" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6747820720 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 4B6GmG2cbYzDqbx for ; Wed, 15 Jul 2020 22:24:46 +1000 (AEST) Received: from ozlabs.org (bilbo.ozlabs.org [IPv6:2401:3900:2:1::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4B6Gjt3XvLzDqj1 for ; Wed, 15 Jul 2020 22:22:42 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=ellerman.id.au header.i=@ellerman.id.au header.a=rsa-sha256 header.s=201909 header.b=mybKQfP/; dkim-atps=neutral Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 4B6Gjs49tdz9s1x; Wed, 15 Jul 2020 22:22:41 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ellerman.id.au; s=201909; t=1594815761; bh=Y8j90lrvJqU8LkgdUr74V2K/s7Gh4WhJQGlePVUnek8=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=mybKQfP/UVFZuhYRuLtxJsKUd4PMqXYvQ4BG43NxDXD67VzjEl65QG5gpw1vQvngE jB6+kGgkGsDvXAHjeQRGUosfNu94A+eBAOKyUhFoEsAluH5GM14CZZFqNQIv2y3zXz IN4QrF9YEhOlYFNAnbye0ZO3jQnYak96lX4fvR81V8BRBakvbizOJW2mXXha5ISDj8 s+YufzfAcVsYd3QnoMnbLgphqPZyGrJRWrUt2IHz1kcG3fG2hFLyDmpTm57KIO91e1 Wolmts2eLiKj4cQtbm37OqhXF0gZ1TWjRDj6+aCkLDZya2EBcL8aOiuz13Aj/30cjI PhHN5cZA0tOlg== From: Michael Ellerman To: Anton Blanchard , benh@kernel.crashing.org, paulus@samba.org, nathanl@linux.ibm.com Subject: Re: [PATCH] pseries: Fix 64 bit logical memory block panic In-Reply-To: <20200715000820.1255764-1-anton@ozlabs.org> References: <20200715000820.1255764-1-anton@ozlabs.org> Date: Wed, 15 Jul 2020 22:22:35 +1000 Message-ID: <87365tufw4.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linuxppc-dev@lists.ozlabs.org Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" Anton Blanchard writes: > Booting with a 4GB LMB size causes us to panic: > > qemu-system-ppc64: OS terminated: OS panic: > Memory block size not suitable: 0x0 > > Fix pseries_memory_block_size() to handle 64 bit LMBs. > > Cc: stable@vger.kernel.org > Signed-off-by: Anton Blanchard > --- > arch/powerpc/platforms/pseries/hotplug-memory.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/powerpc/platforms/pseries/hotplug-memory.c b/arch/powerpc/platforms/pseries/hotplug-memory.c > index 5ace2f9a277e..6574ac33e887 100644 > --- a/arch/powerpc/platforms/pseries/hotplug-memory.c > +++ b/arch/powerpc/platforms/pseries/hotplug-memory.c > @@ -27,7 +27,7 @@ static bool rtas_hp_event; > unsigned long pseries_memory_block_size(void) > { > struct device_node *np; > - unsigned int memblock_size = MIN_MEMORY_BLOCK_SIZE; > + uint64_t memblock_size = MIN_MEMORY_BLOCK_SIZE; I changed it to u64. cheers