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

Rename sysfs device label attribute to group and minor time tweak #14

Open
wants to merge 303 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
303 commits
Select commit Hold shift + click to select a range
f890540
bcachefs: btree_node_lock_increment()
koverstreet Jun 12, 2018
b01a88b
bcachefs: optimize __bch2_btree_iter_relock()
koverstreet Jun 12, 2018
4797746
bcachefs: BCH_NAME_MAX
koverstreet Jun 27, 2018
51dcc05
bcachefs: add missing include
koverstreet Jun 27, 2018
e62b3f9
bcachefs: delete some debug code
koverstreet Jun 27, 2018
e4c7d65
bcachefs: fix an assertion
koverstreet Jun 27, 2018
d7ac3bc
bcachefs: fix btree reserve calculations
koverstreet Jun 28, 2018
9d6c4bc
bcachefs: More btree unit tests
koverstreet Jul 1, 2018
f2f8985
bcachefs: bch2_btree_iter_set_pos() can now go backwards
koverstreet Jun 6, 2018
ef6c7a9
bcachefs: fix __btree_node_iter_used()
koverstreet Jul 1, 2018
ad0bf00
bcachefs: improve bkey_prev()
koverstreet Jul 1, 2018
6124e85
bcachefs: improve btree_node_iter_prev()
koverstreet Jul 1, 2018
8563076
bcachefs: refactor bch2_btree_node_get_sibling() a bit
koverstreet Jul 1, 2018
3b0077b
bcachefs: BTREE_ITER_TYPE
koverstreet Jul 1, 2018
4da5a8e
bcachefs: kill BTREE_ITER_END
koverstreet Jun 27, 2018
a5edf1c
bcachefs: btree_iter_prev()
koverstreet Jul 1, 2018
3b09dd1
bcachefs: don't expose extent whiteouts outside of btree code
koverstreet Jul 1, 2018
7ee9a94
bcachefs: bch2_btree_iter_traverse() no longer has to go up for inten…
koverstreet Jun 12, 2018
7aa1eeb
bcachefs: refactor bch2_btree_node_prefetch()
koverstreet Jun 12, 2018
0eaf4aa
bcachefs: fix a btree iter error path
koverstreet Jul 6, 2018
f7e725e
bcachefs: fix BTREE_INSERT_NOUNLOCK
koverstreet Jul 10, 2018
482ed6a
bcachefs: work around an older dirent bug
koverstreet Jul 12, 2018
594e484
bcachefs: acl code improvements
koverstreet Jul 10, 2018
d561a3e
bcachefs: work around an older xattr bug
koverstreet Jul 12, 2018
2be0f4c
bcachefs: Fix __bch2_strtoh
koverstreet Jul 16, 2018
e9e810d
bcachefs: Fix a bug when dropping invalid btree keys
koverstreet Jul 16, 2018
cf45a5c
bcachefs: improve bch2_btree_iter_copy()
koverstreet Jul 13, 2018
d58c00a
bcachefs: move an assertion to expensive_debug_checks
koverstreet Jul 16, 2018
576f6c6
bcachefs: trivial optimization for fewer transaction restarts
koverstreet Jul 14, 2018
dfd1ad7
bcachefs: create lost+found when initializing fs
koverstreet Jul 13, 2018
9aa9d21
bcachefs: add BCH_INODE_UNLINKED
koverstreet Jul 13, 2018
cf76695
bcachefs: New transaction infrastructure
koverstreet Jun 11, 2018
391e3dd
bcachefs: Convert dirent/xattr/inode code to new transactions
koverstreet Jun 12, 2018
38126c9
bcachefs: Convert bch2_write_inode() to new transactions
koverstreet Jul 6, 2018
b08eed1
bcachefs: Make bch2_set_acl() fully atomic
koverstreet Jul 10, 2018
09054cf
bcachefs: Make create path fully atomic
koverstreet Jul 3, 2018
45aa2a8
bcachefs: Make hardlink path fully atomic
koverstreet Jul 6, 2018
2d3a61b
bcachefs: Make unlink path atomic
koverstreet Jul 7, 2018
c710b0f
bcachefs: Make rename fully atomic
koverstreet Jul 6, 2018
b00fdff
bcachefs: Make bch2_setattr_nonsize() fully atomic
koverstreet Jul 10, 2018
8934a54
bcachefs: Convert bch2_symlink to new transactions
koverstreet Jul 10, 2018
6f7e673
bcachefs: Only check inode i_nlink during full fsck
koverstreet Jul 15, 2018
2b281f0
bcachefs: Convert raw uses of bch2_btree_iter_link() to new transactions
koverstreet Jul 12, 2018
7f55a3d
bcachefs: trace transaction restarts
koverstreet Jul 13, 2018
e87b37a
bcachefs: Fix device add
koverstreet Jul 21, 2018
5b7f770
bcachefs: Fix a use after free in the journal code
koverstreet Jul 17, 2018
da91dca
bcachefs: add bch_verbose() statements for shutdown
koverstreet Jul 21, 2018
760cac3
bcachefs: Simplify bch2_write_inode_trans, fix lockdep splat
koverstreet Jul 17, 2018
0bf02eb
bcachefs: Fix mtime/ctime updates
koverstreet Jul 17, 2018
6ef4b8f
bcachefs: bch2_trans_update() now takes struct btree_insert_entry
koverstreet Jul 17, 2018
b488900
bcachefs: Use ei_update_lock consistently
koverstreet Jul 21, 2018
a6277de
bcachefs: fix rename + fsync
koverstreet Jul 22, 2018
1c963b4
bcachefs: Fix an assertion
koverstreet Jul 22, 2018
5791054
bcachefs: don't call bch2_bucket_seq_cleanup from journal_buf_switch
koverstreet Jul 22, 2018
4a6c95b
bcachefs: kill bucket mark sector count saturation
koverstreet Jul 22, 2018
7b2fd9c
bcachefs: Invalidate buckets when writing to alloc btree
koverstreet Jul 22, 2018
911b4e8
bcachefs: fix nbuckets usage on device resize
koverstreet Jul 23, 2018
61540fa
bcachefs: fix fsync after create
koverstreet Jul 23, 2018
a34df90
bcachefs: fix mtime/ctime update on truncate
koverstreet Jul 23, 2018
cd846d6
bcachefs: fix last_seq_ondisk
koverstreet Jul 23, 2018
455b4b8
bcachefs: Assorted journal refactoring
koverstreet Jul 23, 2018
ef7570b
bcachefs: minor fsync fix
koverstreet Jul 23, 2018
7939b75
bcachefs: fix bch2_val_to_text()
koverstreet Jul 23, 2018
b5f5858
bcachefs: Fix locking in allocator thread
koverstreet Jul 24, 2018
bb83d99
bcachefs: Fix an assertion in the btree node merge path
koverstreet Jul 24, 2018
073b5a3
bcachefs: bch2_mark_key() now takes bch_data_type
koverstreet Jul 24, 2018
f3e4529
bcachefs: kill s_alloc, use bch_data_type
koverstreet Jul 24, 2018
fdeb426
bcachefs: Account for internal fragmentation better
koverstreet Jul 24, 2018
b5f8436
bcachefs: Change how replicated data is accounted
koverstreet Jul 24, 2018
7efbf7e
bcachefs: Better calculation of copygc threshold
koverstreet Aug 1, 2018
bcfeca2
bcachefs: BCH_SB_RESERVE_BYTES
koverstreet Jul 24, 2018
937be3f
bcachefs: Factor out btree_key_can_insert()
koverstreet Aug 3, 2018
cfc76b1
bcachefs: improved rw_aux_tree_bsearch()
koverstreet Aug 6, 2018
3269e16
bcachefs: bkey_written()
koverstreet Aug 6, 2018
04a2a3e
bcachefs: extent unit tests
koverstreet Aug 2, 2018
1c5521a
bcachefs: lift ordering restriction on 0 size extents
koverstreet Jul 22, 2016
65872f0
bcachefs: make struct btree_iter a bit smaller
koverstreet Aug 5, 2018
515a5d1
bcachefs: extent_squash() can no longer fail
koverstreet Aug 5, 2018
8039940
bcachefs: BTREE_INSERT_JOURNAL_RES_FULL is no longer possible
koverstreet Aug 5, 2018
38ba85a
bcachefs: Fix build when CONFIG_BCACHEFS_DEBUG=n
koverstreet Aug 11, 2018
0f4d352
bcachefs: mempoolify btree_trans
koverstreet Aug 9, 2018
331f60f
bcachefs: bch2_extent_trim_atomic()
koverstreet Aug 5, 2018
5abf168
bcachefs: convert bchfs_write_index_update() to bch2_extent_update()
koverstreet Aug 8, 2018
665c799
bcachefs: convert truncate to bch2_extent_update()
koverstreet Aug 9, 2018
b0e7005
bcachefs: convert fpunch to bch2_extent_update()
koverstreet Aug 9, 2018
8fc4fc8
bcachefs: convert fcollapse to bch2_extent_update()
koverstreet Aug 11, 2018
b221a34
bcachefs: kill i_sectors_hook
koverstreet Aug 5, 2018
bdb4bdf
bcachefs: kill extent_insert_hook
koverstreet Aug 8, 2018
a3e54be
bcachefs: pass around bset_tree less
koverstreet Aug 11, 2018
c987aec
bcachefs: Prioritize fragmentation in bucket allocator
koverstreet Aug 21, 2018
b44020e
bcachefs: Comparison function cleanups
koverstreet Aug 21, 2018
0d6636f
bcachefs: Fix a btree iter bug when iter pos == POS_MAX
koverstreet Aug 21, 2018
183f04c
bcachefs: Dirent repair code
koverstreet Aug 21, 2018
959be92
bcachefs: don't select COMPACTION
koverstreet Aug 31, 2018
ad36018
bcachefs: make fsck spew less
koverstreet Aug 28, 2018
cdd226a
bcachefs: fix a divide
koverstreet Sep 6, 2018
38785d9
bcachefs: Fix a deadlock
koverstreet Sep 15, 2018
882ab1c
bcachefs: fix bch2_acl_chmod()
koverstreet Sep 21, 2018
1162414
bcachefs: Fix suspend when moving data faster than ratelimit
koverstreet Sep 26, 2018
9b249a3
bcachefs: Fix failure to suspend
koverstreet Oct 1, 2018
9d71025
bcachefs: Split out alloc_background.c
koverstreet Oct 6, 2018
8eab7ee
bcachefs: Allocation code refactoring
koverstreet Oct 6, 2018
1e3932b
bcachefs: fix a spurious gcc warning
koverstreet Oct 12, 2018
74d4469
bcachefs: fix missing include
koverstreet Oct 12, 2018
836ab6d
bcachefs: extent_ptr_decoded
koverstreet Oct 2, 2018
7582f41
bcachefs: kill bch_extent_crc_type
koverstreet Oct 2, 2018
cf80a10
bcachefs: extent_for_each_ptr_decode()
koverstreet Sep 28, 2018
ae3794d
bcachefs: bch2_extent_drop_ptrs()
koverstreet Sep 30, 2018
e90d4c5
bcachefs: bch2_extent_ptr_decoded_append()
koverstreet Sep 28, 2018
e1d1d4a
bcachefs: BCH_EXTENT_ENTRY_TYPES()
koverstreet Sep 30, 2018
0c07689
bcachefs: btree gc refactoring
koverstreet Oct 21, 2018
9f03f56
bcachefs: add functionality for heaps to update backpointers
koverstreet Oct 21, 2018
ad65334
bcachefs: kill struct bch_replicas_cpu_entry
koverstreet Oct 30, 2018
daaee5a
bcachefs: replicas: prep work for stripes
koverstreet Oct 30, 2018
d09c4b8
bcachefs: more key marking refactoring
koverstreet Nov 1, 2018
9818fd3
bcachefs: new avoid mechanism for io retries
koverstreet Nov 1, 2018
d952676
bcachefs: fix bch2_bkey_print_bfloat
koverstreet Nov 1, 2018
f8c0a4b
bcachefs: Some fixes for building in userspace
koverstreet Nov 4, 2018
65c50b7
bcachefs: fix bounds checks in bch2_bio_map()
koverstreet Nov 4, 2018
0e70d18
bcachefs: Fix journal replay when replicas sb section missing
koverstreet Nov 4, 2018
d184907
bcachefs: Rename nofsck opt to fsck
koverstreet Nov 4, 2018
c67ad97
bcachefs: Fix an assertion when rebuilding replicas
koverstreet Nov 4, 2018
f74950e
bcachefs: Scale down number of writepoints when low on space
koverstreet Nov 5, 2018
59fa07e
bcachefs: Assorted fixes for running on very small devices
koverstreet Nov 5, 2018
e6130ff
bcachefs: Disk usage in compressed sectors, not uncompressed
koverstreet Nov 5, 2018
2c0c78f
Set the last mount time using the realtime clock
modelrockettier Nov 5, 2018
afe2fe4
bcachefs: fix a replicas bug
koverstreet Nov 9, 2018
ade4665
bcachefs: delete some dead code
koverstreet Nov 9, 2018
4c829d8
bcachefs: revamp to_text methods
koverstreet Nov 9, 2018
de56988
bcachefs: Check for unsupported features
koverstreet Nov 12, 2018
f86e617
bcachefs: stripe support for replicas tracking
koverstreet Oct 30, 2018
2567e44
bcachefs: Move key marking out of extents.c
koverstreet Nov 5, 2018
a7ac9ea
bcachefs: Centralize marking of replicas in btree update path
koverstreet Nov 7, 2018
7f47f24
bcachefs: More btree gc refactorings
koverstreet Nov 12, 2018
18da87b
bcachefs: Erasure coding
koverstreet Nov 1, 2018
cb6fcdf
bcachefs: fix typo when picking read method
koverstreet Nov 14, 2018
eb0be7e
bcachefs: Fix an error path
koverstreet Nov 15, 2018
685456c
bcachefs: Clean up, possixly fix page disk reservation accounting
koverstreet Nov 15, 2018
94e2555
bcachefs: start erasure coding after journal replay
koverstreet Nov 19, 2018
2e1d2ed
bcachefs: Don't block on journal reservation with btree locks held
koverstreet Nov 19, 2018
eedc192
bcachefs: Journal refactoring
koverstreet Nov 18, 2018
34634b9
bcachefs: Allocator startup improvements
koverstreet Nov 19, 2018
e3183b7
bcachefs: fix btree iterator bug when using depth > 0
koverstreet Nov 21, 2018
f191ca2
bcachefs: fix mempool double initialization
koverstreet Nov 21, 2018
42b174e
bcachefs: gc now operates on second set of bucket marks
koverstreet Jul 23, 2018
5440048
bcachefs: Allow for new alloc fields
koverstreet Nov 23, 2018
2976c55
bcachefs: Select required config opts for erasure coding
koverstreet Nov 23, 2018
a8eaa6b
Revert "bcachefs: start erasure coding after journal replay"
koverstreet Nov 23, 2018
3c0fb9d
bcachefs: shim for userspace raid library
koverstreet Nov 23, 2018
ab38841
bcachefs: Btree locking fix, refactoring
koverstreet Nov 23, 2018
df3d4b4
bcachefs: Stripes now properly subject to gc
koverstreet Nov 24, 2018
4ff0552
bcachefs: drop a faulty assertion
koverstreet Nov 24, 2018
7a44894
bcachefs: Hold usage_lock over mark_key and fs_usage_apply
koverstreet Nov 23, 2018
ec49139
bcachefs: return errors correctly from gc
koverstreet Nov 27, 2018
e7daa85
bcachefs: fix waiting on an open journal entry
koverstreet Nov 27, 2018
3e4ae84
bcachefs: split out bkey_sort.c
koverstreet Nov 27, 2018
9ec3211
bcachefs: Fix a btree iter usage error
koverstreet Nov 29, 2018
84c099a
bcachefs: Make bkey types globally unique
koverstreet Nov 1, 2018
33b1d65
bcachefs: Track nr_inodes with the key marking machinery
koverstreet Nov 29, 2018
46a4d43
bcachefs: drop bogus percpu_ref_tryget
koverstreet Nov 24, 2018
d2677b6
bcachefs: Deferred btree updates
koverstreet Jul 17, 2018
3c7191c
bcachefs: Add new alloc fields
koverstreet Jul 22, 2018
e73ec46
bcachefs: move dirty into bucket_mark
koverstreet Nov 19, 2018
32f6350
bcachefs: New blockcount field for bch_stripe
koverstreet Nov 25, 2018
fd7d104
bcachefs: s/usage_lock/mark_lock
koverstreet Nov 26, 2018
ae0dd20
bcachefs: fix for spinning on journal reservation
koverstreet Dec 4, 2018
2593b56
bcachefs: fix bch2_extent_ptr_decoded_append()
koverstreet Dec 4, 2018
e9f848d
bcachefs: propagate BCH_WRITE_CACHED
koverstreet Dec 5, 2018
1cdebf0
bcachefs: Compression fixes
koverstreet Dec 5, 2018
ddd9456
bcachefs: Fix for running in degraded mode
koverstreet Dec 6, 2018
016ef75
bcachefs: improve/clarify ptr_disk_sectors()
koverstreet Dec 6, 2018
24a09d0
bcachefs: improve extent debugcheck fn
koverstreet Dec 6, 2018
7cb67a8
bcachefs: fix an incorrect bkey_debugcheck() call
koverstreet Dec 6, 2018
a10ea94
bcachefs: switch replicas to mark_lock
koverstreet Dec 1, 2018
4245a83
bcachefs: refactor bch_fs_usage
koverstreet Nov 27, 2018
5ea12a5
bcachefs: include summarized counts in fs_usage
koverstreet Dec 1, 2018
d75f530
bcachefs: Fix bkey_method compilation on gcc 7.3.0
modelrockettier Dec 9, 2018
e238e29
bcachefs: Fix for building in userspace
koverstreet Dec 12, 2018
f61c687
bcachefs: use x-macros more consistently
koverstreet Dec 13, 2018
92cffbf
bcachefs: merge BCH_INODE_FIELDS_INHERIT/BCH_INODE_OPTS
koverstreet Dec 13, 2018
33700a7
bcachefs: bch2_fs_quota_transfer
koverstreet Dec 17, 2018
9a44371
bcachefs: Add flags to indicate if inode opts were inherited or expli…
koverstreet Dec 13, 2018
cac4648
bcachefs: add bcachefs_effective xattrs
koverstreet Dec 17, 2018
ab1818e
bcachefs: rename keeps inheritable inode opts consistent
koverstreet Dec 17, 2018
000bada
bcachefs: bch2_ioc_reinherit_attrs()
koverstreet Dec 17, 2018
d91ce7d
bcachefs: Fix duplicate ioctl nr
koverstreet Dec 17, 2018
4ce87fa
bcachefs: fix device remove error path
koverstreet Dec 18, 2018
34b6ee1
bcachefs: fix ja->cur_idx use while reading journal
koverstreet Dec 18, 2018
4e2912e
bcachefs: fix an rcu usage bug
koverstreet Dec 18, 2018
b75fd4f
bcachefs: fix build when BCACHEFS_QUOTA=n
koverstreet Dec 19, 2018
4ddc162
bcachefs: more project quota fixes
koverstreet Dec 19, 2018
c64991b
bcachefs: Lots of option handling improvements
koverstreet Dec 19, 2018
dd45637
bcachefs: fix new reinherit_attrs ioctl
koverstreet Dec 19, 2018
b215cac
bcachefs: Minor replicas.c refactoring
koverstreet Dec 17, 2018
946156d
bcachefs: factor out acc_u64s()
koverstreet Dec 17, 2018
303e278
bcachefs: use crc64 from lib/
koverstreet Jan 11, 2019
00ab885
add_to_page_cache_vec()
koverstreet Aug 23, 2018
f7c4346
add_to_page_cache_lru_vec()
koverstreet Aug 23, 2018
5f028e8
bcachefs: hook up add_to_page_cache_lru_vec()
koverstreet Aug 23, 2018
e74c1e3
bcachefs: correctly initialize bch_extent_ptr
koverstreet Jan 12, 2019
9ded406
bcachefs: More allocator startup improvements
koverstreet Jan 13, 2019
57393f0
bcachefs: fix a dio bug
koverstreet Jan 14, 2019
595f10b
bcachefs: fixes for getting stuck flushing journal pins
koverstreet Jan 14, 2019
8a6a99d
bcachefs: Fix an allocator error path
koverstreet Jan 18, 2019
fba0731
bcachefs: Add a workqueue for journal reclaim
koverstreet Jan 19, 2019
a069324
bcachefs: Fix some reserve calculations
koverstreet Jan 19, 2019
55e00ac
bcachefs: dio arithmetic improvements
koverstreet Jan 19, 2019
21779c2
bcachefs: fix error message in device remove path
koverstreet Jan 21, 2019
e370c21
bcachefs: fix check for if extent update is allocating
koverstreet Jan 21, 2019
ee83e76
bcachefs: break out filesystem level disk accounting by replicas entry
koverstreet Dec 1, 2018
cdd92c5
bcachefs: Fix fifo overflow in allocator startup
koverstreet Jan 23, 2019
0666edf
bcachefs: Persist alloc info on clean shutdown
koverstreet Nov 19, 2018
cc20141
bcachefs: Improve c version of __bkey_cmp_bits
koverstreet Jan 22, 2019
f3cb8cf
bcachefs: Persist stripe blocks_used
koverstreet Nov 26, 2018
d75e700
bcachefs: fix inode counting
koverstreet Jan 25, 2019
195942d
bcachefs: improve alloc_debug
koverstreet Jan 25, 2019
e78cfc1
bcachefs: New journal_entry_res mechanism
koverstreet Jan 24, 2019
4337db1
bcachefs: sysfs trigger for bch2_alloc_write
koverstreet Jan 24, 2019
7179543
bcachefs: percpu utility code
koverstreet Feb 6, 2019
8fe5169
bcachefs: Fix a bug when shutting down before allocator started
koverstreet Feb 9, 2019
6d9aa1b
bcachefs: fix for unmount hang
koverstreet Feb 8, 2019
408f9ef
bcachefs: delete a debug printk
koverstreet Feb 9, 2019
80457e8
bcachefs: fix bch2_sb_field_resize()
koverstreet Feb 9, 2019
21da576
bcachefs: reserve space in journal for fs usage entries
koverstreet Jan 24, 2019
6c6f15f
bcachefs: write out fs usage
koverstreet Jan 24, 2019
cdacf5e
bcachefs: journal_replay_early()
koverstreet Jan 25, 2019
a8c2c75
bcachefs: initialize fs usage summary in recovery
koverstreet Jan 25, 2019
4ce17db
bcachefs: serialize persistent_reserved
koverstreet Feb 10, 2019
1fb8635
bcachefs: don't do initial gc if have alloc info feature
koverstreet Feb 6, 2019
09a5465
bcachefs: Don't need to walk inodes on clean shutdown
koverstreet Feb 10, 2019
bddd29f
bcachefs: no need to run gc when initializing new fs
koverstreet Feb 11, 2019
826f685
bcachefs: Fix a lockdep splat
koverstreet Feb 11, 2019
4fb7570
Propagate gfp_t when allocating pte entries from __vmalloc
koverstreet Feb 11, 2019
9c6e97c
bcachefs: Fix a locking bug
koverstreet Feb 12, 2019
a8bd542
bcachefs: Fix oldest_gen handling
koverstreet Feb 12, 2019
8d11e8a
bcachefs: gc lock no longer needed for disk reservations
koverstreet Feb 12, 2019
5ba5fd0
bcachefs: Fix double counting when gc is running
koverstreet Feb 12, 2019
86e1629
bcachefs: refactor key marking code a bit
koverstreet Feb 12, 2019
1879283
bcachefs: fix more locking bugs
koverstreet Feb 13, 2019
4d3f874
bcachefs: fixes for cached data accounting
koverstreet Feb 14, 2019
dbf7e45
bcachefs: Convert bucket invalidation to key marking path
koverstreet Feb 13, 2019
e1964d1
bcachefs: Add a mechanism for blocking the journal
koverstreet Feb 14, 2019
71628be
bcachefs: kill bch_fs_usage_summarized
koverstreet Feb 15, 2019
2252e4b
bcachefs: fs_usage_u64s()
koverstreet Feb 15, 2019
89f1d09
bcachefs: Assorted journal refactoring
koverstreet Feb 18, 2019
ea43593
bcachefs: force str_hash code to be inlined
koverstreet Feb 20, 2019
09a38f4
bcachefs: fix a deadlock on startup
koverstreet Feb 20, 2019
2d1aed5
bcachefs: Fix gc handling of bucket gens
koverstreet Feb 20, 2019
fa785f7
bcachefs: Renamed device label sysfs attribute
modelrockettier Jan 31, 2019
743f977
bcachefs: Use ktime_get_coarse_real_ts64 for the time
modelrockettier Jan 31, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions Documentation/core-api/generic-radix-tree.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
=================================
Generic radix trees/sparse arrays
=================================

.. kernel-doc:: include/linux/generic-radix-tree.h
:doc: Generic radix trees/sparse arrays

generic radix tree functions
----------------------------

.. kernel-doc:: include/linux/generic-radix-tree.h
:functions:
1 change: 1 addition & 0 deletions Documentation/core-api/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ Core utilities
errseq
printk-formats
circular-buffers
generic-radix-tree
memory-allocation
mm-api
gfp_mask-from-fs-io
Expand Down
12 changes: 6 additions & 6 deletions arch/alpha/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ pgd_free(struct mm_struct *mm, pgd_t *pgd)
}

static inline pmd_t *
pmd_alloc_one(struct mm_struct *mm, unsigned long address)
pmd_alloc_one(struct mm_struct *mm, unsigned long address, gfp_t gfp)
{
pmd_t *ret = (pmd_t *)__get_free_page(GFP_KERNEL|__GFP_ZERO);
pmd_t *ret = (pmd_t *)get_zeroed_page(gfp);
return ret;
}

Expand All @@ -52,10 +52,10 @@ pmd_free(struct mm_struct *mm, pmd_t *pmd)
}

static inline pte_t *
pte_alloc_one_kernel(struct mm_struct *mm, unsigned long address)
pte_alloc_one_kernel(struct mm_struct *mm, unsigned long address,
gfp_t gfp)
{
pte_t *pte = (pte_t *)__get_free_page(GFP_KERNEL|__GFP_ZERO);
return pte;
return (pte_t *)get_zeroed_page(gfp);
}

