The physical function defaults to operating in "PXE mode" after a power-on reset. In this mode, receive descriptors are fetched and written back as single descriptors. In normal (non-PXE mode) operation, receive descriptors are fetched and written back only as complete cachelines unless an interrupt is raised. There is no way to return to PXE mode from non-PXE mode, and there is no way for the virtual function driver to operate in PXE mode. Choose to operate in non-PXE mode. This requires us to trick the hardware into believing that it is raising an interrupt, so that it will not defer writing back receive descriptors until a complete cacheline (i.e. four packets) have been consumed. We do so by configuring the hardware to use MSI-X with a dummy target location in place of the usual APIC register. Signed-off-by: Michael Brown <mcb30@ipxe.org>tags/v1.20.1
|
|
||
116 |
|
116 |
|
117 |
|
117 |
|
118 |
|
118 |
|
|
119 |
|
|
|
120 |
|
|
|
121 |
|
|
|
122 |
|
|
|
123 |
|
|
|
124 |
|
|
|
125 |
|
|
|
126 |
|
|
|
127 |
|
|
|
128 |
|
|
|
129 |
|
|
|
130 |
|
|
|
131 |
|
|
|
132 |
|
|
|
133 |
|
|
|
134 |
|
|
|
135 |
|
|
|
136 |
|
|
|
137 |
|
|
|
138 |
|
|
|
139 |
|
|
|
140 |
|
|
|
141 |
|
|
|
142 |
|
|
|
143 |
|
|
|
144 |
|
|
|
145 |
|
|
|
146 |
|
|
|
147 |
|
|
|
148 |
|
|
|
149 |
|
|
|
150 |
|
|
|
151 |
|
|
|
152 |
|
|
|
153 |
|
|
|
154 |
|
|
|
155 |
|
|
|
156 |
|
|
|
157 |
|
|
|
158 |
|
|
|
159 |
|
|
|
160 |
|
|
|
161 |
|
|
|
162 |
|
|
|
163 |
|
|
|
164 |
|
|
|
165 |
|
|
|
166 |
|
|
|
167 |
|
|
|
168 |
|
|
119 |
|
169 |
|
120 |
|
170 |
|
121 |
|
171 |
|
|
|
||
480 |
|
530 |
|
481 |
|
531 |
|
482 |
|
532 |
|
|
533 |
|
|
|
534 |
|
|
|
535 |
|
|
|
536 |
|
|
|
537 |
|
|
|
538 |
|
|
|
539 |
|
|
|
540 |
|
|
|
541 |
|
|
|
542 |
|
|
|
543 |
|
|
|
544 |
|
|
|
545 |
|
|
|
546 |
|
|
|
547 |
|
|
|
548 |
|
|
|
549 |
|
|
|
550 |
|
|
|
551 |
|
|
|
552 |
|
|
|
553 |
|
|
|
554 |
|
|
|
555 |
|
|
|
556 |
|
|
|
557 |
|
|
|
558 |
|
|
|
559 |
|
|
|
560 |
|
|
|
561 |
|
|
|
562 |
|
|
|
563 |
|
|
|
564 |
|
|
|
565 |
|
|
483 |
|
566 |
|
484 |
|
567 |
|
485 |
|
568 |
|
|
|
||
1504 |
|
1587 |
|
1505 |
|
1588 |
|
1506 |
|
1589 |
|
1507 |
|
|
|
1508 |
|
|
|
1509 |
|
|
|
1510 |
|
|
|
1511 |
|
|
|
1512 |
|
|
|
1513 |
|
|
|
1514 |
|
1590 |
|
1515 |
|
1591 |
|
1516 |
|
1592 |
|
|
|
||
1522 |
|
1598 |
|
1523 |
|
1599 |
|
1524 |
|
1600 |
|
1525 |
|
|
|
1526 |
|
|
|
1527 |
|
|
|
1528 |
|
|
|
1529 |
|
|
|
1530 |
|
|
|
1531 |
|
|
|
1532 |
|
|
|
1533 |
|
|
|
1534 |
|
|
|
1535 |
|
1601 |
|
1536 |
|
|
|
1537 |
|
|
|
|
1602 |
|
|
|
1603 |
|
|
|
1604 |
|
|
|
1605 |
|
|
|
1606 |
|
|
|
1607 |
|
|
|
1608 |
|
|
|
1609 |
|
|
|
1610 |
|
|
|
1611 |
|
|
|
1612 |
|
|
|
1613 |
|
|
|
1614 |
|
|
|
1615 |
|
|
|
1616 |
|
|
|
1617 |
|
|
1538 |
|
1618 |
|
1539 |
|
1619 |
|
1540 |
|
1620 |
|
|
|
||
1543 |
|
1623 |
|
1544 |
|
1624 |
|
1545 |
|
1625 |
|
1546 |
|
|
|
1547 |
|
1626 |
|
1548 |
|
1627 |
|
1549 |
|
1628 |
|
|
|
||
1617 |
|
1696 |
|
1618 |
|
1697 |
|
1619 |
|
1698 |
|
|
1699 |
|
|
|
1700 |
|
|
|
1701 |
|
|
|
1702 |
|
|
1620 |
|
1703 |
|
1621 |
|
1704 |
|
1622 |
|
1705 |
|
1623 |
|
1706 |
|
|
1707 |
|
|
|
1708 |
|
|
|
1709 |
|
|
|
1710 |
|
|
1624 |
|
1711 |
|
1625 |
|
1712 |
|
1626 |
|
1713 |
|
|
|
||
1667 |
|
1754 |
|
1668 |
|
1755 |
|
1669 |
|
1756 |
|
|
1757 |
|
|
1670 |
|
1758 |
|
1671 |
|
1759 |
|
|
1760 |
|
|
|
1761 |
|
|
1672 |
|
1762 |
|
1673 |
|
1763 |
|
1674 |
|
1764 |
|
|
|
||
1695 |
|
1785 |
|
1696 |
|
1786 |
|
1697 |
|
1787 |
|
|
1788 |
|
|
|
1789 |
|
|
|
1790 |
|
|
1698 |
|
1791 |
|
1699 |
|
1792 |
|
1700 |
|
1793 |
|
|
|
||
11 |
|
11 |
|
12 |
|
12 |
|
13 |
|
13 |
|
|
14 |
|
|
14 |
|
15 |
|
15 |
|
16 |
|
16 |
|
17 |
|
|
|
||
143 |
|
144 |
|
144 |
|
145 |
|
145 |
|
146 |
|
|
147 |
|
|
|
148 |
|
|
|
149 |
|
|
|
150 |
|
|
|
151 |
|
|
|
152 |
|
|
|
153 |
|
|
|
154 |
|
|
|
155 |
|
|
|
156 |
|
|
|
157 |
|
|
|
158 |
|
|
|
159 |
|
|
|
160 |
|
|
146 |
|
161 |
|
147 |
|
162 |
|
148 |
|
163 |
|
|
|
||
305 |
|
320 |
|
306 |
|
321 |
|
307 |
|
322 |
|
|
323 |
|
|
|
324 |
|
|
308 |
|
325 |
|
309 |
|
326 |
|
310 |
|
327 |
|
|
|
||
563 |
|
580 |
|
564 |
|
581 |
|
565 |
|
582 |
|
|
583 |
|
|
|
584 |
|
|
|
585 |
|
|
|
586 |
|
|
566 |
|
587 |
|
567 |
|
588 |
|
568 |
|
589 |
|
|
|
||
709 |
|
730 |
|
710 |
|
731 |
|
711 |
|
732 |
|
712 |
|
|
|
713 |
|
|
|
|
733 |
|
|
|
734 |
|
|
|
735 |
|
|
|
736 |
|
|
|
737 |
|
|
|
738 |
|
|
714 |
|
739 |
|
715 |
|
740 |
|
716 |
|
741 |
|
717 |
|
742 |
|
718 |
|
743 |
|
719 |
|
744 |
|
720 |
|
|
|
721 |
|
|
|
722 |
|
|
|
|
745 |
|
|
723 |
|
746 |
|
724 |
|
|
|
|
747 |
|
|
725 |
|
748 |
|
726 |
|
|
|
727 |
|
|
|
|
749 |
|
|
|
750 |
|
|
|
751 |
|
|
|
752 |
|
|
|
753 |
|
|
728 |
|
754 |
|
729 |
|
755 |
|
730 |
|
756 |
|
|
|
||
837 |
|
863 |
|
838 |
|
864 |
|
839 |
|
865 |
|
|
866 |
|
|
|
867 |
|
|
|
868 |
|
|
|
869 |
|
|
840 |
|
870 |
|
841 |
|
871 |
|
842 |
|
872 |
|
|
|
||
851 |
|
881 |
|
852 |
|
882 |
|
853 |
|
883 |
|
|
884 |
|
|
|
885 |
|
|
|
886 |
|
|
|
887 |
|
|
854 |
|
888 |
|
855 |
|
889 |
|
856 |
|
890 |
|