On 05/12/2019 15:47, Andrew Cooper wrote: >> --- a/xen/common/grant_table.c >> +++ b/xen/common/grant_table.c >> @@ -1394,7 +1401,7 @@ unmap_common( >> >> op->mfn = act->mfn; >> >> - if ( op->dev_bus_addr && >> + if ( op->dev_bus_addr && (flags & GNTMAP_device_map) && > Drop the first clause entirely? act->mfn will never be 0 so can subsume > the check with one fewer branch.
Never mind. I've just remembered why 0 is special, and the check needs to stay. ~Andrew _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel