question about "struct kvm_segment"

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

 



Hi,

The structure kvm_segment is defined as follows:

struct kvm_segment {
        __u64 base;
        __u32 limit;
        __u16 selector;
        __u8  type;
        __u8  present, dpl, db, s, l, g, avl;
        __u8  unusable;
        __u8  padding;
};

Since the VMX spec defines base is 64 bits, limit is 32bits, selector
is 16bits, understandably, __u64, __u32, __u16 is used for them
respectively.

However, the VMX spec defines that the access rights is 32bits, which
includes a 4 bits type, 2 bits dpl, and 1 bit for the
present,dpl,db,s,l,g,avl. So why here they are all defined as __u8? It
means that, each of them is represented by 8bits? This looks
inconsistent with the VMX spec.

Hope someone can explain this, thanks!

-Jidong
_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/virtualization




[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux