[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] gnttab: drop useless locking
commit 25726f4269c742fd41ee0df733bbe7a3a05339ac Author: Jan Beulich <jbeulich@xxxxxxxx> AuthorDate: Wed Aug 16 10:56:23 2017 +0200 Commit: Jan Beulich <jbeulich@xxxxxxxx> CommitDate: Wed Aug 16 10:56:23 2017 +0200 gnttab: drop useless locking Holding any lock while accessing the maptrack entry fields is pointless, as these entries are protected by their associated active entry lock (which is being acquired later, before re-validating the fields read without holding the lock). Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> --- xen/common/grant_table.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/xen/common/grant_table.c b/xen/common/grant_table.c index 56082d8..5e578c6 100644 --- a/xen/common/grant_table.c +++ b/xen/common/grant_table.c @@ -1143,19 +1143,14 @@ __gnttab_unmap_common( smp_rmb(); map = &maptrack_entry(lgt, op->handle); - grant_read_lock(lgt); - if ( unlikely(!read_atomic(&map->flags)) ) { - grant_read_unlock(lgt); gdprintk(XENLOG_INFO, "Zero flags for handle %#x\n", op->handle); op->status = GNTST_bad_handle; return; } dom = map->domid; - grant_read_unlock(lgt); - if ( unlikely((rd = rcu_lock_domain_by_id(dom)) == NULL) ) { /* This can happen when a grant is implicitly unmapped. */ -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |