Displaying 9 results from an estimated 9 matches for "condition_x".
Did you mean:
condition_y
2019 Apr 26
2
[PATCH net] vhost_net: fix possible infinite loop
...intr)))
> + continue;
> goto out;
> }
> busyloop_intr = false;
The patch misses several other continue that need cares and there's
another call of vhost_exceeds_weight() at the end of the loop.
So instead of duplicating check everywhere like:
for (;;) {
??? if (condition_x) {
??? ??? if (empty_ring())
??? ??? ??? continue;
??? ??? break;
??? }
??? if (condition_y) {
??? ??? if (empty_ring());
??? ??? ??? continue;
??? ??? break;
??? }
??? if (condition_z) {
??? ??? if (empty_ring())
??? ??? ??? continue;
??? ??? break;
??? }
}
What this patch did:
do...
2019 Apr 26
2
[PATCH net] vhost_net: fix possible infinite loop
...intr)))
> + continue;
> goto out;
> }
> busyloop_intr = false;
The patch misses several other continue that need cares and there's
another call of vhost_exceeds_weight() at the end of the loop.
So instead of duplicating check everywhere like:
for (;;) {
??? if (condition_x) {
??? ??? if (empty_ring())
??? ??? ??? continue;
??? ??? break;
??? }
??? if (condition_y) {
??? ??? if (empty_ring());
??? ??? ??? continue;
??? ??? break;
??? }
??? if (condition_z) {
??? ??? if (empty_ring())
??? ??? ??? continue;
??? ??? break;
??? }
}
What this patch did:
do...
2019 May 12
2
[PATCH net] vhost_net: fix possible infinite loop
...intr = false;
> >
> > The patch misses several other continue that need cares and there's
> > another call of vhost_exceeds_weight() at the end of the loop.
> >
> > So instead of duplicating check everywhere like:
> >
> > for (;;) {
> > ??? if (condition_x) {
> > ??? ??? if (empty_ring())
> > ??? ??? ??? continue;
> > ??? ??? break;
> > ??? }
> > ??? if (condition_y) {
> > ??? ??? if (empty_ring());
> > ??? ??? ??? continue;
> > ??? ??? break;
> > ??? }
> > ??? if (condition_z) {
> > ?...
2019 May 12
2
[PATCH net] vhost_net: fix possible infinite loop
...intr = false;
> >
> > The patch misses several other continue that need cares and there's
> > another call of vhost_exceeds_weight() at the end of the loop.
> >
> > So instead of duplicating check everywhere like:
> >
> > for (;;) {
> > ??? if (condition_x) {
> > ??? ??? if (empty_ring())
> > ??? ??? ??? continue;
> > ??? ??? break;
> > ??? }
> > ??? if (condition_y) {
> > ??? ??? if (empty_ring());
> > ??? ??? ??? continue;
> > ??? ??? break;
> > ??? }
> > ??? if (condition_z) {
> > ?...
2019 May 05
0
[PATCH net] vhost_net: fix possible infinite loop
...; ????????? }
>> ????????? busyloop_intr = false;
>
> The patch misses several other continue that need cares and there's
> another call of vhost_exceeds_weight() at the end of the loop.
>
> So instead of duplicating check everywhere like:
>
> for (;;) {
> ??? if (condition_x) {
> ??? ??? if (empty_ring())
> ??? ??? ??? continue;
> ??? ??? break;
> ??? }
> ??? if (condition_y) {
> ??? ??? if (empty_ring());
> ??? ??? ??? continue;
> ??? ??? break;
> ??? }
> ??? if (condition_z) {
> ??? ??? if (empty_ring())
> ??? ??? ??? continue;
>...
2019 May 13
0
[PATCH net] vhost_net: fix possible infinite loop
...lse;
>>> The patch misses several other continue that need cares and there's
>>> another call of vhost_exceeds_weight() at the end of the loop.
>>>
>>> So instead of duplicating check everywhere like:
>>>
>>> for (;;) {
>>> ??? if (condition_x) {
>>> ??? ??? if (empty_ring())
>>> ??? ??? ??? continue;
>>> ??? ??? break;
>>> ??? }
>>> ??? if (condition_y) {
>>> ??? ??? if (empty_ring());
>>> ??? ??? ??? continue;
>>> ??? ??? break;
>>> ??? }
>>...
2019 May 14
1
[PATCH net] vhost_net: fix possible infinite loop
...ther continue that need cares and there's
> > > > another call of vhost_exceeds_weight() at the end of the loop.
> > > >
> > > > So instead of duplicating check everywhere like:
> > > >
> > > > for (;;) {
> > > > ??? if (condition_x) {
> > > > ??? ??? if (empty_ring())
> > > > ??? ??? ??? continue;
> > > > ??? ??? break;
> > > > ??? }
> > > > ??? if (condition_y) {
> > > > ??? ??? if (empty_ring());
> > > > ??? ??? ??? continue;
> >...
2019 Apr 25
2
[PATCH net] vhost_net: fix possible infinite loop
When the rx buffer is too small for a packet, we will discard the vq
descriptor and retry it for the next packet:
while ((sock_len = vhost_net_rx_peek_head_len(net, sock->sk,
&busyloop_intr))) {
...
/* On overrun, truncate and discard */
if (unlikely(headcount > UIO_MAXIOV)) {
iov_iter_init(&msg.msg_iter, READ, vq->iov, 1, 1);
err = sock->ops->recvmsg(sock,
2019 Apr 25
2
[PATCH net] vhost_net: fix possible infinite loop
When the rx buffer is too small for a packet, we will discard the vq
descriptor and retry it for the next packet:
while ((sock_len = vhost_net_rx_peek_head_len(net, sock->sk,
&busyloop_intr))) {
...
/* On overrun, truncate and discard */
if (unlikely(headcount > UIO_MAXIOV)) {
iov_iter_init(&msg.msg_iter, READ, vq->iov, 1, 1);
err = sock->ops->recvmsg(sock,