Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 80716
b: refs/heads/master
c: f9d46eb
h: refs/heads/master
v: v3
  • Loading branch information
Izik Eidus authored and Avi Kivity committed Jan 30, 2008
1 parent a82703b commit 0c0b074
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1a6f4d7fbd11e539630cd5637311a4e55fae60ef
refs/heads/master: f9d46eb0e4a5b5e0926ca61c19f8c8bbb9496b28
1 change: 1 addition & 0 deletions trunk/drivers/kvm/kvm.h
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,7 @@ struct page *gva_to_page(struct kvm_vcpu *vcpu, gva_t gva);
extern struct page *bad_page;

int is_error_page(struct page *page);
int kvm_is_error_hva(unsigned long addr);
int kvm_set_memory_region(struct kvm *kvm,
struct kvm_userspace_memory_region *mem,
int user_alloc);
Expand Down
11 changes: 11 additions & 0 deletions trunk/drivers/kvm/kvm_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -498,6 +498,17 @@ int is_error_page(struct page *page)
}
EXPORT_SYMBOL_GPL(is_error_page);

static inline unsigned long bad_hva(void)
{
return PAGE_OFFSET;
}

int kvm_is_error_hva(unsigned long addr)
{
return addr == bad_hva();
}
EXPORT_SYMBOL_GPL(kvm_is_error_hva);

gfn_t unalias_gfn(struct kvm *kvm, gfn_t gfn)
{
int i;
Expand Down

0 comments on commit 0c0b074

Please sign in to comment.