yashsingh1/xdaforums huggingface dataset:
[Samsung Galaxy A54 5G] BlackMesa123:
Yes you can do that, no need to decompress the lz4 file as Odin supports it.

Vbmeta patching is required on devices with AVB 2.0, Magisk automatically patches the vbmeta.img in the AP tar when you patch it via the app.
[Samsung Galaxy A54 5G] fredapied:
Like you said : vbmeta.img is patched by magisk.

So, the provider update issue could comes from Magisk ?

And if we flash with the stock vbmeta.img (like you've done) there will have no issue (so why Magisk patches this file if the phone can run like you've done with the stock one...)
[Samsung Galaxy A54 5G] BlackMesa123:
If you patched the AP tar rather than the single boot.img you most probably have a patched vbmeta img installed. From my tests there are no issue using a stock vbmeta img with a custom kernel image installed, Magisk patches the vbmeta image as it is required for most devices to boot custom images. As I said that’s how I solved the issue in my end, I’m not entirely sure the issue is caused by that.
[Samsung Galaxy A54 5G] andreidi:
I noticed the recent software update. How can we install OTA updates after patching with magisk without having to reflash everything?
[Samsung Galaxy A54 5G] BlackMesa123:
That's the only possible way unfortunately.
[Samsung Galaxy A54 5G] andreidi:
Because relocking the bootloader would mean wiping all data. Otherwise flashing stock boot and vbmeta to remove magisk would be no problem.
[Samsung Galaxy A54 5G] BlackMesa123:
You don’t need to relock your bootloader to update your device. Just download the new firmware, patch the AP tar with Magisk and flash BL+patched AP+CP+HOME_CSC tar with Odin.
[Samsung Galaxy A54 5G] andreidi:
Yes, I just read and saw a video about this. So it is possible, without losing any of the data, installed apps and settings I have, it doesn't matter needing to flash it using odin. My mistake with my previous post "reflash everything" I meant "reinstall everything".

And after doing this I can flash stock vbmeta do fix the providers issue or do I have to use your patched vbmeta from your repository?
[Samsung Galaxy A54 5G] BlackMesa123:
Keep the stock vbmeta unless you have issues booting custom binaries due to AVB errors at boot.
[Samsung Galaxy A54 5G] andreidi:
I flashed latest firmware using BL, magisk patched AP, CP en HOME_CSC with odin and now it reboots in recovery (bootloop) and it prompts me to factory data reset. What to do so I don't have to reinstall everything?
[Samsung Galaxy A54 5G] BlackMesa123:
Reflash BL+CP+stock AP+HOME_CSC, backup your data, flash BL+CP+patched AP+HOME_CSC, factory reset.
[Samsung Galaxy A54 5G] andreidi:
I messed it up, unfortunately. I tried to flash again only AP magisk patched, but then I lost everything. It's not a big issue as I had everything synced on my Google account (contacts, photos, a lot of app settings etc.), only a hassle to reinstall every app en set everything up. How can I avoid this in the future if I want to update the firmware? What did I do wrong: flashed original BL, Magisk patched AP, original CP, original HOME_CSC? I had some stock apps uninstalled using ADB AppControl, but they were only removed from the data partition, system partition wasn't modified, maybe this was the issue?
[Samsung Galaxy A54 5G] BlackMesa123:
A factory reset is mandatory the first time you install Magisk, as it’s also explained in its install guide.
[Samsung Galaxy A54 5G] andreidi:
I had Magisk already installed, firmware version ending in S4AWF7, then flashed U5AWGJ after patching with magisk and this failed. I thought I could simply retain all data including storage and installed apps with settings and simply update the firmware without any hassle.
[Samsung Galaxy A54 5G] andreidi:
I can't seem to get CTS Pass with SafetyNet checker using safetynetfix 2.4.0 mod 2.0 + shamiko 0,7.3 build 174 anymore with the AWGJ firmware, is this because of security patch level 2023-08-01 so we have to wait for an update for one/both modules?
[Samsung Galaxy A54 5G] corysilas:
My device is stuck on the 'Samsung Galaxy' screen. Please help me with the correct root installation process. I am attempting to root using Magisk, and I know how to get it out of this screen and install the normal boot without modifications.

I am trying to root the A54 5G Brazil ZTO A546EXXS4AWG4.

Please help me!"
[Samsung Galaxy A54 5G] andreidi:
Play integrity fix by chiteroman + shamiko did the trick
[Samsung Galaxy A54 5G] BlackMesa123:
After some research I actually found the real cause about this issue is a Samsung Knox feature called "PROCA", which prevents the VaultKeeper TA to start thus causing the service provider bug, so nothing to do with using a stock/patched vbmeta image. The actual fix would be to use a custom kernel without any Knox drivers (https://github.com/BlackMesa123/and...mmit/ca9b4bc3883c3e5767738bdbc28c073a8e33519b), eg. KSU.
[Samsung Galaxy A54 5G] andreidi:
@BlackMesa123 I saw there is a new software update AWHA. Even if i have magisk rooted rom, I got popup from system update. Is this normal?

I'm afraid to update it since I messed up my data the last time I updated rom with odin using stock bl, magisk patched ap, stock cp and stock home_csc, I got bootloop so i had to flash from scratch.

Is there any sure method to install ota update on magisk patched rom? Please advise me with a step by step procedure.

Is it possible to only patch init_boot.img with magisk and not the whole ap so that I could flash this instead of the whole ap?
[Samsung Galaxy A54 5G] andreidi:
So why does flashing stock vbmeta still fix the issue?
[Samsung Galaxy A54 5G] BlackMesa123:
I haven't tested stock vbmeta+Magisk patched init_boot.img, but if it works it's because the bootloader integrity status does not have a broken status, so PROCA will work normally.
[Samsung Galaxy A54 5G] BlackMesa123:
This happens because some module you've installed is spoofing your bootloader unlock status. Even if you click "Install" the update will not install correctly as the system image hash do not match the ones in the update.zip package. The only way to update with Magisk installed is by downloading the new firmware and flashing BL+CP+new Magisk patched AP+HOME_CSC.
[Samsung Galaxy A54 5G] andreidi:
I tried this the last time I updated to AWGJ, but after reboot got bootloop to recovery. I had to flash new rom without magisk patched with normal CSC, but lost everything installed. I simply used new rom stock BL, patched AP with magisk (done with magisk app installed on the old rom), stock cp and stock home_csc. Now I'm afraid to try again. What should have been the issue?
[Samsung Galaxy A54 5G] andreidi:
You said on the previous page that flashing stock vbmeta after flashing magisk patched ap fixes the carrier problem, that's why I asked. It works for me too.
[Samsung Galaxy A54 5G] BlackMesa123:
Always use the HOME_CSC tar, only use the CSC tar when you wanna factory reset your device.
[Samsung Galaxy A54 5G] andreidi:
I will try again after I backup every installed app and every setting. And in case I get bootloop what can I do to avoid full installation and configuration?
[Samsung Galaxy A54 5G] BlackMesa123:
First time installing Magisk/custom binaries from a full stock ROM requires a factory reset, so in case of boot loops restore the previous images you had installed.
[Samsung Galaxy A54 5G] andreidi:
With this update I can restore the previous rom because binary version is 5 for both roms. Otherwise not I guess.
[Samsung Galaxy A54 5G] seba2kk:
It didn't for me. Strange.
[Samsung Galaxy A54 5G] Jochen K.:
Hi,

scrolling through this thread, I seem to have a similar but different problem to the rest of you.

I rooted two devices concurrently - an A14 5G and an A54 5G.

For both I used the steps described in the first two posts, after finding "EUX" firmware with the correct names on SamFw - with a slight slight modification described by Topjohnwu on github / Installation of Magisk.

The A14 worked flawlessly, and the A54 seemed to do the same - until the reboot after Odin had declared "Pass".

At reboot a screen appeared which stated something like "System can't be loaded; probable corruption; perform factory reset."

I did so, then got the "Service Provider loop".

I tried to run Odin again, this time with the original AP file.

Now I've got an unrooted A54 that works perfectly (though the firmware seems not very new [or haven't there been any Security updates since the 1st of April?]).

