My proposal how to improve the Librem 5 (for the Librem 5 team and Purism)

After digging deep in the FAQ (https://source.puri.sm/Librem5/community-wiki/-/wikis/Frequently-Asked-Questions) I realized how much roadblocks there are for creating open phone to be certified by the Free Software Foundation’s “Respects Your Freedom” certification. I wanted to give my suggestions to solve these problems for most part.

The current SoC (i.MX 8M Quad) (up to Evergreen) is extremely ultra low-end NON-MOBILE SoC made in energy inefficient 28nm node (RIP battery life).

The next gen SoC (i.MX 8M Plus) (starting from Fir) is ultra low-end mobile SoC made in energy efficient-ish 14nm node (expect much much better battery life). This SoC also contains other very crucial things, but it has significantly more crippled GPU. Forget about 3d gaming.

Keep in mind, that these SoC’s were chosen because at that time Purism hadn’t more choices. Don’t blame Purism, they were forced at the time.

But even with new gen Fir SoC there are crazy amount of problems and downsides. The SoC contains proprietary Dolby stuff and more things, that are just a dead weight on the SoC. Not to mention, that it is ultra low-end SoC which is not suitable for use with monitor and this SoC will result in premature obsolescence, because it is extremely slow. Purism is very clear in it’s policy, that it is against Planned obsolescence, and to try archive convergence between PC and phone.

What also boggles my mind is that Purism use non-replaceable (soldered on), very small internal flash storage (32gb) which is a joke. Flash memory WILL eventually die because flash storage has limited read/write cycles and it will happen much faster, because the storage is so extremely small. Once it dies, phone is not usable. Isn’t Purism against planned obsolescence? What’s the solution then? Look at this - https://store.pine64.org/product/128gb-emmc-module/ . In other words, it is very small, very compact way to connect storage. In fact, it could also be made to save space in the Librem 5, because that phone has a lot of empty space inside in some places. This will also empower the consumer to choose the storage size and upgrade if necessary in the future, extending the phone’s lifetime (aka not planned obsolescence)

My main recommendation is to built your own SoC. In that way Purism will have 100% what goes into the SoC and what don’t. The Purism should contact Sifive (or other similar company) to help them design a RISC-V SoC. Sifive offers pizza like ordering service, where you can choose what is inside your pizza and then even delivers to you the pizzas. Also, they claim to be many times lower prices and lower pizza make time and they even share some RTL code for the pizzas. Here is a video explanation from 2018 - https://www.youtube.com/watch?v=jNnCok1H3-g . Librem 5 team would be able to reduce the separate chips on the board to make a phone, which is not a brick AND even more battery life. With RISC-V it is even possible to use free and open source CPU cores from Github to have even more open phone and ensuring that there are not funny things happening in the hardware itself (like backdoors at hardware level). I remember that quite some time back Raspberry Pi team expressed a wish that they want a SoC with 100% open software and firmware, maybe Purism should partner with them to split the expenses? It would be cool if Raspberry Pi 5 would use RISC-V. Purism should do their homework and really think about this.

3 Likes

Odd, I didn’t know it had a soldered on memory chip. Maybe that goes away with Evergreen?

there is the REMOVABLE micro-SD card reader and if i’m not mistaken they are planning to make it so that at some point it could be used as boot-able storage so i’m not sure that this is a legitimate concern … perhaps for Evergreen but until Fir these things should be ironed out even if Fir is limited from other perspective …

search the forum because this has been discussed already i believe …

3 Likes

I don’t want to disappoint you but can you image how much resources it takes to “build your own SoC”? That surely is the way to go in the future but for a first linux phone with PureOS that goal is too high. Just wait and see. If the Librem 5 will be successful for Purism we will get an improved phone for sure.

9 Likes

Only the 3 biggest phone makers in the world make their own SoC’s (Samsung Exynos, Huawei Kirin and Apple A-series). These companies sell between 200 and 300 million phones per year. Xiaomi, which is the 4th largest phone maker in the world, tried to make its own Surge processor in 2017, but then it gave up. Just last month Xiaomi announced that it would invest $1.5 billion, so it could start making the Surge again in the future.

Even a company as large as Samsung struggles. Last year Samsung gave up on producing custom ARM cores for its Exynos, because it couldn’t compete with the performance of Snapdragon.

The best hope that we have for a RISC-V processor that can be used in a phone is NXP’s Chassis SoC, which is based on the i.MX platform. By helping to get the i.MX 8M Quad supported in mainline Linux, Purism is making it more likely that it can use the Chassis SoC when it is released (if it can be run on free software).

8 Likes

For Purism to benefit greatly from an Risc-V SoC, that SoC has to be custom made for the cell phone market, the way that Samsung and Apple phone SoC chips are custom-purpose made.

This week, I saw a press release from Microchip Technology, about their PolarFire Risc-V SoC FPGA development kit. That is an awesome development in the market. But the article says that the PolarFire lacks media oriented chips. Also, it is an FPGA which is great for digital circuit development purposes using the Risc-V instruction set. But the finished digital designs then still need to be built in a Fab for actual silicon chip production to be both small enough and affordable enough to sell in to any retail smart phone market. Mask making is quite expensive as is the purchasing of prototypes from a foundry and then paying for silicon validation and production test development of the open source SoC.

An additional challenge is that although the FPGA will support digital designs for silicon validation purposes of the digital modules, many SoC module designs require integration of the digital designs, with analog circuits which the FPGA does not support (at least that I have ever heard of). Integrating digital and analog designs on the same dice, Fabing them, and validating them is some pretty heavy lifting that requires serious capital and specialized human resources working together as the larger silicon manufacture do. Is NXP willing to do all of this to create a custom SoC for the open source smart phone market? Is any silicon manufacturer willing to do this for a Risc-V instruction set environment, for an open source smart phone? Is this even necessary to build an open-hardware, open-source smart phone?

I propose that a company like Microchip or NXP do what they do best, to build the silicon hardware which is a proprietary SoC that will support open source phones. With the manufacturer’s disclosure of the architecture and all features of the SoC, and all code running on the SoC is open source that anyone can see, compose, and compile on their own, I think that’s all that should be needed to obtain FSF compliance. Leave the silicon device development and manufacturing to the big boys and let the open-source community compose all of the firmware. If the proprietary SoC product datasheet discloses all features and architecture and how to use them, and the open source community controls the firmware, the final smart phone product, that should be all that is required to have the smart phone be FSF compliant.

When it comes to whether or not we can trust the large silicon manufacturers not to have secret back doors and snooping, the answer is an absolute “yes”. Most chips that run firmware come with “code protection” features. Protecting the chip customer’s code is a big legal obligation of the chip manufacturer. If that code protection can be cracked at all, the chip manufacturer is in trouble. With the code protection turned off, everything going-on in the chip is visible to anyone who plugs in to it and reads the memory. This is how the open source phone would be shipped to the customer. Anything less honest than this would get the chip manufacturer in trouble. The chip manufacturers serve and have their duty to their customers, not to the government nor to surveilance capitalism.

2 Likes

One thing that Purism could do is join the OpenHW Alliance, and try to influence the chip companies that are developing RISC-V cores to make chips that can run on 100% free software.

However, I think that Purism is already backing the right horse at this point by using NXP chips in its phones and working on the i.MX 8M mainline driver. Purism is just a drop in the bucket for NXP in terms of demand, but the Librem 5 has to be great advertising for NXP and any work Purism does on the mainline driver for NXP has to generate good will in the company. NXP knows that part of the market for the i.MX 8M will be custom mobile devices and Linux SBC’s, and Purism is giving away the design for free to anyone who wants to make that sort of device with the i.MX 8M.

What this means is that Purism can slowly gain leverage with NXP, so that when it talks to NXP about its Chassis SoC, the NXP engineers are more likely to listen to the changes that Purism wants in the SoC. Of course, NXP would do better if it joins with all the companies using the i.MX with free software, like MNT, Emcraft, Seco and Nitrogen8M, when talking to NXP about the design of the Chassis SoC.

3 Likes
6 Likes

What you typed here is a workaround, not a solution. MicroSD cards are great cheap way for storing large amounts of data in small spaces. MicroSD cards are NOT ideal for booting and having OS on them (they are slow) (write speeds are extremely slow like 10mb/s).

Is attaching a super compact connector for internal storage so hard? That connector costs basically nothing. The advantages are enormous (for end user).

Sifive in 2018 with very few employees slapped together a Linux capable SoC. If they could do it then, I don’t see why in 2020 Purism can’t ask Sifive for help. Sifive is now a much larger company.

I personally don’t see light at the end of the tunnel for Purism if they don’t design their own SoC (or together with Rasperry Pi team to reduce costs) (with Sifive). Even i.MX which is most FOSS-friendly SoC provider, is still not that interested in FOSS according to their track record. They are very slow of mainlining their stuff in the Linux kernel. Purism has to wait and waste their time. Why not just cherry pick IP with libre drivers and slap them all together (with help of Sifive)? Everyone wins that way.

Purism already confirmed, that they expect 50 000 deliveries of Librem 5. And that number is growing. They have crazy profit margins on that phone, so they make mad money with this phone.

1 Like

Unfortunately, SiFive has shown that it has no interest in producing chips that can run on free software. Last year they signed an agreement to use the PowerVR and neural processor from Imagination Technologies, which require proprietary drivers. They had the option to partner with Vivante that produces GPUs that can run on free drivers, but they chose to partner with Imagination instead, which shows their priorities. See: https://source.puri.sm/Librem5/community-wiki/-/wikis/Frequently-Asked-Questions#will-future-versions-of-the-librem-5-use-a-risc-v-processor

1 Like

Then just don’t use PowerVR gpus. As I said in original post, you CAN choose what goes into your SoC and what don’t. Just because Sifive has a deal with Imagination Technologies, it doesn’t mean that everything requires proprietary drivers.

I doubt purism will make the step to using epic RISC-V in say the next ~7 years depending on how well the profits are for the L5. We really need somebody that has the ‘enthusiasm’ of Lord Terry and the free software drive of RMS with the cash flow of a multi-millionaire if we are going to get anything like this soon. Maybe one day purism can make RYF computers and maybe even go further than RYF certification standards as RYF isn’t exactly perfect (not communist enough) when it comes to firmware of some hardware such as the EC of the certified thinkpads.

1 Like

Imagination’s PowerVR is the ONLY GPU that SiFive currently offers on its OpenFive platform, so you can’t put in a Mali, Vivante or VideoCore GPU in its place, which are the three mobile GPUs with free drivers. By the way, you can’t buy the Mali or the VideoCore GPUs separately because ARM Holdings and Broadcom only sell them paired with ARM cores. The only real option is the Vivante GPU, and an internet search didn’t turn up any stand-alone Vivante GPU chips.

There is no reason to use SiFive in the first place. Both Alibaba and NXP are objectively better, because both of them participate in the OpenHW Group which is a consortium of companies that collaborate on the design of free RISC-V cores. What that means is that anyone can download the source and use it in an FPGA or ASIC. All SiFive does is use a free ISA, which is not the same as contributing to a free RISC-V core.

The fact that the i.MX 6 and i.MX 8M can run on almost 100% free software (all except the DDR timer blob) and NXP contributes to the mainline Linux driver for its chips makes NXP the best of the mobile SoC chip makers. There is nobody in the mobile chip world that is like Intel and AMD, which are the biggest and 6th biggest contributors to the Linux kernel, respectively. NXP is slow at supporting its chips in mainline, but at least it contributes to the mainline driver. Broadcom may have contributed a GPU driver for VideoCore, but it still isn’t possible to boot its SoC’s with free software. Only just recently was it possible to boot the Rockchip RK3399 with free software and it is still experimental.

Of the options, NXP is the best shot that Purism has of getting a RISC-V SoC that can run on 100% free software.

If Purism makes a desktop PC, then we can talk about making an FPGA with open source RISC-V cores and adding a discrete AMD graphics card on the PCI bus. The performance will suck and it will be an energy hog and very expensive, but we are in the realm of what is possible.

However, the idea of Purism making a custom mobile RISC-V SoC for phones is about as feasible as making one of Kazmroz’s theoretical physics processors.

6 Likes

You must be joking. :sweat_smile:

5 Likes

from which

NVIDIA plans to use RISC-V in its GPU memory controllers

(I think that quote just means: in its GPUs.)

I wonder if that is out of date now, given nVidia’s purchase of ARM.

My experience of several takeovers is the big fish doesn’t start “interfering” with the product line (or the employees) of the little fish until the second year after the takeover.

(You can use your own expletive instead of “interfering” above.)

2 Likes

considering that we’re CUC-ed into wearing :mask: already they might feel safer than usual in doing just what you suggested above …