aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2022-08-02RDMA/rxe: Fix error unwind in rxe_create_qp()Zhu Yanjun1-4/+8
In the function rxe_create_qp(), rxe_qp_from_init() is called to initialize qp, internally things like the spin locks are not setup until rxe_qp_init_req(). If an error occures before this point then the unwind will call rxe_cleanup() and eventually to rxe_qp_do_cleanup()/rxe_cleanup_task() which will oops when trying to access the uninitialized spinlock. Move the spinlock initializations earlier before any failures. Fixes: 8700e3e7c485 ("Soft RoCE driver") Link: https://lore.kernel.org/r/[email protected] Reported-by: [email protected] Signed-off-by: Zhu Yanjun <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2022-08-02Merge tag 'regulator-v5.20' of ↵Linus Torvalds25-470/+1955
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator updates from Mark Brown: "This has been a fairly quiet release for the regulator API, a few new drivers and a small API update: - Support for specifying an initial load as part of requesting regulators through the bulk API - Support for Maxim MAX597x, Qualcomm PM8074, PM8909 and Realtek RT5120 devices" * tag 'regulator-v5.20' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: (35 commits) regulator: core: Allow drivers to define their init data as const regulator: core: Allow specifying an initial load w/ the bulk API regulator: mt6380: Fix unused array warning regulator: Add missing type for 'regulator-microvolt-offset' regulator: core: Fix off-on-delay-us for always-on/boot-on regulators regulator: of: Fix refcount leak bug in of_get_regulation_constraints() regulator: pwm: Update Lee Jones' email address regulator: max597x: Don't return uninitialized variable in .probe regulator: qcom,spmi-regulator: add PMP8074 PMIC regulator: qcom,spmi-regulator: Convert to dtschema regulator: qcom_spmi: add support for PMP8074 regulators regulator: qcom_spmi: add support for HT_P600 regulator: qcom_spmi: add support for HT_P150 regulator: max597x: Remove unused including <linux/version.h> regulator: Fix MFD_MAX597X dependency regulator: Fix parameter declaration and spelling mistake. regulator: max597x: Add support for max597x regulator regulator: scmi: Add missing of_node_get() regulator: qcom_smd: Add PM8909 RPM regulators regulator: dt-bindings: qcom,smd-rpm: Add PM8909 ...
2022-08-02Merge tag 'regmap-v5.20' of ↵Linus Torvalds4-171/+440
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap Pull regmap updates from Mark Brown: "The big thing this release is a big cleanup of the interrupt code from Aidan MacDonald, plus a few new API updates: - Rework of the interrupt code, making it much simpler and easier to extend - Support for device specific update bits operations with devices that otherwise use bitstream interfaces - Support for bit operations on fields as well as whole registers" * tag 'regmap-v5.20' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap: regmap: permit to set reg_update_bits with bulk implementation regmap: add WARN_ONCE when invalid mask is provided to regmap_field_init() regmap-irq: Fix bug in regmap_irq_get_irq_reg_linear() regmap: cache: Add extra parameter check in regcache_init regmap-irq: Deprecate the not_fixed_stride flag regmap-irq: Add get_irq_reg() callback regmap-irq: Fix inverted handling of unmask registers regmap-irq: Deprecate type registers and virtual registers regmap-irq: Introduce config registers for irq types regmap-irq: Refactor checks for status bulk read support regmap-irq: Remove mask_writeonly and regmap_irq_update_bits() regmap-irq: Remove inappropriate uses of regmap_irq_update_bits() regmap-irq: Remove an unnecessary restriction on type_in_mask regmap-irq: Cleanup sizeof(...) use in memory allocation regmap-irq: Remove unused type_reg_stride field regmap-irq: Convert bool bitfields to unsigned int regmap: Don't warn about cache only mode for devices with no cache regmap: provide regmap_field helpers for simple bit operations regmap: cache: Fix syntax errors in comments
2022-08-02dt-bindings: mtd: microchip,mchp48l640: use spi-peripheral-props.yamlKrzysztof Kozlowski1-3/+4
Instead of listing directly properties typical for SPI peripherals, reference the spi-peripheral-props.yaml schema. This allows using all properties typical for SPI-connected devices, even these which device bindings author did not tried yet. Remove the spi-* properties which now come via spi-peripheral-props.yaml schema, except for the cases when device schema adds some constraints like maximum frequency. While changing additionalProperties->unevaluatedProperties, put it in typical place, just before example DTS. Signed-off-by: Krzysztof Kozlowski <[email protected]> Reviewed-by: Tudor Ambarus <[email protected]> Reviewed-by: Heiko Schocher <[email protected]> Signed-off-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2022-08-02dt-bindings: power: supply: drop quotes when not neededKrzysztof Kozlowski43-86/+86
Id and schema fields do not need quotes. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2022-08-02dt-bindings: power: reset: drop quotes when not neededKrzysztof Kozlowski2-2/+2
string literals do not need quotes. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2022-08-02dt-bindings: power: drop quotes when not neededKrzysztof Kozlowski6-11/+11
Id and schema fields do not need quotes. Signed-off-by: Krzysztof Kozlowski <[email protected]> Reviewed-by: Hector Martin <[email protected]> Reviewed-by: Martin Blumenstingl <[email protected]> Signed-off-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2022-08-02RDMA/mlx5: Add missing check for return value in get namespace flowMaor Gottlieb1-4/+2
Add missing check for return value when calling to mlx5_ib_ft_type_to_namespace, even though it can't really fail in this specific call. Fixes: 52438be44112 ("RDMA/mlx5: Allow inserting a steering rule to the FDB") Link: https://lore.kernel.org/r/7b9ceda217d9368a51dc47a46b769bad4af9ac92.1659256069.git.leonro@nvidia.com Reviewed-by: Itay Aveksis <[email protected]> Signed-off-by: Maor Gottlieb <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2022-08-02RDMA/rxe: Split qp state for requester and completerBob Pearson4-3/+10
Currently the requester can continue to process send wqes after an local qp operation error is detected because the setting of the qp state to the error state is deferred until later. This patch splits the qp state for the completer and requester into two separate states and sets qp->req.state = QP_STATE_ERROR as soon as the error is detected before another wqe can be executed. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Bob Pearson <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2022-08-02RDMA/rxe: Generate error completion for error requester QP stateLi Zhijian1-1/+12
As per IBTA specification, all subsequent WQEs while QP is in error state should be completed with a flush error. Here we check QP_STATE_ERROR after req_next_wqe() so that rxe_completer() has chance to be called where it will set CQ state to FLUSH ERROR and the completion can associate with its WQE. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Li Zhijian <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2022-08-02RDMA/rxe: Update wqe_index for each wqe error completionLi Zhijian1-0/+2
Previously, if user space keeps sending abnormal wqe, queue.index will keep increasing while qp->req.wqe_index doesn't. Once qp->req.wqe_index==queue.index in next round, req_next_wqe() will treat queue as empty. In such case, no new completion would be generated. Update wqe_index for each wqe completion so that req_next_wqe() can get next wqe properly. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Li Zhijian <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2022-08-02fs: remove the NULL get_block case in mpage_writepagesChristoph Hellwig1-16/+6
No one calls mpage_writepages with a NULL get_block paramter, so remove support for that case. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Jan Kara <[email protected]> Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02fs: don't call ->writepage from __mpage_writepageChristoph Hellwig1-1/+1
All callers of mpage_writepage use block_write_full_page as their ->writepage implementation when called from mpage_writepages (although for ntfs3 this is obsfucated a bit). Just call block_write_full_page directly instead of going through the ->writepage indirection. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Jan Kara <[email protected]> Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02fs: remove the nobh helpersChristoph Hellwig4-358/+1
All callers are gone, so remove the now dead code. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Jan Kara <[email protected]> Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02jfs: stop using the nobh helperChristoph Hellwig1-3/+15
The nobh mode is an obscure feature to save lowlevel for large memory 32-bit configurations while trading for much slower performance and has been long obsolete. Switch to the regular buffer head based helpers instead. Signed-off-by: Christoph Hellwig <[email protected]> Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02ext2: remove nobh supportChristoph Hellwig5-63/+7
The nobh mode is an obscure feature to save lowlevel for large memory 32-bit configurations while trading for much slower performance and has been long obsolete. Remove it. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Jan Kara <[email protected]> Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02ntfs3: refactor ntfs_writepagesChristoph Hellwig1-5/+3
Handle the resident case with an explicit generic_writepages call instead of using the obscure overload that makes mpage_writepages with a NULL get_block do the same thing. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Jan Kara <[email protected]> Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02mm/folio-compat: Remove migration compatibility functionsMatthew Wilcox (Oracle)3-34/+1
migrate_page_move_mapping(), migrate_page_copy() and migrate_page_states() are all now unused after converting all the filesystems from aops->migratepage() to aops->migrate_folio(). Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02fs: Remove aops->migratepage()Matthew Wilcox (Oracle)3-8/+2
With all users converted to migrate_folio(), remove this operation. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02secretmem: Convert to migrate_folioMatthew Wilcox (Oracle)1-4/+3
This is little more than changing the types over; there's no real work being done in this function. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02hugetlb: Convert to migrate_folioMatthew Wilcox (Oracle)3-21/+26
This involves converting migrate_huge_page_move_mapping(). We also need a folio variant of hugetlb_set_page_subpool(), but that's for a later patch. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Acked-by: Muchun Song <[email protected]> Reviewed-by: Mike Kravetz <[email protected]>
2022-08-02aio: Convert to migrate_folioMatthew Wilcox (Oracle)1-18/+18
Use a folio throughout this function. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02f2fs: Convert to filemap_migrate_folio()Matthew Wilcox (Oracle)4-49/+3
filemap_migrate_folio() fits f2fs's needs perfectly. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Acked-by: Chao Yu <[email protected]>
2022-08-02ubifs: Convert to filemap_migrate_folio()Matthew Wilcox (Oracle)1-27/+2
filemap_migrate_folio() is a little more general than ubifs really needs, but it's better to share the code. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02btrfs: Convert btrfs_migratepage to migrate_folioMatthew Wilcox (Oracle)1-17/+9
Use filemap_migrate_folio() to do the bulk of the work, and then copy the ordered flag across if needed. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Acked-by: David Sterba <[email protected]>
2022-08-02mm/migrate: Add filemap_migrate_folio()Matthew Wilcox (Oracle)7-34/+29
There is nothing iomap-specific about iomap_migratepage(), and it fits a pattern used by several other filesystems, so move it to mm/migrate.c, convert it to be filemap_migrate_folio() and convert the iomap filesystems to use it. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Reviewed-by: Darrick J. Wong <[email protected]>
2022-08-02mm/migrate: Convert migrate_page() to migrate_folio()Matthew Wilcox (Oracle)8-27/+30
Convert all callers to pass a folio. Most have the folio already available. Switch all users from aops->migratepage to aops->migrate_folio. Also turn the documentation into kerneldoc. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Acked-by: David Sterba <[email protected]>
2022-08-02nfs: Convert to migrate_folioMatthew Wilcox (Oracle)3-13/+13
Use a folio throughout this function. migrate_page() will be converted later. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Acked-by: Anna Schumaker <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02btrfs: Convert btree_migratepage to migrate_folioMatthew Wilcox (Oracle)1-12/+10
Use a folio throughout this function. migrate_page() will be converted later. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Acked-by: David Sterba <[email protected]>
2022-08-02mm/migrate: Convert expected_page_refs() to folio_expected_refs()Matthew Wilcox (Oracle)1-7/+12
Now that both callers have a folio, convert this function to take a folio & rename it. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02mm/migrate: Convert buffer_migrate_page() to buffer_migrate_folio()Matthew Wilcox (Oracle)8-51/+65
Use a folio throughout __buffer_migrate_folio(), add kernel-doc for buffer_migrate_folio() and buffer_migrate_folio_norefs(), move their declarations to buffer.h and switch all filesystems that have wired them up. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02mm/migrate: Convert writeout() to take a folioMatthew Wilcox (Oracle)1-11/+10
Use a folio throughout this function. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02mm/migrate: Convert fallback_migrate_page() to fallback_migrate_folio()Matthew Wilcox (Oracle)1-10/+9
Use a folio throughout. migrate_page() will be converted to migrate_folio() later. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02fs: Add aops->migrate_folioMatthew Wilcox (Oracle)5-15/+23
Provide a folio-based replacement for aops->migratepage. Update the documentation to document migrate_folio instead of migratepage. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]>
2022-08-02mm: Convert all PageMovable users to movable_operationsMatthew Wilcox (Oracle)17-486/+134
These drivers are rather uncomfortably hammered into the address_space_operations hole. They aren't filesystems and don't behave like filesystems. They just need their own movable_operations structure, which we can point to directly from page->mapping. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02secretmem: Remove isolate_pageMatthew Wilcox (Oracle)1-6/+0
The isolate_page operation is never called for filesystems, only for device drivers which call SetPageMovable. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: David Hildenbrand <[email protected]>
2022-08-02ext2: Use a folio in ext2_get_page()Matthew Wilcox (Oracle)1-9/+10
Remove a call to read_mapping_page(). Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02gfs2: Convert gfs2_jhead_process_page() to use a folioMatthew Wilcox (Oracle)1-14/+14
Use folio_put_refs() to perform only one atomic operation instead of two. The other changes are straightforward conversions from page APIs to their folio equivalents. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02ocfs2: Convert ocfs2_read_folio() to use a folioMatthew Wilcox (Oracle)1-14/+12
Use the folio API throughout. There are a few places where we convert back to a page to call into the rest of the filesystem, so folio usage needs to be pushed down to those functions later. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02freevxfs: Convert vxfs_immed_read_folio() to use a folioMatthew Wilcox (Oracle)1-24/+19
Reorganise the file to remove the forward declaration. Use folios throughout vxfs_immed_read_folio(). Use memcpy_to_page() instead of an open-coded kmap()/kunmap(). Remove flush_dcache_page() as this is embedded in memcpy_to_page(). Use folio_pos() instead of opencoding it. Handle multi-page folios. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02coda: Convert coda_symlink_filler() to use a folioMatthew Wilcox (Oracle)1-6/+5
This is a straightforward conversion from the page APIs to the folio APIs. Symlinks are not allowed to be larger than PAGE_SIZE, so there is little work to do here. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02befs: Convert befs_symlink_read_folio() to use a folioMatthew Wilcox (Oracle)1-9/+7
This is a straightforward conversion from the page APIs to the folio APIs. Symlinks are not allowed to be larger than PAGE_SIZE, so there is little work to do here. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02block: Convert read_part_sector() to use a folioMatthew Wilcox (Oracle)2-7/+7
This relatively straightforward converion saves a call to compound_head() hidden inside put_page(). Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02block: Use PAGE_SECTORS_SHIFTMatthew Wilcox (Oracle)1-2/+1
The bare use of '9' confuses some people. We also don't need this cast, since the compiler does exactly that cast for us. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02block: Handle partition read errors more consistentlyMatthew Wilcox (Oracle)1-1/+1
Set p->v to NULL if we try to read beyond the end of the disk, just like we do if we get an error returned from trying to read the disk. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02block: Simplify read_part_sector()Matthew Wilcox (Oracle)1-2/+1
That rather complicated expression is just trying to find the offset of this sector within a page, and there are easier ways to express that. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02cramfs: read_mapping_page() is synchronousMatthew Wilcox (Oracle)1-13/+4
Since commit 67f9fd91f93c, the code to wait for the read to complete has been dead. That commit wrongly stated that the read was synchronous already; this seems to have been a confusion about which ->readpage operation was being called. Instead of reintroducing an asynchronous version of read_mapping_page(), call the readahead code directly to submit all reads first before waiting for them in read_mapping_page(). Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02ocfs2: Use filemap_write_and_wait_range() in ocfs2_cow_sync_writeback()Matthew Wilcox (Oracle)1-36/+6
Remove the open-coding of filemap_fdatawait_range(). Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02hostfs: Handle page write errors correctlyMatthew Wilcox (Oracle)1-3/+3
If a page can't be written back, we need to call mapping_set_error(), not clear the page's Uptodate flag. Also remove the clearing of PageError on success; that flag is used for read errors, not write errors. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>
2022-08-02squashfs: Return the actual error from squashfs_read_folio()Matthew Wilcox (Oracle)1-7/+8
Since we actually know what error happened, we can report it instead of having the generic code return -EIO for pages that were unlocked without being marked uptodate. Also remove a test of PageError since we have the return value at this point. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]>