My question:

Is it normal that a magisk_patched file creates a corruption whereas the original file gives me a working device?

P.S. I tried the whole procedure twice - this time checking all the downloaded zip files against their md5s, and even creating an md5 for the unzipped AP file to compare it with the version copied to the A54.
[Samsung Galaxy A54 5G] spacko1980:
I'm trying to get rid of the provider feature update bug by flashing unpatched vbmeta. But how do I do that?

I extracted vbmeta.img.lz4 from the AP I downloaded, booted into download mode and opened odin (3.13.1), chose the vbmeta.img.lz4 as AP and hit start. Odin is stuck at file analysis. Do I need to flash BL, CP and CSC also or do I need to repack AP with unpatched vbmeta.img? Would appreciate any pointers.
[Samsung Galaxy A54 5G] BlackMesa123:
You need to repack the .lz4 file you extracted in a tar package. Odin only supports .tar files, it can't flash single .img files.
[Samsung Galaxy A54 5G] angarato_surion:
Does OTA updates work on rooted devices?

Do you have to use this steps to re root the device or it stays rooted?
[Samsung Galaxy A54 5G] BlackMesa123:
OTA updates will not work anymore when rooted, you have to download the latest firmware and patch the AP tar via Odin.
[Samsung Galaxy A54 5G] angarato_surion:
will it always delete data whenever you install firmware and patch using odin ?
[Samsung Galaxy A54 5G] BlackMesa123:
Make sure you’re using the “HOME_CSC” tar instead of the “CSC” one to avoid factory resetting your device.
[Samsung Galaxy A54 5G] angarato_surion:
what do you mean with home_csc.tar ? idont have the device snice iam still searching for a device .
[Samsung Galaxy A54 5G] BlackMesa123:
Please check the official Magisk install instructions for more clarifications: https://topjohnwu.github.io/Magisk/install.html#upgrading-the-os
[Samsung Galaxy A54 5G] angarato_surion:
so you download the new firmware.

copy it to the sdcard of the device.

patch it with magisk

and flash the patched with magisk using odin to the samsung device ?
[Samsung Galaxy A54 5G] adrianinsaval:
hey guys, I've been out of the rooting game for a long while. Is bootloader unlocking still irreversible nowdays? once I unlock my phone will I always get an annoying stupid warning every time I boot or is that a problem of the past?
[Samsung Galaxy A54 5G] nyddoT:
October Update won't boot, what can I do?
[Samsung Galaxy A54 5G] x3n1:
Hi, is there any progress on patching vbmeta?
[Samsung Galaxy A54 5G] capdcanoa:
Same problem here!

Spanish A54 from Vodafone

I fixed it with "pm disable com.samsung.android.sdm.config"

Thank you so much
[Samsung Galaxy A54 5G] LidelnFR:
Thank you kindly, it seems to work! (I did not see your reply earlier, what a shame, it has been months! I should have looked earlier...).

What I did (in Windows command prompt):

adb shell "su -c pm disable com.samsung.android.sdm.config"
adb shell "su -c pm disable com.samsung.android.cidmanager"

(before that, I did it using "user 0" but I was afraid it would not be enough, so I took the risk to do it using root as you suggested)
[Samsung Galaxy A54 5G] Nitorac:
No problem !

For the "random" reboots, I noticed that for each reboot I request (either through Magisk or the normal system interface), it seems to rebuild all applications cache (dalvik ?). When the system is finished booting, it reboots itself a second time some seconds/minutes l but I don't know what is causing them.
[Samsung Galaxy A54 5G] LidelnFR:
Yes I noticed as well some reboots with applications being "optimized". Not a major issue if rebooting only seldom, afaiac
[Samsung Galaxy A54 5G] urbanman2004:
Any word on there being an exploit discovered to unlock the bootloader for the US version of the A54 phone?
[Samsung Galaxy A54 5G] billa:
Very unlikely at least not officially. There used to be a guy here on XDA who was able to unlock pretty much any Samsung for a small fee up to the Feb 2021 bootloader version only. Since the A54 (A546U) came out in May 2023, even he couldn't do it. It's better to just get an A546B, it has the same bands as the US version and can be easily rooted.
[Samsung Galaxy A54 5G] urbanman2004:
Only reason why I considered buying the A54 was b/c it was dirt cheap at around $120 give or take when I bought it last May and I was repurposing it as a business phone since it's 5G and my old business phone operated on 3G which has since been discontinued. I swore off using Samsung phones altogether since the last one I owned which was a Galaxy S7 back in 2017 could only be rooted w/ the bootloader still locked which could potentially be a disaster waiting to happen. And since the phone was only rooted, it had functionality issues such as multiple instances of overheating and quirky behavior like the screen being unresponsive, causing missed taps/touches onscreen. I'm not as enthused a/b rooting the A54 anyway since I don't use it as a daily driver, but I wanted to root it in order to record calls, but I guess that's in the rearview.
[Samsung Galaxy A54 5G] billa:
I'm quite familiar with the US model S7 being flaky when rooted via the eng-boot method. While I wouldn't call it a "disaster waiting to happen", there are certainly some drawbacks such as the ones you've mentioned. I also have an international S7 and S7edge which are bootloader unlocked and rooted via TWRP recovery. Course they are outdated now but it's great for testing purposes. heh

The international A54 (A546B model) is fully rootable and has most of the US bands with the exception of one (n41 or n71), which is no big deal and should work just fine. For recording you could just use a third party call recording app on an unrooted phone, or use a regular voice recording app activated during a speakerphone call, there's really no need to root it for that.
[Samsung Galaxy A54 5G] tommyzc1705:
here is the source of a twrp, but it is incomplete xd

GitHub - Nitorac/android_device_samsung_a54x: TWRP device tree for the Samsung A54 5G (Exynos)

TWRP device tree for the Samsung A54 5G (Exynos). Contribute to Nitorac/android_device_samsung_a54x development by creating an account on GitHub.

github.com
[Samsung Galaxy A54 5G] pvdeejay:
Hello,

I have got Samsung Galaxy A54 5G. I haven't yet checked the exact model. I do know it's on Android 13.

My goal is to run preferably magisk rooted lineage GSI or magisk rooted AOSP GSI or something close to it instead of samsung stock variant of android.

This is my first samsung device thus I need some advices.

Is there a better thread to talk about this? I have chosen this one because you are discussing various quirks related to this device.

The most straight forward method of accomplishing my goal looks to be patching the stock recovery with patch-recovery at https://github.com/Johx22/Patch-Recovery/ and then using fastbootd to flash GSI system image. Is this patching method working for this device? Can I also run the script locally if I have android-sdk setup? When fastboot is available as a result of this patching will I be able to also use fastboot to wipe chache and data?

Finally is there a success story of anyone running lineage or any other GSI on this device?

Thanks for any pointers and hints you can give to me.

Greetings

Peter
[Samsung Galaxy A54 5G] billa:
If it's the international SM-A546B/E model, then you should be able to do it.

But if it's any of the North American models SM-A546U/U1/V/W they all have a locked bootloaders, therefore they cannot be rooted.
[Samsung Galaxy A54 5G] animediscover:
After magisk installed,turning on zygisk my phone became unstable.

EX- phone screen misbehaving,Freezing then auto reboot

Magisk-v26.1

firmware-SAMFW.COM_SM-A546E_SLK_A546EXXU5BWK4_fac

I used Odin3 v3.14.1_3B_PatcheD

Any fix :(
[Samsung Galaxy A54 5G] aqibjamal:
I pay 100$ for someone do it for me. i can do the mobile steps sharing screen.

SM-A546E/DS
[Samsung Galaxy A54 5G] beijingaiqingushi:
I had a SM-A5460 which was unlocked bootloader

I can flash magisk patched AP image (A5460ZCU5BWK7 , android14) to it using odin3

However, after reboot it go into recovery mode and require factory reset,

after factory reset the phone reboot, after that it need to be activated again, where is problem occurs: activating (use a sim card) keep returning error and I cannot setup the phone

Can anyone helps me?
[Samsung Galaxy A54 5G] billa:
Before rooting I would reflash it with a full stock firmware to get the phone working again.

https://samfw.com/firmware/SM-A5460

I'm not very familiar with Chinese models like the A5460, but from what I've read it should have an unlockable bootloader. Perhaps someone else can chime in on this.

The rooting process may reset the phone especially after formatting/wiping the data partition. However it shouldn't be stuck in a boot-loop or unable to set it up. In that case you must be doing something wrong.
[Samsung Galaxy A54 5G] shiboby:
I'm on 13/5.1 and haven't gotten any notice of an update even after a couple of months. Can I just download Android 14 and flash it, then go through the steps to root? Will I lose everything on internal storage if I do?
[Samsung Galaxy A54 5G] billa:
You can flash pretty much any Samsung via Odin. In most firmware packages you will find two CSC files which you will load into the CS/CSC tab in Odin.

One is called "HOME_xxx_CSC.tar" which will retain all your app and data after flashing.

The other is called "xxx_CSC.tar" without the name "HOME" (aka non-HOME) which will erase all your apps and data after lashing.

If only one CSC file is present and doesn't show "HOME" in the name, then it's most likely the second one (non-HOME) which will erase everything.

Either one will likely erase the root when flashing via Odin, so it's best to flash it via the root recovery of Magisk or TWRP which will retain root and all your data.
[Samsung Galaxy A54 5G] shiboby:
Hi billa,

thanks for the reply!

To the best of my knowledge, there is no TWRP for the A54. Or did I miss something?

Also, are you saying if I can find a firmware package that has both types of the CSC files, if I flash the one without "HOME" in the filename, it won't erase all my data?
[Samsung Galaxy A54 5G] billa:
This is for the international version A546B/E models, the US models A546U/U1 are bootloader locked therefore cannot be rooted. There's no TWRP at this time, but the Magisk boot/recovery should work just fine.

If you use Frija or SamFirm-Reborn, they will download the full firmware package (with "Binary" option checked) including the HOME and non-HOME CSC's. If you download it from some website, it may only come with the HOME CSC only.

Here's what I wrote earlier, please read it again to understand what each CSC will do.

"One is called "HOME_xxx_CSC.tar" which will retain all your app and user data after flashing.

The other is called "xxx_CSC.tar" without the name "HOME" (aka non-HOME) which will erase all your apps and user data after lashing."
[Samsung Galaxy A54 5G] shiboby:
Hi Billa,

that's good, I have an A546B ;) Ok, so the "HOME" Csc is what I need.

Unfortunately, when I woke up today, my phone offered me an update (the first time I've seen it). Not-fully-awake-me clicked the button to install it. Now for hours my phone reboots to Android Recovery and offers me:

Try Again

Factory Data Reset

View Recovery Logs.

Is there anyway to save my data on the phone?
[Samsung Galaxy A54 5G] billa:
The easiest way to fix it is by flashing it with a full stock firmware via Odin using the non-HOME CSC, without the name "HOME" in the file name. This will erase all your user data, but should fix.

You could try flashing it first with the "HOME" CSC to try to recover your data, but if it fails then the only option is the above.

Here's the A546B EUX European firmware

https://samfw.com/firmware/SM-A546B/EUX

Here's the A546B WWD US firmware

https://samfw.com/firmware/SM-A546B/WWD
[Samsung Galaxy A54 5G] shiboby:
Actually, I think I fixed it. I used SamFirm to get the latest firmware. Then, I used LDPlayer to emulate Android on my computer, so I could install magisk and patch the AP file. Then I used ODIN to install the BL, Patched AP, CP, and HOME CSC. This got my phone to boot again with all my data, and most of my settings, still there. However, I had no root, so I copied the original AP file over to my phone, used magisk to patch that, and then reflashed everything. So now I have Android 14, all my data, and root.

Phew...I was worried there for a bit.
[Samsung Galaxy A54 5G] garethk1979:
*the AP file is patched from within magisk, not within Odin as the recommended changes have stated
[Samsung Galaxy A54 5G] billa:
I guess he was trying to patch AP in an Android emulator LDPlayer running in Windows, then flash it via Odin.
[Samsung Galaxy A54 5G] meric57:
Hello, the manipulation for bootloader is I think the same as all Samsung releases since the security reinforcement of Google and Samsung.

Then don't forget to patch official AP firmware with magisk and transferred to SD card with adb push, as explained here https://topjohnwu.github.io/Magisk/install.html
[Samsung Galaxy A54 5G] shiboby:
That is correct. Windows 10, LDPlayer running, magisk opened within LDPlayer to patch the AP
[Samsung Galaxy A54 5G] meric57:
Hello, I made a fix to remove the security message for the A546B model see my post on this page https://xdaforums.com/t/remove-security-message-after-root-at-startup.4657805/.

As I don't have root my A54 5G if someone can test it to see thank you, if back ok I will do for A546E.
[Samsung Galaxy A54 5G] andreidi:
That warning can be removed. You have to download your Samsung stock firmware and unzip it. You need the "BL...tar.md5" file and unpack it. It contains "up_param.bin". In some case it's "up_param.bin.lz4" which you can unpack with an 7Zip-"Add-on". I recommend that you open the bin file with 7Zip (not unzip it!), just open it (Rightclick > 7-Zip > Open). In there you will find the “svb_orange.jpg” and “booting_warning.jpg”. Then delete these. Then repack "up_param.bin" this further to "up_param.bin.lz4" and flash using BL from Odin.
[Samsung Galaxy A54 5G] mrbonine:
Hi:

Just experienced my first flash dead end with the A54. After accomplishing this so many times, but with many more soft fails over the years than straightforward successful roots I'm stuck.

After merging the info here, which is very helpful however the initial one, with improvements seems to have the mandatory factory reset in the wrong order and place, and the later descriptive narration, I likely skipped or somehowI just didn't do it right.

My A54 is stuck in download/bootloader mode. I can achieve off after vol dn/power but only for a few seconds. If I change key presses after off I may get a (slight vib) but the phone returns to download mode. I've tried every key hold I can think of but I'm likely not being patient enough. I've tried them with the USB cable in and out and PC is detecting the phone. I'll attach the Odin responses.

Ideas?
[Samsung Galaxy A54 5G] billa:
You're likely trying to flash it with a firmware version lower than what's already on the phone, which can cause those flashing errors due to rollback protection.

I would download the latest firmware using Frija or SamFirm, put the phone in download mode. Hold down Vol Up + Vol Down + Power for about 30 seconds (sometimes it can take longer), and flash away.
[Samsung Galaxy A54 5G] mrbonine:
Thank you, I don't think that's the issue, but going over every step I didnt move the Magisk patched AP file back to the PC correctly. I'll bet the copy screwed up the file. I'll have another go at it tomorrow.
[Samsung Galaxy A54 5G] billa:
Hope you're working with an Exynos model. If trying to flash a patched Boot or System on Qualcomm models (U/U1) it will fail due to locked bootloader. Anyway, if it's Exynos then try flashing it with the latest firmware.