diff options
Diffstat (limited to 'README')
-rw-r--r-- | README | 432 |
1 files changed, 0 insertions, 432 deletions
diff --git a/README b/README deleted file mode 100644 index fef16673..00000000 --- a/README +++ /dev/null | |||
@@ -1,432 +0,0 @@ | |||
1 | meta-intel | ||
2 | ========== | ||
3 | |||
4 | This README file contains information on building and booting | ||
5 | meta-intel BSP layers. Please see the corresponding sections below | ||
6 | for details. | ||
7 | |||
8 | |||
9 | Yocto Project Compatible | ||
10 | ======================== | ||
11 | |||
12 | The BSPs contained in this layer are compatible with the Yocto Project | ||
13 | as per the requirements listed here: | ||
14 | |||
15 | https://www.yoctoproject.org/webform/yocto-project-compatible-registration | ||
16 | |||
17 | |||
18 | Dependencies | ||
19 | ============ | ||
20 | |||
21 | This layer depends on: | ||
22 | |||
23 | URI: git://git.openembedded.org/bitbake | ||
24 | |||
25 | URI: git://git.openembedded.org/openembedded-core | ||
26 | layers: meta | ||
27 | branch: master | ||
28 | |||
29 | |||
30 | Table of Contents | ||
31 | ================= | ||
32 | |||
33 | I. Overview | ||
34 | II. Building and booting meta-intel BSP layers | ||
35 | a. Building the intel-common BSP layers | ||
36 | b. Booting the intel-common BSP images | ||
37 | III. Technical Miscellany | ||
38 | Benefits of using meta-intel | ||
39 | The intel-common kernel package architecture | ||
40 | Intel-specific machine features | ||
41 | IV. Tested Hardware | ||
42 | V. Guidelines for submitting patches | ||
43 | |||
44 | |||
45 | I. Overview | ||
46 | =========== | ||
47 | |||
48 | This is the location for Intel-maintained BSPs. | ||
49 | |||
50 | For details on the intel-common, see the information below. | ||
51 | |||
52 | For all others, please see the README files contained in the | ||
53 | individual BSP layers for BSP-specific information. | ||
54 | |||
55 | If you have problems with or questions about a particular BSP, please | ||
56 | contact the maintainer listed in the MAINTAINERS file directly (cc:ing | ||
57 | the Yocto mailing list puts it in the archive and helps other people | ||
58 | who might have the same questions in the future), but please try to do | ||
59 | the following first: | ||
60 | |||
61 | - look in the Yocto Project Bugzilla | ||
62 | (http://bugzilla.yoctoproject.org/) to see if a problem has | ||
63 | already been reported | ||
64 | |||
65 | - look through recent entries of the meta-intel | ||
66 | (https://lists.yoctoproject.org/pipermail/meta-intel/) and Yocto | ||
67 | (https://lists.yoctoproject.org/pipermail/yocto/) mailing list | ||
68 | archives to see if other people have run into similar problems or | ||
69 | had similar questions answered. | ||
70 | |||
71 | If you believe you have encountered a bug, you can open a new bug and | ||
72 | enter the details in the Yocto Project Bugzilla | ||
73 | (http://bugzilla.yoctoproject.org/). If you're relatively certain | ||
74 | that it's a bug against the BSP itself, please use the 'Yocto Project | ||
75 | Components: BSPs | meta-intel' category for the bug; otherwise, please | ||
76 | submit the bug against the most likely category for the problem - if | ||
77 | you're wrong, it's not a big deal and the bug will be recategorized | ||
78 | upon triage. | ||
79 | |||
80 | |||
81 | II. Building and booting meta-intel BSP layers | ||
82 | ============================================== | ||
83 | |||
84 | The following sections contain information on building and booting the | ||
85 | BSPs contained in the meta-intel layer. | ||
86 | |||
87 | Note that these instructions specifically cover the intel-common, which | ||
88 | may or may not be applicable to other BSPs contained in this layer - if | ||
89 | a given BSP contains its own README, that version should be used instead, | ||
90 | and these instructions can be ignored. | ||
91 | |||
92 | a. Building the intel-common BSP layers | ||
93 | ------------------------------------------------- | ||
94 | |||
95 | In order to build an image with BSP support for a given release, you | ||
96 | need to download the corresponding BSP tarball from the 'Board Support | ||
97 | Package (BSP) Downloads' page of the Yocto Project website (or | ||
98 | equivalently, check out the appropriate branch from the meta-intel git | ||
99 | repository, see below). For the intel-common BSPs, those tarballs would | ||
100 | correspond to the following choices in the BSP downloads section: | ||
101 | |||
102 | - Intel-core2-32 IntelĀ® Common Core BSP (Intel-core2-32) | ||
103 | - Intel-corei7-64 IntelĀ® Common Core BSP (Intel-corei7-64) | ||
104 | |||
105 | The intel-* BSPs, also known as the intel-common BSPs, provide a few | ||
106 | carefully selected tune options and generic hardware support to cover | ||
107 | the majority of current Intel CPUs and devices. The naming follows the | ||
108 | convention of intel-<TUNE>-<BITS>, where TUNE is the gcc cpu-type | ||
109 | (used with mtune and march typically) and BITS is either 32 bit or 64 | ||
110 | bit. | ||
111 | |||
112 | Having done that, and assuming you extracted the BSP tarball contents | ||
113 | at the top-level of your yocto build tree, you can build a BSP image | ||
114 | by adding the location of the meta-intel layer to bblayers.conf e.g.: | ||
115 | |||
116 | yocto/meta-intel \ | ||
117 | |||
118 | To enable a particular machine, you need to add a MACHINE line naming | ||
119 | the BSP to the local.conf file: | ||
120 | |||
121 | MACHINE ?= "xxx" | ||
122 | |||
123 | where 'xxx' is replaced by one of the following BSP names: | ||
124 | |||
125 | - intel-core2-32 | ||
126 | |||
127 | This BSP is optimized for the Core2 family of CPUs as well as all | ||
128 | Atom CPUs prior to the Silvermont core. | ||
129 | |||
130 | - intel-corei7-64 | ||
131 | |||
132 | This BSP is optimized for Nehalem and later Core and Xeon CPUs as | ||
133 | well as Silvermont and later Atom CPUs, such as the Baytrail SoCs. | ||
134 | |||
135 | You should then be able to build an image as such: | ||
136 | |||
137 | $ source oe-init-build-env | ||
138 | $ bitbake core-image-sato | ||
139 | |||
140 | At the end of a successful build, you should have an image that | ||
141 | you can boot from a USB flash drive (see instructions on how to do | ||
142 | that below, in the section 'Booting the intel-common BSP images'). | ||
143 | |||
144 | As an alternative to downloading the BSP tarball, you can also work | ||
145 | directly from the meta-intel git repository. For each BSP in the | ||
146 | 'meta-intel' repository, there are multiple branches, one | ||
147 | corresponding to each major release starting with 'laverne' (0.90), in | ||
148 | addition to the latest code which tracks the current master (note that | ||
149 | not all BSPs are present in every release). Instead of extracting | ||
150 | a BSP tarball at the top level of your yocto build tree, you can | ||
151 | equivalently check out the appropriate branch from the meta-intel | ||
152 | repository at the same location. | ||
153 | |||
154 | b. Booting the intel-common BSP images | ||
155 | -------------------------------------- | ||
156 | |||
157 | If you've built your own image, either from the downloaded BSP layer | ||
158 | or from the meta-intel git repository, you'll find the bootable | ||
159 | image in the build/tmp/deploy/images/xxx directory, where again | ||
160 | 'xxx' refers to the machine name used in the build. | ||
161 | |||
162 | Under Linux, insert a USB flash drive. Assuming the USB flash drive | ||
163 | takes device /dev/sdf, use dd to copy the image to it. Before the image | ||
164 | can be burned onto a USB drive, it should be un-mounted. Some Linux distros | ||
165 | may automatically mount a USB drive when it is plugged in. Using USB device | ||
166 | /dev/sdf as an example, find all mounted partitions: | ||
167 | |||
168 | $ mount | grep sdf | ||
169 | |||
170 | and un-mount those that are mounted, for example: | ||
171 | |||
172 | $ umount /dev/sdf1 | ||
173 | $ umount /dev/sdf2 | ||
174 | |||
175 | Now burn the image onto the USB drive: | ||
176 | |||
177 | $ sudo dd if=core-image-sato-intel-corei7-64.wic of=/dev/sdf status=progress | ||
178 | $ sync | ||
179 | $ eject /dev/sdf | ||
180 | |||
181 | This should give you a bootable USB flash device. Insert the device | ||
182 | into a bootable USB socket on the target, and power on. This should | ||
183 | result in a system booted to the Sato graphical desktop. | ||
184 | |||
185 | If you want a terminal, use the arrows at the top of the UI to move to | ||
186 | different pages of available applications, one of which is named | ||
187 | 'Terminal'. Clicking that should give you a root terminal. | ||
188 | |||
189 | If you want to ssh into the system, you can use the root terminal to | ||
190 | ifconfig the IP address and use that to ssh in. The root password is | ||
191 | empty, so to log in type 'root' for the user name and hit 'Enter' at | ||
192 | the Password prompt: and you should be in. | ||
193 | |||
194 | If you find you're getting corrupt images on the USB (it doesn't show | ||
195 | the syslinux boot: prompt, or the boot: prompt contains strange | ||
196 | characters), try doing this first: | ||
197 | |||
198 | $ dd if=/dev/zero of=/dev/sdf bs=1M count=512 | ||
199 | |||
200 | III. Technical Miscellany | ||
201 | ========================= | ||
202 | |||
203 | Benefits of using meta-intel | ||
204 | ---------------------------- | ||
205 | |||
206 | Using meta-intel has the following benefits over a generic BSP: | ||
207 | |||
208 | tune flags | ||
209 | ++++++++++ | ||
210 | intel-* MACHINEs each have different compilation flags appropriate for their | ||
211 | targeted hardware sets. intel-corei7-64 has tune flags appropriate for modern | ||
212 | 64-bit Intel Core i microarchitecture, and includes instruction sets up to | ||
213 | SSE4.2. intel-core2-32 has tune flags appropriate for legacy 32-bit Intel Core2 | ||
214 | microarchitecture, and includes instruction sets up to SSE3. | ||
215 | |||
216 | linux-intel kernel | ||
217 | ++++++++++++++++++ | ||
218 | The linux-intel kernel is an initiative to bring better Intel(R) hardware | ||
219 | support to the current LTS linux kernel. It contains a base LTS kernel with | ||
220 | additional backports from upstream Intel drivers. In addition, a default kernel | ||
221 | config containing most features found on Intel boards is supplied via the | ||
222 | yocto-kernel-cache. | ||
223 | |||
224 | graphics stack | ||
225 | ++++++++++++++ | ||
226 | Meta-intel provides the latest Intel Graphics Linux Stack drivers to support | ||
227 | Intel hardware as defined by the https://01.org/linuxgraphics. | ||
228 | |||
229 | Other software | ||
230 | ++++++++++++++ | ||
231 | * intel ucode - provides the latest microcode updates for Intel processors | ||
232 | |||
233 | * thermald - which proactively controls thermal, using P-states, T-states, and | ||
234 | the Intel power clamp driver. | ||
235 | (https://01.org/linux-thermal-daemon/documentation/introduction-thermal-daemon) | ||
236 | |||
237 | The intel-common kernel package architecture | ||
238 | -------------------------------------------- | ||
239 | |||
240 | These BSPs use what we call the intel-common Linux kernel package | ||
241 | architecture. This includes core2-32-intel-common and | ||
242 | corei7-64-intel-common. These kernel packages can also be used by any | ||
243 | of the BSPs in meta-intel that choose to include the | ||
244 | intel-common-pkgarch.inc file. | ||
245 | |||
246 | To minimize the proliferation of vendor trees, reduce the sources we | ||
247 | must support, and consolidate QA efforts, all BSP maintainers are | ||
248 | encouraged to make use of the intel-common Linux kernel package | ||
249 | architecture. | ||
250 | |||
251 | Intel-specific machine features | ||
252 | ------------------------------- | ||
253 | |||
254 | The meta-intel layer makes some additional machine features available | ||
255 | to BSPs. These machine features can be used in a BSP layer in the | ||
256 | same way that machine features are used in other layers based on | ||
257 | oe-core, via the MACHINE_FEATURES variable. | ||
258 | |||
259 | Requirements | ||
260 | ++++++++++++ | ||
261 | |||
262 | The meta-intel-specific machine features are only available to a BSP | ||
263 | when the meta-intel layer is included in the build configuration, and | ||
264 | the meta-intel.inc file is included in the machine configuration of | ||
265 | that BSP. | ||
266 | |||
267 | To make these features available for your machine, you will need to: | ||
268 | |||
269 | 1. include a configuration line such as the below in bblayers.conf | ||
270 | BBLAYERS += "<local path>/meta-intel" | ||
271 | 2. include the following line in the machine configuration file | ||
272 | require conf/machine/include/meta-intel.inc | ||
273 | |||
274 | Once the above requirements are met, the machine features provided by | ||
275 | the meta-intel layer will be available for the BSP to use. | ||
276 | |||
277 | Available machine features | ||
278 | ++++++++++++++++++++++++++ | ||
279 | |||
280 | Currently, the meta-intel layer makes the following set of | ||
281 | Intel-specific machine features available: | ||
282 | |||
283 | * intel-ucode | ||
284 | |||
285 | These machine features can be included by listing them in the | ||
286 | MACHINE_FEATURES variable in the machine configuration file. For | ||
287 | example: | ||
288 | |||
289 | MACHINE_FEATURES += "intel-ucode" | ||
290 | |||
291 | Machine feature details | ||
292 | +++++++++++++++++++++++ | ||
293 | |||
294 | * intel-ucode | ||
295 | |||
296 | This feature provides support for microcode updates to Intel | ||
297 | processors. The intel-ucode feature runs at early boot and uses | ||
298 | the microcode data file added by the feature into the BSP's | ||
299 | initrd. It also puts the userland microcode-updating tool, | ||
300 | iucode_tool, into the target images along with the microcode data | ||
301 | file. | ||
302 | |||
303 | Q. Why might a user want to enable the intel-ucode feature? | ||
304 | |||
305 | A. Intel releases microcode updates to correct processor behavior | ||
306 | as documented in the respective processor specification | ||
307 | updates. While the normal approach to getting such microcode | ||
308 | updates is via a BIOS upgrade, this can be an administrative | ||
309 | hassle and not always possible in the field. The intel-ucode | ||
310 | feature enables the microcode update capability present in the | ||
311 | Linux kernel. It provides an easy path for upgrading processor | ||
312 | microcode without the need to change the BIOS. If the feature | ||
313 | is enabled, it is also possible to update the existing target | ||
314 | images with a newer microcode update in the future. | ||
315 | |||
316 | Q. How would a user bundle only target-specific microcode in the | ||
317 | target image? | ||
318 | |||
319 | A. The Intel microcode data file released by Intel contains | ||
320 | microcode updates for multiple processors. If the BSP image is | ||
321 | meant to run on only a certain subset of processor types, a | ||
322 | processor-specific subset of microcode can be bundled into the | ||
323 | target image via the UCODE_FILTER_PARAMETERS variable. This | ||
324 | works by listing a sequence of iucode-tool parameters in the | ||
325 | UCODE_FILTER_PARAMETERS variable, which in this case will | ||
326 | select only the specific microcode relevant to the BSP. For | ||
327 | more information on the underlying parameters refer to the | ||
328 | iucode-tool manual page at http://manned.org/iucode-tool | ||
329 | |||
330 | To define a set of parameters for microcode-filtering via the | ||
331 | UCODE_FILTER_PARAMETERS variable, one needs to identify the | ||
332 | cpuid signatures of all the processors the BSP is meant to run | ||
333 | on. One way to determine the cpuid signature for a specific | ||
334 | processor is to build and run an intel-ucode-feature-enabled | ||
335 | image on the target hardware, without first assigning any value | ||
336 | to the UCODE_FILTER_PARAMETERS variable, and then once the | ||
337 | image is booted, run the "ucode_tool -S" command to have the | ||
338 | ucode tool scan the system for processor signatures. These | ||
339 | signatures can then be used in the UCODE_FILTER_PARAMETERS | ||
340 | variable in conjunction with -s parameter. For example, for | ||
341 | the fri2 BSP, the cpuid can be determined as such: | ||
342 | |||
343 | [root@fri2 ~]# iucode_tool -S | ||
344 | iucode_tool: system has processor(s) with signature 0x00020661 | ||
345 | |||
346 | Given that output, a suitable UCODE_FILTER_PARAMETERS variable | ||
347 | definition could be specified in the machine configuration as | ||
348 | such: | ||
349 | |||
350 | UCODE_FILTER_PARAMETERS = "-s 0x00020661" | ||
351 | |||
352 | Q. Are there any reasons a user might want to disable the | ||
353 | intel-ucode feature? | ||
354 | |||
355 | A. The microcode data file and associated tools occupy a small | ||
356 | amount of space (a few KB) on the target image. BSPs which are | ||
357 | highly sensitive to target image size and which are not | ||
358 | experiencing microcode-related issues might consider not | ||
359 | enabling this feature. | ||
360 | |||
361 | |||
362 | IV. Tested Hardware | ||
363 | =================== | ||
364 | |||
365 | The following undergo regular basic testing with their respective MACHINE types. | ||
366 | Note that both 64-bit and 32-bit firmware is available for the MinnowBoard | ||
367 | Turbot, so it is tested against both intel-corei7-64 and intel-core2-32. | ||
368 | |||
369 | intel-corei7-64: | ||
370 | NUC6i5SYH | ||
371 | NUC7i7BNH | ||
372 | Coffee Lake-H | ||
373 | |||
374 | intel-core2-32: | ||
375 | MinnowBoard Turbot | ||
376 | |||
377 | |||
378 | V. Guidelines for submitting patches | ||
379 | ==================================== | ||
380 | |||
381 | Please submit any patches against meta-intel BSPs to the meta-intel | ||
382 | mailing list (meta-intel@yoctoproject.org). Also, if your patches are | ||
383 | available via a public git repository, please also include a URL to | ||
384 | the repo and branch containing your patches as that makes it easier | ||
385 | for maintainers to grab and test your patches. | ||
386 | |||
387 | There are patch submission scripts available that will, among other | ||
388 | things, automatically include the repo URL and branch as mentioned. | ||
389 | Please see the Yocto Project Development Manual sections entitled | ||
390 | 'Using Scripts to Push a Change Upstream and Request a Pull' and | ||
391 | 'Using Email to Submit a Patch' for details. | ||
392 | |||
393 | Regardless of how you submit a patch or patchset, the patches should | ||
394 | at minimum follow the suggestions outlined in the 'Submitting a Change | ||
395 | to the Yocto Project' section in the Yocto Project Development Manual. | ||
396 | Specifically, they should: | ||
397 | |||
398 | - Include a 'Signed-off-by:' line. A commit can't legally be pulled | ||
399 | in without this. | ||
400 | |||
401 | - Provide a single-line, short summary of the change. This short | ||
402 | description should be prefixed by the BSP or recipe name, as | ||
403 | appropriate, followed by a colon. Capitalize the first character | ||
404 | of the summary (following the colon). | ||
405 | |||
406 | - For the body of the commit message, provide detailed information | ||
407 | that describes what you changed, why you made the change, and the | ||
408 | approach you used. | ||
409 | |||
410 | - If the change addresses a specific bug or issue that is associated | ||
411 | with a bug-tracking ID, include a reference to that ID in your | ||
412 | detailed description in the following format: [YOCTO #<bug-id>]. | ||
413 | |||
414 | - Pay attention to line length - please don't allow any particular | ||
415 | line in the commit message to stretch past 72 characters. | ||
416 | |||
417 | - For any non-trivial patch, provide information about how you | ||
418 | tested the patch, and for any non-trivial or non-obvious testing | ||
419 | setup, provide details of that setup. | ||
420 | |||
421 | Doing a quick 'git log' in meta-intel will provide you with many | ||
422 | examples of good example commits if you have questions about any | ||
423 | aspect of the preferred format. | ||
424 | |||
425 | The meta-intel maintainers will do their best to review and/or pull in | ||
426 | a patch or patchset within 24 hours of the time it was posted. For | ||
427 | larger and/or more involved patches and patchsets, the review process | ||
428 | may take longer. | ||
429 | |||
430 | Please see the meta-intel/MAINTAINERS file for the list of maintainers | ||
431 | and their specific areas; it's also a good idea to cc: the specific | ||
432 | maintainer, if applicable. | ||