From: kaf24@firebug.cl.cam.ac.uk Date: Thu, 25 May 2006 14:55:07 +0000 (+0100) Subject: Remove redundant test in grant-table interface code. X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~16025^2~13 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=58407ab2868d3a88d1bad1253f9428a9eb33278d;p=xen.git Remove redundant test in grant-table interface code. Signed-off-by: Jimi Xenidis --- diff --git a/xen/common/grant_table.c b/xen/common/grant_table.c index 3700f78e00..ebd5caa35d 100644 --- a/xen/common/grant_table.c +++ b/xen/common/grant_table.c @@ -505,15 +505,12 @@ gnttab_setup_table( goto out; } - if ( op.nr_frames <= NR_GRANT_FRAMES ) + ASSERT(d->grant_table != NULL); + op.status = GNTST_okay; + for ( i = 0; i < op.nr_frames; i++ ) { - ASSERT(d->grant_table != NULL); - op.status = GNTST_okay; - for ( i = 0; i < op.nr_frames; i++ ) - { - gmfn = gnttab_shared_gmfn(d, d->grant_table, i); - (void)copy_to_guest_offset(op.frame_list, i, &gmfn, 1); - } + gmfn = gnttab_shared_gmfn(d, d->grant_table, i); + (void)copy_to_guest_offset(op.frame_list, i, &gmfn, 1); } put_domain(d);