Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tmpfs is unusable #151

Open
Ismrbsmr opened this issue Jul 23, 2023 · 0 comments
Open

tmpfs is unusable #151

Ismrbsmr opened this issue Jul 23, 2023 · 0 comments

Comments

@Ismrbsmr
Copy link

Ismrbsmr commented Jul 23, 2023

(tldr: See 2 images, also attached IOS crash
report).

111E9748-51E0-48BB-9C02-D87502B0333D
8DE5D6ED-7333-42C4-B09E-6289C1EFBCD8

issue:

  1. mounting tmpfs results in write only mode. (touch returns file name is too long within tmpfs).

  2. Unmounting tmpfs will 100% result in a crash of the app.

  3. abi level rm on a filedesc in tmpfs will crash the app. busybox rm will just report permission issue.(perhaps due to first checking permission before abi)?

  4. basically tmpfs is unsuable.

  5. IOS crash returns "Address Size Fault" .

Theories:

  1. its the 'mount' syscall ( or 'mprotect' or suid bits called within mount param )

  2. its the inode offsets of 32 bit (ISH-AOK) address, differing from the IOS kernel (64 bit) address.

  3. It is due to the differing IOS and "linux"/ISH kernel paramaters of mount.

  4. Executables safely alloc and free avail mem, so it must be mount paramaters.

  5. it is due to the libmusl or busybox mount implimentation/param(related to suid bits).

Proposal:

  1. making a block device driver in /dev/ to mount the tmpfs with mount params preset.
  2. make every filedesc in tmpfs a buffered fifo.

Significance:

tmpfs will make some use cases 60-80% faster. (apt, fzf,tmux,etc...).

Maybe more rootfs distros can start init (related to tmpfs in fstab).

Let me know what you think and if you have any insight/leads to where to start to fix this issue.

534C5061-8496-427D-960A-264F4CA3ABBD
27FC0A0E-34BC-4811-8DA6-29A184887917

Thank you,

ADDITION:

Another solution is to use mmap and specify a valid address(size and location) paramaters manually at the ISH-AOK Kernel when mount is invoked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant