search for: grant_entry_t

Displaying 4 results from an estimated 4 matches for "grant_entry_t".

Did you mean: grant_entry
2008 Jul 11
1
Question about Using Grant Table
Hi: There is a code sample in <The Definite Guide to the Xen Hypervisor>, chapter 4, "Using Grant Tables". The code sample is as following: #include <public/xen.h> extern void * shared_page; extern grant_entry_t * grant_table; void offer_page() { uint16_t flags; /* create the grant table*/ gnttab_setup_table_t setup_op; setup_op.dom =DOMID_SELF; setup_op.nr_frames = 1; setup_op.frame_list = grant_table; HYPERVISOR_grant_table_op(GNTTABOP_setup_ta...
2007 Nov 26
0
[PATCH] [Mini-OS] Make gnttab allocation/free safe
...tras/mini-os/gnttab.c Sun Nov 25 21:24:48 2007 +0000 +++ b/extras/mini-os/gnttab.c Mon Nov 26 11:50:31 2007 +0000 @@ -18,6 +18,7 @@ #include <os.h> #include <mm.h> #include <gnttab.h> +#include <semaphore.h> #define NR_RESERVED_ENTRIES 8 @@ -31,20 +32,29 @@ static grant_entry_t *gnttab_table; static grant_ref_t gnttab_list[NR_GRANT_ENTRIES]; +static __DECLARE_SEMAPHORE_GENERIC(gnttab_sem, NR_GRANT_ENTRIES); static void put_free_entry(grant_ref_t ref) { + unsigned long flags; + local_irq_save(flags); gnttab_list[ref] = gnttab_list[0]; gnttab_list[0]...
2007 Oct 03
0
[PATCH 3/3] TLB flushing and IO memory mapping
.../common/grant_table.c Mon Jul 30 10:28:27 2007 +0100 @@ -199,6 +199,7 @@ __gnttab_map_grant_ref( int handle; unsigned long frame = 0; int rc = GNTST_okay; + int is_iomem = 0; struct active_grant_entry *act; struct grant_mapping *mt; grant_entry_t *sha; @@ -327,34 +328,52 @@ __gnttab_map_grant_ref( spin_unlock(&rd->grant_table->lock); - if ( unlikely(!mfn_valid(frame)) || - unlikely(!((op->flags & GNTMAP_readonly) ? - get_page(mfn_to_page(frame), rd) : - get_page_and_...
2007 Mar 20
62
RFC: [0/2] Remove netloop by lazy copying in netback
Hi Keir: These two patches remove the need for netloop by performing the copying in netback and only if it is necessary. The rationale is that most packets will be processed without delay allowing them to be freed without copying at all. So instead of copying every packet destined to dom0 we''ll only copy those that linger longer than a specified amount of time (currently 0.5s). As it