| … | |
… | |
| 2 | <!DOCTYPE sections SYSTEM "/dtd/book.dtd"> |
2 | <!DOCTYPE sections SYSTEM "/dtd/book.dtd"> |
| 3 | |
3 | |
| 4 | <!-- The content of this document is licensed under the CC-BY-SA license --> |
4 | <!-- The content of this document is licensed under the CC-BY-SA license --> |
| 5 | <!-- See http://creativecommons.org/licenses/by-sa/2.5 --> |
5 | <!-- See http://creativecommons.org/licenses/by-sa/2.5 --> |
| 6 | |
6 | |
| 7 | <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-x86+amd64-bootloader.xml,v 1.14 2009/09/24 20:26:50 nightmorph Exp $ --> |
7 | <!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-x86+amd64-bootloader.xml,v 1.15 2009/11/17 05:55:40 nightmorph Exp $ --> |
| 8 | |
8 | |
| 9 | <sections> |
9 | <sections> |
| 10 | |
10 | |
| 11 | <version>6.4</version> |
11 | <version>6.5</version> |
| 12 | <date>2009-09-24</date> |
12 | <date>2009-11-16</date> |
| 13 | |
13 | |
| 14 | <section> |
14 | <section> |
| 15 | <title>Making your Choice</title> |
15 | <title>Making your Choice</title> |
| 16 | <subsection> |
16 | <subsection> |
| 17 | <title>Introduction</title> |
17 | <title>Introduction</title> |
| … | |
… | |
| 47 | <body> |
47 | <body> |
| 48 | |
48 | |
| 49 | <p> |
49 | <p> |
| 50 | <e>If</e> you have configured your kernel with framebuffer support (or you used |
50 | <e>If</e> you have configured your kernel with framebuffer support (or you used |
| 51 | <c>genkernel</c> default kernel configuration), you can activate it by adding a |
51 | <c>genkernel</c> default kernel configuration), you can activate it by adding a |
| 52 | <c>vga</c> and/or a <c>video</c> statement to your bootloader configuration |
52 | a <c>video</c> statement to your bootloader configuration file. |
| 53 | file. |
|
|
| 54 | </p> |
|
|
| 55 | |
|
|
| 56 | <p> |
53 | </p> |
| 57 | First of all, you need to know what type of framebuffer device you're using. If |
54 | |
| 58 | you use a Gentoo patched kernel tree (such as <c>gentoo-sources</c>) you will |
|
|
| 59 | have had the possibility of selecting <c>uvesafb</c> as the <e>VESA driver</e>. |
|
|
| 60 | If this is the case, you are using <c>uvesafb</c> and <e>do not need</e> to set |
|
|
| 61 | a <c>vga</c> statement. Otherwise you are using the <c>vesafb</c> driver and |
|
|
| 62 | <e>need</e> to set the <c>vga</c> statement. |
|
|
| 63 | </p> |
55 | <p> |
| 64 | |
56 | First of all, you need to know your framebuffer device. You should have used |
|
|
57 | <c>uvesafb</c> as the <e>VESA driver</e>. |
| 65 | <p> |
58 | </p> |
| 66 | The <c>vga</c> statement controls the resolution and color depth of your |
|
|
| 67 | framebuffer screen for <c>vesafb</c>. As stated in |
|
|
| 68 | <path>/usr/src/linux/Documentation/fb/vesafb.txt</path> (which gets installed |
|
|
| 69 | when you install a kernel source package), you need to pass the VESA number |
|
|
| 70 | corresponding to the requested resolution and color depth to it. |
|
|
| 71 | </p> |
|
|
| 72 | |
|
|
| 73 | <p> |
|
|
| 74 | The following table lists the available resolutions and color depths and |
|
|
| 75 | matches those against the value that you need to pass on to the <c>vga</c> |
|
|
| 76 | statement. |
|
|
| 77 | </p> |
|
|
| 78 | |
|
|
| 79 | <table> |
|
|
| 80 | <tr> |
|
|
| 81 | <ti></ti> |
|
|
| 82 | <th>640x480</th> |
|
|
| 83 | <th>800x600</th> |
|
|
| 84 | <th>1024x768</th> |
|
|
| 85 | <th>1280x1024</th> |
|
|
| 86 | </tr> |
|
|
| 87 | <tr> |
|
|
| 88 | <th>256</th> |
|
|
| 89 | <ti>0x301</ti> |
|
|
| 90 | <ti>0x303</ti> |
|
|
| 91 | <ti>0x305</ti> |
|
|
| 92 | <ti>0x307</ti> |
|
|
| 93 | </tr> |
|
|
| 94 | <tr> |
|
|
| 95 | <th>32k</th> |
|
|
| 96 | <ti>0x310</ti> |
|
|
| 97 | <ti>0x313</ti> |
|
|
| 98 | <ti>0x316</ti> |
|
|
| 99 | <ti>0x319</ti> |
|
|
| 100 | </tr> |
|
|
| 101 | <tr> |
|
|
| 102 | <th>64k</th> |
|
|
| 103 | <ti>0x311</ti> |
|
|
| 104 | <ti>0x314</ti> |
|
|
| 105 | <ti>0x317</ti> |
|
|
| 106 | <ti>0x31A</ti> |
|
|
| 107 | </tr> |
|
|
| 108 | <tr> |
|
|
| 109 | <th>16M</th> |
|
|
| 110 | <ti>0x312</ti> |
|
|
| 111 | <ti>0x315</ti> |
|
|
| 112 | <ti>0x318</ti> |
|
|
| 113 | <ti>0x31B</ti> |
|
|
| 114 | </tr> |
|
|
| 115 | </table> |
|
|
| 116 | |
59 | |
| 117 | <p> |
60 | <p> |
| 118 | The <c>video</c> statement controls framebuffer display options. It needs to be |
61 | The <c>video</c> statement controls framebuffer display options. It needs to be |
| 119 | given the framebuffer driver followed by the control statements you wish to |
62 | given the framebuffer driver followed by the control statements you wish to |
| 120 | enable. All variables are listed in |
63 | enable. All variables are listed in |
| 121 | <path>/usr/src/linux/Documentation/fb/vesafb.txt</path>. The most-used options |
64 | <path>/usr/src/linux/Documentation/fb/uvesafb.txt</path>. The most-used options |
| 122 | are: |
65 | are: |
| 123 | </p> |
66 | </p> |
| 124 | |
67 | |
| 125 | <table> |
68 | <table> |
| 126 | <tr> |
69 | <tr> |
| … | |
… | |
| 146 | </ti> |
89 | </ti> |
| 147 | </tr> |
90 | </tr> |
| 148 | <tr> |
91 | <tr> |
| 149 | <ti><c>mode</c></ti> |
92 | <ti><c>mode</c></ti> |
| 150 | <ti> |
93 | <ti> |
| 151 | (<c>uvesafb</c> only)<br/> |
|
|
| 152 | Set up the resolution, color depth and refresh rate. For instance, |
94 | Set up the resolution, color depth and refresh rate. For instance, |
| 153 | <c>1024x768-32@85</c> for a resolution of 1024x768, 32 bit color depth and a |
95 | <c>1024x768-32@85</c> for a resolution of 1024x768, 32 bit color depth and a |
| 154 | refresh rate of 85 Hz. |
96 | refresh rate of 85 Hz. |
| 155 | </ti> |
97 | </ti> |
| 156 | </tr> |
98 | </tr> |
| 157 | </table> |
99 | </table> |
| 158 | |
100 | |
| 159 | <p> |
101 | <p> |
| 160 | The result of those two statements could be something like <c>vga=0x318 |
102 | The result could be something like |
| 161 | video=vesafb:mtrr:3,ywrap</c> or |
|
|
| 162 | <c>video=uvesafb:mtrr:3,ywrap,1024x768-32@85</c>. Write this setting down; you |
103 | <c>video=uvesafb:mtrr:3,ywrap,1024x768-32@85</c>. Write this setting down; you |
| 163 | will need it shortly. |
104 | will need it shortly. |
| 164 | </p> |
105 | </p> |
| 165 | |
106 | |
| 166 | <p test="func:keyval('arch')='IA64'"> |
107 | <p test="func:keyval('arch')='IA64'"> |
| … | |
… | |
| 183 | |
124 | |
| 184 | <p> |
125 | <p> |
| 185 | The most critical part of understanding GRUB is getting comfortable with how |
126 | The most critical part of understanding GRUB is getting comfortable with how |
| 186 | GRUB refers to hard drives and partitions. Your Linux partition |
127 | GRUB refers to hard drives and partitions. Your Linux partition |
| 187 | <path>/dev/sda1</path> will most likely be called <path>(hd0,0)</path> under |
128 | <path>/dev/sda1</path> will most likely be called <path>(hd0,0)</path> under |
| 188 | GRUB. Notice the parentheses around the <path>hd0,0</path> - they are |
129 | GRUB. Notice the parentheses around the <path>hd0,0</path> - they are |
| 189 | required. |
130 | required. |
| 190 | </p> |
131 | </p> |
| 191 | |
132 | |
| 192 | <p> |
133 | <p> |
| 193 | Hard drives count from zero rather than "a" and partitions start at zero |
134 | Hard drives count from zero rather than "a" and partitions start at zero |
| … | |
… | |
| 336 | a <path>boot</path> symlink makes it work. In short, the above examples should |
277 | a <path>boot</path> symlink makes it work. In short, the above examples should |
| 337 | work whether you defined a separate <path>/boot</path> partition or not. |
278 | work whether you defined a separate <path>/boot</path> partition or not. |
| 338 | </p> |
279 | </p> |
| 339 | |
280 | |
| 340 | <p> |
281 | <p> |
| 341 | If you need to pass any additional options to the kernel, simply add |
282 | If you need to pass any additional options to the kernel, simply add them to the |
| 342 | them to the end of the kernel command. We're already passing one option |
283 | end of the kernel command. We're already passing one option |
| 343 | (<c>root=/dev/sda3</c> or <c>real_root=/dev/sda3</c>), but you can pass others |
284 | (<c>root=/dev/sda3</c> or <c>real_root=/dev/sda3</c>), but you can pass others |
| 344 | as well, such as the <c>video</c> and/or <c>vga</c> statements for framebuffer |
285 | as well, such as the <c>video</c>> statement for framebuffer as we discussed |
| 345 | as we discussed previously. |
286 | previously. |
| 346 | </p> |
287 | </p> |
| 347 | |
288 | |
| 348 | <p> |
289 | <p> |
| 349 | If your bootloader configuration file contains the real_root parameter use the |
290 | If your bootloader configuration file contains the real_root parameter use the |
| 350 | rootflags parameter to set root filesystem mount options. In the case where |
291 | rootflags parameter to set root filesystem mount options. In the case where |
| … | |
… | |
| 603 | <pre caption="Using append to add kernel options"> |
544 | <pre caption="Using append to add kernel options"> |
| 604 | image=/boot/<keyval id="kernel-name"/> |
545 | image=/boot/<keyval id="kernel-name"/> |
| 605 | label=gentoo |
546 | label=gentoo |
| 606 | read-only |
547 | read-only |
| 607 | root=/dev/sda3 |
548 | root=/dev/sda3 |
| 608 | <i>append="video=vesafb:mtrr,ywrap,1024x768-32@85"</i> |
549 | <i>append="video=uvesafb:mtrr,ywrap,1024x768-32@85"</i> |
| 609 | </pre> |
550 | </pre> |
| 610 | |
551 | |
| 611 | <p> |
552 | <p> |
| 612 | If you're using a 2.6.7 or higher kernel and you jumpered your harddrive |
553 | If you're using a 2.6.7 or higher kernel and you jumpered your harddrive |
| 613 | because the BIOS can't handle large harddrives you'll need to append |
554 | because the BIOS can't handle large harddrives you'll need to append |