Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1lbKp5-0005DW-F8 for mharc-grub-devel@gnu.org; Tue, 27 Apr 2021 06:20:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35470) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lbKp3-0005AG-Rv for grub-devel@gnu.org; Tue, 27 Apr 2021 06:20:05 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:60684) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lbKp0-0000ft-5l for grub-devel@gnu.org; Tue, 27 Apr 2021 06:20:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1619518796; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vrus1GiWY3n3HVbh1nd5DfJO03UzKTBUMFVOg7C1BBg=; b=d0OAeFH02lxySoj7G+oQP+hKx0aEUfBu/K7c6iCTJKsQj3i0HzqCyIqIu8UhMpWXEBpq9p EzF77x6+o9VSQdY6hefZ4U9OU3H5NmuN0PYkVpZPopAurQ114r3VZIw88iH3a2pgVsxHHf yu+ahumxl/2aOLBL7OlJtUPjVCYpjPg= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-591-BpBLfm1sM2KDduykh9kMuA-1; Tue, 27 Apr 2021 06:19:54 -0400 X-MC-Unique: BpBLfm1sM2KDduykh9kMuA-1 Received: by mail-wr1-f69.google.com with SMTP id s7-20020adfc5470000b0290106eef17cbdso17027320wrf.11 for ; Tue, 27 Apr 2021 03:19:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=vrus1GiWY3n3HVbh1nd5DfJO03UzKTBUMFVOg7C1BBg=; b=R/zG9zReM1pbrfUhl0OYfRm0CGeRmKHKRKZw8zBcajbx0ejk1NKIonVqEUZLyoFK53 T+GfBjpd25KXv8fb51YTTDtOcv24hboOhaxqR7AONEDs0d6VhMeb9Pud3KhlK7O1NvFX rESGd1MmidlaDgHjNMvBCGPueklX5ws+/wCE0Ep3M7ErYOzMg3O+NqxK5rguKQhtThMK JdJmjEQ39sDxtgZry8sQvDCcsdCt9oYiIKRzGbm1ZREhBiwbVchheZhw2f9vqLJcMrf0 4BY+kUaEY/jOiDH45q8YwwLuEwXqdApwiAiudAymyzc7uPW5rh1Eu/6L4psF2CJX+Qic RDew== X-Gm-Message-State: AOAM5324s9DQ85eBstiLmhJfd/LdSrO67ilo5Ab+HhQJHMDMHzY51oZ7 f5m2B96OVMBCKUP/uNQ38DCcreHMBcMrezl0uAHPbk2sU0yC2Xa81XfAyUMD2SHq0A5Q8Lhm76a P4txN1sWBEpg= X-Received: by 2002:a05:6000:144:: with SMTP id r4mr20240167wrx.128.1619518793786; Tue, 27 Apr 2021 03:19:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzdqwp2jX1RHII/LVcYlxZJKkSv0TcHEMH3KQ1iMvGC6dhLVKrnkIMFNfzhU3B52ZjfgW+cGQ== X-Received: by 2002:a05:6000:144:: with SMTP id r4mr20240150wrx.128.1619518793578; Tue, 27 Apr 2021 03:19:53 -0700 (PDT) Received: from [192.168.1.101] ([92.176.231.106]) by smtp.gmail.com with ESMTPSA id n5sm1597910wrx.92.2021.04.27.03.19.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 27 Apr 2021 03:19:52 -0700 (PDT) Subject: Re: [RFC PATCH v2] util/mkimage: Fix wrong PE32+ section sizes for some arches To: John Paul Adrian Glaubitz , The development of GNU GRUB , Daniel Kiper Cc: Daniel Kiper References: <20210426072102.1531425-1-javierm@redhat.com> <20210426171831.dkct5xzu7jahlgde@tomti.i.net-space.pl> From: Javier Martinez Canillas Message-ID: Date: Tue, 27 Apr 2021 12:19:51 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=javierm@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=216.205.24.124; envelope-from=javierm@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -29 X-Spam_score: -3.0 X-Spam_bar: --- X-Spam_report: (-3.0 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.219, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Apr 2021 10:20:06 -0000 Hello Adrian, On 4/27/21 9:55 AM, John Paul Adrian Glaubitz wrote: > Hi Javier! > > On 4/26/21 7:18 PM, Daniel Kiper wrote: >> (...) >> I think this should be: >> layout->kernel_size = ALIGN_UP (layout->kernel_size, GRUB_PE32_FILE_ALIGNMENT); >> >> Here we care about alignment in the PE file not in the memory. So, >> I think we have to use GRUB_PE32_FILE_ALIGNMENT instead. Though >> the result is the same... > > Let me know once you have a new version of the patch ready, I'll test it as quickly > as possible. > Thanks! I was busy this morning with other things but I'll post a v3 now. I'll keep your Tested-by tag since the size calculated should be the same, but would be good to test it again just to make sure that's the case. > Adrian > Best regards, -- Javier Martinez Canillas Software Engineer - Desktop Hardware Enablement Red Hat