Project

General

Profile

Actions

Issue #2072

open

Issue #2025: Enable to recreate the EFS partition completely from scratch

Investigate how the stock RIL recovers partially corrupted EFS on GT-I9300

Added by Louis R over 4 years ago. Updated over 3 years ago.

Status:
New
Priority:
Low
Assignee:
-
Category:
Telephony and mobile data
Target version:
Start date:
07/06/2020
Due date:
% Done:

0%

Estimated time:
Resolution:
Device:
Galaxy S 3 (I9300)
Grant:
Type of work:
C programming

Description

Hi there,
A month ago or so, my i9300 stopped recognising my sim card. It worked fine for around two years. One day in the morning, my phone said "No sim card - no service". I cannot understand how and why the problem started.
The SIM card is working on other phones. None of other SIM I could use work with my i9300.
I restored nv_data.bin following this procedure: https://redmine.replicant.us/projects/replicant/wiki/RestoreEfsNvDataBackupFile It went well but didn't change anything.
Please find attached the logs I got using:

adb logcat -b radio

I am not sure how related this issue is with other similar issues, so I started a new one. I read similar issues, but it seems to me they are a little different. I cannot tell, really, for I am not really able to understand the logs. Do not hesitate to ask for more detail.

Hope someone can help me,
Best


Files

logs (79.5 KB) logs output of >logcat -b radio Louis R, 07/06/2020 08:37 AM
backup_efs-08072020.zip (426 KB) backup_efs-08072020.zip Louis R, 07/08/2020 01:14 PM
backup_efs-corrupted.zip (451 KB) backup_efs-corrupted.zip Louis R, 07/08/2020 01:14 PM
difference_efs-dir (848 Bytes) difference_efs-dir Louis R, 07/08/2020 01:14 PM
Actions #1

Updated by Kurtis Hanna over 4 years ago

Can you try to install both the Replicant 6.0 0004 rc1 Recovery and Operating systems from here? https://ftp-osl.osuosl.org/pub/replicant/images/replicant-6.0/0004-rc1/

Please make sure to read the "Your data will be erased" section before proceeding: https://ftp-osl.osuosl.org/pub/replicant/images/replicant-6.0/0004-rc1/README_VERY_IMPORTANT_INFORMATION.txt

This update has helped a number of people fix the bug you are experiencing, including the person here: https://redmine.replicant.us/boards/21/topics/15564

Please let us know if this works for you.

Cordially,
Kurtis

Actions #2

Updated by Louis R over 4 years ago

Thx Kurtis, I'll look into this related issue. I'll get back to you when the install is done, hope this works for me.
Best,
Louis

Actions #3

Updated by Louis R over 4 years ago

Just installed replicant 6.0 0004 rc1 recovery and OS: does not solve the pb ...

If I look at the related issue, I should be doing what Emmett says here: https://redmine.replicant.us/boards/21/topics/15564?r=15572#message-15572
But I guess I don't understand "I flashed the stock rom"?
What should I do?

Thx

Actions #4

Updated by Louis R about 4 years ago

Dear Kurtis and all,
I fixed the issue! Using the same method as Emmett in https://redmine.replicant.us/boards/21/topics/15564 : I flashed the stock rom, then the replicant rom back again. I do not have more idea of why the issue arose.
Best,
Louis

Actions #5

Updated by Denis 'GNUtoo' Carikli about 4 years ago

01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC:
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: xmm626_sec_modem_fmt_recv: Received FMT message
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: xmm626_sec_modem_fmt_recv: Message: aseq=0xff, command=IPC_PWR_PHONE_PWR_UP, type=IPC_TYPE_NOTI, size=0
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL: Updating RIL radio state to 0
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC:
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: xmm626_sec_modem_fmt_recv: Received FMT message
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: xmm626_sec_modem_fmt_recv: Message: aseq=0x00, command=IPC_MISC_ME_IMSI, type=IPC_TYPE_NOTI, size=16
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: ================================= IPC FMT data =================================
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: [0000]   0F 30 30 30 30 30 30 30  30 30 30 30 30 30 30 30   .0000000 00000000
01-04 19:30:03.035  1965  2301 D use-Rlog/RLOG-RIL-IPC: ================================================================================
01-04 19:30:03.110  1965  2303 D use-Rlog/RLOG-RIL-IPC: Reading RFS data failed
01-04 19:30:03.110  1965  2303 E use-Rlog/RLOG-RIL-IPC: Receiving from IPC RFS client failed
01-04 19:30:03.110  1965  2303 E use-Rlog/RLOG-RIL: IPC RFS client loop failed
01-04 19:30:03.170  1965  2303 D use-Rlog/RLOG-RIL: Closed IPC RFS client
01-04 19:30:03.170  1965  2303 D use-Rlog/RLOG-RIL: Opened IPC RFS client

That looks like a corrupted modem data partition (EFS).

Running the stock OS or specific versions of LineageOS is capable of reparing some issues.

Though we need to do more research on it. Ideally we'd want to be able to reconstruct the modem data partition (EFS) just with the IMEI, but we're not there yet.

Actions #6

Updated by Louis R about 4 years ago

I do not know how much my case can be used to do this research, but here are some details of my issue.
Please find attached my corrupted efs, my functional efs and the difference between the two directories (output of $ diff -qr dir1 dir2).

One can see there are differences. One would need to go into the details of the listed files to understand what was corrupted in my efs partition and led to the sim issue, but I am not really able to do this.

Hope this helps.

Btw, thx for doing what you guys do,
Best,
Louis

Actions #7

Updated by Denis 'GNUtoo' Carikli about 4 years ago

  • Subject changed from Sim card not recognised on i9300 to EFS data corruption on i9300 => SIM card not recognized.
  • Category set to Telephony and mobile data
  • Priority changed from Normal to Low
I've modified a bit the bugreport name to reflect the bug:
  • The original bug talked about the symptom of the SIM card not being recognized, and that's now fixed for Louis R
  • I think it's very interesting to keep that bug open not to loose it, as we might need it for future reference on work to recover from EFS corruptions, as the EFS backups before and after the reparation were posted.

On my side I've advanced a bit on this topic by doing some research on older devices that are supported by Replicant 4.2 but not 6.0, as we have way more documentation on them. I've added the information to the #2025 bug.

In a nutshell I was given code for a tool to change the IMEI for these devices, and I've also found how the template nv_data.bin is created, but I've not managed to rebuild the EFS from scratch yet despite of both advancements.

Actions #8

Updated by Denis 'GNUtoo' Carikli about 4 years ago

  • Related to Issue #2025: Enable to recreate the EFS partition completely from scratch added
Actions #9

Updated by Denis 'GNUtoo' Carikli about 4 years ago

  • Subject changed from EFS data corruption on i9300 => SIM card not recognized. to Investigate how the stock RIL recovers partially corrupted EFS on GT-I9300

I've renamed the bug again to integrate it better with the other bugs to reconstruct the EFS from scratch.

Actions #10

Updated by Denis 'GNUtoo' Carikli about 4 years ago

  • Parent task set to #2025

I've renamed the bug again to integrate it better with the other bugs to reconstruct the EFS from scratch.

Actions #11

Updated by _I3^ RELATIVISM over 3 years ago

  • Type of work C programming added
Actions

Also available in: Atom PDF