tiann / KernelSU

A Kernel based root solution for Android

Home Page:https://kernelsu.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

On android 14 logcat reporting this init second_stage Fatal issue

shaquibimdad opened this issue · comments

Please check before submitting an issue

  • I have searched the issues and haven't found anything relevant
  • I will upload bugreport file in KernelSU Manager - Settings - Report log
  • I know how to reproduce the issue which may not be specific to my device

Describe the bug

While building latest ksu

-- KernelSU version: 11682
-- KernelSU Manager signature size: 0x033b
-- KernelSU Manager signature hash: c371061b19d8c7d7d6133c6a9bafe198fa944e50c1b31c9d8daa8d7f1fc2d2d6

i am getting the below fatal log in logcat

To Reproduce

No response

Expected behavior

No response

Screenshots

No response

Logs

04-21 19:50:48.383  4134  4134 F libc    : Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 4134 (init), pid 4134 (init)
04-21 19:50:48.483  4141  4141 F DEBUG   : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
04-21 19:50:48.483  4141  4141 F DEBUG   : Build fingerprint: 'POCO/munch_in/munch:14/UKQ1.240227.001/eng.nobody.20240409.165147:user/release-keys'
04-21 19:50:48.483  4141  4141 F DEBUG   : Revision: '0'
04-21 19:50:48.483  4141  4141 F DEBUG   : ABI: 'arm64'
04-21 19:50:48.483  4141  4141 F DEBUG   : Timestamp: 2024-04-21 19:50:48.428760825+0530
04-21 19:50:48.483  4141  4141 F DEBUG   : Process uptime: 0s
04-21 19:50:48.483  4141  4141 F DEBUG   : Cmdline: /system/bin/init second_stage
04-21 19:50:48.483  4141  4141 F DEBUG   : pid: 4134, tid: 4134, name: init  >>> /system/bin/init <<<
04-21 19:50:48.483  4141  4141 F DEBUG   : uid: 0
04-21 19:50:48.483  4141  4141 F DEBUG   : signal 6 (SIGABRT), code -1 (SI_QUEUE), fault addr --------
04-21 19:50:48.483  4141  4141 F DEBUG   :     x0  0000000000000000  x1  0000000000001026  x2  0000000000000006  x3  0000007fc0e85990
04-21 19:50:48.483  4141  4141 F DEBUG   :     x4  000000000000000a  x5  000000000000000a  x6  000000000000000a  x7  7f7f7f7f7f7f7f7f
04-21 19:50:48.483  4141  4141 F DEBUG   :     x8  00000000000000f0  x9  0000007f97e4d1c0  x10 0000000000000001  x11 0000007f97e966f0
04-21 19:50:48.483  4141  4141 F DEBUG   :     x12 000000556f0002f8  x13 00000000ffffffaf  x14 0000000000000000  x15 0000000000000001
04-21 19:50:48.483  4141  4141 F DEBUG   :     x16 0000007f97f01cf8  x17 0000007f97ede2c0  x18 0000007f9f636000  x19 0000000000001026
04-21 19:50:48.483  4141  4141 F DEBUG   :     x20 0000000000001026  x21 00000000ffffffff  x22 0000007f9f4f4fc0  x23 0000007f9f4f4fc0
04-21 19:50:48.483  4141  4141 F DEBUG   :     x24 0000007f9f4f4fc0  x25 000000556f2c94d0  x26 0000000000000000  x27 0000007f97e8b520
04-21 19:50:48.483  4141  4141 F DEBUG   :     x28 000000556f2c9b88  x29 0000007fc0e85a10
04-21 19:50:48.483  4141  4141 F DEBUG   :     lr  0000007f97e86d58  sp  0000007fc0e85970  pc  0000007f97e86d84  pst 0000000000001000
04-21 19:50:48.483  4141  4141 F DEBUG   : 15 total frames
04-21 19:50:48.483  4141  4141 F DEBUG   : backtrace:
04-21 19:50:48.483  4141  4141 F DEBUG   :   NOTE: Function names and BuildId information is missing for some frames due
04-21 19:50:48.483  4141  4141 F DEBUG   :   NOTE: to unreadable libraries. For unwinds of apps, only shared libraries
04-21 19:50:48.483  4141  4141 F DEBUG   :   NOTE: found under the lib/ directory are readable.
04-21 19:50:48.483  4141  4141 F DEBUG   :   NOTE: On this device, run setenforce 0 to make the libraries readable.
04-21 19:50:48.483  4141  4141 F DEBUG   :   NOTE: Unreadable libraries:
04-21 19:50:48.483  4141  4141 F DEBUG   :   NOTE:   /system/lib64/bootstrap/libc.so
04-21 19:50:48.483  4141  4141 F DEBUG   :       #00 pc 000000000005bd84  /system/lib64/bootstrap/libc.so
04-21 19:50:48.483  4141  4141 F DEBUG   :       #01 pc 00000000000e2d2c  /system/bin/init (android::base::DefaultAborter(char const*)+12) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #02 pc 00000000000e4ae0  /system/bin/init (android::base::SetAborter(std::__1::function<void (char const*)>&&)::$_0::__invoke(char const*)+80) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #03 pc 00000000000e4090  /system/bin/init (android::base::LogMessage::~LogMessage()+352) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #04 pc 0000000000135274  /system/bin/init (android::init::Service::SetProcessAttributesAndCaps(android::init::InterprocessFifo)+740) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #05 pc 0000000000137eec  /system/bin/init (android::init::Service::RunService(std::__1::vector<android::init::Descriptor, std::__1::allocator<android::init::Descriptor> > const&, android::init::InterprocessFifo, android::init::InterprocessFifo)+604) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #06 pc 0000000000137548  /system/bin/init (android::init::Service::Start()+4136) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #07 pc 000000000012ac94  /system/bin/init (android::init::do_start(android::init::BuiltinArguments const&)+324) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #08 pc 00000000000ec1b0  /system/bin/init (android::init::RunBuiltinFunction(std::__1::function<android::base::expected<void, android::base::ResultError<android::base::Errno, true> > (android::init::BuiltinArguments const&)> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)+464) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #09 pc 00000000000ec40c  /system/bin/init (android::init::Command::InvokeFunc(android::init::Subcontext*) const+300) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #10 pc 00000000000ece9c  /system/bin/init (android::init::Action::ExecuteCommand(android::init::Command const&) const+76) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #11 pc 00000000000ecd8c  /system/bin/init (android::init::Action::ExecuteOneCommand(unsigned long) const+332) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #12 pc 0000000000141544  /system/bin/init (android::init::ActionManager::ExecuteOneCommand()+180) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #13 pc 000000000015c0bc  /system/bin/init (android::init::SecondStageMain(int, char**)+9804) (BuildId: 2e2934de53c9c53c4ad688cf8b3f6bf5)
04-21 19:50:48.483  4141  4141 F DEBUG   :       #14 pc 0000000000054468  /system/lib64/bootstrap/libc.so

Device info

  • Device: Poco F4
  • OS Version: 14
  • KernelSU Version: v0.9.2
  • Kernel Version: 4.19

Additional context

No response

There is no evidence that it is caused by KernelSU.

Just built the same kernel without ksu and this issue disappeared from log

There is something related to this in ksud.c file with second_stage mentioned

And with ksu, during boot this fatal log occur and after booting done when I manually set selinux to permissive and execute /system/bin/init second_stage sometime same fatal log appear and sometime it just executes normally