* [PATCH] Add accessor for kvm->vm_fd
@ 2007-11-07 18:45 Amit Shah
[not found] ` <200711080015.13694.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Amit Shah @ 2007-11-07 18:45 UTC (permalink / raw)
To: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
>From de1adac9a0f63bcac932ba76c8ca4a473e12af10 Mon Sep 17 00:00:00 2001
From: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
Date: Thu, 8 Nov 2007 00:13:07 +0530
Subject: [PATCH] Add accessor for kvm->vm_fd
Introduce kvm_get_vm_fd to get the VM FD
Signed-off-by: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
---
libkvm/libkvm.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/libkvm/libkvm.c b/libkvm/libkvm.c
index 5c8352e..fc2c60a 100644
--- a/libkvm/libkvm.c
+++ b/libkvm/libkvm.c
@@ -918,3 +918,8 @@ int kvm_irqchip_in_kernel(kvm_context_t kvm)
{
return kvm->irqchip_in_kernel;
}
+
+int kvm_get_vm_fd(kvm_context_t kvm)
+{
+ return kvm->vm_fd;
+}
--
1.4.4.2
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] Add accessor for kvm->vm_fd
[not found] ` <200711080015.13694.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
@ 2007-11-07 18:59 ` Amit Shah
[not found] ` <200711080029.05386.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Amit Shah @ 2007-11-07 18:59 UTC (permalink / raw)
To: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
With the declaration in libkvm.h this time:
>From 8313b87bcab415746e6eed86ac3f5b6c562b9764 Mon Sep 17 00:00:00 2001
From: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
Date: Thu, 8 Nov 2007 00:13:07 +0530
Subject: [PATCH] Add accessor for kvm->vm_fd
Introduce kvm_get_vm_fd to get the VM FD
Signed-off-by: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
---
libkvm/libkvm.c | 5 +++++
libkvm/libkvm.h | 7 +++++++
2 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/libkvm/libkvm.c b/libkvm/libkvm.c
index 5c8352e..fc2c60a 100644
--- a/libkvm/libkvm.c
+++ b/libkvm/libkvm.c
@@ -918,3 +918,8 @@ int kvm_irqchip_in_kernel(kvm_context_t kvm)
{
return kvm->irqchip_in_kernel;
}
+
+int kvm_get_vm_fd(kvm_context_t kvm)
+{
+ return kvm->vm_fd;
+}
diff --git a/libkvm/libkvm.h b/libkvm/libkvm.h
index b00d658..d5be0b9 100644
--- a/libkvm/libkvm.h
+++ b/libkvm/libkvm.h
@@ -509,6 +509,13 @@ int kvm_get_lapic(kvm_context_t kvm, int vcpu, struct
kvm_lapic_state *s);
*/
int kvm_set_lapic(kvm_context_t kvm, int vcpu, struct kvm_lapic_state *s);
+/*!
+ * \brief Return the vm_fd field from kvm_context
+ *
+ * \param kvm Pointer to the current kvm_context
+ */
+int kvm_get_vm_fd(kvm_context_t kvm);
+
#endif
#endif
--
1.4.4.2
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] Add accessor for kvm->vm_fd
[not found] ` <200711080029.05386.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
@ 2007-11-08 6:26 ` Avi Kivity
[not found] ` <4732AC10.2030804-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Avi Kivity @ 2007-11-08 6:26 UTC (permalink / raw)
To: Amit Shah; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
Amit Shah wrote:
> With the declaration in libkvm.h this time:
>
> >From 8313b87bcab415746e6eed86ac3f5b6c562b9764 Mon Sep 17 00:00:00 2001
> From: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
> Date: Thu, 8 Nov 2007 00:13:07 +0530
> Subject: [PATCH] Add accessor for kvm->vm_fd
>
> Introduce kvm_get_vm_fd to get the VM FD
>
>
What, so you can issue ioctls like there's no tomorrow? Add function
wrappers for your ioctls instead.
--
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] Add accessor for kvm->vm_fd
[not found] ` <4732AC10.2030804-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
@ 2007-11-08 6:41 ` Amit Shah
[not found] ` <200711081211.09455.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Amit Shah @ 2007-11-08 6:41 UTC (permalink / raw)
To: Avi Kivity; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
On Thursday 08 November 2007 11:56:24 Avi Kivity wrote:
> Amit Shah wrote:
> > With the declaration in libkvm.h this time:
> > >From 8313b87bcab415746e6eed86ac3f5b6c562b9764 Mon Sep 17 00:00:00 2001
> >
> > From: Amit Shah <amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
> > Date: Thu, 8 Nov 2007 00:13:07 +0530
> > Subject: [PATCH] Add accessor for kvm->vm_fd
> >
> > Introduce kvm_get_vm_fd to get the VM FD
>
> What, so you can issue ioctls like there's no tomorrow? Add function
> wrappers for your ioctls instead.
Hmm. this might not be needed now since the kvm_context moved to a .h file. It
was a static in a .c earlier.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] Add accessor for kvm->vm_fd
[not found] ` <200711081211.09455.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
@ 2007-11-08 6:43 ` Avi Kivity
0 siblings, 0 replies; 5+ messages in thread
From: Avi Kivity @ 2007-11-08 6:43 UTC (permalink / raw)
To: Amit Shah; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
Amit Shah wrote:
>>> Introduce kvm_get_vm_fd to get the VM FD
>>>
>> What, so you can issue ioctls like there's no tomorrow? Add function
>> wrappers for your ioctls instead.
>>
>
> Hmm. this might not be needed now since the kvm_context moved to a .h file. It
> was a static in a .c earlier.
>
That .h is not meant to be included by libkvm users.
--
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-11-08 6:43 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-07 18:45 [PATCH] Add accessor for kvm->vm_fd Amit Shah
[not found] ` <200711080015.13694.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-07 18:59 ` Amit Shah
[not found] ` <200711080029.05386.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-08 6:26 ` Avi Kivity
[not found] ` <4732AC10.2030804-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-08 6:41 ` Amit Shah
[not found] ` <200711081211.09455.amit.shah-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-11-08 6:43 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox