Re: [PATCH 2/3] fdisk: add GPT support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Sep 27, 2012 at 11:51:08PM +0200, Davidlohr Bueso wrote:
> >     - remove global label-specific variables (e.g. gpt ents[])
> 
> Do you mean this?
>  static struct gpt_header *pheader = NULL;
>  static struct gpt_header *bheader = NULL;
>  static struct gpt_entry *ents = NULL;

 yes, and also many others in fdisk{dos,bsd,...}.c files

> If so, the reason for it being global is that it's accessed by the
> fdisk_label struct members, which, as you know, callers/users cannot
> know of label-specific stuff (only fdisk_context).

 Think about it as about a shared library. Maybe one day we will want
 to support work with more contexts of more labels, nested partition
 tables (bsd within dos) etc. And it's also about code readability.

 We have everywhere fdisk_context, so fix this problem should not be a
 problem.

> >     - add '<something>' to fdisk menu to print details about selected
> >       partition (uuid, type uuid, type name, name, etc...)
> > 
> >     - add '<something>' to menu to print details about the partition
> >       table (header, backup header, locations, number of allocated
> >       entries, used entries, offset of entry table and offset and size
> >       of data area, etc.)
> 
> Perhaps in verify?

 Maybe. It would be nice to have a way how to get all possible
 information about PT.

> On another note, I am a bit concerned about dealing with writing changes
> on disks with hybrid MBRs and not transforming it the standard
> protective. We need to be able to do so. Any thoughts are appreciated.

 From my point of view hybrid MBRs is nonsense and it's also against
 UEFI standard (there should be protective MBR and GPT, nothing
 other). I don't see a problem to ignore hybrid MBR at all.

    Karel

-- 
 Karel Zak  <kzak@xxxxxxxxxx>
 http://karelzak.blogspot.com
--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux