diff options
Diffstat (limited to 'virt/kvm/kvm_main.c')
-rw-r--r-- | virt/kvm/kvm_main.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index 83a0e5ce6037..9330fad2b918 100644 --- a/virt/kvm/kvm_main.c +++ b/virt/kvm/kvm_main.c | |||
@@ -1350,14 +1350,15 @@ void kvm_io_bus_destroy(struct kvm_io_bus *bus) | |||
1350 | } | 1350 | } |
1351 | } | 1351 | } |
1352 | 1352 | ||
1353 | struct kvm_io_device *kvm_io_bus_find_dev(struct kvm_io_bus *bus, gpa_t addr) | 1353 | struct kvm_io_device *kvm_io_bus_find_dev(struct kvm_io_bus *bus, |
1354 | gpa_t addr, int len, int is_write) | ||
1354 | { | 1355 | { |
1355 | int i; | 1356 | int i; |
1356 | 1357 | ||
1357 | for (i = 0; i < bus->dev_count; i++) { | 1358 | for (i = 0; i < bus->dev_count; i++) { |
1358 | struct kvm_io_device *pos = bus->devs[i]; | 1359 | struct kvm_io_device *pos = bus->devs[i]; |
1359 | 1360 | ||
1360 | if (pos->in_range(pos, addr)) | 1361 | if (pos->in_range(pos, addr, len, is_write)) |
1361 | return pos; | 1362 | return pos; |
1362 | } | 1363 | } |
1363 | 1364 | ||