[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] UUID support for UFS
From: |
Pavel Roskin |
Subject: |
Re: [PATCH] UUID support for UFS |
Date: |
Tue, 21 Jul 2009 17:31:50 -0400 |
On Tue, 2009-07-21 at 20:46 +0200, Javier Martín wrote:
> Vladimir 'phcoder' Serbinenko escribió:
> > On Tue, Jul 21, 2009 at 7:14 PM, Pavel Roskin<address@hidden> wrote:
> >> On Tue, 2009-07-21 at 15:03 +0200, Vladimir 'phcoder' Serbinenko wrote:
> >>> + grub_sprintf (*uuid, "%08lx%08lx",
> >>> + (unsigned long) grub_le_to_cpu32
> >>> (data->sblock.uuidhi),
> >>> + (unsigned long) grub_le_to_cpu32
> >>> (data->sblock.uuidlow));
> >> unsigned long is 64-bit on x86_64. unsigned int would do just fine
> >> here.
> > Ok
> We could use the <inttypes.h> macros for [u]intN_t types:
> grub_sprintf (*uuid, PRIx32 "-" PRIx32,
> grub_le_to_cpu32 (data->sblock.uuidhi),
> grub_le_to_cpu32 (data->sblock.uuidlow));
> Of course, our *printf functions would have to recognize them, and we'd
> have to provide a suitable default for the header if the system compiler
> is not C99 compliant, but I think it's a good step forwards.
>
> I would be willing to implement such a header/change to the *printf
> functions if there's any interest in them.
I think we shouldn't overengineer this. We don't support platforms
where int is not 32-bit. If we add support for such platform, we'll
have more issues than just printf.
--
Regards,
Pavel Roskin
- [PATCH] UUID support for UFS, Vladimir 'phcoder' Serbinenko, 2009/07/21
- Re: [PATCH] UUID support for UFS, Pavel Roskin, 2009/07/21
- Re: [PATCH] UUID support for UFS, Vladimir 'phcoder' Serbinenko, 2009/07/21
- Re: [PATCH] UUID support for UFS, Pavel Roskin, 2009/07/21
- Re: [PATCH] UUID support for UFS, Javier Martín, 2009/07/21
- Re: [PATCH] UUID support for UFS,
Pavel Roskin <=
- Re: [PATCH] UUID support for UFS, Vladimir 'phcoder' Serbinenko, 2009/07/21
- Re: [PATCH] UUID support for UFS, Pavel Roskin, 2009/07/21
- Re: [PATCH] UUID support for UFS, Javier Martín, 2009/07/21
- Re: [PATCH] UUID support for UFS, Pavel Roskin, 2009/07/21
- Re: [PATCH] UUID support for UFS, Javier Martín, 2009/07/21
- Re: [PATCH] UUID support for UFS, Pavel Roskin, 2009/07/21
- Re: [PATCH] UUID support for UFS, Robert Millan, 2009/07/22
- Re: [PATCH] UUID support for UFS, Javier Martín, 2009/07/22
- Re: [PATCH] UUID support for UFS, Robert Millan, 2009/07/22
Re: [PATCH] UUID support for UFS, Robert Millan, 2009/07/22