{"id":34885023,"url":"https://github.com/seclususs/qos-android","last_synced_at":"2026-02-04T22:03:43.161Z","repository":{"id":320641799,"uuid":"1072807109","full_name":"seclususs/qos-android","owner":"seclususs","description":"Android userspace daemon for entry-level devices.","archived":false,"fork":false,"pushed_at":"2026-01-29T04:43:08.000Z","size":560,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-29T18:42:24.329Z","etag":null,"topics":["android","control-theory","cpp-lang","helio-g88","linux-kernel","magisk-module","performance-tuning","rust-lang"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/seclususs.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-09T08:37:02.000Z","updated_at":"2026-01-22T15:38:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"0082d096-4364-471c-a32e-ea94f63f8abc","html_url":"https://github.com/seclususs/qos-android","commit_stats":null,"previous_names":["seclususs/os-enhancer","seclususs/qos-android"],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/seclususs/qos-android","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seclususs%2Fqos-android","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seclususs%2Fqos-android/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seclususs%2Fqos-android/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seclususs%2Fqos-android/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/seclususs","download_url":"https://codeload.github.com/seclususs/qos-android/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seclususs%2Fqos-android/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28919362,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-30T20:25:28.696Z","status":"ssl_error","status_checked_at":"2026-01-30T20:25:13.426Z","response_time":66,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","control-theory","cpp-lang","helio-g88","linux-kernel","magisk-module","performance-tuning","rust-lang"],"created_at":"2025-12-26T03:35:33.914Z","updated_at":"2026-02-04T22:03:43.155Z","avatar_url":"https://github.com/seclususs.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# QoS\n\n[![Magisk](https://img.shields.io/badge/Magisk-24%2B-green.svg)](https://github.com/topjohnwu/Magisk)\n[![Architecture](https://img.shields.io/badge/Arch-ARM64-blue.svg)]()\n[![SoC Support](https://img.shields.io/badge/SoC-Universal-orange.svg)]()\n[![License](https://img.shields.io/badge/License-GPLv3-blue.svg)](LICENSE)\n\n\u003e **! Heads up:** This module tweaks kernel behavior using userspace PID loops and syscall tricks. It can make your device smoother or faster, but **may break things** if combined with other mods. Use at your own risk (DWYOR).\n\u003e\n\u003e **Critical:** QoS is highly dependent on **Kernel PSI** (`/proc/pressure`). Devices without PSI support are **not compatible**.\n\n---\n\n## How It Works\n\nQoS is a lightweight daemon with two layers:\n\n1. **C++ Layer:** Handles low-level stuff memory locking, scheduling, OOM protection.\n2. **Rust Layer:** Runs a fast `epoll` loop to safely apply PID, storage, and I/O tweaks.\n\n### System Architecture\n\n```mermaid\n%%{init: {'theme': 'dark', 'themeVariables': { 'fontSize': '12px','fontFamily': 'monospace'}}}%%\ngraph TD\nsubgraph KERNEL[\"LINUX KERNEL\"]\n    direction TB\n    K_PSI[\"/proc/pressure\u003cbr/\u003e(cpu, io)\"]\n    K_SYS[\"/proc/sys/*\u003cbr/\u003e/sys/block/*\"]\n    K_FS[\"Filesystem\u003cbr/\u003e/data /cache\"]\n    K_PROC[\"/proc\u003cbr/\u003e(Process Info)\"]\n    K_SIG[\"signalfd\u003cbr/\u003eSIGTERM / SIGINT\"]\n    K_PROP[\"Android\u003cbr/\u003eProperties\"]\nend\n\nsubgraph USER[\"USERSPACE DAEMON\"]\n    subgraph NATIVE[\"RUNTIME ENVIRONMENT\"]\n        style NATIVE fill:#2d2d2d,stroke:#ffffff,stroke-width:2px\n        N_MAIN[\"main.cpp\"]\n        N_HARDEN[\"Hardening\"]\n        N_LIM[\"Limits \u0026 IO\"]\n        N_SCHED[\"Scheduler\"]\n        N_DIAG[\"Diagnostics\"]\n        N_CONF[\"Config\"]\n        N_MEM[\"MemLock\"]\n        N_BRIDGE[\"FFI Bridge\"]\n        N_MAIN --\u003e N_HARDEN\n        N_HARDEN --\u003e N_LIM\n        N_LIM --\u003e N_SCHED\n        N_SCHED --\u003e N_DIAG\n        N_DIAG --\u003e N_CONF\n        N_CONF --\u003e N_MEM\n        N_MEM --\u003e N_BRIDGE\n    end\n\n    subgraph CORE[\"CORE\"]\n        style CORE fill:#1e1e1e,stroke:#ffffff,stroke-width:2px\n        R_ENTRY[\"ffi.rs\"]\n        N_BRIDGE ==\u003e R_ENTRY\n\n        W_TWEAK[\"Worker: Tweaks\"]\n        style W_TWEAK fill:#333333,stroke-dasharray: 5 5\n        \n        W_CLN[\"Worker: Cleaner\"]\n        style W_CLN fill:#333333,stroke-dasharray: 5 5\n\n        R_ENTRY -.-\u003e W_TWEAK\n        R_ENTRY --\u003e MAIN\n\n        subgraph MAIN[\"EVENT LOOP\"]\n            style MAIN fill:#252526,stroke:#ffffff\n            EPOLL[\"epoll_wait\"]\n\n            subgraph CTRL[\"CONTROLLERS\"]\n                C_CPU[\"CPU\"]\n                C_IO[\"Storage\"]\n                C_CLN[\"Cleaner\"]\n                C_SIG[\"Signal\"]\n            end\n\n            subgraph LOGIC[\"LOGIC\"]\n                M_KALMAN[\"Kalman\"]\n                M_SMITH[\"Smith Pred\"]\n                M_PID[\"PID\"]\n                M_HEUR[\"Heuristics\"]\n                M_POLL[\"Adaptive Poll\"]\n            end\n\n            subgraph HAL[\"HAL\"]\n                H_PSI[\"PSI\"]\n                H_DISK[\"Disk Stats\"]\n                H_THERM[\"Thermal\"]\n                H_BAT[\"Battery Cap\"]\n            end\n\n            EPOLL --\u003e C_CPU\n            C_CPU --\u003e H_PSI\n            C_CPU --\u003e H_THERM\n            C_CPU --\u003e H_BAT\n            H_PSI --\u003e M_KALMAN\n            M_KALMAN --\u003e M_PID\n            C_CPU -.-\u003e M_SMITH\n            M_SMITH --\u003e M_PID\n            H_THERM --\u003e M_PID\n            H_BAT --\u003e M_HEUR\n            M_HEUR --\u003e M_PID\n            M_PID --\u003e C_CPU\n            C_CPU --\u003e M_POLL\n            EPOLL --\u003e C_IO\n            C_IO --\u003e H_DISK\n            C_IO --\u003e H_PSI\n            H_DISK --\u003e M_HEUR\n            H_PSI --\u003e M_HEUR\n            M_HEUR --\u003e C_IO\n            C_IO --\u003e M_POLL\n            EPOLL --\u003e C_CLN\n            C_CLN --\u003e H_PSI\n            C_CLN --\u003e H_THERM\n            M_POLL --\u003e EPOLL\n            EPOLL --\u003e C_SIG\n        end\n        C_CLN -.-\u003e W_CLN\n    end\nend\n\nW_TWEAK --\u003e K_SYS\nW_TWEAK --\u003e K_PROP\nC_CPU --\u003e K_SYS\nC_IO --\u003e K_SYS\nW_CLN --\u003e K_FS\nW_CLN --\u003e K_PROC\nC_CLN --\u003e K_FS\nK_PSI -.-\u003e EPOLL\nK_SIG -.-\u003e EPOLL\n```\n\n---\n\n## What It Does\n\n* **CPU Control:** Smooth frequency scaling using PID loops, Kalman filter for load, Smith predictor for thermal lag.\n* **Storage Tweaks:** Adjusts I/O queue depth and read-ahead dynamically.\n* **Cleaner Service:** Background cache cleanup only when idle and cool.\n\nEverything runs quietly with minimal CPU usage when idle.\n\n---\n\n## Key Points\n\n* Detects **CPU cores and SoC type** automatically.\n* Applies **tier-based presets** (Low/Mid/Flagship).\n* Considers **battery and thermal state** for smarter boosts.\n* Fully **async**, avoids stalling the main loop.\n\n---\n\n## Requirements\n\n* Android 13+ (API 33+)\n* Magisk 24.0+\n* ARM64\n* **Kernel with PSI (`CONFIG_PSI=y`) – mandatory!**\n\nCheck: `ls /proc/pressure/` → must show `cpu`, `io`.\n\n\u003e QoS will **not function correctly** on kernels without PSI support.\n\n---\n\n## Installation\n\n1. Download the latest `.zip` from [Releases](../../releases).\n2. Open Magisk → **Install from storage** → select file.\n3. Reboot.\n4. Logs: `/data/local/tmp/qos_log` or Logcat tag `QoS`.\n\n---\n\n## Notes\n\n* **DWYOR:** This is a tweak tool, not a magic fix.\n* Mixing with other performance modules **may cause instability**.\n* **PSI dependency is critical**: without proper kernel support, QoS may fail or misbehave.\n* You are responsible for the effects.\n\n---\n\n## License\n\nCopyright (C) 2025 Seclususs\n\nThis project is licensed under the **GNU General Public License v3.0 or later (GPL-3.0-or-later)**.\n\nThis program comes with **NO WARRANTY**, to the extent permitted by law.\u003cbr\u003e\nSee [LICENSE](LICENSE) for details.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseclususs%2Fqos-android","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseclususs%2Fqos-android","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseclususs%2Fqos-android/lists"}