source: postlfs/config/firmware.xml@ ba78ebe2

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since ba78ebe2 was ba78ebe2, checked in by Bruce Dubbs <bdubbs@…>, 7 years ago

Update firmware discussion for Intel CPUs

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@18439 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 25.3 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="postlfs-firmware" xreflabel="About Firmware">
9 <?dbhtml filename="firmware.html"?>
10
11 <sect1info>
12 <othername>$LastChangedBy$</othername>
13 <date>$Date$</date>
14 </sect1info>
15
16 <title>About Firmware</title>
17
18 <indexterm zone="postlfs-firmware">
19 <primary sortas="e-lib-firmware">/lib/firmware</primary>
20 </indexterm>
21
22 <para> On some recent PCs it can be necessary, or desirable, to load firmware
23 to make them work at their best. There is a directory, <filename
24 class="directory">/lib/firmware</filename>, where the kernel or kernel
25 drivers look for firmware images.</para>
26
27 <para>Preparing firmware for multiple different machines, as a distro would
28 do, is outside the scope of this book.</para>
29
30 <para>Currently, most firmware can be found at a <userinput>git</userinput>
31 repository: <ulink
32 url="http://git.kernel.org/cgit/linux/kernel/git/firmware/linux-firmware.git/tree/"/>.
33 For convenience, the LFS Project has created a mirror, updated daily, where
34 these firmware files can be accessed via <userinput>wget</userinput> or a web
35 browser at <ulink
36 url="&sources-anduin-http;/linux-firmware/"/>.</para>
37
38 <para>To get the firmware, either point a browser to one of the above
39 repositories and then download the item(s) which you need, or install
40 <userinput>git</userinput> and clone that repository.</para>
41
42 <para>For some other firmware, particularly for Intel microcode and certain
43 wifi devices, the needed firmware is not available in the above repository.
44 Some of this will be addressed below, but a search of the Internet for needed
45 firmware is sometimes necessary.</para>
46
47 <para>Firmware files are conventionally referred to as blobs because you cannot
48 determine what they will do. Note that firmware is distributed under various
49 different licenses which do not permit disassembly or reverse-engineering.</para>
50
51 <para>Firmware for PCs falls into four categories:</para>
52
53 <itemizedlist spacing="compact">
54 <listitem>
55 <para>Updates to the CPU to work around errata, usually referred to as
56 microcode.</para>
57 </listitem>
58 <listitem>
59 <para>Firmware for video controllers. On x86 machines this seems to only
60 apply to ATI devices : Radeons require firmware to be able to use KMS
61 (kernel modesetting - the preferred option) as well as for Xorg. For
62 earlier radeon chips (before the R600), the firmware is still in the
63 kernel.</para>
64 </listitem>
65 <listitem>
66 <para>Firmware updates for wired network ports. Mostly they work even
67 without the updates, but one must assume that they will work better with
68 the updated firmware.</para>
69 </listitem>
70 <listitem>
71 <para>Firmware for other devices, such as wifi. These devices are not
72 required for the PC to boot, but need the firmware before these devices
73 can be used.</para>
74 </listitem>
75 </itemizedlist>
76
77 <note><para>Although not needed to load a firmware blob, the following
78 tools may be useful for determining, obtaining, or preparing the needed
79 firmware in order to load it into the system:
80 <xref linkend="cpio"/>,
81 <xref linkend="git"/>,
82 <xref linkend="pciutils"/>, and
83 <xref linkend="wget"/></para></note>
84
85 <para condition="html" role="usernotes">User Notes:
86 <ulink url="&blfs-wiki;/aboutfirmware"/></para>
87
88 <sect2 id="cpu-microcode">
89 <title>Microcode updates for CPUs</title>
90
91 <para>In general, microcode can be loaded by the BIOS or UEFI, and it might
92 be updated by upgrading to a newer version of those. On linux, you can also
93 load the microcode from the kernel if you are using an AMD family 10h or
94 later processor (first introduced late 2007), or an Intel processor from
95 1998 and later (Pentium4, Core, etc), if updated microcode has been
96 released. These updates only last until the machine is powered off, so they
97 need to be applied on every boot.</para>
98
99 <para>There are two ways of loading the microcode, described as 'early' and
100 'late'. Early loading happens before userspace has been started, late
101 loading happens when userspace has started. Not surprisingly, early loading
102 is preferred, (see e.g. an explanatory comment in a kernel commit noted at
103 <ulink url="https://lwn.net/Articles/530346/">x86/microcode: Early load
104 microcode </ulink> on LWN.) Indeed, it is needed to work around one
105 particular erratum in early Intel Haswell processors which had TSX enabled.
106 (See <ulink
107 url="http://www.anandtech.com/show/8376/intel-disables-tsx-instructions-erratum-found-in-haswell-haswelleep-broadwellyi/">
108 Intel Disables TSX Instructions: Erratum Found in Haswell, Haswell-E/EP,
109 Broadwell-Y</ulink>.) Without this update glibc can do the wrong thing in
110 uncommon situations.</para>
111
112 <para>It is much simpler to begin by building a kernel which boots on
113 your hardware, try late microcode loading to see if there is an update (in
114 many cases the BIOS or UEFI will have already applied any update), and then
115 take the extra steps required for early loading.</para>
116
117 <para>This means you will be reconfiguring your kernel if you use early
118 loading, so keep the built source around to minimise what gets rebuilt, and
119 if you are at all uncertain, add your own identifier (A,B, etc) to the end
120 of the EXTRAVERSION in the kernel configuration, e.g. "EXTRAVERSION -A" if
121 nothing was set.</para>
122
123 <para>To confirm what processor(s) you have (if more than one, they will be
124 identical) look in /proc/cpuinfo.</para>
125
126 <sect3 id="intel-microcode">
127 <title>Intel Microcode for the CPU</title>
128<!--
129 <bridgehead renderas="sect4">Required Package</bridgehead>
130 <para role='required'>
131 <ulink url='http://fedorahosted.org/released/microcode_ctl/'/></para>
132
133 <para>For Intel CPUs an extra package, microcode_ctl, is required. The
134 package chosen is the version hosted at fedora &mdash; there is an
135 alternative version at github from the same packager, but that still
136 includes a redundant old version of an AMD microcode container, and also
137 requires the unzip package.</para>
138
139 <para>Download the latest version from the link above; when last checked
140 this was 2.1-8 and is updated when Intel releases new microcode.</para>
141
142 <para>This package reformats the microcode supplied by Intel into a
143 format which the kernel can apply. The program
144 <userinput>intel-microcode2ucode</userinput> is built and invoked by the
145 Makefile to create the individual firmware blobs, so there is no reason
146 to install it.</para>
147
148 <para>Begin by extracting the tarball and changing to the directory it created.
149 Then change to the source directory and run:</para>
150
151<screen><userinput>make</userinput></screen>
152
153 <para>This creates various blobs with names in the form XX-YY-ZZ. Now you
154 need to determine your processor's identity, to see if there is any
155 microcode for it. Determine the decimal values of the cpu family, model
156 and stepping by running:</para>
157-->
158
159 <bridgehead renderas="sect4">Required File</bridgehead>
160 <para role='required'>
161 <ulink url='&sources-anduin-http;/intel-microcode/intel-microcode2ucode.c'/>
162 </para>
163
164 <para>For Intel CPUs an extra program, intel-microcode2ucode, is required.
165 This is done a little differently since it is only a single source
166 code file. The reason for this is that there are differnet versions
167 available, but most are specific to commercial distributions.</para>
168
169 <para>This program reformats the microcode supplied by Intel into a
170 format which the kernel can apply. The program
171 <userinput>intel-microcode2ucode</userinput> is used create the
172 individual firmware blobs </para>
173
174 <para>Create the program by downloading the source file and running:</para>
175
176<screen><userinput>gcc -g -Wall -O2 -o intel-microcode2ucode intel-microcode2ucode.c</userinput></screen>
177
178 <para>Now install the program as the <systemitem class="username">root</systemitem> user:</para>
179
180<screen><userinput>install intel-microcode2ucode /usr/bin</userinput></screen>
181
182 <para>The next step is to get the most recent version of the Intel
183 microcode. The must be done by navigating to
184 <ulink url='https://downloadcenter.intel.com/download/26400/Linux-Processor-Microcode-Data-File'/>
185 and following the instructions there. As of this writing the most recent
186 version of the microcode is <filename>microcode-20161104.tgz</filename>.
187 This file is a tar file, but expands to <filename>microcode.dat</filename>
188 in the current directory.</para>
189
190 <para>Next, create various blobs with names in the form XX-YY-ZZ in a
191 subdirectory named <filename class="directory">intel-ucode/</filename>:
192 </para>
193
194<screen><userinput>intel-microcode2ucode microcode.dat</userinput></screen>
195
196 <para>Now you need to determine your processor's identity to see if there
197 is any microcode for it. Determine the decimal values of the cpu family,
198 model and stepping by running:</para>
199
200<screen><userinput>head -n7 /proc/cpuinfo</userinput></screen>
201
202 <para>Convert the cpu family, model and stepping to pairs of hexadecimal
203 digits. For a SandyBridge i3-2120 (described as Intel(R) Core(TM) i3-2120
204 CPU) the relevant values are cpu family 6, model 42, stepping 7 so in
205 this case the required identification is 06-2a-07. A look at the blobs
206 will show that there is one for this CPU (although it might
207 have already been applied by the BIOS). If there is a blob for your
208 system then test if it will be applied by copying it (replace &lt;XX-YY-ZZ&gt;
209 by the identifier for your machine) to where the kernel can find it:</para>
210
211<screen><userinput>mkdir -pv /lib/firmware/intel-ucode
212cp -v intel-ucode/&lt;XX-YY-ZZ&gt; /lib/firmware/intel-ucode</userinput></screen>
213
214 <para>Now that the Intel microcode has been prepared, use the following
215 options when you configure the kernel to try late loading of the Intel
216 microcode:</para>
217
218<screen><literal>Processor type and features ---&gt;
219 &lt;M&gt; CPU microcode loading support [CONFIG_MICROCODE]
220 [*] Intel microcode loading support [CONFIG_MICROCODE_INTEL]</literal></screen>
221
222 <para>After you have successfully booted the new system, use the command
223 <userinput>dmesg | grep microcode</userinput> and study the results to
224 see if the message new patch_level appears. This example from the
225 SandyBridge i3:</para>
226
227<screen><literal>[ 0.059906] perf_event_intel: PEBS disabled due to CPU errata, please upgrade microcode
228[ 2.603083] microcode: CPU0 sig=0x206a7, pf=0x2, revision=0x23
229[ 2.669378] microcode: CPU0 sig=0x206a7, pf=0x2, revision=0x23
230[ 2.669994] microcode: CPU0 updated to revision 0x29, date = 2013-06-12
231[ 2.670069] microcode: CPU1 sig=0x206a7, pf=0x2, revision=0x23
232[ 2.670139] microcode: CPU1 sig=0x206a7, pf=0x2, revision=0x23
233[ 2.670501] microcode: CPU1 updated to revision 0x29, date = 2013-06-12
234[ 2.670509] microcode: CPU2 sig=0x206a7, pf=0x2, revision=0x23
235[ 2.670540] microcode: CPU2 sig=0x206a7, pf=0x2, revision=0x23
236[ 2.670917] microcode: CPU2 updated to revision 0x29, date = 2013-06-12
237[ 2.670955] microcode: CPU3 sig=0x206a7, pf=0x2, revision=0x23
238[ 2.670988] microcode: CPU3 sig=0x206a7, pf=0x2, revision=0x23
239[ 2.671348] microcode: CPU3 updated to revision 0x29, date = 2013-06-12
240[ 2.671356] perf_event_intel: PEBS enabled due to microcode update
241[ 2.671412] microcode: Microcode Update Driver: v2.00 &lt;tigran@aivazian.fsnet.co.uk&gt;, Peter Oruba</literal></screen>
242
243 <para>If the microcode was not updated, there is no new microcode for
244 this system's processor. If it did get updated, you can now proceed to <xref
245 linkend='early-microcode'/>.</para>
246
247 </sect3>
248
249 <sect3 id="and-microcode">
250 <title>AMD Microcode for the CPU</title>
251
252 <para>Begin by downloading a container of firmware for your CPU family
253 from <ulink
254 url='&sources-anduin-http;/linux-firmware/amd-ucode/'/>.
255 The family is always specified in hex. Families 10h to 14h (16 to 20)
256 are in microcode_amd.bin. Families 15h and 16h have their own containers.
257 Create the required directory and put the firmware you downloaded into
258 it as the <systemitem class="username">root</systemitem> user:</para>
259
260<screen><userinput>mkdir -pv /lib/firmware/amd-ucode
261cp -v microcode_amd* /lib/firmware/amd-ucode</userinput></screen>
262
263 <para>When you configure the kernel, use the following options to try
264 late loading of AMD microcode:</para>
265
266<screen><literal>Processor type and features ---&gt;
267 &lt;M&gt; CPU microcode loading support [CONFIG_MICROCODE]
268 [*] AMD microcode loading support [CONFIG_MICROCODE_AMD]</literal></screen>
269
270 <para>After you have successfully booted the new system, use the command
271 <userinput>dmesg | grep microcode</userinput> and study the results to see
272 if the message new patch_level appears, as in this example from an old
273 Athlon(tm) II X2:</para>
274
275<screen><literal>[ 4.183907] microcode: CPU0: patch_level=0x010000b6
276[ 4.184271] microcode: CPU0: new patch_level=0x010000c8
277[ 4.184278] microcode: CPU1: patch_level=0x010000b6
278[ 4.184283] microcode: CPU1: new patch_level=0x010000c8
279[ 4.184359] microcode: Microcode Update Driver: v2.00 &lt;tigran@aivazian.fsnet.co.uk&gt;, Peter Oruba</literal></screen>
280
281 <para>If the microcode was not updated, there is no new microcode for
282 this system's processor. If it did get updated, you can now proceed to <xref
283 linkend='early-microcode'/>.</para>
284
285 </sect3>
286
287 <sect3 id="early-microcode">
288 <title>Early loading of microcode</title>
289
290 <para>If you have established that updated microcode is available for
291 your system, it is time to prepare it for early loading. This requires
292 an additional package, <xref linkend='cpio'/>, as well as changes to
293 the kernel config and the creation of an initrd which will need to be
294 added to grub.cfg.</para>
295
296 <para>It does not matter where you prepare the initrd, and once it is
297 working you can apply the same initrd to later LFS systems or newer
298 kernels on this same machine, at least until any newer microcode is
299 released. Use the following commands:</para>
300
301<screen><userinput>mkdir -p initrd/kernel/x86/microcode
302cd initrd</userinput></screen>
303
304 <para>For an AMD machine, use the following command (replace
305 &lt;MYCONTAINER&gt; with the name of the container for your CPU's
306 family):</para>
307
308<screen><userinput>cp -v /lib/firmware/amd_ucode/&lt;MYCONTAINER&gt; kernel/x86/microcode/AuthenticAMD.bin</userinput></screen>
309
310 <para>Or for an Intel machine copy the appropriate blob using this command:</para>
311
312<screen><userinput>cp -v /lib/firmware/intel-ucode/&lt;XX-YY-ZZ&gt; kernel/x86/microcode/GenuineIntel.bin</userinput></screen>
313
314 <para>Now prepare the initrd:</para>
315
316<screen><userinput>find . | cpio -o -H newc &gt; /boot/microcode.img</userinput></screen>
317
318 <para>You will now need to reconfigure and rebuild your kernel. It is
319 safer to either add/change the EXTRAVERSION in the kernel's configuration
320 and install the newer kernel with a new name, or else (unless you have a
321 machine which requires an early firmware update) wait for the next
322 SUBLEVEL kernel release so that you can fall back to the existing kernel
323 in the event that something goes wrong.</para>
324
325 <para>You will also need to add a new entry to /boot/grub/grub.cfg and
326 here you should add a new line after the linux line within the stanza.
327 If /boot is a separate mountpoint: </para>
328
329<screen><userinput>initrd /microcode.img</userinput></screen>
330
331 <para>or this if it is not:</para>
332
333<screen><userinput>initrd /boot/microcode.img</userinput></screen>
334
335 <para>You must also change the kernel config:</para>
336
337<screen><literal>General Setup ---&gt;
338 [y] Initial RAM filesystem and RAM disk (initramfs/initrd) support [CONFIG_BLK_DEV_INITRD]
339 [y] CPU microcode loading support [CONFIG_MICROCODE]</literal></screen>
340
341 <para>Retain the setting for INTEL or AMD microcode. When you have saved
342 the .config file, either CONFIG_MICROCODE_INTEL_EARLY=y or
343 CONFIG_MICROCODE_AMD_EARLY=y should be set, together with
344 CONFIG_MICROCODE_EARLY=y.</para>
345
346 <para>When you have installed and booted this kernel, you should check
347 the output of dmesg to confirm that the early load worked. The places and
348 times where this happens are very different in AMD and Intel machines.
349 First, an Intel example where a development kernel is being tested,
350 showing that the first notification comes before the kernel version is
351 mentioned:</para>
352
353<screen><literal>[ 0.000000] CPU0 microcode updated early to revision 0x29, date = 2013-06-12
354[ 0.000000] Linux version 4.0.0-rc6 (ken@jtm1) (gcc version 4.9.2 (GCC) )
355 #3 SMP PREEMPT Mon Mar 30 21:26:02 BST 2015
356[ 0.000000] Command line: BOOT_IMAGE=/vmlinuz-4.0.0-rc6-sda13 root=/dev/sda13 ro
357...
358[ 0.103091] CPU1 microcode updated early to revision 0x29, date = 2013-06-12
359[ 0.113241] #2
360[ 0.134631] #3
361[ 0.147821] x86: Booted up 1 node, 4 CPUs
362[ 0.147936] smpboot: Total of 4 processors activated (26338.66 BogoMIPS)
363...
364[ 0.272643] microcode: CPU0 sig=0x206a7, pf=0x2, revision=0x29
365[ 0.272709] microcode: CPU1 sig=0x206a7, pf=0x2, revision=0x29
366[ 0.272775] microcode: CPU2 sig=0x206a7, pf=0x2, revision=0x29
367[ 0.272842] microcode: CPU3 sig=0x206a7, pf=0x2, revision=0x29
368[ 0.272941] microcode: Microcode Update Driver: v2.00 &lt;tigran@aivazian.fsnet.co.uk&gt;, Peter Oruba</literal></screen>
369
370 <para>A second AMD example is where the machine was running a stable
371 kernel on an older version of LFS. Note that here there is no mention of
372 the previous microcode version &mdash; compare this output to the AMD
373 late loading messages (above) from the same machine:</para>
374
375<screen><literal>[ 0.000000] Linux version 3.18.11 (ken@milliways) (gcc version 4.9.1 (GCC) )
376 #4 SMP Thu Apr 9 21:51:05 BST 2015
377[ 0.000000] Command line: BOOT_IMAGE=/vmlinuz-3.18.11-sda5 root=/dev/sda5 video=800x600 ro
378...
379[ 0.584009] Trying to unpack rootfs image as initramfs...
380[ 0.584092] microcode: updated early to new patch_level=0x010000c8
381...
382[ 0.586733] microcode: CPU0: patch_level=0x010000c8
383[ 0.586778] microcode: CPU1: patch_level=0x010000c8
384[ 0.586866] microcode: Microcode Update Driver: v2.00 &lt;tigran@aivazian.fsnet.co.uk&gt;, Peter Oruba</literal></screen>
385
386 </sect3>
387
388 </sect2>
389
390 <sect2 id="video-firmware">
391 <title>Firmware for Video Cards</title>
392
393 <sect3 id="ati-video-firmware">
394 <title>Firmware for ATI video chips (R600 and later)</title>
395
396 <para>These instructions do NOT apply to old radeons before the R600
397 family. For those, the firmware is in the kernel's <filename
398 class='directory'>/lib/firmware/</filename> directory. Nor do they apply if
399 you intend to avoid a graphical setup such as Xorg and are content to use
400 the default 80x25 display rather than a framebuffer. </para>
401
402 <para> Early radeon devices only needed a single 2K blob of firmware.
403 Recent devices need several different blobs, and some of them are much
404 bigger. The total size of the radeon firmware directory is over 500K &mdash; on a
405 large modern system you can probably spare the space, but it is still
406 redundant to install all the unused files each time you build a system.</para>
407
408 <para>A better approach is to install <xref linkend='pciutils'/> and then
409 use <userinput>lspci</userinput> to identify which VGA controller is
410 installed.</para>
411
412 <para>With that information, check the RadeonFeature page of the Xorg wiki
413 for <ulink url="http://wiki.x.org/wiki/RadeonFeature/#index5h2">Decoder
414 ring for engineering vs marketing names</ulink> to identify the family (you
415 may need to know this for the Xorg driver in BLFS &mdash; Southern Islands and
416 Sea Islands use the radeonsi driver) and the specific model.</para>
417
418 <para>Now that you know which controller you are using, consult the
419 <ulink url="https://wiki.gentoo.org/wiki/Radeon#Firmware">Radeon</ulink> page
420 of the Gentoo wiki which has a table listing the required firmware blobs
421 for the various chipsets. Note that Southern Islands and Sea Islands chips
422 use different firmware for kernel 3.17 and later compared to earlier
423 kernels. Identify and download the required blobs then install them:</para>
424
425<screen><userinput>mkdir -pv /lib/firmware/radeon
426cp -v &lt;YOUR_BLOBS&gt; /lib/firmware/radeon</userinput></screen>
427
428 <para>There are actually two ways of installing this firmware. BLFS, in the
429 'Kernel Configuration for additional firmware' section part of the <xref
430 linkend="xorg-ati-driver"/> section gives an example of compiling the
431 firmware into the kernel - that is slightly faster to load, but uses more
432 kernel memory. Here we will use the alternative method of making the radeon
433 driver a module. In your kernel config set the following: </para>
434
435<screen><literal>Device Drivers ---&gt;
436 Graphics support ---&gt;
437 Direct Rendering Manager ---&gt;
438 &lt;*&gt; Direct Rendering Manager (XFree86 ... support) [CONFIG_DRM]
439 &lt;m&gt; ATI Radeon [CONFIG_DRM_RADEON]</literal></screen>
440
441 <para>Loading several large blobs from /lib/firmware takes a noticeable
442 time, during which the screen will be blank. If you do not enable the
443 penguin framebuffer logo, or change the console size by using a bigger
444 font, that probably does not matter. If desired, you can slightly
445 reduce the time if you follow the alternate method of specifying 'y' for
446 CONFIG_DRM_RADEON covered in BLFS at the link above &mdash; you must specify each
447 needed radeon blob if you do that.</para>
448
449 </sect3>
450
451 <sect3 id="nvidia-video-firmware">
452 <title>Firmware for Nvidia video chips</title>
453
454 <para>Some Nvidia graphics chips need firmware updates to take advantage
455 of all the card's capability. These are generally the GeForce 8, 9, 9300,
456 and 200-900 series chips. For more exact information, see <ulink
457 url="https://nouveau.freedesktop.org/wiki/VideoAcceleration/#firmware">
458 https://nouveau.freedesktop.org/wiki/VideoAcceleration/#firmware</ulink>.</para>
459
460 <para>First, the kernel Nvidia driver must be activated:</para>
461
462<screen><literal>Device Drivers ---&gt;
463 Graphics support ---&gt;
464 Direct Rendering Manager ---&gt;
465 &lt;*&gt; Direct Rendering Manager (XFree86 ... support) [CONFIG_DRM]
466 &lt;*/m&gt; Nouveau (NVIDIA) cards [CONFIG_DRM_NOUVEAU]</literal></screen>
467
468 <para>The steps to install the Nvidia firmware are:</para>
469
470<screen><userinput>wget https://raw.github.com/imirkin/re-vp2/master/extract_firmware.py
471wget http://us.download.nvidia.com/XFree86/Linux-x86/325.15/NVIDIA-Linux-x86-325.15.run
472sh NVIDIA-Linux-x86-325.15.run --extract-only
473python extract_firmware.py
474mkdir -p /lib/firmware/nouveau
475cp -d nv* vuc-* /lib/firmware/nouveau/</userinput></screen>
476
477 </sect3>
478 </sect2>
479
480 <sect2 id="nic-firmware">
481 <title>Firmware for Network Interfaces</title>
482
483 <para>The kernel likes to load firmware for some network drivers,
484 particularly those from Realtek (the /lib/linux-firmware/rtl_nic/) directory,
485 but they generally appear to work without it. Therefore, you can boot the
486 kernel, check dmesg for messages about this missing firmware, and if
487 necessary download the firmware and put it in the specified directory in
488 /lib/firmware so that it will be found on subsequent boots. Note that with
489 current kernels this works whether or not the driver is compiled in or
490 built as a module, there is no need to build this firmware into the kernel.
491 Here is an example where the R8169 driver has been compiled in but the
492 firmware was not made available. Once the firmware had been provided, there
493 was no mention of it on later boots. </para>
494
495<screen><literal>dmesg | grep firmware | grep r8169
496[ 7.018028] r8169 0000:01:00.0: Direct firmware load for rtl_nic/rtl8168g-2.fw failed with error -2
497[ 7.018036] r8169 0000:01:00.0 eth0: unable to load firmware patch rtl_nic/rtl8168g-2.fw (-2)</literal></screen>
498
499 </sect2>
500
501 <sect2 id="other-firmware">
502 <title>Firmware for Other Devices</title>
503
504 <para> Identifying the correct firmware will typically require you to
505 install <xref linkend='pciutils'/>, and then use
506 <userinput>lspci</userinput> to identify the device. You should then search
507 online to check which module it uses, which firmware, and where to obtain
508 the firmware &mdash; not all of it is in linux-firmware.</para>
509
510 <para>If possible, you should begin by using a wired connection when you
511 first boot your LFS system. To use a wireless connection you will need to
512 use a network tools such as <xref linkend='wireless_tools'/> and <xref
513 linkend='wpa_supplicant'/>.</para>
514
515 <para>Firmware may also be needed for other devices such as some SCSI
516 controllers, bluetooth adaptors, or TV recorders. The same principles
517 apply.</para>
518
519 </sect2>
520
521</sect1>
Note: See TracBrowser for help on using the repository browser.