1 /* Test case contributed by Ingo Rohloff <rohloff@in.tum.de>.
2 Code distilled from Linux kernel. */
4 /* Compile this program with a gcc-2.95.2 using
5 "gcc -O2" and run it. The result will be that
6 rx_ring[1].next == 0 (it should be == 14)
8 ep.skbuff[4] == 5 (it should be 0)
11 extern void abort(void);
20 struct epic_rx_desc *rx_ring;
21 unsigned int rx_skbuff[5];
24 static void epic_init_ring(struct epic_private *ep)
28 for (i = 0; i < 5; i++)
30 ep->rx_ring[i].next = 10 + (i+1)*2;
33 ep->rx_ring[i-1].next = 10;
36 static int check_rx_ring[5] = { 12,14,16,18,10 };
40 struct epic_private ep;
41 struct epic_rx_desc rx_ring[5];
55 if ( rx_ring[i].next != check_rx_ring[i] ) abort();
56 if ( ep.rx_skbuff[i] != 0 ) abort();