From: Petre Pircalabu <ppircalabu@bitdefender.com> To: xen-devel@lists.xenproject.org Cc: Petre Pircalabu <ppircalabu@bitdefender.com>, Tamas K Lengyel <tamas@tklengyel.com>, Wei Liu <wl@xen.org>, Razvan Cojocaru <rcojocaru@bitdefender.com>, Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>, George Dunlap <George.Dunlap@eu.citrix.com>, Andrew Cooper <andrew.cooper3@citrix.com>, Ian Jackson <ian.jackson@eu.citrix.com>, Tim Deegan <tim@xen.org>, Julien Grall <julien.grall@arm.com>, Stefano Stabellini <sstabellini@kernel.org>, Jan Beulich <jbeulich@suse.com> Subject: [PATCH 6/9] vm_event: Move struct vm_event_domain to vm_event.c Date: Thu, 30 May 2019 17:18:20 +0300 [thread overview] Message-ID: <d50c5737dcff7f3225fe507322bb10d104a6e6b4.1559224640.git.ppircalabu@bitdefender.com> (raw) In-Reply-To: <cover.1559224640.git.ppircalabu@bitdefender.com> In-Reply-To: <cover.1559224640.git.ppircalabu@bitdefender.com> The vm_event_domain members are not accessed outside vm_event.c so it's better to hide de implementation details. Signed-off-by: Petre Pircalabu <ppircalabu@bitdefender.com> --- xen/common/vm_event.c | 27 +++++++++++++++++++++++++++ xen/include/xen/sched.h | 27 +-------------------------- 2 files changed, 28 insertions(+), 26 deletions(-) diff --git a/xen/common/vm_event.c b/xen/common/vm_event.c index 3e87bbc..02c5853 100644 --- a/xen/common/vm_event.c +++ b/xen/common/vm_event.c @@ -39,6 +39,33 @@ #define vm_event_ring_lock(_ved) spin_lock(&(_ved)->ring_lock) #define vm_event_ring_unlock(_ved) spin_unlock(&(_ved)->ring_lock) +/* VM event */ +struct vm_event_domain +{ + /* Domain reference */ + struct domain *d; + /* ring lock */ + spinlock_t ring_lock; + /* The ring has 64 entries */ + unsigned char foreign_producers; + unsigned char target_producers; + /* shared ring page */ + void *ring_page; + struct page_info *ring_pg_struct; + /* front-end ring */ + vm_event_front_ring_t front_ring; + /* event channel port (vcpu0 only) */ + int xen_port; + /* vm_event bit for vcpu->pause_flags */ + int pause_flag; + /* list of vcpus waiting for room in the ring */ + struct waitqueue_head wq; + /* the number of vCPUs blocked */ + unsigned int blocked; + /* The last vcpu woken up */ + unsigned int last_vcpu_wake_up; +}; + static int vm_event_enable( struct domain *d, struct xen_domctl_vm_event_op *vec, diff --git a/xen/include/xen/sched.h b/xen/include/xen/sched.h index 7dee022..207fbc4 100644 --- a/xen/include/xen/sched.h +++ b/xen/include/xen/sched.h @@ -279,32 +279,7 @@ struct vcpu #define domain_lock(d) spin_lock_recursive(&(d)->domain_lock) #define domain_unlock(d) spin_unlock_recursive(&(d)->domain_lock) -/* VM event */ -struct vm_event_domain -{ - /* Domain reference */ - struct domain *d; - /* ring lock */ - spinlock_t ring_lock; - /* The ring has 64 entries */ - unsigned char foreign_producers; - unsigned char target_producers; - /* shared ring page */ - void *ring_page; - struct page_info *ring_pg_struct; - /* front-end ring */ - vm_event_front_ring_t front_ring; - /* event channel port (vcpu0 only) */ - int xen_port; - /* vm_event bit for vcpu->pause_flags */ - int pause_flag; - /* list of vcpus waiting for room in the ring */ - struct waitqueue_head wq; - /* the number of vCPUs blocked */ - unsigned int blocked; - /* The last vcpu woken up */ - unsigned int last_vcpu_wake_up; -}; +struct vm_event_domain; struct evtchn_port_ops; -- 2.7.4 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel
WARNING: multiple messages have this Message-ID (diff)
From: Petre Pircalabu <ppircalabu@bitdefender.com> To: xen-devel@lists.xenproject.org Cc: Petre Pircalabu <ppircalabu@bitdefender.com>, Tamas K Lengyel <tamas@tklengyel.com>, Wei Liu <wl@xen.org>, Razvan Cojocaru <rcojocaru@bitdefender.com>, Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>, George Dunlap <George.Dunlap@eu.citrix.com>, Andrew Cooper <andrew.cooper3@citrix.com>, Ian Jackson <ian.jackson@eu.citrix.com>, Tim Deegan <tim@xen.org>, Julien Grall <julien.grall@arm.com>, Stefano Stabellini <sstabellini@kernel.org>, Jan Beulich <jbeulich@suse.com> Subject: [Xen-devel] [PATCH 6/9] vm_event: Move struct vm_event_domain to vm_event.c Date: Thu, 30 May 2019 17:18:20 +0300 [thread overview] Message-ID: <d50c5737dcff7f3225fe507322bb10d104a6e6b4.1559224640.git.ppircalabu@bitdefender.com> (raw) Message-ID: <20190530141820.valO--mWnh2gs-ijOqs5mHbMsmHmG15QbfRZjKYF-6Y@z> (raw) In-Reply-To: <cover.1559224640.git.ppircalabu@bitdefender.com> In-Reply-To: <cover.1559224640.git.ppircalabu@bitdefender.com> The vm_event_domain members are not accessed outside vm_event.c so it's better to hide de implementation details. Signed-off-by: Petre Pircalabu <ppircalabu@bitdefender.com> --- xen/common/vm_event.c | 27 +++++++++++++++++++++++++++ xen/include/xen/sched.h | 27 +-------------------------- 2 files changed, 28 insertions(+), 26 deletions(-) diff --git a/xen/common/vm_event.c b/xen/common/vm_event.c index 3e87bbc..02c5853 100644 --- a/xen/common/vm_event.c +++ b/xen/common/vm_event.c @@ -39,6 +39,33 @@ #define vm_event_ring_lock(_ved) spin_lock(&(_ved)->ring_lock) #define vm_event_ring_unlock(_ved) spin_unlock(&(_ved)->ring_lock) +/* VM event */ +struct vm_event_domain +{ + /* Domain reference */ + struct domain *d; + /* ring lock */ + spinlock_t ring_lock; + /* The ring has 64 entries */ + unsigned char foreign_producers; + unsigned char target_producers; + /* shared ring page */ + void *ring_page; + struct page_info *ring_pg_struct; + /* front-end ring */ + vm_event_front_ring_t front_ring; + /* event channel port (vcpu0 only) */ + int xen_port; + /* vm_event bit for vcpu->pause_flags */ + int pause_flag; + /* list of vcpus waiting for room in the ring */ + struct waitqueue_head wq; + /* the number of vCPUs blocked */ + unsigned int blocked; + /* The last vcpu woken up */ + unsigned int last_vcpu_wake_up; +}; + static int vm_event_enable( struct domain *d, struct xen_domctl_vm_event_op *vec, diff --git a/xen/include/xen/sched.h b/xen/include/xen/sched.h index 7dee022..207fbc4 100644 --- a/xen/include/xen/sched.h +++ b/xen/include/xen/sched.h @@ -279,32 +279,7 @@ struct vcpu #define domain_lock(d) spin_lock_recursive(&(d)->domain_lock) #define domain_unlock(d) spin_unlock_recursive(&(d)->domain_lock) -/* VM event */ -struct vm_event_domain -{ - /* Domain reference */ - struct domain *d; - /* ring lock */ - spinlock_t ring_lock; - /* The ring has 64 entries */ - unsigned char foreign_producers; - unsigned char target_producers; - /* shared ring page */ - void *ring_page; - struct page_info *ring_pg_struct; - /* front-end ring */ - vm_event_front_ring_t front_ring; - /* event channel port (vcpu0 only) */ - int xen_port; - /* vm_event bit for vcpu->pause_flags */ - int pause_flag; - /* list of vcpus waiting for room in the ring */ - struct waitqueue_head wq; - /* the number of vCPUs blocked */ - unsigned int blocked; - /* The last vcpu woken up */ - unsigned int last_vcpu_wake_up; -}; +struct vm_event_domain; struct evtchn_port_ops; -- 2.7.4 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel
next prev parent reply other threads:[~2019-05-30 14:18 UTC|newest] Thread overview: 67+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-05-30 14:18 [PATCH 0/9] Per vcpu vm_event channels Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-30 14:18 ` [PATCH 1/9] tools/libxc: Consistent usage of xc_vm_event_* interface Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-31 23:01 ` Andrew Cooper 2019-05-31 23:01 ` [Xen-devel] " Andrew Cooper 2019-06-04 14:23 ` Petre Ovidiu PIRCALABU 2019-06-04 16:07 ` Andrew Cooper 2019-05-30 14:18 ` [PATCH 2/9] vm_event: Define VM_EVENT type Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-31 23:26 ` Andrew Cooper 2019-05-31 23:26 ` [Xen-devel] " Andrew Cooper 2019-06-03 22:22 ` Tamas K Lengyel 2019-06-03 22:22 ` [Xen-devel] " Tamas K Lengyel 2019-06-03 22:26 ` Tamas K Lengyel 2019-06-03 22:26 ` [Xen-devel] " Tamas K Lengyel 2019-06-04 16:09 ` Andrew Cooper 2019-06-04 10:12 ` Petre Ovidiu PIRCALABU 2019-06-04 10:12 ` [Xen-devel] " Petre Ovidiu PIRCALABU 2019-06-03 15:51 ` Jan Beulich 2019-06-03 15:51 ` [Xen-devel] " Jan Beulich 2019-05-30 14:18 ` [PATCH 3/9] vm_event: Make ‘local’ functions ‘static’ Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-31 23:28 ` Andrew Cooper 2019-05-31 23:28 ` [Xen-devel] " Andrew Cooper 2019-06-02 0:36 ` Tamas K Lengyel 2019-06-02 0:36 ` [Xen-devel] " Tamas K Lengyel 2019-05-30 14:18 ` [PATCH 4/9] vm_event: Remove "ring" suffix from vm_event_check_ring Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-31 23:32 ` Andrew Cooper 2019-05-31 23:32 ` [Xen-devel] " Andrew Cooper 2019-06-05 15:52 ` Tamas K Lengyel 2019-05-30 14:18 ` [PATCH 5/9] vm_event: Simplify vm_event interface Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-31 23:43 ` Andrew Cooper 2019-05-31 23:43 ` [Xen-devel] " Andrew Cooper 2019-06-01 0:06 ` Andrew Cooper 2019-06-01 0:06 ` [Xen-devel] " Andrew Cooper 2019-06-03 15:33 ` Petre Ovidiu PIRCALABU 2019-06-03 15:33 ` [Xen-devel] " Petre Ovidiu PIRCALABU 2019-05-30 14:18 ` Petre Pircalabu [this message] 2019-05-30 14:18 ` [Xen-devel] [PATCH 6/9] vm_event: Move struct vm_event_domain to vm_event.c Petre Pircalabu 2019-05-31 23:44 ` Andrew Cooper 2019-05-31 23:44 ` [Xen-devel] " Andrew Cooper 2019-06-03 11:28 ` Petre Ovidiu PIRCALABU 2019-06-03 11:28 ` [Xen-devel] " Petre Ovidiu PIRCALABU 2019-06-05 15:53 ` Tamas K Lengyel 2019-05-30 14:18 ` [PATCH 7/9] vm_event: Decouple implementation details from interface Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-05-30 14:18 ` [PATCH 8/9] vm_event: Add vm_event_ng interface Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-06-04 14:43 ` Andrew Cooper 2019-06-05 17:01 ` Petre Ovidiu PIRCALABU 2019-06-06 8:37 ` Jan Beulich 2019-06-06 13:48 ` Petre Ovidiu PIRCALABU 2019-06-06 14:16 ` Jan Beulich 2019-05-30 14:18 ` [PATCH 9/9] xen-access: Add support for " Petre Pircalabu 2019-05-30 14:18 ` [Xen-devel] " Petre Pircalabu 2019-06-04 16:04 ` Andrew Cooper 2019-05-30 15:27 ` [PATCH 0/9] Per vcpu vm_event channels Tamas K Lengyel 2019-05-30 15:27 ` [Xen-devel] " Tamas K Lengyel 2019-05-31 7:07 ` Petre Ovidiu PIRCALABU 2019-05-31 7:07 ` [Xen-devel] " Petre Ovidiu PIRCALABU 2019-06-01 0:25 ` Andrew Cooper 2019-06-01 0:25 ` [Xen-devel] " Andrew Cooper 2019-06-03 14:04 ` Petre Ovidiu PIRCALABU 2019-06-03 14:04 ` [Xen-devel] " Petre Ovidiu PIRCALABU
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=d50c5737dcff7f3225fe507322bb10d104a6e6b4.1559224640.git.ppircalabu@bitdefender.com \ --to=ppircalabu@bitdefender.com \ --cc=George.Dunlap@eu.citrix.com \ --cc=andrew.cooper3@citrix.com \ --cc=ian.jackson@eu.citrix.com \ --cc=jbeulich@suse.com \ --cc=julien.grall@arm.com \ --cc=konrad.wilk@oracle.com \ --cc=rcojocaru@bitdefender.com \ --cc=sstabellini@kernel.org \ --cc=tamas@tklengyel.com \ --cc=tim@xen.org \ --cc=wl@xen.org \ --cc=xen-devel@lists.xenproject.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: linkBe 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.