From mboxrd@z Thu Jan 1 00:00:00 1970 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.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 D7139C433ED for ; Tue, 18 May 2021 22:26:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B4F9B60232 for ; Tue, 18 May 2021 22:26:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242589AbhERW2Q (ORCPT ); Tue, 18 May 2021 18:28:16 -0400 Received: from pb-smtp1.pobox.com ([64.147.108.70]:61547 "EHLO pb-smtp1.pobox.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232020AbhERW2P (ORCPT ); Tue, 18 May 2021 18:28:15 -0400 Received: from pb-smtp1.pobox.com (unknown [127.0.0.1]) by pb-smtp1.pobox.com (Postfix) with ESMTP id 4E889C94B9; Tue, 18 May 2021 18:26:56 -0400 (EDT) (envelope-from nico@fluxnic.net) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=pobox.com; h=date:from :to:cc:subject:in-reply-to:message-id:references:mime-version :content-type; s=sasl; bh=uyX7ogXS6ttXtxFCbmbVJP7Uy1ThRGIHklbWlj 5/1VM=; b=SBb6K/wMjBJmXenq7GziC3+EM1gJaPRLnIzjFL0SSUqdeFGYWAWEsk z5Ngawvv2Mrfvwsisgkw3fk5nD0Fi4nughxecFDIEniVhqMKLI3ibuaOhljzhqiL X5hAV/UUOR3XV7j/mb9zkODMBiJv5Pm1jjIIoI71N1YGkNIL9oNmg= Received: from pb-smtp1.nyi.icgroup.com (unknown [127.0.0.1]) by pb-smtp1.pobox.com (Postfix) with ESMTP id 44F70C94B8; Tue, 18 May 2021 18:26:56 -0400 (EDT) (envelope-from nico@fluxnic.net) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=fluxnic.net; h=date:from:to:cc:subject:in-reply-to:message-id:references:mime-version:content-type; s=2016-12.pbsmtp; bh=uyX7ogXS6ttXtxFCbmbVJP7Uy1ThRGIHklbWlj5/1VM=; b=Kvi1UQ8jAmauFX24SwSRCxgrbHf6aHWfv34aYkbuN1wT/6gUjqZUeUxsqqSXETW4XwN7gCPjkUn1MJ2YqlOJKkDDRfqi/eqO4rlfY8CTza9Bsk/xvnm1l77h5dkuwpz4en9er302gBJZg2cLKrYoraznZ4C2tN+ALRtoxZnYHzw= Received: from yoda.home (unknown [96.21.170.108]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp1.pobox.com (Postfix) with ESMTPSA id BD810C94B7; Tue, 18 May 2021 18:26:55 -0400 (EDT) (envelope-from nico@fluxnic.net) Received: from xanadu.home (xanadu.home [192.168.2.2]) by yoda.home (Postfix) with ESMTPSA id C6DEE2DA0092; Tue, 18 May 2021 18:26:54 -0400 (EDT) Date: Tue, 18 May 2021 18:26:54 -0400 (EDT) From: Nicolas Pitre To: Linus Walleij cc: "Russell King (Oracle)" , Yanfei Xu , Mike Rapoport , Ard Biesheuvel , Andrew Morton , Hailong liu , Tian Tao , Linux ARM , linux-kernel Subject: Re: [PATCH 3/4] ARM: change vmalloc_min to vmalloc_start In-Reply-To: Message-ID: References: <20210518120633.GW12395@shell.armlinux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Pobox-Relay-ID: 270766AC-B828-11EB-80B9-D152C8D8090B-78420484!pb-smtp1.pobox.com Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 19 May 2021, Linus Walleij wrote: > On Tue, May 18, 2021 at 2:15 PM Russell King (Oracle) > wrote: > > > Change the current vmalloc_min, which is supposed to be the lowest > > address of vmalloc space including the VMALLOC_OFFSET, to vmalloc_start > > which does not include VMALLOC_OFFSET. > > > > Signed-off-by: Russell King (Oracle) > > Reviewed-by: Linus Walleij > > > +static unsigned long __initdata vmalloc_start = VMALLOC_END - (240 << 20); > > When I first read this it took me some time to figure out what was > going on here, so if you have time, please fold in a comment > with some explanation of that (240 << 20) thing, in some blog > post I described it as "an interesting way to write 0x0f000000" > but I suppose commit 0536bdf33faf chose this way for a > specific reason? (Paging Nico if he can explain it.) That's an alternative (and deprecated) way to write MB(240). Nicolas From mboxrd@z Thu Jan 1 00:00:00 1970 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=-9.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 CB9A4C433B4 for ; Tue, 18 May 2021 22:29:02 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 4C27E61002 for ; Tue, 18 May 2021 22:29:02 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4C27E61002 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=fluxnic.net Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:Message-ID:In-Reply-To: Subject:cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=J24ji1/9T5RKyeM3ZxFRfBFzmdpO/gc4234OfEAUK2g=; b=hUbr4iv8aaXBS+ZIe2aOKewt/ P9WMVtmM0MK+6fabUpe1HSIxzuSCfjzuprVslRrSrQod7sPW2mcoy7IQNvwwSKTUD5sFC6nK49H2k lVePtuXS93dVkJois06rGKJLyLqRVfJLcWnIhm2yy8kLgDUUMQxua/feSMTlS88nh030OBmDPw4FS uxertSp8GTy2rcrMgpC/sFLxR39CU8hZGsY0Y84HQziaXdNRe23WtSWcy8J67nE29xu/jOvLBUJ/9 yShz+zmDx4JjpsNR5PETn9M5lln2iMss7uD1R/50Wt4K9vT5n9xYfxao8VN6Uxf+xDqi4FueTLAx2 96Eq+Y6CQ==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lj8B8-0023h7-7P; Tue, 18 May 2021 22:27:06 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lj8B5-0023gu-Ep for linux-arm-kernel@desiato.infradead.org; Tue, 18 May 2021 22:27:03 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Type:MIME-Version:References: Message-ID:In-Reply-To:Subject:cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=Azx94azArb+f4h+fNai79zzkhNmflz1CKPLhDeB4Vqw=; b=yJq+KR/MH+0/jh0Qx0N7ITeONT weAR0aAAAYoAUkoAp2RB3DSJDNuUhb5fa7gCJ5/yncgTO8vgtQgHnV2/u7TvqZ8HChFGHTMfwm8OC SUdaP6LjyM+GUMChy+Lr6qVAigN357P0FpVeVp3AeBvvfuDUoyUfVJ0OLVAA/58EDMoIkCbaNtSQu +rDsHn6gvZSQg+Rv4I/vlSzR1He0sQTxlPpp/c8a583AkUO7AB8fHZCrBVyIsvQzlmCvQ+56SMiBw 1hV0t8QtMkya8fW056+qfpGFDdV+X4EJ05NF8x0bufQ8tmn13wTcQbc9oiSlAZ/hnv+eGI64zaRlv NegLpZag==; Received: from pb-smtp1.pobox.com ([64.147.108.70]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lj8B2-00F07T-4W for linux-arm-kernel@lists.infradead.org; Tue, 18 May 2021 22:27:01 +0000 Received: from pb-smtp1.pobox.com (unknown [127.0.0.1]) by pb-smtp1.pobox.com (Postfix) with ESMTP id 4E889C94B9; Tue, 18 May 2021 18:26:56 -0400 (EDT) (envelope-from nico@fluxnic.net) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=pobox.com; h=date:from :to:cc:subject:in-reply-to:message-id:references:mime-version :content-type; s=sasl; bh=uyX7ogXS6ttXtxFCbmbVJP7Uy1ThRGIHklbWlj 5/1VM=; b=SBb6K/wMjBJmXenq7GziC3+EM1gJaPRLnIzjFL0SSUqdeFGYWAWEsk z5Ngawvv2Mrfvwsisgkw3fk5nD0Fi4nughxecFDIEniVhqMKLI3ibuaOhljzhqiL X5hAV/UUOR3XV7j/mb9zkODMBiJv5Pm1jjIIoI71N1YGkNIL9oNmg= Received: from pb-smtp1.nyi.icgroup.com (unknown [127.0.0.1]) by pb-smtp1.pobox.com (Postfix) with ESMTP id 44F70C94B8; Tue, 18 May 2021 18:26:56 -0400 (EDT) (envelope-from nico@fluxnic.net) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=fluxnic.net; h=date:from:to:cc:subject:in-reply-to:message-id:references:mime-version:content-type; s=2016-12.pbsmtp; bh=uyX7ogXS6ttXtxFCbmbVJP7Uy1ThRGIHklbWlj5/1VM=; b=Kvi1UQ8jAmauFX24SwSRCxgrbHf6aHWfv34aYkbuN1wT/6gUjqZUeUxsqqSXETW4XwN7gCPjkUn1MJ2YqlOJKkDDRfqi/eqO4rlfY8CTza9Bsk/xvnm1l77h5dkuwpz4en9er302gBJZg2cLKrYoraznZ4C2tN+ALRtoxZnYHzw= Received: from yoda.home (unknown [96.21.170.108]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp1.pobox.com (Postfix) with ESMTPSA id BD810C94B7; Tue, 18 May 2021 18:26:55 -0400 (EDT) (envelope-from nico@fluxnic.net) Received: from xanadu.home (xanadu.home [192.168.2.2]) by yoda.home (Postfix) with ESMTPSA id C6DEE2DA0092; Tue, 18 May 2021 18:26:54 -0400 (EDT) Date: Tue, 18 May 2021 18:26:54 -0400 (EDT) From: Nicolas Pitre To: Linus Walleij cc: "Russell King (Oracle)" , Yanfei Xu , Mike Rapoport , Ard Biesheuvel , Andrew Morton , Hailong liu , Tian Tao , Linux ARM , linux-kernel Subject: Re: [PATCH 3/4] ARM: change vmalloc_min to vmalloc_start In-Reply-To: Message-ID: References: <20210518120633.GW12395@shell.armlinux.org.uk> MIME-Version: 1.0 X-Pobox-Relay-ID: 270766AC-B828-11EB-80B9-D152C8D8090B-78420484!pb-smtp1.pobox.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210518_152700_286942_BE9A88F5 X-CRM114-Status: GOOD ( 20.10 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, 19 May 2021, Linus Walleij wrote: > On Tue, May 18, 2021 at 2:15 PM Russell King (Oracle) > wrote: > > > Change the current vmalloc_min, which is supposed to be the lowest > > address of vmalloc space including the VMALLOC_OFFSET, to vmalloc_start > > which does not include VMALLOC_OFFSET. > > > > Signed-off-by: Russell King (Oracle) > > Reviewed-by: Linus Walleij > > > +static unsigned long __initdata vmalloc_start = VMALLOC_END - (240 << 20); > > When I first read this it took me some time to figure out what was > going on here, so if you have time, please fold in a comment > with some explanation of that (240 << 20) thing, in some blog > post I described it as "an interesting way to write 0x0f000000" > but I suppose commit 0536bdf33faf chose this way for a > specific reason? (Paging Nico if he can explain it.) That's an alternative (and deprecated) way to write MB(240). Nicolas _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel