VisionFive2 Linux kernel

StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)

More than 9999 Commits   32 Branches   54 Tags
Commit Message
ntfs: fix ntfs_test_inode and ntfs_init_locked_inode function type
Luca Stefani
ntfs: replace attach_page_buffers with attach_page_private
Guoqing Jiang
ntfs: remove (un)?likely() from IS_ERR() conditions
Denis Efremov
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 96
Thomas Gleixner
ntfs: mft: remove VLA usage
Kees Cook
ntfs: fix bogus __mark_inode_dirty(I_DIRTY_SYNC | I_DIRTY_DATASYNC) call
Christoph Hellwig
ntfs: remove i_version handling
Jeff Layton
buffer: have alloc_page_buffers() use __GFP_NOFAIL
Jens Axboe
mm: only include blk_types in swap.h if CONFIG_SWAP is enabled
Christoph Hellwig
fs: Replace current_fs_time() with current_time()
Deepa Dinamani
fs: have submit_bh users pass in op and flags separately
Mike Christie
mm, fs: get rid of PAGE_CACHE_* and page_cache_{get,release} macros
Kirill A. Shutemov
NTFS: Correct two spelling errors "dealocate" to "deallocate" in mft.c.
Anton Altaparmakov
Fix common misspellings
Lucas De Marchi
NTFS: Fix invalid pointer dereference in ntfs_mft_record_alloc().
Anton Altaparmakov
include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
Tejun Heo
ntfs: Use new syncing helpers and update comments
Jan Kara
ntfs: remove private wrapper of endian helpers
Harvey Harrison
fs: rename buffer trylock
Nick Piggin
Remove duplicated unlikely() in IS_ERR()
Hirofumi Nakagawa
[PATCH] fs/ntfs: Conversion to generic boolean
Richard Knutsson
[PATCH] inode-diet: Eliminate i_blksize from the inode structure
Theodore Ts'o
[PATCH] fs: Removing useless casts
Panagiotis Issaris
[PATCH] bitops: ntfs: remove generic_ffs()
Akinobu Mita
NTFS: Semaphore to mutex conversion.
Ingo Molnar
NTFS: Fix a bug in fs/ntfs/inode.c::ntfs_read_locked_index_inode() where we forgot to update a temporary variable so loading index inodes which have an index allocation attribute failed.
Anton Altaparmakov
NTFS: Remove all the make_bad_inode() calls. This should only be called from read inode and new inode code paths.
Anton Altaparmakov
NTFS: Implement support for sector sizes above 512 bytes (up to the maximum supported by NTFS which is 4096 bytes).
Anton Altaparmakov
NTFS: - Change ntfs_cluster_alloc() to take an extra boolean parameter specifying whether the cluster are being allocated to extend an attribute or to fill a hole. - Change ntfs_attr_make_non_resident() to call ntfs_cluster_alloc() with @is_extension set to TRUE and remove the runlist terminator fixup code as this is now done by ntfs_cluster_alloc().
Anton Altaparmakov
NTFS: - Change {__,}ntfs_cluster_free() to also take an optional attribute search context as argument. This allows calling it with the mft record mapped. Update all callers. - Fix potential deadlock in ntfs_mft_data_extend_allocation_nolock() error handling by passing in the active search context when calling ntfs_cluster_free().
Anton Altaparmakov
NTFS: Change ntfs_attr_find_vcn_nolock() to also take an optional attribute search context as argument. This allows calling it with the mft record mapped. Update all callers.
Anton Altaparmakov
NTFS: Fix a 64-bitness bug where a left-shift could overflow a 32-bit variable which we now cast to 64-bit first (fs/ntfs/mft.c::map_mft_record_page().
Anton Altaparmakov
NTFS: Change ntfs_cluster_free() to require a write locked runlist on entry since we otherwise get into a lock reversal deadlock if a read locked runlist is passed in. In the process also change it to take an ntfs inode instead of a vfs inode as parameter.
Anton Altaparmakov
NTFS: Fix cluster (de)allocators to work when the runlist is NULL and more importantly to take a locked runlist rather than them locking it which leads to lock reversal.
Anton Altaparmakov
NTFS: Remove two bogus BUG_ON()s from fs/ntfs/mft.c.
Anton Altaparmakov
NTFS: Fix bug in mft record writing where we forgot to set the device in the buffers when mapping them after the VM had discarded them. Thanks to Martin MOKREJŠ for the bug report.
Anton Altaparmakov
NTFS: Fix a nasty deadlock that appeared in recent kernels. The situation: VFS inode X on a mounted ntfs volume is dirty. For same inode X, the ntfs_inode is dirty and thus corresponding on-disk inode, i.e. mft record, which is in a dirty PAGE_CACHE_PAGE belonging to the table of inodes, i.e. $MFT, inode 0. What happens: Process 1: sys_sync()/umount()/whatever... calls __sync_single_inode() for $MFT -> do_writepages() -> write_page for the dirty page containing the on-disk inode X, the page is now locked -> ntfs_write_mst_block() which clears PageUptodate() on the page to prevent anyone else getting hold of it whilst it does the write out. This is necessary as the on-disk inode needs "fixups" applied before the write to disk which are removed again after the write and PageUptodate is then set again. It then analyses the page looking for dirty on-disk inodes and when it finds one it calls ntfs_may_write_mft_record() to see if it is safe to write this on-disk inode. This then calls ilookup5() to check if the corresponding VFS inode is in icache(). This in turn calls ifind() which waits on the inode lock via wait_on_inode whilst holding the global inode_lock. Process 2: pdflush results in a call to __sync_single_inode for the same VFS inode X on the ntfs volume. This locks the inode (I_LOCK) then calls write-inode -> ntfs_write_inode -> map_mft_record() -> read_cache_page() for the page (in page cache of table of inodes $MFT, inode 0) containing the on-disk inode. This page has PageUptodate() clear because of Process 1 (see above) so read_cache_page() blocks when it tries to take the page lock for the page so it can call ntfs_read_page(). Thus Process 1 is holding the page lock on the page containing the on-disk inode X and it is waiting on the inode X to be unlocked in ifind() so it can write the page out and then unlock the page. And Process 2 is holding the inode lock on inode X and is waiting for the page to be unlocked so it can call ntfs_readpage() or discover that Process 1 set PageUptodate() again and use the page. Thus we have a deadlock due to ifind() waiting on the inode lock. The solution: The fix is to use the newly introduced ilookup5_nowait() which does not wait on the inode's lock and hence avoids the deadlock. This is safe as we do not care about the VFS inode and only use the fact that it is in the VFS inode cache and the fact that the vfs and ntfs inodes are one struct in memory to find the ntfs inode in memory if present. Also, the ntfs inode has its own locking so it does not matter if the vfs inode is locked.
Anton Altaparmakov
NTFS: Add an extra parameter @last_vcn to ntfs_get_size_for_mapping_pairs() and ntfs_mapping_pairs_build() to allow the runlist encoding to be partial which is desirable when filling holes in sparse attributes. Update all callers.
Anton Altaparmakov
NTFS: - Fix bug in fs/ntfs/attrib.c::ntfs_find_vcn_nolock() where after dropping the read lock and taking the write lock we were not checking whether someone else did not already do the work we wanted to do. - Rename ntfs_find_vcn_nolock() to ntfs_attr_find_vcn_nolock(). - Tidy up some comments in fs/ntfs/runlist.c. - Add LCN_ENOMEM and LCN_EIO definitions to fs/ntfs/runlist.h.
Anton Altaparmakov
NTFS: Fix printk format warnings on ia64. (Randy Dunlap)
Randy Dunlap
NTFS: - Split ntfs_map_runlist() into ntfs_map_runlist() and a non-locking helper ntfs_map_runlist_nolock() which is used by ntfs_map_runlist(). This allows us to map runlist fragments with the runlist lock already held without having to drop and reacquire it around the call. Adapt all callers. - Change ntfs_find_vcn() to ntfs_find_vcn_nolock() which takes a locked runlist. This allows us to find runlist elements with the runlist lock already held without having to drop and reacquire it around the call. Adapt all callers.
Anton Altaparmakov
NTFS: Fix stupid bug in fs/ntfs/mft.c introduced in last changeset.
Anton Altaparmakov
NTFS: Use i_size_{read,write}() in fs/ntfs/{aops.c,mft.c} and protect access to the i_size and other size fields using the size_lock.
Anton Altaparmakov
Linus Torvalds