Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Add new options for Linux's fallocate(2) #1681

Merged
merged 1 commit into from Jul 5, 2017
Merged

Conversation

Burgos
Copy link
Member

@Burgos Burgos commented Oct 23, 2016

Linux's fallocate in the kernels newer than 3.15
brings three new options:

FALLOC_FL_COLLAPSE_RANGE
FALLOC_FL_ZERO_RANGE
FALLOC_FL_INSERT_RANGE

which are now defined in fcntl.d

Copy link
Member

@PetarKirov PetarKirov left a comment

Choose a reason for hiding this comment

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

@nemanja-boric-sociomantic
Copy link
Contributor

Any way to trigger the testers without ammending and pushing?

@wilzbach
Copy link
Member

Any way to trigger the testers without ammending and pushing?

Auto-tester automatically rebuilds the PRs from time to time, but unfortunately CircleCi doesn't.
The easiest is closing and reopening the issue (and of course contributors can go to CircleCi and click for a rebuild). We are working actively to improve the CI situation, so hopefully less annoyance in the future ;-)

@Burgos Burgos closed this Feb 12, 2017
@Burgos Burgos reopened this Feb 12, 2017
@Burgos
Copy link
Member Author

Burgos commented Feb 12, 2017

The easiest is closing and reopening the issue (and of course contributors can go to CircleCi and click for a rebuild)

Thanks, I just gave it a go!

@wilzbach
Copy link
Member

wilzbach commented Mar 4, 2017

Thanks, I just gave it a go!

It seems this didn't work either :S
Maybe you could try it again?

@Burgos
Copy link
Member Author

Burgos commented May 9, 2017

Rebased on master and now all tests (except autotester which is running) are passing.

@PetarKirov
Copy link
Member

Ping @jmdavis @schveiguy this looks good to go.

Copy link
Member

@wilzbach wilzbach left a comment

Choose a reason for hiding this comment

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

I guess we should add FALLOC_FL_UNSHARE_RANGE as well?

FALLOC_FL_NO_HIDE_STALE = 0x04,
FALLOC_FL_COLLAPSE_RANGE = 0x08,
FALLOC_FL_ZERO_RANGE = 0x10,
FALLOC_FL_INSERT_RANGE = 0x20
Copy link
Member

Choose a reason for hiding this comment

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

Looking at https://github.com/torvalds/linux/blob/v4.11/include/uapi/linux/falloc.h, it seems that

FALLOC_FL_UNSHARE_RANGE		0x40

has been added in the meantime.
It was added in October 2016: torvalds/linux@71be6b4

@Burgos
Copy link
Member Author

Burgos commented May 11, 2017 via email

Linux's fallocate in the kernels newer than 3.15
brings three new options:

FALLOC_FL_COLLAPSE_RANGE
FALLOC_FL_ZERO_RANGE
FALLOC_FL_INSERT_RANGE

which are now defined in fcntl.d
@Burgos
Copy link
Member Author

Burgos commented May 13, 2017

Updated!

Copy link
Member

@wilzbach wilzbach left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@wilzbach
Copy link
Member

@ other reviewers, for convenience the falloc header file can be e.g. found here https://github.com/torvalds/linux/blob/v4.11/include/uapi/linux/falloc.h

@nemanja-boric-sociomantic
Copy link
Contributor

Ha, thanks! I forgot about this one :-

@wilzbach
Copy link
Member

wilzbach commented Jul 5, 2017

Ha, thanks! I forgot about this one :-

Same here. Let's get this in then!

@dlang-bot dlang-bot merged commit 2fcbbd5 into dlang:master Jul 5, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
6 participants