UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image)

    Scheduled Pinned Locked Moved Oneplus 5/5T
    39 Posts 4 Posters 6.8k Views 4 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
      Reply
      • Reply as topic
      Log in to reply
      This topic has been deleted. Only users with topic management privileges can see it.
      • danfroD Offline
        danfro @Luksus
        last edited by danfro

        @Luksus Just some followup questions before I try this:

        1. Can it be safely reverted in case it doesn't work out? I am a bit cautious since this would be on my daily driver.
        2. Does it matter which channel I am using? Currently focal devel.
        3. Will it affect (for good or for worse) dual sim usage?

        But it is good to see things taking steps forward. I am looking forward to try it.

        LuksusL 1 Reply Last reply Reply Quote 0
        • M Offline
          malditobastardo
          last edited by

          i am also willing to give it a try on my OP5, btw, does this also include the necessary flags to be able to run virtualization and winebox?

          Thank you for your great work!

          LuksusL 1 Reply Last reply Reply Quote 0
          • LuksusL Offline
            Luksus @danfro
            last edited by

            @danfro
            yes, you can just install the official build with the installer, or even by OTA update again.
            The channel you are currently on, does not matter. My build is using the devel channel.
            Regarding dual sim, I don't know.

            Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

            danfroD 1 Reply Last reply Reply Quote 0
            • LuksusL Offline
              Luksus @malditobastardo
              last edited by Luksus

              @malditobastardo it is using the same kernel like the official builds, therefor it should be included as far as I know.

              Edit:
              So it seems, that the kernel config BINFMT_MISC, which is needed for winebox, is not set.
              But as I said, you just can update the system-image and leave your boot-image as it is.

              Which configs are necessary for visualization?

              Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

              1 Reply Last reply Reply Quote 0
              • danfroD Offline
                danfro @Luksus
                last edited by danfro

                @Luksus Thanks for the quick answers. I flashed the ubuntu.img. Log as follows, especially because of the first error message:

                fastboot flash system ubuntu.img
                Invalid sparse file format at header magic
                Sending sparse 'system' 1/6 (494594 KB)            OKAY [ 20.907s]
                Writing 'system'                                   OKAY [  0.009s]
                Sending sparse 'system' 2/6 (518366 KB)            OKAY [ 24.441s]
                Writing 'system'                                   OKAY [  0.015s]
                Sending sparse 'system' 3/6 (504130 KB)            OKAY [ 23.555s]
                Writing 'system'                                   OKAY [  0.007s]
                Sending sparse 'system' 4/6 (524284 KB)            OKAY [ 24.233s]
                Writing 'system'                                   OKAY [  0.005s]
                Sending sparse 'system' 5/6 (502723 KB)            OKAY [ 23.165s]
                Writing 'system'                                   OKAY [  0.005s]
                Sending sparse 'system' 6/6 (82784 KB)             OKAY [ 17.075s]
                Writing 'system'                                   OKAY [  0.010s]
                Finished. Total time: 137.869s
                
                

                So far it did reboot, load the system and no obvious issues.
                Wireguard kernel patch seems to be present too.
                Hardware button on the left side works.
                Fingerprint works.

                Attaching with usb now brings up the devices name as "OnePlus 5", before it was "OnePlus5T" (edit: or "OP5T" not 100% sure). My device is a OP5T.

                Some known issues with dual sim are the same:

                • no mobile data on slot 2
                • sim card selected for mobile data is not remembered (although that is more a Lomiri issue, not kernel bases I think)

                BUT the good news is, one issue seems to be solved: both of my sim cards get detected on every reboot (done about 10 or so). With the other kernel it would take sometimes up to 4 reboots for both cards to be detected. This is a really great improvement!
                :crying_face: after applying the battery saver patch and rebooting, the "one sim card is not detected" issue came up again at a 50:50 rate. Can that be related?

                Regarding battery saving, I am going to give this a try. Thinking of battery saver app, can this patch be amended so it also turns to 2G when wifi is on (even with the screen on)?

                Extending system partition size worked. Installing the snap support and snaps worked too.

                And one last question: I should not do any devel/RC/OTA updates right now since that would overwrite this kernel, right?

                Btw. on a footnote, your footnote here in the forum does not list the OP5T. 😉

                LuksusL 1 Reply Last reply Reply Quote 0
                • LuksusL Offline
                  Luksus @danfro
                  last edited by

                  Thanks for the detailed feedback.
                  As I tried to explain, the kernel and kernel features itself should be the same as in the official image... the difference is the system-image and how device-overlays are getting applied.

                  Because of that, i.e. the usb-config is more generic and does not allow to distinguish between OP5 and OP5T.

                  @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                  after applying the battery saver patch and rebooting, the "one sim card is not detected" issue came up again at a 50:50 rate. Can that be related?

                  Maybe, since it is modifying sim cards mobile data config.

                  @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                  can this patch be amended so it also turns to 2G when wifi is on (even with the screen on)?

                  Sure. I have that on my mind too for a while, but did not find the time to look into it.
                  Maybe there is already an attempt somewhere in this thread:
                  https://forums.ubports.com/post/51164

                  @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                  And one last question: I should not do any devel/RC/OTA updates right now since that would overwrite this kernel, right?

                  Yes, kind of.
                  I am not sure, if it would replace the kernel, but it would at least switch to the official system build again.

                  Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                  danfroD 2 Replies Last reply Reply Quote 0
                  • danfroD Offline
                    danfro @Luksus
                    last edited by

                    @Luksus said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                    Thanks for the detailed feedback.
                    As I tried to explain, the kernel and kernel features itself should be the same as in the official image... the difference is the system-image and how device-overlays are getting applied.

                    Because of that, i.e. the usb-config is more generic and does not allow to distinguish between OP5 and OP5T.

                    Just my hope that some things get magically solved so I mentioned or tested those things. 😉

                    @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                    after applying the battery saver patch and rebooting, the "one sim card is not detected" issue came up again at a 50:50 rate. Can that be related?
                    

                    Maybe, since it is modifying sim cards mobile data config.

                    I turned the script off later to see if the sim card detection then works again. No. But I also have the impression, that it works good after doing some larger (kernel?) updates/OTA or flashing a kernel manually as here. As soon as I change or update something or whatever things go bad again. I guess I could only test this by flashing the whole thing again.

                    @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                    can this patch be amended so it also turns to 2G when wifi is on (even with the screen on)?
                    

                    Sure. I have that on my mind too for a while, but did not find the time to look into it.
                    Maybe there is already an attempt somewhere in this thread:
                    https://forums.ubports.com/post/51164

                    Quickly zapping over the post I couldn't see anything regarding wifi. I may give it a more detailed read later. But battery safer app has this already implemented, which I was using. I turned that off for testing this kernel.

                    @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                    And one last question: I should not do any devel/RC/OTA updates right now since that would overwrite this kernel, right?
                    

                    Yes, kind of.
                    I am not sure, if it would replace the kernel, but it would at least switch to the official system build again.

                    👍 I will not update then for a while and see how this version works.

                    M 1 Reply Last reply Reply Quote 0
                    • M Offline
                      malditobastardo @danfro
                      last edited by malditobastardo

                      Just some preliminary report:

                      • I got the same error message as @danfro "invalid sparse file format.." but everything was OK and it flashed fine
                      • the keyboard is smaller??
                      • I've had a bug where I could not write anything and I had to reboot
                      • snaps after the space "hack" finally works again 🙂
                      • I can confirm the kernel config BINFMT_MISC is not set as you mentioned, but not biggie since winebox never really worked for me on this device.

                      I will apply now the battery saver ""patch"" and see if I notice some improvements. I will continue testing and report any findings.

                      LuksusL 1 Reply Last reply Reply Quote 0
                      • LuksusL Offline
                        Luksus @malditobastardo
                        last edited by Luksus

                        @malditobastardo Oh yes, I forgot to mention that:
                        I've did some adjustments (improvements in my opinion) to the keyboard, that it fits better the display height. Mainly for the landscape mode, but then I found, that it could use an adjustment in portrait mode too.

                        And I made the font smaller in the the "word-ribbon" (the line above the keyboard, with suggestions or the options to copy and paste when in editing mode).

                        If you want you can switch it forth an back to compare. It would be needed to make system writable and then edit the file /opt/halium-overlay/usr/share/maliit/plugins/lomiri-keyboard/keys/key_constants.js

                        The original parts are commented: /* overlay-adjusted */
                        See: maliit key_constants.js overlay


                        "invalid sparse file format.."

                        I have that too, but I don't think its relevant, though I just don't know.


                        I still wonder, if virtualization (pocketVMs) is working for you?
                        Do you have any kernel-adjustments for making it work? Which images are you using?

                        Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                        M 1 Reply Last reply Reply Quote 1
                        • M Offline
                          malditobastardo @Luksus
                          last edited by

                          @Luksus Hello everyone,
                          After testing this on my OP5 for the past 2 days and experiencing issues with the battery life (it only lasts for 2-3 hours with minimum use), I've decided to rollback to the stable kernel by using the updater (updating from the phone using the channels didn't work).
                          I will continue running more tests to try to see if this is an isolated case or not.

                          LuksusL 1 Reply Last reply Reply Quote 1
                          • LuksusL Offline
                            Luksus @malditobastardo
                            last edited by

                            @malditobastardo thanks forums testing.

                            I wonder, if maybe your CPU is not clocking down, or something like that. I will check the device tree of the OP5, if there are differences to the OP5t in this regard.

                            Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                            1 Reply Last reply Reply Quote -1
                            • danfroD Offline
                              danfro @Luksus
                              last edited by

                              @Luksus said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                              Because of that, i.e. the usb-config is more generic and does not allow to distinguish between OP5 and OP5T.

                              Btw. would a label like "OnePlus 5/5T" be possible to show that it could be either one?

                              LuksusL 2 Replies Last reply Reply Quote 0
                              • LuksusL Offline
                                Luksus @danfro
                                last edited by

                                @danfro should be possible.

                                Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                                1 Reply Last reply Reply Quote 0
                                • LuksusL Offline
                                  Luksus @danfro
                                  last edited by

                                  @danfro said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                                  Btw. would a label like "OnePlus 5/5T" be possible to show that it could be either one?

                                  Its updated now. (you would need to reflash system image with the latest pipeline build)

                                  Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                                  danfroD 1 Reply Last reply Reply Quote 0
                                  • danfroD Offline
                                    danfro @Luksus
                                    last edited by

                                    @Luksus Great, thanks for adding that.

                                    But when I try to flash the new ubuntu.img, I get the error message:

                                    $ fastboot flash system ubuntu.img
                                    Sending 'system' (2867200 KB)                      FAILED (remote: 'Requested download size is more than max allowed
                                    ')
                                    fastboot: error: Command failed
                                    

                                    Is that because of the resized partition?

                                    LuksusL 1 Reply Last reply Reply Quote 0
                                    • LuksusL Offline
                                      Luksus @danfro
                                      last edited by Luksus

                                      @danfro I don't know, why that happens. But I remember this from FP3 in the early porting days...
                                      Try fastboot -S 300M flash system ubuntu.img

                                      Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                                      danfroD 1 Reply Last reply Reply Quote 0
                                      • danfroD Offline
                                        danfro @Luksus
                                        last edited by

                                        @Luksus Thanks, looks like that has worked. The label is now shown as suggested above. 👍

                                        The log does show different size numbers than on my initial install of this kernel as shown above.

                                        $ fastboot -S 300M flash system ubuntu.img
                                        Invalid sparse file format at header magic
                                        Sending sparse 'system' 1/9 (300225 KB)            OKAY [ 12.544s]
                                        Writing 'system'                                   OKAY [  0.005s]
                                        Sending sparse 'system' 2/9 (301241 KB)            OKAY [ 15.055s]
                                        Writing 'system'                                   OKAY [  0.009s]
                                        Sending sparse 'system' 3/9 (298985 KB)            OKAY [ 14.681s]
                                        Writing 'system'                                   OKAY [  0.005s]
                                        Sending sparse 'system' 4/9 (302652 KB)            OKAY [ 14.525s]
                                        Writing 'system'                                   OKAY [  0.009s]
                                        Sending sparse 'system' 5/9 (281309 KB)            OKAY [ 13.530s]
                                        Writing 'system'                                   OKAY [  0.007s]
                                        Sending sparse 'system' 6/9 (307196 KB)            OKAY [ 16.153s]
                                        Writing 'system'                                   OKAY [  0.011s]
                                        Sending sparse 'system' 7/9 (293496 KB)            OKAY [ 14.079s]
                                        Writing 'system'                                   OKAY [  0.009s]
                                        Sending sparse 'system' 8/9 (294882 KB)            OKAY [ 14.181s]
                                        Writing 'system'                                   OKAY [  0.007s]
                                        Sending sparse 'system' 9/9 (246952 KB)            OKAY [ 12.233s]
                                        Writing 'system'                                   OKAY [  0.006s]
                                        Finished. Total time: 135.474s
                                        
                                        
                                        danfroD 1 Reply Last reply Reply Quote 0
                                        • danfroD Offline
                                          danfro @danfro
                                          last edited by danfro

                                          Btw. after flashing the kernel, my led works for notifications and charging. Also my sim cards get detected.

                                          As soon as I make my device r/w or apply any other change or an update that is not a full flash, this functionality breaks. No idea why though...

                                          Edit: Nope, did not work this time. A shame. I wish we could reproduce better why led and sim detection work sometimes to at least get an idea where to start fixing this.

                                          1 Reply Last reply Reply Quote 0
                                          • danfroD danfro referenced this topic on
                                          • LuksusL Offline
                                            Luksus
                                            last edited by

                                            I have a fix for the notification LED, you can test it with build here:
                                            https://gitlab.com/ubports/porting/community-ports/android9/oneplus-5/oneplus-cheeseburger-dumpling/-/commit/76220f525846ad2f6fa7c6fb63f861912ad576e5/pipelines

                                            I am not sure yet, if this fix will be the final solution.
                                            Maybe Jami has an idea, how to make it better, based on my description in the merge request.

                                            Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605F, Pinephone, Moto Z2 Force, OnePlus5T

                                            danfroD 1 Reply Last reply Reply Quote 0
                                            • danfroD Offline
                                              danfro @Luksus
                                              last edited by

                                              @Luksus said in Call for testing a the new build-variant "standalone-kernel-method" (vs. full-system-image):

                                              I have a fix for the notification LED, you can test it with build here:

                                              Oh, great! Just flashed that image. LED worked after the reboot. I will test this further.

                                              I know @vince-vs would love to see the LED fixed. 😉 (Would you also dare to flash a kernel to get the led working? :smiling_face_with_halo: )

                                              danfroD 1 Reply Last reply Reply Quote 0
                                              • First post
                                                Last post