lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Fri, 12 Aug 2011 16:33:49 +0800
From:	liu pf <kernelfans@...il.com>
To:	kvm@...r.kernel.org
Cc:	Avi Kivity <avi@...hat.com>, linux-kernel@...r.kernel.org
Subject: [KVM]:could anyone give me some instruction for KVM pci driver? Thanks

Hi guys,

When I develop a PCI device driver for qemu-kvm, I am suffering from
some problem, Could anyone give me some instruction? Thanks :)

My solution consists of two parts:  emulated PCI device in Qemu and
corresponding PCI device driver in guest OS.
The emulated  device has a PCI -memmap registers. So as expected, when
the guest device driver wrote this area, we will capture such event in
Qemu.
But it failed to do so. After tracing the host kernel, I found that
 1. my guest PCI device driver had claimed the gpa from
pci_dev->resource[0].start=0xf0050000 to resource[0].end=0xf00500ff
and succeed to ioremap
 2. In host kernel,  I added "printk" after
handle_ept_violation(struct kvm_vcpu *vcpu) {gpa
=vmcs_read64(GUEST_PHYSICAL_ADDRESS); printk(..);}
    BUT, when guest wrote this "ioremap" area, the host did NOT hit
the region [0xf0050000,0xf00500ff]


I had thought that when accessing the emulated device, the gva ->gpa
has been set up by guest, so EPT violation will be the only reason
which caused guest exit .  And the event will be finally passed to the
user mode--qemu.  Am I right?

And the most important is what I can do for the next step?

BTW, I am sure that "kvm_enable_tdp". and kernel is 2.6.39, for config
file, pls see attachment.


Thanks,
Pierce

Download attachment "config.gz" of type "application/x-gzip" (24799 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