-
Notifications
You must be signed in to change notification settings - Fork 3
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
Support ngnfs-tests #9
Open
valversity
wants to merge
19
commits into
versity:main
Choose a base branch
from
valversity:val/ngnfsTests
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
thread_stop_wait() already does a thread_stop_indicate() first thing, no need to do it twice. Signed-off-by: Valerie Aurora <[email protected]>
The return code is alreadly negative (-1); setting itself to its negative made it positive and broke the error handling code which assumes -ERRNO. Instead set it to -errno. Signed-off-by: Valerie Aurora <[email protected]>
The send thread of a peer socket may be asleep on a wait queue. Wake it so that the socket destroy can complete. Signed-off-by: Valerie Aurora <[email protected]>
end_write_io was clearing the dirty bit on the set, but not the block itself. Signed-off-by: Valerie Aurora <[email protected]>
Remove the thread_should_return() check from the outer loop so that we can't return without fully draining the queue. Signed-off-by: Valerie Aurora <[email protected]>
ngfns_pfs_read_inode() already destroys the transaction, no need to do it again.
We are renaming the manifests to maps and preparing for them to be provided by a server. This is the initial version of the part of the maps code shared by both kernel and user. Nothing uses it yet. Signed-off-by: Valerie Aurora <[email protected]>
The mapd server will replace specifying the devd addresses on the command line. Signed-off-by: Valerie Aurora <[email protected]>
Add an ngnfs-cli subcommand to ask for a map from the mapd server. Signed-off-by: Valerie Aurora <[email protected]>
Make all of ngnfs use the new maps code instead of the old manifests. Signed-off-by: Valerie Aurora <[email protected]>
Now that we are using the new maps code everywhere, delete the unused manifest code. Signed-off-by: Valerie Aurora <[email protected]>
Add thread_shutdown_all() which sends a SIGUSR1 to the main supervisory thread, which can then wake its child which is actually doing ngnfs things with signals off. Allows the program to exit cleanly for tests. Signed-off-by: Valerie Aurora <[email protected]>
Add a function to shutdown in-progress ngnfs threads in the event of a fatal fs-wide error like being unable to connect to the devd or mapd servers. Signed-off-by: Valerie Aurora <[email protected]>
If we get any connect() error, shut down the entire file system. Signed-off-by: Valerie Aurora <[email protected]>
Mount now requests the maps but does not wait for them to arrive before returning. Unmount now uses ngnfs_shutdown to quiesce work and wake blocked threads before calling the destroy routines.
Make debugfs exit if connect() fails to the mapd or devd server. At some point this should be a flag or a timeout, but for now this lets us write tests. Signed-off-by: Valerie Aurora <[email protected]>
Now that children can signal parents to quit, add a quit command to debugfs to exit cleanly. Signed-off-by: Valerie Aurora <[email protected]>
Build a static library for use by test binaries in ngnfs-tests. Signed-off-by: Valerie Aurora <[email protected]>
To make testing easier and support running as a SysV style daemon, make the default mode of the mapd and devd servers be to spawn a subprocess and signal the status of initialization before going into sigwait() mode. To prevent this, use the -f/--foreground option. Signed-off-by: Valerie Aurora <[email protected]>
05c37bc
to
91a7b6b
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To support automated testing by the external ngnfs-tests, this adds two commits on top of the clientExit branch: