All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christian Ehrhardt <ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
To: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Cc: ,
	kvm-ppc-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
	"Avi Kivity <avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org>; 
	Hollis Blanchard
	<hollisb-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>;  Jerone
	Young" <jyoung5-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>,
	Christian Ehrhardt
	<ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
Subject: [PATCH 3/3] Add dcr read/write to the PowerPC kvmctl implementation
Date: Wed,  9 Jan 2008 16:11:16 +0100	[thread overview]
Message-ID: <1199891480765-git-send-email-ehrhardt@linux.vnet.ibm.com> (raw)
In-Reply-To: <1199891476938-git-send-email-ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>

Subject: [PATCH 3/3] Add dcr read/write to the PowerPC kvmctl implementation
From: Christian Ehrhardt <ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>

Adds simple functions to catch dcr access while executing testcases printing
information about that access when triggered.

Signed-off-by: Christian Ehrhardt <ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>

---
 main-ppc.c |   15 +++++++++++++++
 1 files changed, 15 insertions(+)

diff -r d19893c744fa user/main-ppc.c
--- a/user/main-ppc.c	Wed Jan 09 14:06:38 2008 +0100
+++ b/user/main-ppc.c	Wed Jan 09 14:34:49 2008 +0100
@@ -146,6 +146,19 @@ static int test_mem_write(void *opaque, 
 	return 0;
 }
 
+static int test_dcr_read(kvm_context_t kvm, uint32_t dcrn, uint32_t *data)
+{
+	printf("%s: dcrn %04X\n", __func__, dcrn);
+	*data = 0;
+	return 0;
+}
+
+static int test_dcr_write(kvm_context_t kvm, uint32_t dcrn, uint32_t data)
+{
+	printf("%s: dcrn %04X data %04X\n", __func__, dcrn, data);
+	return 0;
+}
+
 static struct kvm_callbacks test_callbacks = {
 	.mmio_read   = test_mem_read,
 	.mmio_write  = test_mem_write,
@@ -155,6 +168,8 @@ static struct kvm_callbacks test_callbac
 	.try_push_interrupts = test_try_push_interrupts,
 	.post_kvm_run = test_post_kvm_run,
 	.pre_kvm_run = test_pre_kvm_run,
+	.powerpc_dcr_read = test_dcr_read,
+	.powerpc_dcr_write = test_dcr_write,
 };
 
 static unsigned long load_file(void *mem, const char *fname, int inval_icache)

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace

  parent reply	other threads:[~2008-01-09 15:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-09 15:11 [PATCH 1/3] Add OBJCOPY to kvm-userspace/user/configure output Christian Ehrhardt
     [not found] ` <1199891476938-git-send-email-ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
2008-01-09 15:11   ` [PATCH 2/3] Add PowerPC kvmctl harness and fix building the testcases Christian Ehrhardt
2008-01-09 15:11   ` Christian Ehrhardt [this message]
     [not found]     ` <1199891480765-git-send-email-ehrhardt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
2008-01-09 15:24       ` [PATCH 3/3] Add dcr read/write to the PowerPC kvmctl implementation Avi Kivity

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1199891480765-git-send-email-ehrhardt@linux.vnet.ibm.com \
    --to=ehrhardt-23vcf4htsmix0ybbhkvfkdbpr1lh4cv8@public.gmane.org \
    --cc=jyoung5-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org \
    --cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    --cc=kvm-ppc-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.