Skip to content

docs: improve clarity in xattrs and chunked format documentation#29

Open
SKM2227229725 wants to merge 2 commits intoerofs:mainfrom
SKM2227229725:docs-pr28-followup
Open

docs: improve clarity in xattrs and chunked format documentation#29
SKM2227229725 wants to merge 2 commits intoerofs:mainfrom
SKM2227229725:docs-pr28-followup

Conversation

@SKM2227229725
Copy link
Copy Markdown
Contributor

This PR improves clarity in xattr and chunk-based format documentation.

Changes:

  • Added note about reserved e_name_index values (0 and 5)
  • Standardized "Bloom filter" capitalization
  • Improved wording for long xattr prefix structure
  • Clarified chunk size formula expression to avoid ambiguity

These changes are based on discussion in #28.

Copilot AI review requested due to automatic review settings March 21, 2026 18:21
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR expands and refines the EROFS on-disk format documentation by adding dedicated pages for extended attributes (xattrs) and the chunk-based file layout, and by improving phrasing/consistency in related docs.

Changes:

  • Add new xattrs on-disk format documentation, including reserved e_name_index notes and Bloom filter wording.
  • Add new chunk-based file format documentation, including clearer chunk size expression and multi-device addressing details.
  • Update the on-disk docs index to link these optional-feature pages; minor wording fix in core superblock table.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
src/ondisk/xattrs.md New xattr format page (superblock/inode fields, inline/shared xattrs, long prefixes, Bloom filter, image-share xattrs).
src/ondisk/chunked_format.md New chunk-based inode format page (chunk info record, entry formats, device table, address resolution).
src/ondisk/index.md Adds narrative + toctree entries to surface the new optional-feature docs.
src/ondisk/core_ondisk.md Improves wording (“48-bit layout specific”) in the superblock table.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/ondisk/xattrs.md Outdated
| 4 | `trusted.` |
| 6 | `security.` |

All other `e_name_index` values (including `0` and `5`) are reserved and must not be used unless defined by a future format extension.
Copy link

Copilot AI Mar 21, 2026

Choose a reason for hiding this comment

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

Add a blank line before the (shared_xattr_area)= label. As written, the label is immediately adjacent to the preceding paragraph, which can cause MyST/Sphinx to treat it as part of the paragraph instead of a standalone label and may break cross-referencing.

Suggested change
All other `e_name_index` values (including `0` and `5`) are reserved and must not be used unless defined by a future format extension.
All other `e_name_index` values (including `0` and `5`) are reserved and must not be used unless defined by a future format extension.

Copilot uses AI. Check for mistakes.
Comment thread src/ondisk/xattrs.md
Comment on lines +119 to +126
| Value | Prefix |
|-------|--------|
| 1 | `user.` |
| 2 | `system.posix_acl_access` |
| 3 | `system.posix_acl_default` |
| 4 | `trusted.` |
| 6 | `security.` |

Copy link

Copilot AI Mar 21, 2026

Choose a reason for hiding this comment

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

The e_name_index mapping table is labeled as a "Prefix", but entries system.posix_acl_access and system.posix_acl_default are full xattr names rather than prefixes (they don't end with a dot). Consider renaming the column/wording (e.g. "Prefix or full name") and/or explicitly stating that for these indexes the stored name suffix length (e_name_len) is 0.

Suggested change
| Value | Prefix |
|-------|--------|
| 1 | `user.` |
| 2 | `system.posix_acl_access` |
| 3 | `system.posix_acl_default` |
| 4 | `trusted.` |
| 6 | `security.` |
| Value | Prefix or full name |
|-------|----------------------|
| 1 | `user.` |
| 2 | `system.posix_acl_access` |
| 3 | `system.posix_acl_default` |
| 4 | `trusted.` |
| 6 | `security.` |
For indices `2` and `3`, the string shown above is the entire xattr name (no additional suffix bytes are stored), so `e_name_len` must be `0`. For the other indices, the string is a prefix and the remaining name bytes are stored as the suffix of length `e_name_len`.

Copilot uses AI. Check for mistakes.
@SKM2227229725 SKM2227229725 force-pushed the docs-pr28-followup branch 2 times, most recently from befead0 to fbb467a Compare April 7, 2026 12:44
@SKM2227229725
Copy link
Copy Markdown
Contributor Author

Hi @hsiangkao,

Thanks for your time.

I’ve resolved merge conflicts and ensured all checks are passing. I can also address the minor suggestions (label spacing and table wording) if needed.

Looking forward to your feedback.

Thanks!

@SKM2227229725
Copy link
Copy Markdown
Contributor Author

Hi @hsiangkao,

Just a gentle follow-up on this PR.
I’ve addressed earlier suggestions and ensured everything is clean and up to date.

Happy to make any further changes if needed.
Thanks for your time!

@hsiangkao
Copy link
Copy Markdown
Member

please rebase your commits first,

@SKM2227229725
Copy link
Copy Markdown
Contributor Author

Hi @hsiangkao,

I’ve resolved the merge conflicts with the latest upstream main and updated the branch.

Please let me know if any further changes are needed.

Thanks!

@hsiangkao
Copy link
Copy Markdown
Member

I don't think you resolved the issue.

Signed-off-by: SKM2227229725 <shailesh91199477@gmail.com>
@SKM2227229725
Copy link
Copy Markdown
Contributor Author

Hi @hsiangkao,

I’ve rebased the branch onto the latest upstream main and updated the PR.

Please let me know if anything else needs adjustment.

Thanks!

@SKM2227229725
Copy link
Copy Markdown
Contributor Author

Hi @hsiangkao,

Thanks for pointing that out. I’ve now rebased the branch onto the latest upstream main and force-pushed the updated branch.

GitHub is now showing no conflicts with the base branch and all checks are passing. Please let me know if there is still anything specific I should adjust.

Thanks!

Copy link
Copy Markdown
Member

@hsiangkao hsiangkao left a comment

Choose a reason for hiding this comment

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

for others, I will defer to @SToPire

Comment thread src/ondisk/xattrs.md Outdated
| 4 | `trusted.` |
| 6 | `security.` |

All other `e_name_index` values (including `0` and `5`) are reserved and must not be used unless defined by a future format extension.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

no, e_name_index 0 is used for arbitary namespace xattrs. They are only hidden by the runtime.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hi @hsiangkao,

Thanks for the clarification. I’ve updated the documentation to correctly reflect the usage of e_name_index = 0 for arbitrary namespace xattrs and pushed the changes.

Please let me know if anything else needs adjustment.

Thanks!

Signed-off-by: SKM2227229725 <shailesh91199477@gmail.com>
@SKM2227229725
Copy link
Copy Markdown
Contributor Author

Hi @SToPire,

Just a gentle follow-up on this PR. It has been updated based on previous feedback and is now rebased on the latest main.

I would really appreciate your review whenever you have time.

Thanks!

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.

3 participants