Ticket #11184 (closed enhancement: fixed)

Opened 3 years ago

Last modified 2 years ago

OpenFirmware ext4 filesystem support

Reported by: FGrose Owned by: FGrose
Priority: normal Milestone: Opportunity
Component: ofw - open firmware Version: Development firmware
Keywords: Cc:
Action Needed: test in build Verified: no
Deployments affected: Blocked By:
Blocking:

Description

observed on XO-1.75 B1 with q4b07 and q4b08 with os1, os40, & os41

at OFW command line:

fs-update ext:\os41.zd

returns

ext:\os41.zd:1: O┴ ?
 
WARNING: The file said highest block 0 but wrote only as high as block 0
00:00:00
ok

The same os41.zd file copied to an SD card formatted as vfat did not fail.

Attachments

log-1314347962.zip (144.8 kB) - added by FGrose 3 years ago.
logs
tune2fs (1.7 kB) - added by FGrose 3 years ago.

Change History

Changed 3 years ago by FGrose

logs

follow-up: ↓ 2   Changed 3 years ago by Quozl

  • owner set to wmb@…
  • type changed from defect to enhancement
  • next_action changed from never set to design
  • component changed from not assigned to ofw - open firmware
  • milestone changed from Not Triaged to Opportunity

OpenFirmware does not have ext4 support, so I wouldn't expect this to work.

Please provide the size in blocks of the external SD card, as shown by /proc/partitions, and the command used to format the card under Linux.

Meanwhile, use ext2, ext3, or fat.

Changed 3 years ago by FGrose

in reply to: ↑ 1   Changed 3 years ago by FGrose

Replying to Quozl:

Please provide the size in blocks of the external SD card, as shown by /proc/partitions, and the command used to format the card under Linux.

device 3979776 blocks
partition 3978240 blocks

The device was probably formatted with the Fedora Disk Utility. It reports,
Master Boot Record partitioning
Partition Type: Linux (0x83)
Type: Ext4 (version 1.0)

tune2fs -l output attached

  Changed 3 years ago by Quozl

  • summary changed from fs-update fails from SD card formatted as ext4 to OpenFirmware ext4 filesystem support

Reproduced.

Excluded fs-update. Excluded external SD port.


A text file and a .zd file were placed on ext4 formatted external SD card, and on an ext4 formatted USB drive, and OpenFirmware was used to read them into a 0xff filled buffer. The .zd file contained this byte sequence as first line: "zblocks: 20000 7331", hex:

7a 62 6c 6f 63 6b 73 3a 20 32 30 30 30 30 20 37 33 33 31 0a

The buffer contained this byte sequence after read:

7a 14 58 96 fa 75 0b 72 7a 1c ee 3a 73 1a 40 dc 71 d4 b0 a4

Displaying the text file with more showed no useful output.

  Changed 2 years ago by wmb@…

  • status changed from new to assigned

svn 2798 adds the ability to read from an ext4 filesystem.

svn 2799 adds the ability to delete files from ext4.

General file writing is not yet implemented.

  Changed 2 years ago by Quozl

Read and delete capability released in Q4C12.

  Changed 2 years ago by wmb@…

svn 2815 corrects a problem with group descriptor checksum management for ext4. The impact of that problem is filesystem corruption (correctable by fsck) when you delete a file on an ext4 filesystem with OFW.

Another problem has cropped up. If the journal is dirty (from Linux), OFW fails to recover it correctly.

  Changed 2 years ago by wmb@…

The aforementioned problem with journal recovery is fixed by svn 2816.

  Changed 2 years ago by wmb@…

svn 2817 fixes another journal recovery problem and enables creating new files and writing to them on ext4 filesystems. The writing works by using the old block-mapped format, which can coexist with the new extent-mapped format

  Changed 2 years ago by Quozl

  • owner changed from wmb@… to FGrose
  • status changed from assigned to new
  • next_action changed from design to test in build
  • version changed from 1.75-B1 to Development firmware

Q4D01 released, please test.

  Changed 2 years ago by FGrose

  • status changed from new to closed
  • resolution set to fixed

Tested with os30.zd4 on an ext4 formatted USB flash drive.

fs-update worked.

Note: See TracTickets for help on using tickets.