[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [win-pv-devel] [PATCH 2/3] Prevent Schedule from preparing every outstanding SRB
> -----Original Message----- > From: win-pv-devel <win-pv-devel-bounces@xxxxxxxxxxxxxxxxxxxx> On Behalf Of > Owen Smith > Sent: 03 September 2019 15:43 > To: win-pv-devel@xxxxxxxxxxxxxxxxxxxx > Cc: Owen Smith <owen.smith@xxxxxxxxxx> > Subject: [win-pv-devel] [PATCH 2/3] Prevent Schedule from preparing every > outstanding SRB > > Returning a fail code from BlkifRingPostRequests will make the > BlkifRingSchedule loop try a poll for responses, and exit the loop if > no space is made available on the ring. This prevents the loop from > proceeding to prepare the next queued SRB. > > Signed-off-by: Owen Smith <owen.smith@xxxxxxxxxx> > --- > src/xenvbd/ring.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/src/xenvbd/ring.c b/src/xenvbd/ring.c > index 74426f1..c8ad87d 100644 > --- a/src/xenvbd/ring.c > +++ b/src/xenvbd/ring.c > @@ -1132,12 +1132,11 @@ __BlkifRingPostRequests( > > InsertTailList(&BlkifRing->SubmittedList, ListEntry); > > + BlkifRing->Front.req_prod_pvt = req_prod; > if (RING_SLOTS_AVAILABLE(&BlkifRing->Front, req_prod, rsp_cons) <= 1) Why <= 1? > - break; > + goto fail1; > } > > - BlkifRing->Front.req_prod_pvt = req_prod; > - Also this could stay here if you simply drop out of the loop with a break... > return STATUS_SUCCESS; ...and this was something like: (enough ring slots available) ? STATUS_SUCCESS : STATUS_ALLOTTED_SPACE_EXCEEDED; > > fail1: ...and then I think you could get rid of this. Paul > -- > 2.16.2.windows.1 > > > _______________________________________________ > win-pv-devel mailing list > win-pv-devel@xxxxxxxxxxxxxxxxxxxx > https://lists.xenproject.org/mailman/listinfo/win-pv-devel _______________________________________________ win-pv-devel mailing list win-pv-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/win-pv-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |