Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2316988yba; Fri, 17 May 2019 14:48:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqwmjFkQl27IRluNtEcS+N+kW9aze46a12XfKwdykCrGSS9qL4h0UaDEGL13UVC9cz8XrDqx X-Received: by 2002:aa7:820c:: with SMTP id k12mr63345413pfi.177.1558129712512; Fri, 17 May 2019 14:48:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558129712; cv=none; d=google.com; s=arc-20160816; b=oacDpebx4x1M7LAA1NLkt5T0geKkVUq2oWaBtODctbPDx9afv6kMFrtyVRZRkDulsx XPE4SK3qNO/dxn+DvLHE6Sp/v1WCnxL7gWjd0xhn9msVVaSEgNhSiqbp3E2SHT1y1HJ6 NdwTfGeRTnJaoUEjrCDXlIdh/94c4EklkF4mlxgL9UI0UUn2TKgQ3nlFdi+JnLAaBJhT liTnDDUe62dirOYIqrVboIB/4LOxtxVu58fw4L2TK9avhmLhvSnDMgjepvRP3tvRZdn+ g3o/9TqwhZGRJ9P2fZg9dNlNrqDD/0iAQh1CA4K9PMEUNJZTXal4yxE55TWFb/BE/EmK b+cw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:ironport-sdr:ironport-sdr :dkim-signature; bh=PMRXvjq1v4iRSsKXLxLYSwJqwg+c+ARNPaoIOqYqkQg=; b=beIRNm41X1zg5fcadRw7CvANY3IHNcKRic95Rlmkhc5x4JsdmefR78rh8cCyxZaOSx ISpD3tP7jEhYiK9pBF7SWCUaMAnPF+4GYKZXALxmXzGZZFx/frZzFOHS98cwMnnRghqh sSdypJ3VxXBKnF6ABjvqILdCxq1+VXa6ZuKCeTVqu2Mx0IKaHi0RqoqBU12i3s2RGQmt rQv0WOaqBP5X2LyDd2Oam8n/xIOocXheZ2gMG0o/DsFN0ZYzJItuNmIHeJqS2u+HesZv YjzA9G2uX8TWanhUN780CvyzLC495sMtpctwAo0gl5kpnDoyT4Oop4Jj0ubRd7rAZ13+ DKUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b="nor/VvRW"; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=wdc.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t11si9108701pgj.284.2019.05.17.14.48.16; Fri, 17 May 2019 14:48:32 -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=fail header.i=@wdc.com header.s=dkim.wdc.com header.b="nor/VvRW"; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=wdc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727543AbfEQTBt (ORCPT + 99 others); Fri, 17 May 2019 15:01:49 -0400 Received: from esa6.hgst.iphmx.com ([216.71.154.45]:54647 "EHLO esa6.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726293AbfEQTBs (ORCPT ); Fri, 17 May 2019 15:01:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1558119709; x=1589655709; h=subject:to:cc:references:from:message-id:date: mime-version:in-reply-to:content-transfer-encoding; bh=sCHcqEnJzvTT1HQ3nCB58qYi8YhUS/CBmEQC9NnNdhw=; b=nor/VvRW6QPxLy4bMwbwSn3Gi1vOCVmSKF6geTP1qXE4xFx1r4Fc07tl DWVVSyTBny3CWM0cFW+2/Ey8Gh1SErR7aPKR6aBaZ7eG/NnNCVIR4jlm8 QIyX7joLds3h7czoFvEDRGq04Q852kzTRciTjzvlcj0OufN/yOgIOjt8D 494pSMS10ryQYixx/jkFHCxPvtzAjtWgJBSgwBzgxFN+0BzVh2VM63x+/ bnlbt7Rdk2Dp5yZMldsLhlI3xBBUUMqFZHEL1HZ5hJdc1WI53BUzSJSn9 lfyyvBAMZeCP3woK0U29AbGe3boP2HXMwIIS+MQWhOgBEe7zlkF7rH8q2 A==; X-IronPort-AV: E=Sophos;i="5.60,481,1549900800"; d="scan'208";a="110234059" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 18 May 2019 03:01:48 +0800 IronPort-SDR: XGJtbrv01eKlBOw/5PDXS1C43hjFtduMAVejp6s3geoT17gSVnsxPn2uQ6qBuKX070PvVXM0La wwLJzwiZ2iWf+ighkihF0K3iUZ64ibBYcLTWXeDeOuapLw7Doflb9Ch8FpC5rxLeFutr70XjBJ /3QDxhNiKKPEwDRmpkG81KIBqHtxRsbXo1En67UbQS49b0KlaxeX/uGELhA8RUv6zIAcp1fIuu oSMzU2ulkjNLWP079O72NvpuqSeKYr1xwARlWEz6G2D7YLBE6udCLussWeTg4Mp2w+vvnY6P4L tNaZEULsIpIc0qg0i62aFgt0 Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP; 17 May 2019 11:37:19 -0700 IronPort-SDR: Gu7q0xAdL22XcBU/yPn/+JDD88Iu4XRdgU+EV6wulb5SqSKv19ICR1lonDFOjrdpIwtlS7B9tI XVbnajdmVvoGWxmqt6qEXlO5rcWvN/q7Eh/y8cMV07uveDWi9O2aoxh2y1Ea284gcrHe00Sxlz WcyfjAXg0A9QGZOswE9zJwCdnybPxRq/TiSklrAL8tNdFnMO5VmFkC9g3bvEm5UD3oY6dHBYfw MNI81DExSLt8zytIpglwz2NUbY6wuyQu3JVLb2X17VvPqZC39q7e01ZIImcr2H3MHyW4viTQvk pwo= Received: from cnf000212.ad.shared (HELO [10.86.56.27]) ([10.86.56.27]) by uls-op-cesaip02.wdc.com with ESMTP; 17 May 2019 12:01:48 -0700 Subject: Re: [v2 PATCH] RISC-V: Add a PE/COFF compliant Image header. To: Paul Walmsley Cc: "linux-kernel@vger.kernel.org" , "mark.rutland@arm.com" , Albert Ou , Anup Patel , Palmer Dabbelt , Zong Li , "merker@debian.org" , "linux-riscv@lists.infradead.org" References: <20190501195607.32553-1-atish.patra@wdc.com> From: Atish Patra Message-ID: Date: Fri, 17 May 2019 12:00:22 -0700 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/17/19 10:39 AM, Paul Walmsley wrote: > > On Wed, 1 May 2019, Atish Patra wrote: > >> Currently, last stage boot loaders such as U-Boot can accept only >> uImage which is an unnecessary additional step in automating boot flows. >> >> Add a PE/COFF compliant image header that boot loaders can parse and >> directly load kernel flat Image. The existing booting methods will continue >> to work as it is. > > One other thought: as I think you or someone else may have pointed out, > this isn't the PE/COFF header itself, but rather an ersatz DOS stub > header, that is apparently quite close to what some EFI bootloaders > require. So from that point of view, it's probably best to just write in > the patch description that the idea is to add something that resembles an > MS-DOS stub header, and that the motivations are that: > > 1. it resembles what ARM64 is doing, and there's not much point in > inventing another boot header format that's completely different > Yup. I will add this in the next version. > 2. it can be easily converted into an MS-DOS header that some EFI > bootloaders apparently require, by tweaking a few bytes at the beginning > I mentioned all the required changes in the proposed header to so that EFI bootloaders can load it directly. Probably, I will clarify it more to avoid confusion. > > - Paul > -- Regards, Atish