static inline void
Expand All @@ -67,7 +67,7 @@ pte_free_kernel(struct mm_struct *mm, pte_t *pte)
static inline pgtable_t
pte_alloc_one(struct mm_struct *mm, unsigned long address)
{
pte_t *pte = pte_alloc_one_kernel(mm, address);
pte_t *pte = pte_alloc_one_kernel(mm, address, GFP_KERNEL);
struct page *page;

if (!pte)
Expand Down
10 changes: 3 additions & 7 deletions arch/arc/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,14 +91,10 @@ static inline int __get_order_pte(void)
}

static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long address)
unsigned long address,
gfp_t gfp)
{
pte_t *pte;

pte = (pte_t *) __get_free_pages(GFP_KERNEL | __GFP_ZERO,
__get_order_pte());

return pte;
return (pte_t *) __get_free_pages(gfp|__GFP_ZERO, __get_order_pte());
}

static inline pgtable_t
Expand Down
12 changes: 7 additions & 5 deletions arch/arm/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,10 @@

#ifdef CONFIG_ARM_LPAE

static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr)
static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
return (pmd_t *)get_zeroed_page(GFP_KERNEL);
return (pmd_t *)get_zeroed_page(gfp);
}

static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd)
Expand All @@ -48,7 +49,7 @@ static inline void pud_populate(struct mm_struct *mm, pud_t *pud, pmd_t *pmd)
/*
* Since we have only two-level page tables, these are trivial
*/
#define pmd_alloc_one(mm,addr) ({ BUG(); ((pmd_t *)2); })
#define pmd_alloc_one(mm,addr,gfp) ({ BUG(); ((pmd_t *)2); })
#define pmd_free(mm, pmd) do { } while (0)
#define pud_populate(mm,pmd,pte) BUG()

Expand Down Expand Up @@ -81,11 +82,12 @@ static inline void clean_pte_table(pte_t *pte)
* +------------+
*/
static inline pte_t *
pte_alloc_one_kernel(struct mm_struct *mm, unsigned long addr)
pte_alloc_one_kernel(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
pte_t *pte;

pte = (pte_t *)__get_free_page(PGALLOC_GFP);
pte = (pte_t *)get_zeroed_page(gfp);
if (pte)
clean_pte_table(pte);

Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mm/idmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ static void idmap_add_pmd(pud_t *pud, unsigned long addr, unsigned long end,
unsigned long next;

if (pud_none_or_clear_bad(pud) || (pud_val(*pud) & L_PGD_SWAPPER)) {
pmd = pmd_alloc_one(&init_mm, addr);
pmd = pmd_alloc_one(&init_mm, addr, GFP_KERNEL);
if (!pmd) {
pr_warn("Failed to allocate identity pmd.\n");
return;
Expand Down
5 changes: 3 additions & 2 deletions arch/arm/mm/mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -980,10 +980,11 @@ void __init create_mapping_late(struct mm_struct *mm, struct map_desc *md,
bool ng)
{
#ifdef CONFIG_ARM_LPAE
pud_t *pud = pud_alloc(mm, pgd_offset(mm, md->virtual), md->virtual);
pud_t *pud = pud_alloc(mm, pgd_offset(mm, md->virtual), md->virtual,
GFP_KERNEL);
if (WARN_ON(!pud))
return;
pmd_alloc(mm, pud, 0);
pmd_alloc(mm, pud, 0, GFP_KERNEL);
#endif
__create_mapping(mm, md, late_alloc, ng);
}
Expand Down
8 changes: 4 additions & 4 deletions arch/arm/mm/pgd.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@ pgd_t *pgd_alloc(struct mm_struct *mm)
* Allocate PMD table for modules and pkmap mappings.
*/
new_pud = pud_alloc(mm, new_pgd + pgd_index(MODULES_VADDR),
MODULES_VADDR);
MODULES_VADDR, GFP_KERNEL);
if (!new_pud)
goto no_pud;

new_pmd = pmd_alloc(mm, new_pud, 0);
new_pmd = pmd_alloc(mm, new_pud, 0, GFP_KERNEL);
if (!new_pmd)
goto no_pmd;
#endif
Expand All @@ -72,11 +72,11 @@ pgd_t *pgd_alloc(struct mm_struct *mm)
* contains the machine vectors. The vectors are always high
* with LPAE.
*/
new_pud = pud_alloc(mm, new_pgd, 0);
new_pud = pud_alloc(mm, new_pgd, 0, GFP_KERNEL);
if (!new_pud)
goto no_pud;

new_pmd = pmd_alloc(mm, new_pud, 0);
new_pmd = pmd_alloc(mm, new_pud, 0, GFP_KERNEL);
if (!new_pmd)
goto no_pmd;

Expand Down
18 changes: 10 additions & 8 deletions arch/arm64/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@

#define check_pgt_cache() do { } while (0)

#define PGALLOC_GFP (GFP_KERNEL | __GFP_ZERO)
#define PGD_SIZE (PTRS_PER_PGD * sizeof(pgd_t))

#if CONFIG_PGTABLE_LEVELS > 2

static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr)
static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
return (pmd_t *)__get_free_page(PGALLOC_GFP);
return (pmd_t *)get_zeroed_page(gfp);
}

static inline void pmd_free(struct mm_struct *mm, pmd_t *pmdp)
Expand All @@ -60,9 +60,10 @@ static inline void __pud_populate(pud_t *pudp, phys_addr_t pmdp, pudval_t prot)

#if CONFIG_PGTABLE_LEVELS > 3

static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long addr)
static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
return (pud_t *)__get_free_page(PGALLOC_GFP);
return (pud_t *)get_zeroed_page(gfp);
}

static inline void pud_free(struct mm_struct *mm, pud_t *pudp)
Expand Down Expand Up @@ -91,17 +92,18 @@ extern pgd_t *pgd_alloc(struct mm_struct *mm);
extern void pgd_free(struct mm_struct *mm, pgd_t *pgdp);

static inline pte_t *
pte_alloc_one_kernel(struct mm_struct *mm, unsigned long addr)
pte_alloc_one_kernel(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
return (pte_t *)__get_free_page(PGALLOC_GFP);
return (pte_t *)get_zeroed_page(gfp);
}

static inline pgtable_t
pte_alloc_one(struct mm_struct *mm, unsigned long addr)
{
struct page *pte;

pte = alloc_pages(PGALLOC_GFP, 0);
pte = alloc_pages(GFP_KERNEL|__GFP_ZERO, 0);
if (!pte)
return NULL;
if (!pgtable_page_ctor(pte)) {
Expand Down
8 changes: 4 additions & 4 deletions arch/arm64/mm/hugetlbpage.c
Original file line number Diff line number Diff line change
Expand Up @@ -210,14 +210,14 @@ pte_t *huge_pte_alloc(struct mm_struct *mm,
pte_t *ptep = NULL;

pgdp = pgd_offset(mm, addr);
pudp = pud_alloc(mm, pgdp, addr);
pudp = pud_alloc(mm, pgdp, addr, GFP_KERNEL);
if (!pudp)
return NULL;

if (sz == PUD_SIZE) {
ptep = (pte_t *)pudp;
} else if (sz == (PAGE_SIZE * CONT_PTES)) {
pmdp = pmd_alloc(mm, pudp, addr);
pmdp = pmd_alloc(mm, pudp, addr, GFP_KERNEL);

WARN_ON(addr & (sz - 1));
/*
Expand All @@ -233,9 +233,9 @@ pte_t *huge_pte_alloc(struct mm_struct *mm,
pud_none(READ_ONCE(*pudp)))
ptep = huge_pmd_share(mm, addr, pudp);
else
ptep = (pte_t *)pmd_alloc(mm, pudp, addr);
ptep = (pte_t *)pmd_alloc(mm, pudp, addr, GFP_KERNEL);
} else if (sz == (PMD_SIZE * CONT_PMDS)) {
pmdp = pmd_alloc(mm, pudp, addr);
pmdp = pmd_alloc(mm, pudp, addr, GFP_KERNEL);
WARN_ON(addr & (sz - 1));
return (pte_t *)pmdp;
}
Expand Down
8 changes: 6 additions & 2 deletions arch/csky/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,17 @@ static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd,
extern void pgd_init(unsigned long *p);

static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long address)
unsigned long address,
gfp_t gfp)
{
pte_t *pte;
unsigned long *kaddr, i;

pte = (pte_t *) __get_free_pages(GFP_KERNEL | __GFP_RETRY_MAYFAIL,
pte = (pte_t *) __get_free_pages(gfp | __GFP_RETRY_MAYFAIL,
PTE_ORDER);
if (!pte)
return NULL;

kaddr = (unsigned long *)pte;
if (address & 0x80000000)
for (i = 0; i < (PAGE_SIZE/4); i++)
Expand Down
6 changes: 3 additions & 3 deletions arch/hexagon/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,10 @@ static inline struct page *pte_alloc_one(struct mm_struct *mm,

/* _kernel variant gets to use a different allocator */
static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long address)
unsigned long address,
gfp_t gfp)
{
gfp_t flags = GFP_KERNEL | __GFP_ZERO;
return (pte_t *) __get_free_page(flags);
return (pte_t *) get_zeroed_page(gfp);
}

static inline void pte_free(struct mm_struct *mm, struct page *pte)
Expand Down
15 changes: 9 additions & 6 deletions arch/ia64/include/asm/pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,10 @@ pgd_populate(struct mm_struct *mm, pgd_t * pgd_entry, pud_t * pud)
pgd_val(*pgd_entry) = __pa(pud);
}

static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long addr)
static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
return quicklist_alloc(0, GFP_KERNEL, NULL);
return quicklist_alloc(0, gfp, NULL);
}

static inline void pud_free(struct mm_struct *mm, pud_t *pud)
Expand All @@ -58,9 +59,10 @@ pud_populate(struct mm_struct *mm, pud_t * pud_entry, pmd_t * pmd)
pud_val(*pud_entry) = __pa(pmd);
}

static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr)
static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr,
gfp_t gfp)
{
return quicklist_alloc(0, GFP_KERNEL, NULL);
return quicklist_alloc(0, gfp, NULL);
}

static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd)
Expand Down Expand Up @@ -100,9 +102,10 @@ static inline pgtable_t pte_alloc_one(struct mm_struct *mm, unsigned long addr)
}

static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long addr)
unsigned long addr,
gfp_t gfp)
{
return quicklist_alloc(0, GFP_KERNEL, NULL);
return quicklist_alloc(0, gfp, NULL);
}

static inline void pte_free(struct mm_struct *mm, pgtable_t pte)
Expand Down
4 changes: 2 additions & 2 deletions arch/ia64/mm/hugetlbpage.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ huge_pte_alloc(struct mm_struct *mm, unsigned long addr, unsigned long sz)
pte_t *pte = NULL;

pgd = pgd_offset(mm, taddr);
pud = pud_alloc(mm, pgd, taddr);
pud = pud_alloc(mm, pgd, taddr, GFP_KERNEL);
if (pud) {
pmd = pmd_alloc(mm, pud, taddr);
pmd = pmd_alloc(mm, pud, taddr, GFP_KERNEL);
if (pmd)
pte = pte_alloc_map(mm, pmd, taddr);
}
Expand Down
6 changes: 3 additions & 3 deletions arch/ia64/mm/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -217,13 +217,13 @@ put_kernel_page (struct page *page, unsigned long address, pgprot_t pgprot)
pgd = pgd_offset_k(address); /* note: this is NOT pgd_offset()! */

{
pud = pud_alloc(&init_mm, pgd, address);
pud = pud_alloc(&init_mm, pgd, address, GFP_KERNEL);
if (!pud)
goto out;
pmd = pmd_alloc(&init_mm, pud, address);
pmd = pmd_alloc(&init_mm, pud, address, GFP_KERNEL);
if (!pmd)
goto out;
pte = pte_alloc_kernel(pmd, address);
pte = pte_alloc_kernel(pmd, address, GFP_KERNEL);
if (!pte)
goto out;
if (!pte_none(*pte))
Expand Down
13 changes: 4 additions & 9 deletions arch/m68k/include/asm/mcf_pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,10 @@ extern inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte)
extern const char bad_pmd_string[];

extern inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long address)
unsigned long address,
gfp_t gfp)
{
unsigned long page = __get_free_page(GFP_DMA);

if (!page)
return NULL;

memset((void *)page, 0, PAGE_SIZE);
return (pte_t *) (page);
return (pte_t *) get_zeroed_page(gfp|GFP_DMA);
}

extern inline pmd_t *pmd_alloc_kernel(pgd_t *pgd, unsigned long address)
Expand All @@ -30,7 +25,7 @@ extern inline pmd_t *pmd_alloc_kernel(pgd_t *pgd, unsigned long address)
}

#define pmd_alloc_one_fast(mm, address) ({ BUG(); ((pmd_t *)1); })
#define pmd_alloc_one(mm, address) ({ BUG(); ((pmd_t *)2); })
#define pmd_alloc_one(mm, address, gfp) ({ BUG(); ((pmd_t *)2); })

#define pte_alloc_one_fast(mm, addr) pte_alloc_one(mm, addr)

Expand Down
9 changes: 6 additions & 3 deletions arch/m68k/include/asm/motorola_pgalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@
extern pmd_t *get_pointer_table(void);
extern int free_pointer_table(pmd_t *);

static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm, unsigned long address)
static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long address,
gfp_t gfp)
{
pte_t *pte;

pte = (pte_t *)__get_free_page(GFP_KERNEL|__GFP_ZERO);
pte = (pte_t *)get_zeroed_page(gfp);
if (pte) {
__flush_page_to_ram(pte);
flush_tlb_kernel_page(pte);
Expand Down Expand Up @@ -67,7 +69,8 @@ static inline void __pte_free_tlb(struct mmu_gather *tlb, pgtable_t page,
}


static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address,
gfp_t gfp)
{
return get_pointer_table();
}
Expand Down
Loading