Am Wed, 25 Apr 2018 09:28:38 +0200
schrieb Juergen Gross <jgr...@suse.com>:

> Why? (u16)0 - (u16)65400 == 136

My helloworld.c shows that ushort gets promoted to uint, unless it is done like 
that:

-               if (queue->tx.sring->req_prod - queue->tx.req_cons >
-                   XEN_NETIF_TX_RING_SIZE) {
+               idx = queue->tx.sring->req_prod - queue->tx.req_cons; 
+               if ( idx > XEN_NETIF_TX_RING_SIZE) {

Olaf

Attachment: pgpAzwssvPxQm.pgp
Description: Digitale Signatur von OpenPGP

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to