[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Make grub_efidisk_get_device_name() work on 4K native disks.
From: |
Vladimir 'φ-coder/phcoder' Serbinenko |
Subject: |
Re: [PATCH] Make grub_efidisk_get_device_name() work on 4K native disks. |
Date: |
Fri, 05 Apr 2013 09:09:38 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:10.0.12) Gecko/20130116 Icedove/10.0.12 |
On 04.04.2013 20:14, Andrey Borzenkov wrote:
> В Thu, 4 Apr 2013 13:52:05 -0400
> Peter Jones <address@hidden> пишет:
>
>> On Wed, Apr 03, 2013 at 11:03:46PM +0400, Andrey Borzenkov wrote:
>>> В Wed, 3 Apr 2013 11:53:06 -0400
>>> Peter Jones <address@hidden> пишет:
>>>
>>>> When we have 4kB sectors instead of 512b sectors, hd.partition_start and
>>>> grub_partition_get_start() won't match - the latter assumes 512-byte
>>>> sectors, and the former gives us the correct number based on the
>>>> physical media's sector size. So when we have to compare them, we need
>>>> to compensate.
>>>>
>>>> Signed-off-by: Peter Jones <address@hidden>
>>>> ---
>>>> grub-core/disk/efi/efidisk.c | 10 ++++++----
>>>> 1 file changed, 6 insertions(+), 4 deletions(-)
>>>>
>>>> diff --git a/grub-core/disk/efi/efidisk.c b/grub-core/disk/efi/efidisk.c
>>>> index 77ab5b0..a905b52 100644
>>>> --- a/grub-core/disk/efi/efidisk.c
>>>> +++ b/grub-core/disk/efi/efidisk.c
>>>> @@ -791,11 +791,13 @@ grub_efidisk_get_device_name (grub_efi_handle_t
>>>> *handle)
>>>> auto int find_partition (grub_disk_t disk, const grub_partition_t
>>>> part);
>>>>
>>>
>>> You need to rebase to current trunk which does not use nested functions
>>> anymore. Also in current trunk there is second use of
>>> grub_partition_get_start() which looks like it has the same issue.
>>
>> Oh, indeed, you're right, that has changed. Although the current tree looks
>> like it already takes this in to consideration.
>>
>
> Hmm ... I do not see it. Your change looks still necessary.
>
Probably your copy is a bit old. I adjusted and committed his patch.
>> So nevermind then :)
>>
>> Thanks for having a look.
>
>
> _______________________________________________
> Grub-devel mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/grub-devel
signature.asc
Description: OpenPGP digital signature