docs/contributing: Rename "easy projects" to "small projects"
[coreboot.git] / Documentation / contributing / project_ideas.md
blob700373b0fe7fc672e0f25cc1eb3974ac5d5f7ab0
1 # Project Ideas
3 This section collects ideas to improve coreboot and related projects and
4 should serve as a pool of ideas for people who want to enter the field
5 of firmware development but need some guidance what to work on.
7 These tasks can be adopted as part of programs like Google Summer of
8 Code or by motivated individuals outside such programs.
10 Each entry should outline what would be done, the benefit it brings
11 to the project, the pre-requisites, both in knowledge and parts. They
12 should also list people interested in supporting people who want to work
13 on them - since we started building this list for Google Summer of Code,
14 we'll adopt its term for those people and call them mentors.
16 The requirements for each project aim for productive work on the project,
17 but it's always possible to learn them "on the job". If you have any
18 doubt if you can bring yourself up to speed in a required time frame
19 (e.g. for GSoC), feel free to ask in the community or the mentors listed
20 with the projects. We can then try together to figure out if you're a
21 good match for a project, even when requirements might not all be met.
23 ## Small projects
25 This is a collection of tasks which don't require deep knowledge on
26 coreboot itself. If you are a beginner and want to get familiar with the
27 the project and the code base, or if you just want to get your hands
28 dirty with some small tasks, then these are for you.
30   * Resolve static analysis issues reported by [scan-build] and
31     [Coverity scan]. More details on the page for
32     [Coverity scan integration].
34   * Resolve issues reported by the [linter][Linter issues]
36 [scan-build]: https://coreboot.org/scan-build/
37 [Coverity scan]: https://scan.coverity.com/projects/coreboot
38 [Coverity scan integration]: ../infrastructure/coverity.md
39 [Linter issues]: https://qa.coreboot.org/job/coreboot-untested-files/lastSuccessfulBuild/artifact/lint.txt
41 ## Provide toolchain binaries
42 Our crossgcc subproject provides a uniform compiler environment for
43 working on coreboot and related projects. Sadly, building it takes hours,
44 which is a bad experience when trying to build coreboot the first time.
46 Provide packages/installers of our compiler toolchain for Linux distros,
47 Windows, Mac OS. For Windows, this should also include the environment
48 (shell, make, ...). A student doesn't have to cover _all_ platforms, but
49 pick a set of systems that match their interest and knowledge and lay
50 out a plan on how to do this.
52 The scripts to generate these packages should be usable on a Linux
53 host, as that's what we're using for our automated build testing system
54 that we could extend to provide current packages going forward. This
55 might include automating some virtualization system (eg. QEMU or CrosVM) for
56 non-Linux builds or Docker for different Linux distributions.
58 ### Requirements
59 * coreboot knowledge: Should know how to build coreboot images and where
60   the compiler comes into play in our build system.
61 * other knowledge: Should know how packages or installers for their
62   target OS work. Knowledge of the GCC build system is a big plus
63 * hardware requirements: Nothing special
65 ### Mentors
66 * Patrick Georgi <patrick@georgi.software>
68 ## Support Power9/Power8 in coreboot
69 There are some basic PPC64 stubs in coreboot, and there's open hardware
70 in TALOS2 and its family. While they already have fully open source
71 firmware, coreboot support adds a unified story for minimal firmware
72 across architectures.
74 ### Requirements
75 * coreboot knowledge: Should be familiar with making chipset level
76   changes to the code.
77 * other knowledge: A general idea of the Power architecture, the more,
78   the better
79 * hardware requirements: QEMU Power bring-up exists, and even if it
80   probably needs to be fixed up, that shouldn't be an exceedingly large
81   task. For everything else, access to real Power8/9 hardware and recovery
82   tools (e.g. for external flashing) is required.
84 ### Mentors
85 * Timothy Pearson <tpearson@raptorengineering.com>
87 ## Port payloads to ARM, AArch64 or RISC-V
88 While we have a rather big set of payloads for x86 based platforms, all other
89 architectures are rather limited. Improve the situation by porting a payload
90 to one of the platforms, for example GRUB2, U-Boot (the UI part), edk2,
91 yabits, FILO, or Linux-as-Payload.
93 Since this is a bit of a catch-all idea, an application to GSoC should pick a
94 combination of payload and architecture to support.
96 ### Requirements
97 * coreboot knowledge: Should know the general boot flow in coreboot
98 * other knowledge: It helps to be familiar with the architecture you want to
99   work on.
100 * hardware requirements: Much of this can be done in QEMU or other emulators,
101   but the ability to test on real hardware is a plus.
103 ### Mentors
104 * Simon Glass <sjg@chromium.org> for U-Boot payload projects
106 ## Fully support building coreboot with the Clang compiler
107 Most coreboot code is written in C, and it would be useful to support
108 a second compiler suite in addition to gcc. Clang is another popular
109 compiler suite and the build system generally supports building coreboot
110 with it, but firmware is a rather special situation and we need to
111 adjust coreboot and Clang some more to get usable binaries out of that
112 combination.
114 The goal would be to get the emulation targets to boot reliably first,
115 but also to support real hardware. If you don't have hardware around,
116 you likely will find willing testers for devices they own and work from
117 their bug reports.
119 ### Requirements
120 * coreboot knowledge: Have a general concept of the build system
121 * Clang knowledge: It may be necessary to apply minor modifications to Clang
122   itself, but at least there will be Clang-specific compiler options etc to
123   adapt, so some idea how compilers work and how to modify their behavior is
124   helpful.
125 * hardware requirements: If you have your own hardware that is already
126   supported by coreboot that can be a good test target, but you will debug
127   other people's hardware, too.
128 * debugging experience: It helps if you know how to get the most out of a bug
129   report, generate theories, build patches to test them and figure out what's
130   going on from the resulting logs.
132 ### Mentors
133 * Patrick Georgi <patrick@georgi.software>
135 ## Extend Ghidra to support analysis of firmware images
136 [Ghidra](https://ghidra-sre.org) is a recently released cross-platform
137 disassembler and decompiler that is extensible through plugins. Make it
138 useful for firmware related work: Automatically parse formats (eg. by
139 integrating UEFITool, cbfstool, decompressors), automatically identify
140 16/32/64bit code on x86/amd64, etc.
142 This has been done in 2019 with [some neat
143 features](https://github.com/al3xtjames/ghidra-firmware-utils) being
144 developed, but it may be possible to expand support for all kinds of firmware
145 analyses.
147 ## Learn hardware behavior from I/O and memory access logs
148 [SerialICE](https://www.serialice.com) is a tool to trace the behavior of
149 executable code like firmware images. One result of that is a long log file
150 containing the accesses to hardware resources.
152 It would be useful to have a tool that assists a developer-analyst in deriving
153 knowledge about hardware from such logs. This likely can't be entirely
154 automatic, but a tool that finds patterns and can propagate them across the
155 log (incrementially raising the log from plain I/O accesses to a high-level
156 description of driver behavior) would be of great use.
158 This is a research-heavy project.
160 ### Requirements
161 * Driver knowledge: Somebody working on this should be familiar with
162   how hardware works (eg. MMIO based register access, index/data port
163   accesses) and how to read data sheets.
164 * Machine Learning: ML techniques may be useful to find structure in traces.
166 ### Mentors
167 * Ron Minnich <rminnich@google.com>
169 ## Libpayload based memtest payload
170 [Memtest86+](https://www.memtest.org/) has some limitations: first and
171 foremost it only works on x86, while it can print to serial console the
172 GUI only works in legacy VGA mode.
174 This project would involve porting the memtest suite to libpayload and
175 build a payload around it.
177 ### Requirements
178 * coreboot knowledge: Should know how to build coreboot images and
179   include payloads.
180 * other knowledge: Knowledge on how dram works is a plus.
181 * hardware requirements: Initial work can happen on qemu targets,
182   being able to test on coreboot supported hardware is a plus.
184 ### Mentors
185 * TODO
187 ## Fix POST code handling
188 coreboot supports writing POST codes to I/O port 80.
189 There are various Kconfigs that deal with POST codes, which don't have
190 effect on most platforms.
191 The code to send POST codes is scattered in C and Assembly, some use
192 functions, some use macros and others simply use the `outb` instruction.
193 The POST codes are duplicated between stages and aren't documented properly.
196 Tasks:
197 * Guard Kconfigs with a *depends on* to only show on supported platforms
198 * Remove duplicated Kconfigs
199 * Replace `outb(0x80, ...)` with calls to `post_code(...)`
200 * Update Documentation/POSTCODES
201 * Use defines from console/post_codes.h where possible
202 * Drop duplicated POST codes
203 * Make use of all possible 255 values
205 ### Requirements
206 * knowledge in the coreboot build system and the concept of stages
207 * other knowledge: Little experience with C and x86 Assembly
208 * hardware requirements: Nothing special
210 ### Mentors
211 * Patrick Rudolph <patrick.rudolph@9elements.com>
212 * Christian Walter <christian.walter@9elements.com>
214 ## Board status replacement
215 The [Board status page](https://coreboot.org/status/board-status.html) allows
216 to see last working commit of a board. The page is generated by a cron job
217 that runs on a huge git repository.
219 Build an open source replacement written in Golang using existing tools
220 and libraries, consisting of a backend, a frontend and client side
221 scripts. The backend should connect to an SQL database with can be
222 controlled using a RESTful API. The RESTful API should have basic authentication
223 for management tasks and new board status uploads.
225 At least one older test result should be kept in the database.
227 The frontend should use established UI libraries or frameworks (for example
228 Angular) to display the current board status, that is if it's working or not
229 and some details provided with the last test. If a board isn't working the last
230 working commit (if any) should be shown in addition to the broken one.
232 Provide a script/tool that allows to:
233 1. Push mainboard details from coreboot master CI
234 2. Push mainboard test results from authenticated users containing
235    * working
236    * commit hash
237    * bootlog (if any)
238    * dmesg (if it's booting)
239    * timestamps (if it's booting)
240    * coreboot config
242 ### Requirements
243 * coreboot knowledge: Non-technical, needed to perform requirements analysis
244 * software knowledge: Golang, SQL for the backend, JS for the frontend
246 ### Mentors
247 * Patrick Rudolph <patrick.rudolph@9elements.com>
248 * Christian Walter <christian.walter@9elements.com>