diff options
Diffstat (limited to '36c3/Replicant_sustainability/Replicant_sustainability.tex')
-rw-r--r-- | 36c3/Replicant_sustainability/Replicant_sustainability.tex | 391 |
1 files changed, 391 insertions, 0 deletions
diff --git a/36c3/Replicant_sustainability/Replicant_sustainability.tex b/36c3/Replicant_sustainability/Replicant_sustainability.tex new file mode 100644 index 0000000..1aefd44 --- /dev/null +++ b/36c3/Replicant_sustainability/Replicant_sustainability.tex @@ -0,0 +1,391 @@ +\documentclass{beamer} +\usepackage[english]{babel} +\usepackage{color} +\usepackage{graphicx} +\usepackage{ifthen} +\usepackage[utf8]{inputenc} +\usepackage{ulem} +\usepackage{listings} +\usepackage{pdfpages} +\usepackage{tikz} +\usepackage{xtab} + +\newcommand{\outputpicture}[2] { + {\includegraphics[scale=#1]{output/#2}} +} +\newcommand{\devicepicture}[1] { + {\includegraphics[scale=0.5]{../../external_resources/replicant_website/images/supported-devices/#1.png}} +} + +%% \usetheme{Singapore} + +\title{Extending the lifetime of smartphones with Replicant, a fully free Android distribution} +\author{Denis 'GNUtoo' Carikli and David 'dllud' Ludovino} +\date{\today} + +\begin{document} + +\maketitle + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\section{Introduction} + +\begin{frame} + \center{Introduction} +\end{frame} + +\begin{frame} + \center{Replicant:} + \begin{itemize} + \item Fully free Android distribution approved by the FSF + \item But the hardware it runs on is not... + \item More details on hardware related freedom issues later %% TODO + \end{itemize} +\end{frame} + +\begin{frame} + \center{Quick Facts} + \begin{itemize} + \item Website: replicant.us + \item Exists since September 2009 + \item Currently based on LineageOS + \item Android versions: + \begin{itemize} + \item Replicant 6: Android 6, last security update: October 2017\cite{last-android-6-update} + \item Replicant 9: Android 9, work in progress\cite{porting-to-android-9} + \end{itemize} + \item Supports $\sim$ 10 devices (smartphones and tablets) + \item $\sim$ 2 full time equivalent contributors and a big community + \end{itemize} +\end{frame} + +\begin{frame} + \center{Minimum feature set required to support a device:} + \begin{itemize} + \item Display working and graphics fast enough + \item sound working + \item Be able to make calls + \item etc + \item GPS, Camera, and other non crucial hardware may not work, or work in later releases + \end{itemize} +\end{frame} + +{ + \begin{frame} + \center{A very short introduction on hardware:} + \outputpicture{0.8}{i9300_hardware.png} + \begin{itemize} + \item System on a chip + \item Smartphones and the modem + \end{itemize} + \end{frame} +} + +{ + \begin{frame} + \center{Freedom issues in supported devices} + \outputpicture{0.8}{i9300_hardware.png} + \begin{itemize} + \item The cellular network + \item The modem firmware + \item Other nonfree firmwares + \item Bootloaders and TrustZone + \item Upstream anti-feature and huge code base + \end{itemize} + \end{frame} +} + +%% { +%% \begin{frame} +%% \center{Freedom issues in LineageOS (without google play)} +%% \outputpicture{0.8}{i9300_hardware.png} +%% \begin{itemize} +%% \item + Modem control over the device (MSM7K) or shared memory +%% \item + Nonfree libraries (ril backdoor, etc) +%% \item + Anti-features +%% \end{itemize} +%% \end{frame} +%% } + +%% { +%% \begin{frame} +%% \center{Worst case with stock devices:} +%% \begin{itemize} +%% \item + Only the kernel is free software +%% \item + Users potentially locked out of their devices +%% \item + Many Anti-features or unwanted applications +%% \item $\rightarrow$ Remining freedoms: The ability to install F-Droid or other applications +%% \end{itemize} +%% \end{frame} +%% } + +\begin{frame} + \center{Why Android?} + \begin{itemize} + \item Advantages: + \begin{itemize} + \item GUI and applications adapted to big fingers + \item $\rightarrow$ run on devices that: + \begin{itemize} + \item lack keyboard + \item have capacitive touchscreen and no stylus + \item Have very small displays with very high number of pixel + \end{itemize} + \end{itemize} + \item Issues + \begin{itemize} + \item Part of the GNU/Linux software architecture is light years away: Package management and build system, Graphics, audio, etc + \item Huge unknown code from google + \item Meant to run proprietary software, not to empower users + \end{itemize} + \end{itemize} +\end{frame} + +\begin{frame} + \center{Android: From time to market driven architecture to sustainability} + \begin{itemize} + \item SOCs, WiFi chips, smartphones and tablets + \begin{itemize} + \item Write the code that work as fast as possible + \item Support as many hardware features as possible + \item $\rightarrow$ Varying code quality + \item $\rightarrow$ Example: One driver rewritten 3 times %% TODO: reference + \end{itemize} + \item Breaking Kernel API and ABI + \begin{itemize} + \item It can take time (years) to bring in a new framework in Linux + \item Example of API breakage: HTC dream audio driver + \item Solution: Apps $\leftrightarrow$ Android framework $\leftrightarrow$ HAL $\leftrightarrow$ Kernel + \item Getting better in Android: Treble and Generic Kernel images + \end{itemize} + \end{itemize} +\end{frame} + +\begin{frame} + \center{Ugly code is good (for freedom):} + %% TODO: replace with [blobby from OpenBSD] VS [dirty tux] -> [freedo] + \begin{itemize} + \item Having the source code under free software licenses, even if the code quality is bad is crucial for freedom: + \begin{itemize} + \item Hardware bringup is often made that way anyway + \item Things can be improved later: + always be cleaned up later or if the code quality is too bad, rewritten from scratch + \item Having the source code under a free software license is very important + \item Worst case: use the source code as documentation or reverse engineer it (add prints) + \end{itemize} + \item $\rightarrow$ We depend on that source code + \end{itemize} +\end{frame} + +%% TODO: free your mind / bend the rules +%% - Number of smartphones models made each year +%% -> Another way to look at it + +%% Freedom +%% (climate activists, etc) + +%% \begin{frame} +%% \center{From a purely sustainable perspective:} +%% \begin{xtabular}{ll} +%% Big brand old devices & Big brand new devices \\ +%% Removable battery & Battery too difficult to replace \\ +%% Device specific kernel & Device specific modules \\ +%% Changing HAL API & HAL API being versioned \\ +%% \end{xtabular} +%% \end{frame} + +\section{Part II} +\begin{frame} + \center{Part II} +\end{frame} + +\begin{frame} + \center{Replicant 6 $\rightarrow$ More recent Android} +\end{frame} + +\begin{frame} + \center{Devices supported by Lineage 16 with a removable battery} +\end{frame} + +\begin{frame} + \begin{itemize} + \item Qualcomm MSM8*: + \begin{itemize} + \item Fairphone: FP2 + \item LG: G3 (many versions) + \item OPPO: Find 7a/s + \item Samsung: Galaxy Note 3 LTE (Many versions) + \item Samsung: Galaxy S III Neo (2 versions) + \item Samsung: Galaxy S5 Active + \item Samsung: Galaxy S5 LTE (Many versions) + \item Samsung: Galaxy S5 LTE Duos (Many versions) + \item Wileyfox: Swift + \end{itemize} + \item Qualcomm APQ8* + \begin{itemize} + \item Samsung: Galaxy S4 (Many versions) + \item Samsung: Galaxy S4 Value Edition (GT-I9515/L) + \item Samsung: Galaxy S4 Active + \item Samsung: Galaxy S5 LTE-A + \item Samsung: Galaxy S5 Plus + \end{itemize} + \item Samsung Exynos 7580: + \begin{itemize} + \item Samsung: Galaxy S5 Neo + \end{itemize} + \end{itemize} +\end{frame} + +\begin{frame} + \center{Limiting the freedom, privacy and security attacks} + \begin{itemize} + \item Isolated modem: + \begin{itemize} + \item Modem not in the SOC + \item No shared memory (RAM) between the modem and the SOC + \begin{itemize} + \item HSIC: USB-like, the host control re-enumeration + \item MIPI: Should be OK, not extensively reviewed + \end{itemize} + \end{itemize} + \end{itemize} +\end{frame} + +\begin{frame} + \begin{itemize} + \item \sout{Qualcomm MSM8*:} Modem in the SOC + \begin{itemize} + \item \sout{Fairphone: FP2} + \item \sout{LG: G3 (many versions)} + \item \sout{OPPO: Find 7a/s} + \item \sout{Samsung: Galaxy Note 3 LTE (Many versions)} + \item \sout{Samsung: Galaxy S III Neo (2 versions)} + \item \sout{Samsung: Galaxy S5 Active} + \item \sout{Samsung: Galaxy S5 LTE (Many versions)} + \item \sout{Samsung: Galaxy S5 LTE Duos (Many versions)} + \item \sout{Wileyfox: Swift} + \end{itemize} + \item Qualcomm APQ8* + \begin{itemize} + \item Samsung: Galaxy S4 (Many versions) + \item Samsung: Galaxy S4 Value Edition (GT-I9515/L) + \item Samsung: Galaxy S4 Active + \item Samsung: Galaxy S5 LTE-A + \item Samsung: Galaxy S5 Plus + \end{itemize} + \item Samsung Exynos 7580: + \begin{itemize} + \item \sout{Samsung: Galaxy S5 Neo} Modem $\leftrightarrow$ SOC: shared memory + \end{itemize} + \end{itemize} +\end{frame} + +\begin{frame} + \center{Hmmm} + \begin{itemize} + \item $\rightarrow$ No Exynos with removable battery and isolated modem. + \item $\rightarrow$ All the devices supported by Replicant 6.0 have been dropped. + \item $\rightarrow$ We'd like to support the devices longer... + \item The APQ* also look interesting, we would need to do more research on it: + \begin{itemize} + \item Isolated modem? + \item Upstream support for the SOC? + \item Nonfree bootloader ($\sim$ BIOS+GRUB) (signed?) + \item Probably way more work needed (different modem, more upstreaming work) + \end{itemize} + \item We also took the decision when LineageOS didn't support theses. + \end{itemize} +\end{frame} + +\section{Part III} +\begin{frame} + \center{Part III} +\end{frame} + +\begin{frame} + \center{Already supported by Replicant 6.0:} + \begin{itemize} + \item Galaxy SIII (I9300): Good upstream status, modem support lacking, and other small fixes to do. + \item Galaxy Note II (I9300): Good upstream status, modem and display support lacking + \item Galaxy SIII 4G (I9305) and Galaxy Note II 4G (N7105): Different modem + \end{itemize} +\end{frame} + +\begin{frame} + \center{Making devices more sustainable:} + \begin{itemize} + \item $\rightarrow$ Upstream Linux $\rightarrow$ We can support them longer. + \item $\rightarrow$ Most Replicant users and developers already have one. + \item $\rightarrow$ Known hardware that works and can still be bought second hand + \item Remaining issues: + \begin{itemize} + %% $\rightarrow$ Repurpose the device and run GNU/Linux when not supported anymore. + \item RAM size and new Android versions + \item Nonfree bootloader + \end{itemize} + \end{itemize} +\end{frame} + +\begin{frame} + \center{Main blocker: Nonfree bootloader} + \begin{itemize} + \item Nonfree $\rightarrow$ Incentive to drop the device + \item Partially free u-boot port $\rightarrow$ can't redistribute the nonfree part + \item Research to understand if we can make it fully free (XBOOT) + \item Stock bootloader incompatible with Linux... + \end{itemize} +\end{frame} + +\begin{frame} + \center{Upstream Linux bootloader requirements} + Documentation/arm/Booting (since 2003): + \begin{verse} + The MMU must be off. + + Instruction cache may be on or off. + + Data cache must be off. + \end{verse} +\end{frame} + +\begin{frame} + \center{Some funding later...} +\end{frame} + +\begin{frame} + \center{Replicant 9.0:} + \begin{itemize} + \item Galaxy SIII booting, modem initialized + \item Still work to do + \item Slowed down by conferences and other Replicant work (XBOOT, Replicant 6, etc) + \end{itemize} +\end{frame} + +\begin{frame} + \center{Future directions:} + \begin{itemize} + \item Finish the research on XBOOT + \begin{itemize} + \item https://github.com/xboot/xboot + \end{itemize} + \item Look into devices like the PinePhone and the Librem5 + \item Share more work with GNU/Linux upstream (OFono, other hardware support libraries) + \end{itemize} +\end{frame} + +\begin{frame} + Licenses: + \begin{itemize} + \item The SIM card and BTS pictures comes from \url{https://en.wikipedia.org/wiki/File:Gsm_network.png} and are under the GFDL 1.2 or the Creative commons Attributions-Share ALike 3.0 Unported. + \item This presentation: CC-BY-SA 4.0 International + \item The Galaxy SIII picture: CC-BY-SA 4.0 International + \end{itemize} +\end{frame} + +\begin{thebibliography}{99} +\bibitem{porting-to-android-9} + \url{https://redmine.replicant.us/projects/replicant/wiki/PortingToAndroid9} +\bibitem{last-android-6-update} + \url{https://en.wikipedia.org/wiki/Android_Marshmallow#cite_note-2} +\end{thebibliography} +\end{document} |