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

comments: modify comments of src_ino and i_ino #519

Merged
merged 1 commit into from
Jun 24, 2022

Conversation

power-more
Copy link
Contributor

Signed-off-by: zhaoshang zhaoshangsjtu@linux.alibaba.com

@@ -914,7 +914,7 @@ pub struct RafsV5Inode {
pub i_digest: RafsDigest, // 32
/// parent inode number
pub i_parent: u64,
/// from fs stat()
/// rafs inode number, set_ino() from RAFS_ROOT_INODE = 1
Copy link
Collaborator

Choose a reason for hiding this comment

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

The comment is a little confusing, could you help to elaberate more?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

src_ino is rafs inode number, but not from fs stat().
src_ino is set by function set_ino(), and its number is from const RAFS_ROOT_INODE = 1.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I think for the "/" inode, it's set to RAFS_ROOT_INODE. For other inodes, it should be read from fs by stat().
If so, it would be better to just remove the comments.

@power-more power-more force-pushed the zhaoshang/comments branch from 3afe1f9 to 95deaca Compare June 22, 2022 09:21
@yqleng1987
Copy link
Contributor

@power-more , your pull request has been updated. A new test job will be submitted. Please wait in patience.

@yqleng1987
Copy link
Contributor

@power-more , the test job has been submitted. Please wait in patience.

@yqleng1987
Copy link
Contributor

@power-more , The CI test is completed, please check result:

Test CaseTest Result
merge-target-branch✅SUCCESS
build-docker-image✅SUCCESS
compile-nydus✅SUCCESS
compile-ctr-remote✅SUCCESS
compile-nydus-snapshotter✅SUCCESS
start-nydus-snapshotter-config-containerd✅SUCCESS
run-container-with-nydus-image✅SUCCESS

Congratulations, your test job passed!

@@ -914,7 +914,7 @@ pub struct RafsV5Inode {
pub i_digest: RafsDigest, // 32
/// parent inode number
pub i_parent: u64,
/// from fs stat()
/// rafs inode number, set from 1
Copy link
Member

Choose a reason for hiding this comment

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

How about:

/// Artifact inode number set by the nydus image builder. Start from RAFS_ROOT_INODE  = 1.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fix

Signed-off-by: zhaoshang <zhaoshangsjtu@linux.alibaba.com>
@yqleng1987
Copy link
Contributor

@power-more , your pull request has been updated. A new test job will be submitted. Please wait in patience.

@yqleng1987
Copy link
Contributor

@power-more , your test job has passed, and no need to test again.

@jiangliu jiangliu merged commit 79124eb into dragonflyoss:master Jun 24, 2022
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.

4 participants