April 2018 Development Projects Update04/30/2018
Another Successful University of Waterloo Co-op Student Term
At the end of April the Foundation’s two co-operative education (co-op) students from the University of Waterloo, Mitchell and Arshan, will conclude their work terms and head back to school. The University of Waterloo is a pioneer in co-operative education, where students divide their time between University studies and practical work placements in industry. The Waterloo model divides the year into three four-month terms, with a total of eight study terms in Engineering and Computer Science. School and work terms run year-round, including over the summer. A typical four year degree thus takes an extra eight months, but upon graduation students have a total of two years of real work experience.
Last month I wrote about one of Mitchell’s main projects, updating the FreeBSD port of the Syzkaller kernel system call fuzzing tool. Mitchell’s working on a blog post that describes his experience as a newcomer to FreeBSD development working for the FreeBSD Foundation, so stay tuned for that. This month I’ll focus on one of Arshan’s projects. Arshan has worked on a few projects over the term, including supporting the Foundation’s effort on the recent Spectre & Meltdown mitigation work by benchmarking and testing in-progress patches, and a number of other small projects and tasks. I asked him about the project he found most interesting this term.
Ed: What project really caught your attention this term?
Arshan: A week after PI day, in the staff meeting, I heard you talk about the Raspberry PI 3B+ that was newly released. You mentioned that FreeBSD doesn’t support the network chip used in the new RPi, and that we need someone to write a driver for it. That caught my attention as I was looking for some driver project to work on.
Ed: What was it that attracted you to this project?
Arshan: I was always curious to learn about the low-level details of how hardware interacts with software. Because of this, device drivers were attractive to me in general. With this particular project, I think the fact that it was related to RPi made it even more interesting for me. RPi is a popular embedded platform, and a contribution towards RPi would have a big impact on the FreeBSD community. To be honest I didn’t think I would be able to get it to a working state during the remaining days of my co-op, but thankfully and luckily, it did and I’m grateful for that.
Ed: What was the most challenging part of the driver porting effort?
Arshan: The whole process was pretty linear, I didn’t get stuck in anything for a long time that would make it tedious. I think it was mostly because FreeBSD has a pretty awesome USB and a USB to Ethernet stack that did some of the heavy lifting for me. The existing drivers on the source tree were also well documented. Reading those definitely helped a lot.
Ed: Describe your interaction with the FreeBSD community as you worked on the driver port.
Arshan: The community was really helpful. I had to contact the developer of the driver for the USB-Ethernet controller on older RPi’s on FreeBSD. Although he is no longer a committer of the project, he was still really timely on his responses. He was more than happy to help me with some of the details of the driver. People at Microchip, and the Raspberry Pi Foundation were also really helpful.
Ed: What’s the current state of the driver? What’s next?
Arshan: The patch is currently in review; with the patch users should be able to connect to the internet with their Raspberry Pi’s using an ethernet cable with no problem. However, the driver is at a pretty minimal state right now. There are several features that the chip supports such as RX/TX checksumming, VLAN tag removal, and a bunch more that are not currently enabled on the driver. I’m planning on adding support for all these features in the near future. I’m currently working on RX/TX checksumming.
Ed: Overall, how did you find the term? Any final thoughts?
Arshan: This has been my fourth work term, and the best one so far. I wish I had more time with the Foundation as I think I really got up to speed in the second half of my work term. I really liked the freedom I had here. There are so many interesting projects to work on, and lots of great resources and people to reach out to for help. I think and I hope that I remain actively involved with the FreeBSD project in the future.
— contributed by Ed Maste