スイッチのSDカードにexFATはやめておけ。ポケモン剣盾のSDカードデータ破損バグに関して海外のHomebrew側からのテクニカルな指摘。

31
リンク twitter.com Michael (@SciresM) on Twitter 442

Michael @SciresM
Pokemon researcher@ http://projectpokemon.org. Console hacker/Horizon OS Proselytizer/B9S & Atmosphère dev (Joyeux 15 juin!). !t.3fxzeyWo http://i.imgur.com/98xMuQz.png

Michael @SciresM

So, let's talk the Swish crash/data deletion issue. Crash report for that issue: gist.github.com/SciresM/de9010… The error code in question is "Software timeout in NAND access", and it's observed by the BCAT system module.

2019-11-15 23:02:56

では剣盾のエラー、データ削除の剣について語ろうか。

この件に関するクラッシュリポート

リンク Gist swsh_crash.log GitHub Gist: instantly share code, notes, and snippets.

この件に関するエラーコードは"Software timeout in NAND access"。そしてそれはBCATのsystem moduleで見られる。

Michael @SciresM

This timeout error occurs, and N's SDMMC driver resets a lot of state trying to recover. This leads to the other stuff being handled by the SDMMC driver (SD card filesystem) getting messed up --> N's shitty exFAT driver corrupts the SD card, as tends to happen.

2019-11-15 23:04:17

このタイムアウトエラーが起きると、スイッチのSDMMCドライバが修復しようとして沢山のステートをリセットする。

これによってSDMMCドライバに管理されているその他のもの、たとえばSDカードのファイルシステムを散らかされることになる。それによってスイッチのクソexFATドライバがSDカードを駄目にする事が起きる。

Michael @SciresM

It's unclear why the timeout is happening when BCAT is trying to access savedata in nand. Could be bad game access patterns, or could be concurrency with accesses to read gamedata, or a bunch of other stuff. Not much evidence pointing to the cause.

2019-11-15 23:05:25

何でBCATがnandに保存されたデータをアクセスしようとする時にタイムアウトが起きているのかは謎だ。酷いゲームアクセスパターンかもしれないし、ゲームデータを読み込もうとする時の同時実行かもしれないし、その他に色々有る。原因を示せる証拠があまりない。

Michael @SciresM

Either way, don't use the exFAT driver and you should be fine/not lose data even if your console crashes. I guess on Nintendo's end the action items are: -Figure out why software timeout occurs for NAND access. -Think about fixing prFile2, or using a less shitty exFAT driver.

2019-11-15 23:06:52

どのみちexFATドライバを使わなければ大丈夫、SDカードに保存されたデータを失うことはない。たとえゲーム機がクラッシュ(強制終了)してもな。

任天堂側には2つの選択肢があると思う。

-何でソフトウェアタイムアウトがNANDアクセス中に起きるのか。
-prFile2の修正か、今あるクソexFATドライバよりマシなドライバを使う。

Michael @SciresM

Also, to be explicit: save data is not at risk at all. Saves are stored on the internal NAND, which uses FAT32/doesn't corrupt. The only data at risk are downloaded games/other SD card files, and those can be redownloaded. The absolute worst case is you lose some screenshots.

2019-11-15 23:12:15

とりあえずセーブデータは安全だ。セーブデータはFAT32形式の内部NANDに保存されている。つまり駄目にされない。

危機にさらされているのはSDカードにダウンロードされたゲームとその他のファイルだが、これは再ダウンロードできる。

完全に最悪の場合はいくつかのスクリーンショットのロストだ。

Michael @SciresM

The error code the JP streamer saw as a result of the crash, on another note, was 2002-4690. This is part of fs::ResultFatFileSystemCorrupted(), and in particular "The SD card FAT is in an invalid format". Pretty conclusive -- the OS is explicitly reporting SD FAT corruption.

2019-11-15 23:19:41

日本人生放送配信者が配信中のエラーで見ることになったエラーコードの番号は2002-4690

これはfs::ResultFatFileSystemCorrupted()の一部で、特にThe SD card FAT is in an invalid format、「SDカードのFATの形式が不正です」を意味する。

かなり結論付けられるな。OSがSDのFATの破損を明らかにリポートしてる。

Michael @SciresM

Another clarification -- the crash in question may well not actually be Gamefreak's fault. The underlying error is an OS one (a NAND read is failing). Pokemon may be triggering it because its access patterns might be bad, but that's not for sure.

2019-11-16 00:53:38

一応言っておくけど、もしかしたらエラーはゲームフリークのせいではないのかもしれない。エラーコードはOSのものだ。(NAND読み込みに失敗している)。

ポケモンのアクセスパターンが酷いからトリガーになったかもしれないが、そこは確実ではない。

Michael @SciresM

Even in the case where something about the way Pokemon's accessing NAND is triggering the problem (maybe frequent auto-saving + background content downloading causes concurrent access issues?), the game was approved by lotcheck, so its accesses would have been approved.

2019-11-16 00:54:36

たとえポケモンのNANDの読み込み方がトリガーになってたとしても(自動セーブやバックグラウンドのコンテンツダウンロードとかが原因?)、このゲームはlotcheckにOK出されたんだ。つまりこの様なアクセスの許可を出されたのだ。

※lotcheckはこのゲームをゲーム機で走らせても問題ないかを確認してOKをだす任天堂の機関。

Michael @SciresM

Frankly, I think the most likely case here is that documentation says it's safe to do whatever Gamefreak's doing, and so whatever bad sequences of accesses are happening got approved because they *should* be correct. In that case, it's an OS problem, not a Pokemon problem.

2019-11-16 00:55:31

正直言って、書類はゲーフリがやろうとしてる事をセーフだとOKだした。なので読み込み問題は公式にセーフだと言い渡されたと同じ。その書類は正しくなければならないのだから。だからこの件はOSの問題であり、ポケモンの問題ではない。

Michael @SciresM

If this is the case, Gamefreak can still probably mitigate crashes via a software update that changes the access patterns to not trigger the issue, however the underlying problem would require a switch firmware update to solve.

2019-11-16 00:56:11

それが問題なのならゲームフリークはアップデートエラーを修正してアクセスパターンを変えることでトリガーにしないようにできるが、どのみち、この問題の解決にはスイッチのファームウェアアップデートが不可欠だ。

ArKaWu @ArKaWu

@SciresM My file-based emummc got corrupted on exfat and the user partition with the saves only consists of garbled symbols now, is it possible to recover lost data?

2019-11-15 23:22:05
1 ・・ 4 次へ