Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 146473
b: refs/heads/master
c: cf9e4e1
h: refs/heads/master
i:
  146471: 9527502
v: v3
  • Loading branch information
Sheng Yang authored and Avi Kivity committed Jun 10, 2009
1 parent fca5881 commit bb50fdf
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 20 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5897297bc228fc3c85fdc421fd5c487f9a99821a
refs/heads/master: cf9e4e15e8f6306b2559979269ead7c02e6b2b95
17 changes: 17 additions & 0 deletions trunk/include/linux/kvm_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,21 @@ typedef unsigned long hfn_t;

typedef hfn_t pfn_t;

union kvm_ioapic_redirect_entry {
u64 bits;
struct {
u8 vector;
u8 delivery_mode:3;
u8 dest_mode:1;
u8 delivery_status:1;
u8 polarity:1;
u8 remote_irr:1;
u8 trig_mode:1;
u8 mask:1;
u8 reserve:7;
u8 reserved[4];
u8 dest_id;
} fields;
};

#endif /* __KVM_TYPES_H__ */
6 changes: 3 additions & 3 deletions trunk/virt/kvm/ioapic.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ static unsigned long ioapic_read_indirect(struct kvm_ioapic *ioapic,

static int ioapic_service(struct kvm_ioapic *ioapic, unsigned int idx)
{
union ioapic_redir_entry *pent;
union kvm_ioapic_redirect_entry *pent;
int injected = -1;

pent = &ioapic->redirtbl[idx];
Expand Down Expand Up @@ -284,7 +284,7 @@ int kvm_ioapic_set_irq(struct kvm_ioapic *ioapic, int irq, int level)
{
u32 old_irr = ioapic->irr;
u32 mask = 1 << irq;
union ioapic_redir_entry entry;
union kvm_ioapic_redirect_entry entry;
int ret = 1;

if (irq >= 0 && irq < IOAPIC_NUM_PINS) {
Expand All @@ -305,7 +305,7 @@ int kvm_ioapic_set_irq(struct kvm_ioapic *ioapic, int irq, int level)
static void __kvm_ioapic_update_eoi(struct kvm_ioapic *ioapic, int pin,
int trigger_mode)
{
union ioapic_redir_entry *ent;
union kvm_ioapic_redirect_entry *ent;

ent = &ioapic->redirtbl[pin];

Expand Down
17 changes: 1 addition & 16 deletions trunk/virt/kvm/ioapic.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,22 +40,7 @@ struct kvm_ioapic {
u32 id;
u32 irr;
u32 pad;
union ioapic_redir_entry {
u64 bits;
struct {
u8 vector;
u8 delivery_mode:3;
u8 dest_mode:1;
u8 delivery_status:1;
u8 polarity:1;
u8 remote_irr:1;
u8 trig_mode:1;
u8 mask:1;
u8 reserve:7;
u8 reserved[4];
u8 dest_id;
} fields;
} redirtbl[IOAPIC_NUM_PINS];
union kvm_ioapic_redirect_entry redirtbl[IOAPIC_NUM_PINS];
struct kvm_io_device dev;
struct kvm *kvm;
void (*ack_notifier)(void *opaque, int irq);
Expand Down

0 comments on commit bb50fdf

Please sign in to comment.