1\  Combine Multiple PCI headers with overlapping FCodes.
2\  Updated Fri, 01 Sep 2006 at 12:55 PDT by David L. Paktor
3
4\  We already have a source with overlapping FCodes in two FCode blocks
5\  We just have to wrap it in multiple PCI headers.
6\  Also, we have to make sure to define  NoCrash  as a command-line symbol
7\  While we're at it, let's also create another switchable behavior:
8\  If the command-line symbol  RangeTwo  is defined, it should have
9\      a value in the form of a hex number (We'll take care of the "hex")
10\      which will, in a roundabout way, become the starting FCode for
11\      the second loading of the common Source.
12\  We'll save the symbol in a roundabout manner that will test whether
13\      a particular means can be used to preserve the current FCode
14\      assignment counter across PCI blocks, especially when there is
15\      an  fcode-reset  associated with the end of a PCI block.
16\  Oh, and...  We'll control whether the  fcode-reset  is called by another
17\      command-line symbol:  If NoReset  is defined, we will bypass
18\      issuing the  fcode-reset  command.  (We expect we'll be making it
19\      automatic and implicit at the end of a PCI block, but we're still
20\      testing the premise...)
21
22
23tokenizer[
24
25h#   f2a7     \   Bogus Rev-Level
26      SET-REV-LEVEL
27
28not-last-image
29
30h#   1fed     \   Vendor
31h#   9009     \   Bogus Device ID
32h#  20109     \   Bogus Class Code
33     pci-header
34
35	 ]tokenizer
36
37fload TooManyFCodes.fth
38
39
40\  Generate an error or two if  RangeTwo  is not DEFINED.  It's harmless
41     f[
42	[DEFINED]  RangeTwo  constant SecondRangeFCode
43      ]f
44\  because all the other references to  SecondRangeFCode  are conditioned...
45
46\  Try it once before and once after...
47[ifndef]  NoReset  fcode-reset [else] #message" Not resetting..." [endif]
48pci-header-end  [ifndef]  NoReset  fcode-reset  [endif]
49
50tokenizer[
51
52h#   ea57     \   Bogus Rev-Level
53      SET-REV-LEVEL
54
55     last-image
56
57h#   deaf     \   Vendor
58h#   9021     \   Bogus Device ID
59h#  10902     \   Bogus Class Code
60     pci-header
61
62	 ]tokenizer
63
64
65[ifdef] RangeTwo
66     f[
67	SecondRangeFCode next-fcode
68      ]f
69[endif]
70
71fload TooManyFCodes.fth
72
73
74pci-header-end  [ifndef]  NoReset  fcode-reset  [endif]
75