📜 ⬆️ ⬇️

Opensource development on the example of the implementation of the IEEE802.11s standard mesh network support for the Nokia N810 Internet Tablet

The article describes the personal experience of implementing a small opensource project and the issues that arose during the course.

I was at the Open Source Linux Lab meeting in the fall of 2008, at which I had the idea to implement IEEE802.11s support for the Nokia N810. Sounded like one of the insane suggestions about what can be done with this wonderful device.

It happened a bit later after Nokia published the GPL code for the stlc45xx driver, which is able to control the wi-fi adapter built into the N810 and organized the stlc45xx.garage.maemo.org project.

Interestingly, Nokia itself has not released firmware with an updated kernel or network driver in the past six months.
Why - this is the first unanswered question.
')
At first glance, the problem, as it seemed to me, for an experienced administrator is the assembly of the correct kernel, the assembly stlc45xx, the launch setup. But no, it turned out, stlc45xx supports only the work in the client mode wi-fi access point. With the correct core, too, it turned out not to be simple. The README from stlc45xx referred to a linux-omap branch specific to TI OMAP 2420 processors on which the N800 and N810 are built. But over time, stlc45xx began to noticeably deviate in its requirements for the mac80211 library from what linux-omap provides. Kalle Valo, the main developer of stlc45xx, explained this by saying that he needed changes appearing in the linux-wireless branch. For which he periodically combines the heads of linux-omap and linux-wireless. And linux-wireless has a mailing list, which receives about 1,000 messages per month, of which about a third are patches. The task, simple at first glance, began to resemble shooting at a mobile target.

I will not describe the details of the fights with the technical part of the driver, I will list only the main questions and answers that have arisen.
The first question is, of course, what is a mesh? How does it relate to other modes of operation of IEEE802.11 networks? What is required of the driver to support it?

It seemed that, in spite of the frequent mentioning of the term, few people are familiar with the technical side of the matter. The draft standard was not available to our group for several months. And this is despite the fact that the project during this time was registered at FRUCT and we turned to Nokia for help. Much clarified existing drivers in linux with support for mesh mode, for example p54, much - the analysis of adapters for which the quality of the draft implementation is at the proper level, for example b43. But only having received a draft of the standard, we gained some confidence in our development. As a result, we implemented the ad-hoc mode as the basis for IEEE802.11s in the stlc45xx driver and sent a series of patches to the stlc45xx-devel@garage.maemo.org mailing list.

At a small step from ad-hoc to the mesh, we encountered, as it turned out, a well-known firmware feature for our wi-fi adapter — packets whose length is not a multiple of 4 are shortened to the nearest multiple of 4 lengths. However, the question about this , asked in stlc45xx-devel in January 2009, remained unanswered for more than half a month. After which Kalle Valo said that he had not heard about anything similar to our problem.

Thus, a small community at garage.maemo.org was powerless in the face of this problem.
Hence another question: why open source projects are not looking for the largest possible audience for themselves, but huddle in private forums? Is this a single mistake or a common occurrence?

Anyway, without receiving any support for testing at garage.maemo.org, we decided to try linux-wireless p54spi, which was included by that time, designed for the same wi-fi adapters. “Core,” I thought, “one step to the Linus tree.” Again, everything is not so simple. The p54spi has not yet reached the Linus tree, and no one seems to have tested it in linux-wireless. Fact: in early March 2009, the p54spi in the linux-wireless tree was not working, due to elementary typos in the code. A few patches sent to linux-wireless@vger.kernel.org solved these minor issues. It also quickly clarified the status of the mentioned firmware error. However, the more significant difficulties associated with driver instability under load, which are present both in stlc45xx and p54spi, have not yet been resolved. The reason is a lack of information, now about the functioning of the firmware. The specification of the composition of registers, the assignment of their bits and timing diagrams for the adapter stlc4560 turned out to be very difficult to find. Officially, it is not shipped. And even accidentally found unofficially, it leaves room for speculation.

Here is another question: why do some equipment manufacturers relate to their specifications? Why are they apparently not interested in the availability and quality of drivers for their products?

The result is this: on April 12, we recorded a demo video with a heterogeneous mesh network between the N810 and the OLPC XO for an OSLL presentation at the fifth FRUCT workshop , which will be held April 29-30. The p54spi patches are taken in linux-wireless. The second stage of the project is nearing completion. OSLL continues to improve the driver.

Join us, we are an open group. We have interesting projects.

I believe opensource will win. (:

Source: https://habr.com/ru/post/57497/


All Articles