xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] x86/HVM: drop hvm_emulate_one_no_write()
@ 2016-12-06 12:47 Jan Beulich
  2016-12-06 12:54 ` Paul Durrant
  2016-12-06 15:40 ` Andrew Cooper
  0 siblings, 2 replies; 3+ messages in thread
From: Jan Beulich @ 2016-12-06 12:47 UTC (permalink / raw)
  To: xen-devel; +Cc: Paul Durrant

[-- Attachment #1: Type: text/plain, Size: 1371 bytes --]

It was pointlessly non-static, and being static and a simple wrapper it
can as well be folded into its single caller.

Signed-off-by: Jan Beulich <jbeulich@suse.com>

--- a/xen/arch/x86/hvm/emulate.c
+++ b/xen/arch/x86/hvm/emulate.c
@@ -1775,12 +1775,6 @@ int hvm_emulate_one(
     return _hvm_emulate_one(hvmemul_ctxt, &hvm_emulate_ops);
 }
 
-int hvm_emulate_one_no_write(
-    struct hvm_emulate_ctxt *hvmemul_ctxt)
-{
-    return _hvm_emulate_one(hvmemul_ctxt, &hvm_emulate_ops_no_write);
-}
-
 int hvm_emulate_one_mmio(unsigned long mfn, unsigned long gla)
 {
     static const struct x86_emulate_ops hvm_intercept_ops_mmcfg = {
@@ -1840,7 +1834,7 @@ void hvm_emulate_one_vm_event(enum emul_
     switch ( kind )
     {
     case EMUL_KIND_NOWRITE:
-        rc = hvm_emulate_one_no_write(&ctx);
+        rc = _hvm_emulate_one(&ctx, &hvm_emulate_ops_no_write);
         break;
     case EMUL_KIND_SET_CONTEXT_INSN: {
         struct vcpu *curr = current;
--- a/xen/include/asm-x86/hvm/emulate.h
+++ b/xen/include/asm-x86/hvm/emulate.h
@@ -43,8 +43,6 @@ enum emul_kind {
 
 int hvm_emulate_one(
     struct hvm_emulate_ctxt *hvmemul_ctxt);
-int hvm_emulate_one_no_write(
-    struct hvm_emulate_ctxt *hvmemul_ctxt);
 void hvm_emulate_one_vm_event(enum emul_kind kind,
     unsigned int trapnr,
     unsigned int errcode);




[-- Attachment #2: x86-HVM-drop-emul1nowrite.patch --]
[-- Type: text/plain, Size: 1409 bytes --]

x86/HVM: drop hvm_emulate_one_no_write()

It was pointlessly non-static, and being static and a simple wrapper it
can as well be folded into its single caller.

Signed-off-by: Jan Beulich <jbeulich@suse.com>

--- a/xen/arch/x86/hvm/emulate.c
+++ b/xen/arch/x86/hvm/emulate.c
@@ -1775,12 +1775,6 @@ int hvm_emulate_one(
     return _hvm_emulate_one(hvmemul_ctxt, &hvm_emulate_ops);
 }
 
-int hvm_emulate_one_no_write(
-    struct hvm_emulate_ctxt *hvmemul_ctxt)
-{
-    return _hvm_emulate_one(hvmemul_ctxt, &hvm_emulate_ops_no_write);
-}
-
 int hvm_emulate_one_mmio(unsigned long mfn, unsigned long gla)
 {
     static const struct x86_emulate_ops hvm_intercept_ops_mmcfg = {
@@ -1840,7 +1834,7 @@ void hvm_emulate_one_vm_event(enum emul_
     switch ( kind )
     {
     case EMUL_KIND_NOWRITE:
-        rc = hvm_emulate_one_no_write(&ctx);
+        rc = _hvm_emulate_one(&ctx, &hvm_emulate_ops_no_write);
         break;
     case EMUL_KIND_SET_CONTEXT_INSN: {
         struct vcpu *curr = current;
--- a/xen/include/asm-x86/hvm/emulate.h
+++ b/xen/include/asm-x86/hvm/emulate.h
@@ -43,8 +43,6 @@ enum emul_kind {
 
 int hvm_emulate_one(
     struct hvm_emulate_ctxt *hvmemul_ctxt);
-int hvm_emulate_one_no_write(
-    struct hvm_emulate_ctxt *hvmemul_ctxt);
 void hvm_emulate_one_vm_event(enum emul_kind kind,
     unsigned int trapnr,
     unsigned int errcode);

[-- Attachment #3: Type: text/plain, Size: 127 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/HVM: drop hvm_emulate_one_no_write()
  2016-12-06 12:47 [PATCH] x86/HVM: drop hvm_emulate_one_no_write() Jan Beulich
@ 2016-12-06 12:54 ` Paul Durrant
  2016-12-06 15:40 ` Andrew Cooper
  1 sibling, 0 replies; 3+ messages in thread
From: Paul Durrant @ 2016-12-06 12:54 UTC (permalink / raw)
  To: Jan Beulich, xen-devel

> -----Original Message-----
> From: Jan Beulich [mailto:JBeulich@suse.com]
> Sent: 06 December 2016 12:47
> To: xen-devel <xen-devel@lists.xenproject.org>
> Cc: Paul Durrant <Paul.Durrant@citrix.com>
> Subject: [PATCH] x86/HVM: drop hvm_emulate_one_no_write()
> 
> It was pointlessly non-static, and being static and a simple wrapper it
> can as well be folded into its single caller.
> 
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Reviewed-by: Paul Durrant <paul.durrant@citrix.com>

> 
> --- a/xen/arch/x86/hvm/emulate.c
> +++ b/xen/arch/x86/hvm/emulate.c
> @@ -1775,12 +1775,6 @@ int hvm_emulate_one(
>      return _hvm_emulate_one(hvmemul_ctxt, &hvm_emulate_ops);
>  }
> 
> -int hvm_emulate_one_no_write(
> -    struct hvm_emulate_ctxt *hvmemul_ctxt)
> -{
> -    return _hvm_emulate_one(hvmemul_ctxt,
> &hvm_emulate_ops_no_write);
> -}
> -
>  int hvm_emulate_one_mmio(unsigned long mfn, unsigned long gla)
>  {
>      static const struct x86_emulate_ops hvm_intercept_ops_mmcfg = {
> @@ -1840,7 +1834,7 @@ void hvm_emulate_one_vm_event(enum emul_
>      switch ( kind )
>      {
>      case EMUL_KIND_NOWRITE:
> -        rc = hvm_emulate_one_no_write(&ctx);
> +        rc = _hvm_emulate_one(&ctx, &hvm_emulate_ops_no_write);
>          break;
>      case EMUL_KIND_SET_CONTEXT_INSN: {
>          struct vcpu *curr = current;
> --- a/xen/include/asm-x86/hvm/emulate.h
> +++ b/xen/include/asm-x86/hvm/emulate.h
> @@ -43,8 +43,6 @@ enum emul_kind {
> 
>  int hvm_emulate_one(
>      struct hvm_emulate_ctxt *hvmemul_ctxt);
> -int hvm_emulate_one_no_write(
> -    struct hvm_emulate_ctxt *hvmemul_ctxt);
>  void hvm_emulate_one_vm_event(enum emul_kind kind,
>      unsigned int trapnr,
>      unsigned int errcode);
> 
> 


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/HVM: drop hvm_emulate_one_no_write()
  2016-12-06 12:47 [PATCH] x86/HVM: drop hvm_emulate_one_no_write() Jan Beulich
  2016-12-06 12:54 ` Paul Durrant
@ 2016-12-06 15:40 ` Andrew Cooper
  1 sibling, 0 replies; 3+ messages in thread
From: Andrew Cooper @ 2016-12-06 15:40 UTC (permalink / raw)
  To: Jan Beulich, xen-devel; +Cc: Paul Durrant

On 06/12/16 12:47, Jan Beulich wrote:
> It was pointlessly non-static, and being static and a simple wrapper it
> can as well be folded into its single caller.
>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-12-06 15:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-12-06 12:47 [PATCH] x86/HVM: drop hvm_emulate_one_no_write() Jan Beulich
2016-12-06 12:54 ` Paul Durrant
2016-12-06 15:40 ` Andrew Cooper

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).