Skip to content

Conversation

@AKuHAK
Copy link
Contributor

@AKuHAK AKuHAK commented Jul 9, 2025

This PR introduces the following changes:

  • Reduces the minimum APA partition size from 128 MB to 8 MB.
  • Fixes an issue where __empty partitions could exceed APA spec limits — they are now restricted to a maximum of 1 GB.
  • Enhances getStat() to report the total partition size (main + all sub-partitions) using the private_1 and private_2 fields.

@AKuHAK
Copy link
Contributor Author

AKuHAK commented Jul 9, 2025

I enabled in POSIX flag 8MB support as I didn't found any problems with it after massive testing. All this changes necessary for future pfs-shell improvements.
getStat change will also be useful for Athena project OSD-XMB

Copy link
Member

@uyjulian uyjulian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@uyjulian uyjulian merged commit 9c43697 into ps2dev:master Jul 9, 2025
3 checks passed
@AKuHAK
Copy link
Contributor Author

AKuHAK commented Jul 10, 2025

Doh, @uyjulian thanks for fast merge, but i kept one workaround there :D

// TODO: switch to HDDDevices.partitionMaxSize
u32 maxsize = 0x1FFFFF; // 1Gb

here wanna ask you if you know how to safely access HDDDevice.partitionMaxSize . Currently I limited empty partitions to be max 1Gb, but for disks larger than 80Gb APA specs allows larger single partitions (2Gb+), but current code will still limit empty to one Gb. Its definetly better than it was before, cause smaller partitions does not break APA specs, but still enforces fragmentation.

@AKuHAK AKuHAK deleted the renameapafix branch July 10, 2025 19:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants