Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp3636112ybd; Fri, 28 Jun 2019 12:09:29 -0700 (PDT) X-Google-Smtp-Source: APXvYqw3mERlItqf+WVIa604fTmwNglnYYDeWRuQYpj9hO3CHBgOU0kG7PicEgKgX5Wu6BInV1RC X-Received: by 2002:a63:6981:: with SMTP id e123mr10620250pgc.136.1561748968990; Fri, 28 Jun 2019 12:09:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561748968; cv=none; d=google.com; s=arc-20160816; b=RWmcFPI/n/GfyZrFh2qQuK+k54Pm9WYk5+/ncTReY+GcQPKJUudJegTIGVFpUwPUn6 o0iQVesrthm2FJHEc4TCz6ty1VZLxFHNlARGyH6F8n9WydHA8sLfe0MhYCfPgmZXxqry 76T1JcljR5UjA0WCq1cXGCVbeQYwxW1eTTHVEXghUu4l15jZ0tY5Z7ONmqZ9MVAuhTw5 l1zQicDgCipZ+TVtweP2e+W49NNFHKHNYqR+o0n57GpIdWqsx1tAA32sjTUOg/ZunetC /6SrDpX9uYoFez6XYDxgFOsdU0PHgO0bZs1hJFAu4oGURX7yuzg75sRanM3nDG2Tz8dE yOGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=denpEz7Y25tPYld+8szHUZUn70KyumHMuU5ZgYCdiKI=; b=BqiLgzC7fKVijprYkuTqz6w+FHLmmaVnc0k9q42+8JGU30BkftxU90BnzfqAFBgd3Y dgGj6zAfivV1hbD2xNaIyJIJgffDEaHBY/QSVHoPCPQcVgCllbAYOVocHlhiUI+RtpqA kkFh/olJSxc4m6YVSZTqx+ognByMcjRpqu/5hV0OaaNFyqlcCyydN9mQSBOMiHOCW9F1 IkvhuIypcL6zLlIMbBbhabWBMeoUt091Ih6p49RMwy77tkv3VuihfB6K9ezErV2xIVlp XrKo1UcmGuALhb2Q285A4I83OC0KTBH4IxOUqdiricPU5EFvZS3STiiQfIOl7Dq/VnIA TKTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sifive.com header.s=google header.b=HWMrmaJn; 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 r6si2825099pji.71.2019.06.28.12.09.10; Fri, 28 Jun 2019 12:09:28 -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; dkim=pass header.i=@sifive.com header.s=google header.b=HWMrmaJn; 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 S1726852AbfF1TJG (ORCPT + 99 others); Fri, 28 Jun 2019 15:09:06 -0400 Received: from mail-io1-f67.google.com ([209.85.166.67]:44100 "EHLO mail-io1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726643AbfF1TJG (ORCPT ); Fri, 28 Jun 2019 15:09:06 -0400 Received: by mail-io1-f67.google.com with SMTP id s7so14674251iob.11 for ; Fri, 28 Jun 2019 12:09:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; h=date:from:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=denpEz7Y25tPYld+8szHUZUn70KyumHMuU5ZgYCdiKI=; b=HWMrmaJnz5V8Ac64W9ltGnhij2/onexK3xCea2eFyAXK6JVJnwj62PwageLoaznljr lVtZWieElekXXI6Q4uto5rBOs5y5+Y+oEhsPTyrfK/jawOxPcID1zg2pkEYUErrhcwJB aszK3rXIb3zpoK6myJKG5S0dwok2xahK5qCTGgIkyiJIZXoRbIwMC/T+A04ynBDaa7BH hrEXqsOvUf285Gj4q/Vnqx2FcdDFpiK+Iaa3nU5B1d3yP/hh7wB2rHg3xnWWrSZTkWn+ Q8Ff3Ayu/GN5pDCx+2ZM3PNc7q0wBMyQInqc2hToFVqvI2Nn3mimmdf2GreNGgeTmOwr KdwQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=denpEz7Y25tPYld+8szHUZUn70KyumHMuU5ZgYCdiKI=; b=ETM89ubDjWVqTmFOrOPVfVeVtENJMKTjsiXUvAGianC3yZpr9qr3eJ9L7pVOjp8nPf Qbbnmmf+YZzaTRcuk9Zv3UIcyQcsqryHx+uBHLY6gGjndDDrRJvSEfZn/Yh5RXvAmK/2 m7N2rhZBnTsLPet2XIguPqMLhOyOHziLeaizYw9RWNVJ54T5aKu06gYV7yUNIv+Ppw/3 VVEjBf1c+aXYUtDr6f7+Cf2dxhW/aeyEhquFKqtbqYHIboasSaeF4pQkWUi2eR74udsc ndyWwxpAYoB2MnMdxSSxFRzvgYsEQtDNDLcI2cELEwtWgwijAHXGzAXYLo2IxWYkN+30 WiVA== X-Gm-Message-State: APjAAAW9L6Dq4U13m54h1dW2zJ22Gy7bBlk6rUT4+f2S3LyJPbShkfln nc2f9srur0fBnPTI7V/Pg03//w== X-Received: by 2002:a05:6638:281:: with SMTP id c1mr13074518jaq.43.1561748945460; Fri, 28 Jun 2019 12:09:05 -0700 (PDT) Received: from localhost (c-73-95-159-87.hsd1.co.comcast.net. [73.95.159.87]) by smtp.gmail.com with ESMTPSA id x13sm2623367ioj.18.2019.06.28.12.09.04 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 28 Jun 2019 12:09:05 -0700 (PDT) Date: Fri, 28 Jun 2019 12:09:04 -0700 (PDT) From: Paul Walmsley X-X-Sender: paulw@viisi.sifive.com To: Atish Patra cc: linux-kernel@vger.kernel.org, Karsten Merker , Kevin Hilman , Albert Ou , Anup Patel , Jonathan Corbet , linux-doc@vger.kernel.org, linux-riscv@lists.infradead.org, Nick Kossifidis , Palmer Dabbelt , "linux-arm-kernel@lists.infradead.org" , "mark.rutland@arm.com" , "marek.vasut@gmail.com" , "catalin.marinas@arm.com" , "will.deacon@arm.com" , "trini@konsulko.com" Subject: Re: [PATCH v4] RISC-V: Add an Image header that boot loader can parse. In-Reply-To: <20190606230800.19932-1-atish.patra@wdc.com> Message-ID: References: <20190606230800.19932-1-atish.patra@wdc.com> User-Agent: Alpine 2.21.9999 (DEB 301 2018-08-15) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 6 Jun 2019, Atish Patra wrote: > Currently, the last stage boot loaders such as U-Boot can accept only > uImage which is an unnecessary additional step in automating boot > process. > > Add an image header that boot loader understands and boot Linux from > flat Image directly. ... > +#if __riscv_xlen == 64 > + /* Image load offset(2MB) from start of RAM */ > + .dword 0x200000 > +#else > + /* Image load offset(4MB) from start of RAM */ > + .dword 0x400000 > +#endif Is there a rationale behind these load offset values? - Paul