aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2020-05-19rnbd/rtrs: Pass max segment size from blk user to the rdma libraryDanil Kipnis4-6/+14
When Block Device Layer is disabled, BLK_MAX_SEGMENT_SIZE is undefined. The rtrs is a transport library and should compile independently of the block layer. The desired max segment size should be passed down by the user. Introduce max_segment_size parameter for the rtrs_clt_open() call. Fixes: f7a7a5c228d4 ("block/rnbd: client: main functionality") Fixes: 6a98d71daea1 ("RDMA/rtrs: client: main functionality") Fixes: cb80329c9434 ("RDMA/rtrs: client: private header with client structs and functions") Fixes: b5c27cdb094e ("RDMA/rtrs: public interface header to establish RDMA connections") Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Reported-by: Randy Dunlap <[email protected]> Acked-by: Randy Dunlap <[email protected]> # build-tested Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-19RDMA/rtrs: server: Fix some error return codeWei Yongjun2-3/+6
Fix to return negative error code -ENOMEM from the some error handling cases instead of 0, as done elsewhere in this function. Fixes: 9cb837480424 ("RDMA/rtrs: server: main functionality") Fixes: 91b11610af8d ("RDMA/rtrs: server: sysfs interface functions") Link: https://lore.kernel.org/r/[email protected] Reported-by: Hulk Robot <[email protected]> Signed-off-by: Wei Yongjun <[email protected]> Reviewed-by: Danil Kipnis <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-19RDMA/rtrs: client: Fix function return on successGustavo A. R. Silva1-3/+0
Remove the if-statement and return the value contained in _err_, unconditionally. Link: https://lore.kernel.org/r/20200519163612.GA6043@embeddedor Addresses-Coverity-ID: 1493753 ("Identical code for different branches") Fixes: 6a98d71daea1 ("RDMA/rtrs: client: main functionality") Signed-off-by: Gustavo A. R. Silva <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-19RDMA/rtrs: Fix a couple off by one bugs in rtrs_srv_rdma_done()Dan Carpenter1-2/+2
These > comparisons should be >= to prevent accessing one element beyond the end of the buffer. Fixes: 9cb837480424 ("RDMA/rtrs: server: main functionality") Link: https://lore.kernel.org/r/20200519154525.GA66801@mwanda Signed-off-by: Dan Carpenter <[email protected]> Acked-by: Danil Kipnis <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-19RDMA/rtrs: Fix some signedness bugs in error handlingDan Carpenter2-5/+4
The problem is that "req->sg_cnt" is an unsigned int so if "nr" is negative, it gets type promoted to a high positive value and the condition is false. This patch fixes it by handling negatives separately. Fixes: 6a98d71daea1 ("RDMA/rtrs: client: main functionality") Link: https://lore.kernel.org/r/20200519133223.GN2078@kadam Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-18net/mlx5: Add support for RDMA TX FT headers modifyingMichael Guralnik2-1/+8
Support adding header modifying actions to the RDMA TX flow table. Signed-off-by: Michael Guralnik <[email protected]> Reviewed-by: Mark Bloch <[email protected]> Reviewed-by: Maor Gottlieb <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
2020-05-18net/mlx5: Move iseg access helper routines close to mlx5_core driverParav Pandit3-10/+10
Only mlx5_core driver handles fw initialization check and command interface revision check. Hence move them inside the mlx5_core driver where it is used. This avoid exposing these helpers to all mlx5 drivers. Signed-off-by: Parav Pandit <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
2020-05-18net/mlx5: Cleanup mlx5_ifc_fte_match_set_misc2_bitsRaed Salem3-6/+2
Remove the "metadata_reg_b" field and all uses of this field in code to match the device specification. As this field is not in use in SW steering it is safe to remove it. Signed-off-by: Raed Salem <[email protected]> Reviewed-by: Alex Vesker <[email protected]> Signed-off-by: Saeed Mahameed <[email protected]>
2020-05-17Linux 5.7-rc6Linus Torvalds1-1/+1
2020-05-17RDMA/srpt: Fix disabling device managementKamal Heib1-2/+6
Avoid disabling device management for devices that don't support Management datagrams (MADs) by checking if the "mad_agent" pointer is initialized before calling ib_modify_port, also fix the error flow in srpt_refresh_port() to disable device management if ib_register_mad_agent() fail. Fixes: 09f8a1486dca ("RDMA/srpt: Fix handling of SR-IOV and iWARP ports") Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Kamal Heib <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/mlx5: Update mlx5_ib driver nameShay Drory1-10/+1
Current description doesn't include new devices, change it by updating to have more generic description and remove DRIVER_NAME and DRIVER_VERSION defines. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Shay Drory <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/srpt: Add a newline when printing parameter 'srpt_service_guid' by sysfsXiongfeng Wang1-1/+1
When I cat module parameter 'srpt_service_guid', it displays as follows. It is better to add a newline for easy reading. [root@hulk-202 ~]# cat /sys/module/ib_srpt/parameters/srpt_service_guid 0x0205cdfffe8346b9[root@hulk-202 ~]# Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Xiongfeng Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/core: Consolidate ib_create_srq flowsJason Gunthorpe3-56/+40
The uverbs layer largely duplicate the code in ib_create_srq(), with the slight difference that it passes in a udata. Move all the code together into ib_create_srq_user() and provide an inline for kernel users, similar to other create calls. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Yishai Hadas <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/uverbs: Fix create WQ to use the given user handleYishai Hadas1-2/+1
Fix create WQ to use the given user handle, in addition dropped some duplicated code from this flow. Fixes: fd3c7904db6e ("IB/core: Change idr objects to use the new schema") Fixes: f213c0527210 ("IB/uverbs: Add WQ support") Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Yishai Hadas <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/uverbs: Cleanup wq/srq context usage from uverbs layerYishai Hadas1-4/+0
Both wq_context and srq_context are some leftover from the past in uverbs layer, they are not really in use, drop them. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Yishai Hadas <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17Merge tag 'for-linus-5.7-2' of git://github.com/cminyard/linux-ipmiLinus Torvalds1-2/+2
Pull IPMI update from Corey Minyard: "Convert i2c_new_device() to i2c_new_client_device() Wolfram Sang has asked to have this included in 5.7 so the deprecated API can be removed next release. There should be no functional difference. I think that entire this section of code can be removed; it is leftover from other things that have since changed, but this is the safer thing to do for now. The full removal can happen next release" * tag 'for-linus-5.7-2' of git://github.com/cminyard/linux-ipmi: char: ipmi: convert to use i2c_new_client_device()
2020-05-17MAINTAINERS: Add maintainers for RNBD/RTRS modulesJack Wang1-0/+14
Danil and I will maintain RNBD/RTRS modules. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: a bit of documentationJack Wang4-0/+299
README with description of major sysfs entries, sysfs documentation are moved to ABI dir as Bart suggested. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: include client and server modules into kernel compilationJack Wang4-0/+46
Add rnbd Makefile, Kconfig and also corresponding lines into upper block layer files. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: server: sysfs interface functionsJack Wang1-0/+215
This is the sysfs interface to rnbd mapped devices on server side: /sys/class/rnbd-server/ctl/devices/<device_name>/ |- block_dev | *** link pointing to the corresponding block device sysfs entry | |- sessions/<session-name>/ | *** sessions directory | |- read_only | *** is devices mapped as read only | |- mapping_path *** relative device path provided by the client during mapping Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: server: functionality for IO submitting to block devJack Wang2-0/+226
This provides helper functions for IO submitting to block dev. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: server: main functionalityJack Wang1-0/+844
This is main functionality of rnbd-server module, which handles RTRS events and rnbd protocol requests, like map (open) or unmap (close) device. Also server side is responsible for processing incoming IBTRS IO requests and forward them to local mapped devices. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: server: private header with server structs and functionsJack Wang1-0/+78
This header describes main structs and functions used by rnbd-server module, namely structs for managing sessions from different clients and mapped (opened) devices. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: client: sysfs interface functionsJack Wang1-0/+636
This is the sysfs interface to rnbd block devices on client side: /sys/class/rnbd-client/ctl/ |- map_device | *** maps remote device | |- devices/ *** all mapped devices /sys/block/rnbd<N>/rnbd/ |- unmap_device | *** unmaps device | |- state | *** device state | |- session | *** session name | |- mapping_path *** path of the dev that was mapped on server Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: client: main functionalityJack Wang1-0/+1729
This is main functionality of rnbd-client module, which provides interface to map remote device as local block device /dev/rnbd<N> and feeds RTRS with IO requests. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: client: private header with client structs and functionsJack Wang1-0/+156
This header describes main structs and functions used by rnbd-client module, mainly for managing RNBD sessions and mapped block devices, creating and destroying sysfs entries. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17block/rnbd: private headers with rnbd protocol structs and helpersJack Wang3-0/+367
These are common private headers with rnbd protocol structures, logging, sysfs and other helper functions, which are used on both client and server sides. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Acked-by: Jens Axboe <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: a bit of documentationJack Wang3-0/+397
README with description of major sysfs entries, sysfs documentation has been moved to ABI dir as suggested by Bart. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Cc: [email protected] Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: include client and server modules into kernel compilationJack Wang4-0/+44
Add rtrs Makefile, Kconfig and also corresponding lines into upper layer infiniband/ulp files. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: server: sysfs interface functionsJack Wang1-0/+320
This is the sysfs interface to rtrs sessions on server side: /sys/class/rtrs-server/<SESS-NAME>/ *** rtrs session accepted from a client peer | |- paths/<SRC@DST>/ *** established paths from a client in a session | |- disconnect | *** disconnect path | |- hca_name | *** HCA name | |- hca_port | *** HCA port | |- stats/ *** current path statistics | |- rdma Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: server: statistics functionsJack Wang1-0/+38
This introduces set of functions used on server side to account statistics of RDMA data sent/received. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: server: main functionalityJack Wang1-0/+2175
This is main functionality of rtrs-server module, which accepts set of RDMA connections (so called rtrs session), creates/destroys sysfs entries associated with rtrs session and notifies upper layer (user of RTRS API) about RDMA requests or link events. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: server: private header with server structs and functionsJack Wang1-0/+148
This header describes main structs and functions used by rtrs-server module, mainly for accepting rtrs sessions, creating/destroying sysfs entries, accounting statistics on server side. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: client: sysfs interface functionsJack Wang1-0/+483
This is the sysfs interface to rtrs sessions on client side: /sys/class/rtrs-client/<SESS-NAME>/ *** rtrs session created by rtrs_clt_open() API call | |- max_reconnect_attempts | *** number of reconnect attempts for session | |- add_path | *** adds another connection path into rtrs session | |- paths/<SRC@DST>/ *** established paths to server in a session | |- disconnect | *** disconnect path | |- reconnect | *** reconnect path | |- remove_path | *** remove current path | |- state | *** retrieve current path state | |- hca_port | *** HCA port number | |- hca_name | *** HCA name | |- stats/ *** current path statistics | |- cpu_migration |- rdma |- reconnects |- reset_all Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: client: statistics functionsJack Wang1-0/+200
This introduces set of functions used on client side to account statistics of RDMA data sent/received, amount of IOs inflight, latency, cpu migrations, etc. Almost all statistics are collected using percpu variables. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: client: main functionalityJack Wang1-0/+2994
This is main functionality of rtrs-client module, which manages set of RDMA connections for each rtrs session, does multipathing, load balancing and failover of RDMA requests. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: client: private header with client structs and functionsJack Wang1-0/+251
This header describes main structs and functions used by rtrs-client module, mainly for managing rtrs sessions, creating/destroying sysfs entries, accounting statistics on client side. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: core: lib functions shared between client and server modulesJack Wang1-0/+612
This is a set of library functions existing as a rtrs-core module, used by client and server modules. Mainly these functions wrap IB and RDMA calls and provide a bit higher abstraction for implementing of RTRS protocol on client or server sides. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: private headers with rtrs protocol structs and helpersJack Wang2-0/+427
These are common private headers with rtrs protocol structures, logging, sysfs and other helper functions, which are used on both client and server sides. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17RDMA/rtrs: public interface header to establish RDMA connectionsJack Wang1-0/+195
Introduce public header which provides set of API functions to establish RDMA connections from client to server machine using RTRS protocol, which manages RDMA connections for each session, does multipathing and load balancing. Main functions for client (active) side: rtrs_clt_open() - Creates set of RDMA connections incapsulated in IBTRS session and returns pointer on RTRS session object. rtrs_clt_close() - Closes RDMA connections associated with RTRS session. rtrs_clt_request() - Requests zero-copy RDMA transfer to/from server. Main functions for server (passive) side: rtrs_srv_open() - Starts listening for RTRS clients on specified port and invokes RTRS callbacks for incoming RDMA requests or link events. rtrs_srv_close() - Closes RTRS server context. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Danil Kipnis <[email protected]> Signed-off-by: Jack Wang <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17sysfs: export sysfs_remove_file_self()Jack Wang1-0/+1
Function is going to be used in transport over RDMA module in subsequent patches, so export it to GPL modules. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Roman Pen <[email protected]> Acked-by: Tejun Heo <[email protected]> Cc: [email protected] [jwang: extend the commit message] Signed-off-by: Jack Wang <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
2020-05-17Merge tag 'clk-fixes-for-linus' of ↵Linus Torvalds6-66/+58
git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux Pull clk fixes from Stephen Boyd: "Some more clk driver fixes and one core framework fix: - A handful of TI driver fixes for bad of_node_put() and incorrect parent names - Rockchip rk3228 aclk_gpu* creation was interfering with lima GPU work so we use a composite clk now - Resuming from suspend on Tegra Jetson TK1 was broken because an audio PLL calculated an incorrect rate - A fix for devicetree probing on IM-PD1 by actually specifying a clk name which is required to pass clk registration - Avoid list corruption if registration fails for a critical clk" * tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: clk: ti: clkctrl: convert subclocks to use proper names also clk: ti: am33xx: fix RTC clock parent clk: ti: clkctrl: Fix Bad of_node_put within clkctrl_get_name clk: tegra: Fix initial rate for pll_a on Tegra124 clk: impd1: Look up clock-output-names clk: Unlink clock if failed to prepare or enable clk: rockchip: fix incorrect configuration of rk3228 aclk_gpu* clocks
2020-05-17Merge tag 'usb-5.7-rc6' of ↵Linus Torvalds22-123/+448
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb Pull USB fixes from Greg KH: "Here are a number of USB fixes for 5.7-rc6 The "largest" in here is a bunch of raw-gadget fixes and api changes as the driver just showed up in -rc1 and work has been done to fix up some uapi issues found with the original submission, before it shows up in a -final release. Other than that, a bunch of other small USB gadget fixes, xhci fixes, some quirks, andother tiny fixes for reported issues. All of these have been in linux-next with no reported issues" * tag 'usb-5.7-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (26 commits) USB: gadget: fix illegal array access in binding with UDC usb: core: hub: limit HUB_QUIRK_DISABLE_AUTOSUSPEND to USB5534B USB: usbfs: fix mmap dma mismatch usb: host: xhci-plat: keep runtime active when removing host usb: xhci: Fix NULL pointer dereference when enqueuing trbs from urb sg list usb: cdns3: gadget: make a bunch of functions static usb: mtu3: constify struct debugfs_reg32 usb: gadget: udc: atmel: Make some symbols static usb: raw-gadget: fix null-ptr-deref when reenabling endpoints usb: raw-gadget: documentation updates usb: raw-gadget: support stalling/halting/wedging endpoints usb: raw-gadget: fix gadget endpoint selection usb: raw-gadget: improve uapi headers comments usb: typec: mux: intel: Fix DP_HPD_LVL bit field usb: raw-gadget: fix return value of ep read ioctls usb: dwc3: select USB_ROLE_SWITCH usb: gadget: legacy: fix error return code in gncm_bind() usb: gadget: legacy: fix error return code in cdc_bind() usb: gadget: legacy: fix redundant initialization warnings usb: gadget: tegra-xudc: Fix idle suspend/resume ...
2020-05-17Merge branch 'exec-linus' of ↵Linus Torvalds1-2/+2
git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace Pull execve fix from Eric Biederman: "While working on my exec cleanups I found a bug in exec that I introduced by accident a couple of years ago. I apparently missed the fact that bprm->file can change. Now I have a very personal motive to clean up exec and make it more approachable. The change is just moving woud_dump to where it acts on the final bprm->file not the initial bprm->file. I have been careful and tested and verify this fix works" * 'exec-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace: exec: Move would_dump into flush_old_exec
2020-05-17Merge tag 'objtool-urgent-2020-05-17' of ↵Linus Torvalds1-7/+9
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 stack unwinding fix from Thomas Gleixner: "A single bugfix for the ORC unwinder to ensure that the error flag which tells the unwinding code whether a stack trace can be trusted or not is always set correctly. This was messed up by a couple of changes in the recent past" * tag 'objtool-urgent-2020-05-17' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/unwind/orc: Fix error handling in __unwind_start()
2020-05-17Merge tag 'x86_urgent_for_v5.7-rc7' of ↵Linus Torvalds5-1/+23
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fix from Borislav Petkov: "A single fix for early boot crashes of kernels built with gcc10 and stack protector enabled" * tag 'x86_urgent_for_v5.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86: Fix early boot crash on gcc-10, third try
2020-05-17exec: Move would_dump into flush_old_execEric W. Biederman1-2/+2
I goofed when I added mm->user_ns support to would_dump. I missed the fact that in the case of binfmt_loader, binfmt_em86, binfmt_misc, and binfmt_script bprm->file is reassigned. Which made the move of would_dump from setup_new_exec to __do_execve_file before exec_binprm incorrect as it can result in would_dump running on the script instead of the interpreter of the script. The net result is that the code stopped making unreadable interpreters undumpable. Which allows them to be ptraced and written to disk without special permissions. Oops. The move was necessary because the call in set_new_exec was after bprm->mm was no longer valid. To correct this mistake move the misplaced would_dump from __do_execve_file into flos_old_exec, before exec_mmap is called. I tested and confirmed that without this fix I can attach with gdb to a script with an unreadable interpreter, and with this fix I can not. Cc: [email protected] Fixes: f84df2a6f268 ("exec: Ensure mm->user_ns contains the execed files") Signed-off-by: "Eric W. Biederman" <[email protected]>
2020-05-16Merge tag '5.7-rc5-smb3-fixes' of git://git.samba.org/sfrench/cifs-2.6Linus Torvalds3-3/+3
Pull cifs fixes from Steve French: "Three small cifs/smb3 fixes, one for stable" * tag '5.7-rc5-smb3-fixes' of git://git.samba.org/sfrench/cifs-2.6: cifs: fix leaked reference on requeued write cifs: Fix null pointer check in cifs_read CIFS: Spelling s/EACCESS/EACCES/
2020-05-16Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvmLinus Torvalds12-88/+325
Pull kvm fixes from Paolo Bonzini: "A new testcase for guest debugging (gdbstub) that exposed a bunch of bugs, mostly for AMD processors. And a few other x86 fixes" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: KVM: x86: Fix off-by-one error in kvm_vcpu_ioctl_x86_setup_mce KVM: x86: Fix pkru save/restore when guest CR4.PKE=0, move it to x86.c KVM: SVM: Disable AVIC before setting V_IRQ KVM: Introduce kvm_make_all_cpus_request_except() KVM: VMX: pass correct DR6 for GD userspace exit KVM: x86, SVM: isolate vcpu->arch.dr6 from vmcb->save.dr6 KVM: SVM: keep DR6 synchronized with vcpu->arch.dr6 KVM: nSVM: trap #DB and #BP to userspace if guest debugging is on KVM: selftests: Add KVM_SET_GUEST_DEBUG test KVM: X86: Fix single-step with KVM_SET_GUEST_DEBUG KVM: X86: Set RTM for DB_VECTOR too for KVM_EXIT_DEBUG KVM: x86: fix DR6 delivery for various cases of #DB injection KVM: X86: Declare KVM_CAP_SET_GUEST_DEBUG properly
2020-05-16Merge tag 'powerpc-5.7-4' of ↵Linus Torvalds9-33/+78
git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux Pull powerpc fixes from Michael Ellerman: - A fix for unrecoverable SLB faults in the interrupt exit path, introduced by the recent rewrite of interrupt exit in C. - Four fixes for our KUAP (Kernel Userspace Access Prevention) support on 64-bit. These are all fairly minor with the exception of the change to evaluate the get/put_user() arguments before we enable user access, which reduces the amount of code we run with user access enabled. - A fix for our secure boot IMA rules, if enforcement of module signatures is enabled at runtime rather than build time. - A fix to our 32-bit VDSO clock_getres() which wasn't falling back to the syscall for unknown clocks. - A build fix for CONFIG_PPC_KUAP_DEBUG on 32-bit BookS, and another for 40x. Thanks to: Christophe Leroy, Hugh Dickins, Nicholas Piggin, Aurelien Jarno, Mimi Zohar, Nayna Jain. * tag 'powerpc-5.7-4' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: powerpc/40x: Make more space for system call exception powerpc/vdso32: Fallback on getres syscall when clock is unknown powerpc/32s: Fix build failure with CONFIG_PPC_KUAP_DEBUG powerpc/ima: Fix secure boot rules in ima arch policy powerpc/64s/kuap: Restore AMR in fast_interrupt_return powerpc/64s/kuap: Restore AMR in system reset exception powerpc/64/kuap: Move kuap checks out of MSR[RI]=0 regions of exit code powerpc/64s: Fix unrecoverable SLB crashes due to preemption check powerpc/uaccess: Evaluate macro arguments once, before user access is allowed