Salvage Android Phone as Linux-Server (radio/wifi hardware broken)


Question

My device has hardware problems with radio/wifi. Hence it's not possible to use sim-card or wifi. That also makes it restart frequently. Now it's useless as a phone. So I am trying to turn it in a desk computer (mini-server linuxdeploy). Simple air-plane mode isn't enough to solve these reboots.


How I figure out its wifi/radio components were broken (tentative)


I have an OnePlus 6 enchilada.



Deeper disable wifi/radio than simple air-plane mode


Is it possible to somehow to disable the WIFI/radio somehow deeper than simple air-plane mode? So I can use it as a desk mini-server. Installing linuxdeploy or any other software like that and use reverse tethering.


I tried many solutions around internet (including android.stackexchange) but none really works.


If someone could give me any tip or advice I would greatly appreciate!!


Answer

I solved by myself so I'm sharing so it might be useful for others.


Deeper disable wifi/radio = recompile android Linux Kernel disabling wifi/radio drivers


First I tested the Lineage OS custom ROM for my device.


From that I got access to fully rebuild my Custom Lineage ROM. They have all source code for all supported devices including the source for the linux kernel for my mobile board (Qualcomm SDM845 Snapdragon 845 SoC).


When the kernel is built It should be decided if It will load driver modules (all SoC board component needs a driver) or have driver modules statically built in it. In either case the driver must be enabled during the kernel build. For configuring the linux kernel build a .config file is used.


After studying a lot more about linux kernel building. Found from here that QDSP6V5 from OnePlus 6 SoC SDM845 board was mandatory for mobile-data and WIFI when building the kernel.


Using Lineage OS docs and more research and 250 GB of source code and almost 12 hours of download (repo sync + brunch enchilada) I managed to build my custom Lineage OS 16.0 ROM after modifying the kernel .config fragment (enchilada_defconfig) from android\lineage\kernel\oneplus\sdm845\arch\arm64\configs\enchilada_defconfig.


Setting CONFIG_MSM_PIL_MSS_QDSP6V5 from y to n(NO).


Note: When building LOS I had to disable dashd since I couldn't find this file while extracting proprietary blobs. Comment it out on ~/android/lineage/vendor/oneplus/sdm845-common/Android.mk


#include $(CLEAR_VARS)
#LOCAL_MODULE := dashd
#LOCAL_MODULE_OWNER := oneplus
#LOCAL_MODULE_PATH := $(TARGET_ROOT_OUT_SBIN)
#LOCAL_UNSTRIPPED_PATH := $(TARGET_ROOT_OUT_SBIN_UNSTRIPPED)
#LOCAL_SRC_FILES := proprietary/rootfs/sbin/dashd
#LOCAL_MODULE_TAGS := optional
#LOCAL_MODULE_CLASS := EXECUTABLES
#include $(BUILD_PREBUILT)

and deleting it from PRODUCT_PACKAGES += list on sdm845-common-vendor.mk on same folder.


Eureka!!


Wifi and Mobile not working at all.


No more reboots and internet working flawlessly from usb reverse tethering.


Hilariously solution is exactly like @Robert commented. I had to spent almost an year of exploration to find that by myself. `-)


Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes