xref: /aosp_15_r20/external/coreboot/Documentation/releases/checklist.md (revision b9411a12aaaa7e1e6a6fb7c5e057f44ee179a49c)
1```{eval-rst}
2:orphan:
3```
4
5# coreboot Release Process
6
7This document describes our release process and all prerequisites to
8implement it successfully.
9
10
11## Purpose of coreboot releases
12Our releases aren't primarily a vehicle for code that is stable across
13all boards: The logistics of testing the more than 100 boards that are
14spread out all continents (except Antarctica, probably) on a given tree
15state are prohibitive for project of our size.
16
17Instead, the releases are regular breakpoints that serve multiple
18purposes: They support cooperation between multiple groups (corporations
19or otherwise) in that it's easier to keep source trees synchronized
20based on a limited set of commits. They allow a quick assessment of the
21age of any given build or source tree based on its git version (4.8-1234
22was merged into master a few months after 4.8, which came out in April
23of 2018. 4.0-21718's age is harder to guess).
24
25And finally we use releases to as points in time where we remove old
26code: Once we decide that a certain part of coreboot gets in the way of
27future development, we announce on the next release that we intend to
28remove that part - and everything that depends on it - after the
29following release. So removing feature FOO will be announced in release
30X for release X+1. The first commit after X+1 is fair game for such
31removal.
32
33Together with our 3 months release horizon, this provides time to plan
34any migrations necessary to keep older boards in the tree by bringing
35them up to current standards.
36
37## coreboot release team
38To avoid issues of blocking the release on a single person, a release
39team has been formed. Please see the `COREBOOT RELEASES` section of the
40MAINTAINERS file for the current members.
41
42These individuals work together to make sure releases are done on time,
43follow the steps of this document, and update the release processes and
44scripts.
45
46
47## Needed credentials & authorizations
48
49### coreboot admins only
50* Website access is required to post the release files to the website.
51
52### All release team members
53* IRC topic access is required to update the topic.
54* Git access rights are needed to post the tag.
55* Blog post access is needed to do the blog post.
56* A PGP key is required to sign the release tarballs and git tag.
57
58Most of the steps in the release process can be done by anyone on the
59release team. Only adding the files to the website needs to be done
60by a coreboot administrator.
61
62## When to release
63Releases are done roughly on a 3-month schedule. If a release is
64delayed, the next release will still be 3 months after the last release.
65
66
67## Checklist
68
69### ~2 weeks prior to release
70- [ ] Announce upcoming release to mailing list, ask people to test and
71      to update release notes.
72- [ ] Start marking patches that should to go into the release with a
73      tag "coreboot_release_X.yy"
74
75### ~1 week prior to release
76- [ ] Send reminder email to mailing list, ask for people to test,
77      and to update the release notes.
78- [ ] Update the topic in the IRC channel with the date of the upcoming
79      release.
80- [ ] If there are any deprecations announced for the following release,
81      make sure that a list of currently affected boards and chipsets is
82      part of the release notes.
83- [ ] Finalize release notes as much as possible
84- [ ] Prepare release notes template for following release
85- [ ] Update `Documentation/releases/index.md`
86- [ ] Check which branches need to be released. Any branch with changes
87      should get a new release. Announce these branch releases and
88      prepare release notes.
89
90### Day before release
91- [ ] Make sure patches with tags for the release are merged.
92- [ ] Announce to IRC that the release will be tomorrow and ask for
93      testing.
94- [ ] Run `util/vboot_list/vboot_list.sh` script to update the list of
95      boards supported by vboot.
96
97### Day of release
98- [ ] Review the full documentation about doing the release below.
99- [ ] Select a commit ID to base the release upon.
100- [ ] Test the commit selected for release.
101- [ ] Submit last pre-release release notes.
102- [ ] Run the release script.
103- [ ] Test the release from the actual release tarballs.
104- [ ] Push signed Tag to repo. *This is the actual release step.*
105      Once this patch is pushed, the release itself has been done.
106      everything after this step is packaging and delivering the
107      release.
108
109- [ ] Announce that the release tag is done on IRC.
110- [ ] Update the topic in the IRC channel that the release is done.
111
112- [ ] Do the final release notes - Fill in the release date, remove
113      "Upcoming release" and other filler from the current release
114      notes.
115- [ ] ADMIN: Upload release files to web server.
116- [ ] ADMIN: Upload the final release notes to the web server.
117- [ ] ADMIN: Upload crossgcc sources to web server.
118- [ ] Create coreboot-sdk and coreboot-jenkins-node docker images
119      based on the release ID and push them to dockerhub. These
120      can be used as release builders.
121
122### Week following the release
123- [ ] Update download page to point to files, push to repo.
124- [ ] Write and publish blog post with release final notes. Branch
125      releases notes should be included in the same post.
126- [ ] Remove code that was announced it was going to be removed.
127- [ ] Update `Documentation/releases/boards_supported_on_branches.md`
128
129### Creating a branch
130- [ ] Branches are named 4.xx_branch to differentiate from the tags.
131      Instructions on creating branches are listed below.
132
133
134## Pre-Release tasks
135Announce the upcoming release to the mailing list release 2 weeks ahead
136of the planned release date.
137
138The announcement should state the planned release date, point to the
139release notes that are in the making and ask people to test the hardware
140they have to make sure it's working with the current master branch,
141from which the release will ultimately be derived from.
142
143People should be encouraged to provide additions to the release notes.
144
145The final release notes will reside in coreboot's Documentation/releases
146directory, so asking for additions to that through the regular Gerrit
147process works as well. Note that git requires lots of conflict
148resolution on heavily edited text files though.
149
150Frequently, we will want to wait until particular things are in the
151release. Once those are in, you can select the commit ID that you want
152to use for your release. For the 4.6 release, we waited until we had
153time to do the release, then pulled in a few patches that we wanted
154to have in the release. The release was based on the final of those
155patches to be pulled in.
156
157When a release candidate has been selected, announce the commit ID to
158the #coreboot IRC channel, and request that it get some testing, just
159to make sure that everything is sane.
160
161
162## Generate the release
163After the commit for the release has been selected and verified, run the
164release script - util/release/build-release. This will download a new
165tree, checkout the commit that you specified, download the submodules,
166create a tag, then generate and sign the tarballs.
167
168**Be prepared to type in your PGP key’s passphrase.**
169
170```text
171usage: util/release/build-release <version> [commit id] [username] [gpg key id]
172Tags a new coreboot version and creates a tar archive
173
174version:    New version name to tag the tree with
175commit id:  check out this commit-id after cloning the coreboot tree
176username:   clone the tree using ssh://USERNAME - defaults to https://
177gpg key id: used to tag the version, and generate a gpg signature
178```
179
180After running the script, you should have a new directory for the
181release, along with 4 files: 2 tarballs, and 2 signature files.
182
183```text
184drwxr-xr-x   9 martin martin      4096 Apr 30 19:57 coreboot-4.6
185-rw-r--r--   1 martin martin  29156788 Apr 30 19:58 coreboot-4.6.tar.xz
186-rw-r--r--   1 martin martin       836 Apr 30 19:58 coreboot-4.6.tar.xz.sig
187-rw-r--r--   1 martin martin   5902076 Apr 30 19:58 coreboot-blobs-4.6.tar.xz
188-rw-r--r--   1 martin martin       836 Apr 30 19:58 coreboot-blobs-4.6.tar.xz.sig
189```
190
191Here’s the command that was used to generate the 4.6 release:
192```bash
193util/release/build-release 4.6 db508565 Gaumless 3E4F7DF7
194```
195
196
197## Test the release from the tarballs
198* Run “make what-jenkins-does” and verify that everything is building.
199* Build and test qemu
200```bash
201cp configs/config.emulation_qemu_x86_i440fx .config
202make olddefconfig
203make
204qemu-system-x86_64 -bios build/coreboot.rom -serial stdio
205```
206* Build and test any other platforms you can.
207* Compare the directory from the tarballs to the coreboot repo to make
208  sure nothing went wrong.
209* Push the tag to git
210
211A good tag will look like this:
212````text
213% git show 4.6
214tag 4.6
215Tagger: Martin Roth <[email protected]>
216Date:   Sun Apr 30 19:48:38 2017 -0600
217
218coreboot version 4.6
219-----BEGIN PGP SIGNATURE-----
220Version: GnuPG v1
221
222iQIcBAABCQAGBQJZBpP2AAoJEBl5bCs+T333xfgQAKhilfDTzqlr3MLJC4VChbmr
223...
224678e0NzyWsyqU1Vx2rdFdLANx6hghH1R7E5ybzHHUQrhb55BoEsnQMU1oS0npnT4
225dwfLho1afk0ZLPUU1JFW
226=25y8
227-----END PGP SIGNATURE-----
228
229commit db508565d2483394b709654c57533e55eebace51 (HEAD, tag: 4.6, origin/master, origin/HEAD)
230...
231````
232
233When you used the script to generate the release, a signed tag was
234generated in the tree that was downloaded. From the coreboot-X.Y tree,
235just run: `git push origin X.Y`. In case you pushed the wrong tag
236already, you have to force push the new one.
237
238You will need write access for tags to the coreboot git repo to do this.
239
240
241## After the release is tagged in git
242Announce that the release has been tagged - this lets people know that
243they should update their trees to grab the new tag. Until they do this,
244the version number in build.h will still be based on the previous tag.
245
246Copy the tarballs and .sig files generated by the script to
247the coreboot server, and put them in the release directory at
248`/srv/docker/www.coreboot.org-staticfiles/releases/`
249
250````bash
251# Update the sha256sum file
252sha256sum -b coreboot-*.tar.xz > sha256suma.txt
253
254# make sure the two new files are present (and nothing else has changed)
255diff sha256sum.txt sha256suma.txt
256
257mv sha256suma.txt sha256sum.txt
258````
259
260People can now see the release tarballs on the website at
261<https://www.coreboot.org/releases/>
262
263The downloads page is the official place to download the releases from,
264and it needs to be updated with links to the new release tarballs and
265.sig files. It can be found at:
266<https://review.coreboot.org/cgit/homepage.git/tree/downloads.html>
267
268Here is an example commit to change it:
269<https://review.coreboot.org/c/homepage/+/19515>
270
271
272## Upload crossgcc sources
273Sometimes the source files for older revisions of
274crossgcc disappear. To deal with that we maintain a mirror at
275<https://www.coreboot.org/releases/crossgcc-sources/> where we host the
276sources used by the crossgcc scripts that are part of coreboot releases.
277
278Run
279
280````bash
281util/crossgcc/buildgcc -u
282````
283
284This will output the set of URLs that the script uses to download the
285sources. Download them yourself and copy them into the crossgcc-sources
286directory on the server.
287
288
289## After the release is complete
290Post the final release notes on <https://blogs.coreboot.org>
291
292
293## Making a branch
294At times we will need to create a branch, generally for patch fixes.
295When making a branch, do NOT name it the same as the release tag: X.Y -
296this creates trouble when trying to check it out, as git can’t tell
297whether you want the tag or the branch. Instead, name it X.Y\_branch:
298```bash
299git checkout 4.8
300git checkout -b 4.8_branch
301git push origin 4.8_branch
302```
303
304You can then cherry-pick changes and push them up to the branch:
305````bash
306git cherry-pick c6d134988c856d0025153fb885045d995bc8c397
307git push origin HEAD:refs/for/4.8_branch
308````
309