The standard option ROM format provides a header indicating the size of the entire ROM, which the BIOS will reserve space for, load, and call as necessary. However, this space is strictly limited to 128k for all ROMs. gPXE ameliorates this somewhat by reserving space for itself in high memory and relocating the majority of its code there, but on systems prior to PCI3 enough space must still be present to load the ROM in the first place. Even on PCI3 systems, the BIOS often limits the size of ROM it will load to a bit over 64kB. These space problems can be solved by providing an artificially small size in the ROM header: just enough to let the prefix code (at the beginning of the ROM image) be loaded by the BIOS. To the BIOS, the gPXE ROM will appear to be only a few kilobytes; it can then load the rest of itself by accessing the ROM directly using the PCI interface reserved for that task. There are a few problems with this approach. First, gPXE needs to find an unmapped region in memory to map the ROM so it can read from it; this is done using the crude but effective approach of scanning high memory (over 0xF0000000) for a sufficiently large region of all-ones (0xFF) reads. (In x86 architecture, all-ones is returned for accesses to memory regions that no mapped device can satisfy.) This is not provably valid in all situations, but has worked well in practice. More importantly, this type of ROM access can only work if the PCI ROM BAR exists at all. NICs on physical add-in PCI cards generally must have the BAR in order for the BIOS to be able to load their ROM, but ISA cards and LAN-on-Motherboard cards will both fail to load gPXE using this scheme. Due to these uncertainties, it is recommended that .xrom only be used when a regular .rom image is infeasible due to crowded option ROM space. However, when it works it could allow loading gPXE images as large as a flash chip one could find - 128kB or even higher. Signed-off-by: Marty Connor <mdc@etherboot.org>tags/v1.0.0-rc1
|
|
||
831 |
|
831 |
|
832 |
|
832 |
|
833 |
|
833 |
|
|
834 |
|
|
|
835 |
|
|
834 |
|
836 |
|
835 |
|
837 |
|
836 |
|
838 |
|
|
|
||
12 |
|
12 |
|
13 |
|
13 |
|
14 |
|
14 |
|
|
15 |
|
|
15 |
|
16 |
|
16 |
|
17 |
|
17 |
|
18 |
|
|
|
||
32 |
|
33 |
|
33 |
|
34 |
|
34 |
|
35 |
|
|
36 |
|
|
35 |
|
37 |
|
36 |
|
38 |
|
37 |
|
39 |
|
|
|
||
25 |
|
25 |
|
26 |
|
26 |
|
27 |
|
27 |
|
|
28 |
|
|
|
29 |
|
|
|
30 |
|
|
|
31 |
|
|
|
32 |
|
|
|
33 |
|
|
|
34 |
|
|
|
35 |
|
|
|
36 |
|
|
|
37 |
|
|
|
38 |
|
|
|
39 |
|
|
|
40 |
|
|
28 |
|
41 |
|
29 |
|
42 |
|
30 |
|
43 |
|
|
|
||
33 |
|
46 |
|
34 |
|
47 |
|
35 |
|
48 |
|
36 |
|
|
|
|
49 |
|
|
37 |
|
50 |
|
38 |
|
51 |
|
39 |
|
|
|
|
52 |
|
|
|
53 |
|
|
|
54 |
|
|
40 |
|
55 |
|
41 |
|
56 |
|
42 |
|
57 |
|
|
|
||
44 |
|
59 |
|
45 |
|
60 |
|
46 |
|
61 |
|
47 |
|
|
|
|
62 |
|
|
48 |
|
63 |
|
|
64 |
|
|
49 |
|
65 |
|
50 |
|
66 |
|
51 |
|
67 |
|
52 |
|
68 |
|
|
69 |
|
|
|
70 |
|
|
|
71 |
|
|
|
72 |
|
|
|
73 |
|
|
53 |
|
74 |
|
54 |
|
75 |
|
55 |
|
76 |
|
|
|
||
61 |
|
82 |
|
62 |
|
83 |
|
63 |
|
84 |
|
64 |
|
|
|
|
85 |
|
|
65 |
|
86 |
|
66 |
|
87 |
|
67 |
|
88 |
|
68 |
|
89 |
|
69 |
|
|
|
|
90 |
|
|
70 |
|
91 |
|
71 |
|
92 |
|
72 |
|
93 |
|
73 |
|
94 |
|
74 |
|
|
|
|
95 |
|
|
|
96 |
|
|
75 |
|
97 |
|
76 |
|
98 |
|
77 |
|
99 |
|
|
|
||
82 |
|
104 |
|
83 |
|
105 |
|
84 |
|
106 |
|
|
107 |
|
|
85 |
|
108 |
|
86 |
|
109 |
|
87 |
|
110 |
|
|
|
||
175 |
|
198 |
|
176 |
|
199 |
|
177 |
|
200 |
|
|
201 |
|
|
|
202 |
|
|
|
203 |
|
|
|
204 |
|
|
|
205 |
|
|
178 |
|
206 |
|
179 |
|
207 |
|
180 |
|
208 |
|
|
|
||
199 |
|
227 |
|
200 |
|
228 |
|
201 |
|
229 |
|
|
230 |
|
|
|
231 |
|
|
|
232 |
|
|
202 |
|
233 |
|
203 |
|
234 |
|
204 |
|
235 |
|
|
|
||
310 |
|
341 |
|
311 |
|
342 |
|
312 |
|
343 |
|
313 |
|
|
|
|
344 |
|
|
314 |
|
345 |
|
315 |
|
346 |
|
316 |
|
347 |
|
|
|
||
364 |
|
395 |
|
365 |
|
396 |
|
366 |
|
397 |
|
367 |
|
|
|
|
398 |
|
|
368 |
|
399 |
|
369 |
|
400 |
|
370 |
|
401 |
|
|
|
||
379 |
|
410 |
|
380 |
|
411 |
|
381 |
|
412 |
|
|
413 |
|
|
|
414 |
|
|
|
415 |
|
|
|
416 |
|
|
382 |
|
417 |
|
|
418 |
|
|
|
419 |
|
|
|
420 |
|
|
|
421 |
|
|
|
422 |
|
|
|
423 |
|
|
|
424 |
|
|
|
425 |
|
|
|
426 |
|
|
|
427 |
|
|
|
428 |
|
|
|
429 |
|
|
383 |
|
430 |
|
|
431 |
|
|
|
432 |
|
|
|
433 |
|
|
|
434 |
|
|
384 |
|
435 |
|
385 |
|
436 |
|
386 |
|
437 |
|
|
|
||
425 |
|
476 |
|
426 |
|
477 |
|
427 |
|
478 |
|
428 |
|
|
|
|
479 |
|
|
429 |
|
480 |
|
430 |
|
481 |
|
431 |
|
482 |
|
432 |
|
483 |
|
433 |
|
484 |
|
434 |
|
485 |
|
435 |
|
|
|
|
486 |
|
|
436 |
|
487 |
|
437 |
|
488 |
|
438 |
|
489 |
|
|
|
||
479 |
|
530 |
|
480 |
|
531 |
|
481 |
|
532 |
|
|
533 |
|
|
|
534 |
|
|
|
535 |
|
|
|
536 |
|
|
|
537 |
|
|
482 |
|
538 |
|
483 |
|
539 |
|
484 |
|
540 |
|
|
|
||
504 |
|
560 |
|
505 |
|
561 |
|
506 |
|
562 |
|
|
563 |
|
|
507 |
|
564 |
|
508 |
|
565 |
|
509 |
|
566 |
|
510 |
|
567 |
|
511 |
|
568 |
|
512 |
|
569 |
|
|
570 |
|
|
|
571 |
|
|
|
572 |
|
|
|
573 |
|
|
|
574 |
|
|
|
575 |
|
|
|
576 |
|
|
|
577 |
|
|
|
578 |
|
|
|
579 |
|
|
|
580 |
|
|
|
581 |
|
|
|
582 |
|
|
|
583 |
|
|
|
584 |
|
|
|
585 |
|
|
|
586 |
|
|
|
587 |
|
|
|
588 |
|
|
513 |
|
589 |
|
514 |
|
590 |
|
515 |
|
591 |
|
|
|
||
528 |
|
604 |
|
529 |
|
605 |
|
530 |
|
606 |
|
|
607 |
|
|
|
608 |
|
|
|
609 |
|
|
|
610 |
|
|
|
611 |
|
|
|
612 |
|
|
|
613 |
|
|
|
614 |
|
|
|
615 |
|
|
|
616 |
|
|
|
617 |
|
|
|
618 |
|
|
|
619 |
|
|
|
620 |
|
|
|
621 |
|
|
|
622 |
|
|
|
623 |
|
|
|
624 |
|
|
|
625 |
|
|
|
626 |
|
|
|
627 |
|
|
|
628 |
|
|
|
629 |
|
|
|
630 |
|
|
|
631 |
|
|
|
632 |
|
|
|
633 |
|
|
|
634 |
|
|
|
635 |
|
|
|
636 |
|
|
|
637 |
|
|
|
638 |
|
|
|
639 |
|
|
|
640 |
|
|
|
641 |
|
|
|
642 |
|
|
|
643 |
|
|
|
644 |
|
|
|
645 |
|
|
|
646 |
|
|
|
647 |
|
|
|
648 |
|
|
|
649 |
|
|
|
650 |
|
|
|
651 |
|
|
|
652 |
|
|
|
653 |
|
|
|
654 |
|
|
|
655 |
|
|
|
656 |
|
|
|
657 |
|
|
|
658 |
|
|
|
659 |
|
|
|
660 |
|
|
|
661 |
|
|
|
662 |
|
|
|
663 |
|
|
|
664 |
|
|
|
665 |
|
|
|
666 |
|
|
|
667 |
|
|
|
668 |
|
|
|
669 |
|
|
|
670 |
|
|
|
671 |
|
|
|
672 |
|
|
|
673 |
|
|
|
674 |
|
|
|
675 |
|
|
|
676 |
|
|
|
677 |
|
|
|
678 |
|
|
|
679 |
|
|
|
680 |
|
|
|
681 |
|
|
|
682 |
|
|
|
683 |
|
|
|
684 |
|
|
|
685 |
|
|
|
686 |
|
|
|
687 |
|
|
|
688 |
|
|
|
689 |
|
|
|
690 |
|
|
|
691 |
|
|
|
692 |
|
|
|
693 |
|
|
|
694 |
|
|
|
695 |
|
|
|
696 |
|
|
|
697 |
|
|
|
698 |
|
|
|
699 |
|
|
|
700 |
|
|
|
701 |
|
|
|
702 |
|
|
|
703 |
|
|
|
704 |
|
|
|
705 |
|
|
|
706 |
|
|
|
707 |
|
|
|
708 |
|
|
|
709 |
|
|
|
710 |
|
|
|
711 |
|
|
|
712 |
|
|
|
713 |
|
|
|
714 |
|
|
|
715 |
|
|
|
716 |
|
|
|
717 |
|
|
|
718 |
|
|
|
719 |
|
|
|
720 |
|
|
|
721 |
|
|
|
722 |
|
|
|
723 |
|
|
|
724 |
|
|
|
725 |
|
|
|
726 |
|
|
|
727 |
|
|
|
728 |
|
|
|
729 |
|
|
|
730 |
|
|
|
731 |
|
|
|
732 |
|
|
|
733 |
|
|
|
734 |
|
|
|
735 |
|
|
|
736 |
|
|
|
737 |
|
|
|
738 |
|
|
|
739 |
|
|
|
740 |
|
|
|
741 |
|
|
|
742 |
|
|
|
743 |
|
|
|
744 |
|
|
|
745 |
|
|
|
746 |
|
|
|
747 |
|
|
|
748 |
|
|
|
749 |
|
|
|
750 |
|
|
|
751 |
|
|
|
752 |
|
|
|
753 |
|
|
|
754 |
|
|
|
755 |
|
|
|
756 |
|
|
|
757 |
|
|
|
758 |
|
|
|
759 |
|
|
|
760 |
|
|
|
761 |
|
|
|
762 |
|
|
|
763 |
|
|
|
764 |
|
|
|
765 |
|
|
|
766 |
|
|
|
767 |
|
|
|
768 |
|
|
|
769 |
|
|
|
770 |
|
|
|
771 |
|
|
|
772 |
|
|
|
773 |
|
|
|
774 |
|
|
|
775 |
|
|
|
776 |
|
|
|
777 |
|
|
|
778 |
|
|
|
779 |
|
|
|
780 |
|
|
|
781 |
|
|
|
782 |
|
|
|
783 |
|
|
|
784 |
|
|
|
785 |
|
|
|
786 |
|
|
|
787 |
|
|
|
788 |
|
|
|
789 |
|
|
|
790 |
|
|
|
791 |
|
|
|
792 |
|
|
|
793 |
|
|
|
794 |
|
|
|
795 |
|
|
|
796 |
|
|
|
797 |
|
|
|
798 |
|
|
|
799 |
|
|
|
800 |
|
|
|
801 |
|
|
|
802 |
|
|
|
803 |
|
|
|
804 |
|
|
|
805 |
|
|
|
806 |
|
|
|
807 |
|
|
|
808 |
|
|
|
809 |
|
|
|
810 |
|
|
|
811 |
|
|
|
812 |
|
|
|
813 |
|
|
|
814 |
|
|
|
815 |
|
|
|
816 |
|
|
|
817 |
|
|
|
818 |
|
|
|
819 |
|
|
|
820 |
|
|
|
821 |
|
|
|
822 |
|
|
|
823 |
|
|
|
824 |
|
|
|
825 |
|
|
|
826 |
|
|
|
827 |
|
|
|
828 |
|
|
|
829 |
|
|
|
830 |
|
|
|
831 |
|
|
|
832 |
|
|
|
833 |
|
|
|
834 |
|
|
|
835 |
|
|
|
836 |
|
|
|
837 |
|
|
|
838 |
|
|
|
839 |
|
|
|
840 |
|
|
|
841 |
|
|
|
842 |
|
|
|
843 |
|
|
|
844 |
|
|
|
845 |
|
|
|
846 |
|
|
|
847 |
|
|
|
848 |
|
|
|
849 |
|
|
|
850 |
|
|
|
851 |
|
|
|
852 |
|
|
|
853 |
|
|
|
854 |
|
|
|
855 |
|
|
|
856 |
|
|
|
857 |
|
|
|
858 |
|
|
|
859 |
|
|
|
860 |
|
|
|
861 |
|
|
|
862 |
|
|
|
863 |
|
|
|
864 |
|
|
|
865 |
|
|
|
866 |
|
|
|
867 |
|
|
|
868 |
|
|
|
869 |
|
|
|
870 |
|
|
|
871 |
|
|
|
872 |
|
|
|
873 |
|
|
|
874 |
|
|
|
875 |
|
|
|
876 |
|
|
|
877 |
|
|
|
878 |
|
|
|
879 |
|
|
|
880 |
|
|
|
881 |
|
|
|
882 |
|
|
|
883 |
|
|
|
884 |
|
|
|
885 |
|
|
|
886 |
|
|
|
887 |
|
|
|
888 |
|
|
|
889 |
|
|
531 |
|
890 |
|
532 |
|
891 |
|
533 |
|
892 |
|
|
|
||
588 |
|
947 |
|
589 |
|
948 |
|
590 |
|
949 |
|
|
950 |
|
|
|
951 |
|
|
|
952 |
|
|
|
953 |
|
|
|
954 |
|
|
|
955 |
|
|
|
956 |
|
|
|
957 |
|
|
591 |
|
958 |
|
592 |
|
959 |
|
593 |
|
960 |
|
|
|
||
|
1 |
|
|
|
2 |
|
|
|
3 |
|
|
|
4 |
|
|
|
5 |
|
|
|
6 |
|
|
|
7 |
|
|
|
8 |
|
|
|
9 |
|
|
|
||
194 |
|
194 |
|
195 |
|
195 |
|
196 |
|
196 |
|
|
197 |
|
|
197 |
|
198 |
|
198 |
|
199 |
|
199 |
|
200 |
|
|
|
||
130 |
|
130 |
|
131 |
|
131 |
|
132 |
|
132 |
|
133 |
|
|
|
134 |
|
|
|
|
133 |
|
|
|
134 |
|
|
135 |
|
135 |
|
136 |
|
136 |
|
137 |
|
|
|
|
137 |
|
|
138 |
|
138 |
|
139 |
|
139 |
|
140 |
|
|
|
|
140 |
|
|
141 |
|
141 |
|
142 |
|
142 |
|
143 |
|
143 |
|
|
|
||
146 |
|
146 |
|
147 |
|
147 |
|
148 |
|
148 |
|
149 |
|
|
|
|
149 |
|
|
150 |
|
150 |
|
151 |
|
|
|
152 |
|
|
|
|
151 |
|
|
|
152 |
|
|
153 |
|
153 |
|
154 |
|
154 |
|
155 |
|
155 |
|
|
|
||
183 |
|
183 |
|
184 |
|
184 |
|
185 |
|
185 |
|
186 |
|
|
|
187 |
|
|
|
|
186 |
|
|
|
187 |
|
|
|
188 |
|
|
|
189 |
|
|
|
190 |
|
|
|
191 |
|
|
|
192 |
|
|
|
193 |
|
|
|
194 |
|
|
188 |
|
195 |
|
189 |
|
|
|
190 |
|
196 |
|
191 |
|
197 |
|
192 |
|
198 |
|
|
|
||
196 |
|
202 |
|
197 |
|
203 |
|
198 |
|
204 |
|
199 |
|
|
|
|
205 |
|
|
200 |
|
206 |
|
201 |
|
207 |
|
202 |
|
208 |
|
|
|
||
213 |
|
219 |
|
214 |
|
220 |
|
215 |
|
221 |
|
216 |
|
|
|
|
222 |
|
|
217 |
|
223 |
|
218 |
|
224 |
|
219 |
|
225 |
|