5.15.111-rc1 review
Subsystems (4)
Greg Kroah-Hartman
maintainerPATCH 308/371 clk: qcom: gcc-sm6115: Mark RCGs shared where applicable
In reply to Greg Kroah-HartmanFrom: Konrad Dybcio <[email protected]>
[ Upstream commit 996c32b745a15a637e8244a25f06b74acce98976 ]
The vast majority of shared RCGs were not marked as such. Fix it.
--- drivers/clk/qcom/gcc-sm6115.c | 50 +++++++++++++++++------------------ 1 file changed, 25 insertions(+), 25 deletions(-)
drivers/clk/qcom/gcc-sm6115.c +25 -25
@@ -720,7 +720,7 @@ static struct clk_rcg2 gcc_camss_axi_clk_src = { .parent_data = gcc_parents_7, .num_parents = ARRAY_SIZE(gcc_parents_7), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -741,7 +741,7 @@ static struct clk_rcg2 gcc_camss_cci_clk_src = { .parent_data = gcc_parents_9, .num_parents = ARRAY_SIZE(gcc_parents_9), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -764,7 +764,7 @@ static struct clk_rcg2 gcc_camss_csi0phytimer_clk_src = { .parent_data = gcc_parents_4, .num_parents = ARRAY_SIZE(gcc_parents_4), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -779,7 +779,7 @@ static struct clk_rcg2 gcc_camss_csi1phytimer_clk_src = { .parent_data = gcc_parents_4, .num_parents = ARRAY_SIZE(gcc_parents_4), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -794,7 +794,7 @@ static struct clk_rcg2 gcc_camss_csi2phytimer_clk_src = { .parent_data = gcc_parents_4, .num_parents = ARRAY_SIZE(gcc_parents_4), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -816,7 +816,7 @@ static struct clk_rcg2 gcc_camss_mclk0_clk_src = { .parent_data = gcc_parents_3, .num_parents = ARRAY_SIZE(gcc_parents_3), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -831,7 +831,7 @@ static struct clk_rcg2 gcc_camss_mclk1_clk_src = { .parent_data = gcc_parents_3, .num_parents = ARRAY_SIZE(gcc_parents_3), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -846,7 +846,7 @@ static struct clk_rcg2 gcc_camss_mclk2_clk_src = { .parent_data = gcc_parents_3, .num_parents = ARRAY_SIZE(gcc_parents_3), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -861,7 +861,7 @@ static struct clk_rcg2 gcc_camss_mclk3_clk_src = { .parent_data = gcc_parents_3, .num_parents = ARRAY_SIZE(gcc_parents_3), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -883,7 +883,7 @@ static struct clk_rcg2 gcc_camss_ope_ahb_clk_src = { .parent_data = gcc_parents_8, .num_parents = ARRAY_SIZE(gcc_parents_8), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -907,7 +907,7 @@ static struct clk_rcg2 gcc_camss_ope_clk_src = { .parent_data = gcc_parents_8, .num_parents = ARRAY_SIZE(gcc_parents_8), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -942,7 +942,7 @@ static struct clk_rcg2 gcc_camss_tfe_0_clk_src = { .parent_data = gcc_parents_5, .num_parents = ARRAY_SIZE(gcc_parents_5), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -967,7 +967,7 @@ static struct clk_rcg2 gcc_camss_tfe_0_csid_clk_src = { .parent_data = gcc_parents_6, .num_parents = ARRAY_SIZE(gcc_parents_6), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -982,7 +982,7 @@ static struct clk_rcg2 gcc_camss_tfe_1_clk_src = { .parent_data = gcc_parents_5, .num_parents = ARRAY_SIZE(gcc_parents_5), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -997,7 +997,7 @@ static struct clk_rcg2 gcc_camss_tfe_1_csid_clk_src = { .parent_data = gcc_parents_6, .num_parents = ARRAY_SIZE(gcc_parents_6), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1012,7 +1012,7 @@ static struct clk_rcg2 gcc_camss_tfe_2_clk_src = { .parent_data = gcc_parents_5, .num_parents = ARRAY_SIZE(gcc_parents_5), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1027,7 +1027,7 @@ static struct clk_rcg2 gcc_camss_tfe_2_csid_clk_src = { .parent_data = gcc_parents_6, .num_parents = ARRAY_SIZE(gcc_parents_6), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1050,7 +1050,7 @@ static struct clk_rcg2 gcc_camss_tfe_cphy_rx_clk_src = { .parent_data = gcc_parents_10, .num_parents = ARRAY_SIZE(gcc_parents_10), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1072,7 +1072,7 @@ static struct clk_rcg2 gcc_camss_top_ahb_clk_src = { .parent_data = gcc_parents_7, .num_parents = ARRAY_SIZE(gcc_parents_7), .flags = CLK_SET_RATE_PARENT | CLK_OPS_PARENT_ENABLE, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1142,7 +1142,7 @@ static struct clk_rcg2 gcc_pdm2_clk_src = { .name = "gcc_pdm2_clk_src", .parent_data = gcc_parents_0, .num_parents = ARRAY_SIZE(gcc_parents_0), - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1355,7 +1355,7 @@ static struct clk_rcg2 gcc_ufs_phy_axi_clk_src = { .name = "gcc_ufs_phy_axi_clk_src", .parent_data = gcc_parents_0, .num_parents = ARRAY_SIZE(gcc_parents_0), - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1377,7 +1377,7 @@ static struct clk_rcg2 gcc_ufs_phy_ice_core_clk_src = { .name = "gcc_ufs_phy_ice_core_clk_src", .parent_data = gcc_parents_0, .num_parents = ARRAY_SIZE(gcc_parents_0), - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1418,7 +1418,7 @@ static struct clk_rcg2 gcc_ufs_phy_unipro_core_clk_src = { .name = "gcc_ufs_phy_unipro_core_clk_src", .parent_data = gcc_parents_0, .num_parents = ARRAY_SIZE(gcc_parents_0), - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1440,7 +1440,7 @@ static struct clk_rcg2 gcc_usb30_prim_master_clk_src = { .name = "gcc_usb30_prim_master_clk_src", .parent_data = gcc_parents_0, .num_parents = ARRAY_SIZE(gcc_parents_0), - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
@@ -1509,7 +1509,7 @@ static struct clk_rcg2 gcc_video_venus_clk_src = { .parent_data = gcc_parents_13, .num_parents = ARRAY_SIZE(gcc_parents_13), .flags = CLK_SET_RATE_PARENT, - .ops = &clk_rcg2_ops, + .ops = &clk_rcg2_shared_ops, }, };
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 309/371 RDMA/cm: Trace icm_send_rej event before the cm state is reset
In reply to Greg Kroah-HartmanFrom: Mark Zhang <[email protected]>
[ Upstream commit bd9de1badac7e4ff6780365d4aa38983f5e2a436 ]
Trace icm_send_rej event before the cm state is reset to idle, so that correct cm state will be logged. For example when an incoming request is rejected, the old trace log was:
icm_send_rej: local_id=961102742 remote_id=3829151631 state=IDLE reason=REJ_CONSUMER_DEFINED
With this patch:
icm_send_rej: local_id=312971016 remote_id=3778819983 state=MRA_REQ_SENT reason=REJ_CONSUMER_DEFINED--- drivers/infiniband/core/cm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/infiniband/core/cm.c +2 -1
@@ -2914,6 +2914,8 @@ static int cm_send_rej_locked(struct cm_id_private *cm_id_priv, (ari && ari_length > IB_CM_REJ_ARI_LENGTH))return -EINVAL ; +trace_icm_send_rej (&cm_id_priv->id, reason); +switch (state) {case IB_CM_REQ_SENT :case IB_CM_MRA_REQ_RCVD :
@@ -2944,7 +2946,6 @@ static int cm_send_rej_locked(struct cm_id_private *cm_id_priv,return -EINVAL ; } -trace_icm_send_rej (&cm_id_priv->id, reason); ret =ib_post_send_mad (msg,NULL );if (ret) {cm_free_msg (msg);
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 310/371 RDMA/srpt: Add a check for valid mad_agent pointer
In reply to Greg Kroah-HartmanFrom: Saravanan Vajravel <[email protected]>
[ Upstream commit eca5cd9474cd26d62f9756f536e2e656d3f62f3a ]
When unregistering MAD agent, srpt module has a non-null check for 'mad_agent' pointer before invoking ib_unregister_mad_agent(). This check can pass if 'mad_agent' variable holds an error value. The 'mad_agent' can have an error value for a short window when srpt_add_one() and srpt_remove_one() is executed simultaneously.
In srpt module, added a valid pointer check for 'sport->mad_agent' before unregistering MAD agent.
This issue can hit when RoCE driver unregisters ib_device
Stack Trace:
------------
BUG: kernel NULL pointer dereference, address: 000000000000004d PGD 145003067 P4D 145003067 PUD 2324fe067 PMD 0 Oops: 0002 [#1] PREEMPT SMP NOPTI CPU: 10 PID: 4459 Comm: kworker/u80:0 Kdump: loaded Tainted: P Hardware name: Dell Inc. PowerEdge R640/06NR82, BIOS 2.5.4 01/13/2020 Workqueue: bnxt_re bnxt_re_task [bnxt_re] RIP: 0010:_raw_spin_lock_irqsave+0x19/0x40 Call Trace: ib_unregister_mad_agent+0x46/0x2f0 [ib_core] IPv6: ADDRCONF(NETDEV_CHANGE): bond0: link becomes ready ? __schedule+0x20b/0x560 srpt_unregister_mad_agent+0x93/0xd0 [ib_srpt] srpt_remove_one+0x20/0x150 [ib_srpt] remove_client_context+0x88/0xd0 [ib_core] bond0: (slave p2p1): link status definitely up, 100000 Mbps full duplex disable_device+0x8a/0x160 [ib_core] bond0: active interface up! ? kernfs_name_hash+0x12/0x80 (NULL device *): Bonding Info Received: rdev: 000000006c0b8247 __ib_unregister_device+0x42/0xb0 [ib_core] (NULL device *): Master: mode: 4 num_slaves:2 ib_unregister_device+0x22/0x30 [ib_core] (NULL device *): Slave: id: 105069936 name:p2p1 link:0 state:0 bnxt_re_stopqps_and_ib_uninit+0x83/0x90 [bnxt_re] bnxt_re_alloc_lag+0x12e/0x4e0 [bnxt_re]
--- drivers/infiniband/ulp/srpt/ib_srpt.c | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-)
drivers/infiniband/ulp/srpt/ib_srpt.c +13 -10
@@ -549,6 +549,7 @@ static int srpt_format_guid(char *buf, unsigned int size, const __be64 *guid)*/ static int srpt_refresh_port (struct srpt_port *sport) { +struct ib_mad_agent *mad_agent;struct ib_mad_reg_req reg_req;struct ib_port_modify port_modify;struct ib_port_attr port_attr;
@@ -593,24 +594,26 @@ static int srpt_refresh_port(struct srpt_port *sport)set_bit (IB_MGMT_METHOD_GET , reg_req.method_mask);set_bit (IB_MGMT_METHOD_SET , reg_req.method_mask); - sport->mad_agent =ib_register_mad_agent (sport->sdev->device, - sport->port, -IB_QPT_GSI , - ®_req,0 , - srpt_mad_send_handler, - srpt_mad_recv_handler, - sport,0 ); -if (IS_ERR (sport->mad_agent)) { + mad_agent =ib_register_mad_agent (sport->sdev->device, + sport->port, +IB_QPT_GSI , + ®_req,0 , + srpt_mad_send_handler, + srpt_mad_recv_handler, + sport,0 ); +if (IS_ERR (mad_agent)) {pr_err ("%s-%d: MAD agent registration failed (%ld). Note: this is expected if SR-IOV is enabled.\n" ,dev_name (&sport->sdev->device->dev), sport->port, -PTR_ERR (sport->mad_agent)); +PTR_ERR (mad_agent)); sport->mad_agent =NULL ;memset (&port_modify,0 ,sizeof (port_modify)); port_modify.clr_port_cap_mask =IB_PORT_DEVICE_MGMT_SUP ;ib_modify_port (sport->sdev->device, sport->port,0 , &port_modify); - +return 0 ; } + + sport->mad_agent = mad_agent; }return 0 ;
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 311/371 IB/hfi1: Fix SDMA mmu_rb_node not being evicted in LRU order
In reply to Greg Kroah-HartmanFrom: Patrick Kelsey <[email protected]>
[ Upstream commit 9fe8fec5e43d5a80f43cbf61aaada1b047a1eb61 ]
hfi1_mmu_rb_remove_unless_exact() did not move mmu_rb_node objects in mmu_rb_handler->lru_list after getting a cache hit on an mmu_rb_node.
As a result, hfi1_mmu_rb_evict() was not guaranteed to evict truly least-recently used nodes.
This could be a performance issue for an application when that application:
- Uses some long-lived buffers frequently.
- Uses a large number of buffers once.
- Hits the mmu_rb_handler cache size or pinned-page limits, forcing mmu_rb_handler cache entries to be evicted.
In this case, the one-time use buffers cause the long-lived buffer entries to eventually filter to the end of the LRU list where hfi1_mmu_rb_evict() will consider evicting a frequently-used long-lived entry instead of evicting one of the one-time use entries.
Fix this by inserting new mmu_rb_node at the tail of mmu_rb_handler->lru_list and move mmu_rb_ndoe to the tail of mmu_rb_handler->lru_list when the mmu_rb_node is a hit in hfi1_mmu_rb_remove_unless_exact(). Change hfi1_mmu_rb_evict() to evict from the head of mmu_rb_handler->lru_list instead of the tail.
--- drivers/infiniband/hw/hfi1/mmu_rb.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-)
drivers/infiniband/hw/hfi1/mmu_rb.c +6 -7
@@ -130,7 +130,7 @@ int hfi1_mmu_rb_insert(struct mmu_rb_handler *handler, goto unlock; }__mmu_int_rb_insert (mnode, &handler->root); -list_add (&mnode->list, &handler->lru_list); +list_add_tail (&mnode->list, &handler->lru_list); ret = handler->ops->insert (handler->ops_arg, mnode);if (ret) {
@@ -181,8 +181,10 @@ bool hfi1_mmu_rb_remove_unless_exact(struct mmu_rb_handler *handler,spin_lock_irqsave (&handler->lock, flags); node =__mmu_rb_search (handler, addr, len);if (node) { -if (node->addr == addr && node->len == len) +if (node->addr == addr && node->len == len) { +list_move_tail (&node->list, &handler->lru_list); goto unlock; + }__mmu_int_rb_remove (node, &handler->root);list_del (&node->list);/* remove from LRU list */ ret = true;
@@ -206,8 +208,7 @@ void hfi1_mmu_rb_evict(struct mmu_rb_handler *handler, void *evict_arg)INIT_LIST_HEAD (&del_list);spin_lock_irqsave (&handler->lock, flags); -list_for_each_entry_safe_reverse (rbnode, ptr, &handler->lru_list, - list) { +list_for_each_entry_safe (rbnode, ptr, &handler->lru_list, list) {if (handler->ops->evict (handler->ops_arg, rbnode, evict_arg, &stop)) {__mmu_int_rb_remove (rbnode, &handler->root);
@@ -219,9 +220,7 @@ void hfi1_mmu_rb_evict(struct mmu_rb_handler *handler, void *evict_arg) }spin_unlock_irqrestore (&handler->lock, flags); -while (!list_empty (&del_list)) { - rbnode = list_first_entry(&del_list, struct mmu_rb_node, list); -list_del (&rbnode->list); +list_for_each_entry_safe (rbnode, ptr, &del_list, list) { handler->ops->remove (handler->ops_arg, rbnode); } }
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 312/371 IB/hfi1: Fix bugs with non-PAGE_SIZE-end multi-iovec user SDMA requests
In reply to Greg Kroah-HartmanFrom: Patrick Kelsey <[email protected]>
[ Upstream commit 00cbce5cbf88459cd1aa1d60d0f1df15477df127 ]
hfi1 user SDMA request processing has two bugs that can cause data corruption for user SDMA requests that have multiple payload iovecs where an iovec other than the tail iovec does not run up to the page boundary for the buffer pointed to by that iovec.a
Here are the specific bugs:
1. user_sdma_txadd() does not use struct user_sdma_iovec->iov.iov_len. Rather, user_sdma_txadd() will add up to PAGE_SIZE bytes from iovec to the packet, even if some of those bytes are past iovec->iov.iov_len and are thus not intended to be in the packet.
2. user_sdma_txadd() and user_sdma_send_pkts() fail to advance to the next iovec in user_sdma_request->iovs when the current iovec is not PAGE_SIZE and does not contain enough data to complete the packet. The transmitted packet will contain the wrong data from the iovec pages.
This has not been an issue with SDMA packets from hfi1 Verbs or PSM2 because they only produce iovecs that end short of PAGE_SIZE as the tail iovec of an SDMA request.
Fixing these bugs exposes other bugs with the SDMA pin cache (struct mmu_rb_handler) that get in way of supporting user SDMA requests with multiple payload iovecs whose buffers do not end at PAGE_SIZE. So this commit fixes those issues as well.
Here are the mmu_rb_handler bugs that non-PAGE_SIZE-end multi-iovec payload user SDMA requests can hit:
1. Overlapping memory ranges in mmu_rb_handler will result in duplicate pinnings.
2. When extending an existing mmu_rb_handler entry (struct mmu_rb_node), the mmu_rb code (1) removes the existing entry under a lock, (2) releases that lock, pins the new pages, (3) then reacquires the lock to insert the extended mmu_rb_node.
If someone else comes in and inserts an overlapping entry between (2) and (3), insert in (3) will fail.
The failure path code in this case unpins _all_ pages in either the original mmu_rb_node or the new mmu_rb_node that was inserted between
(2) and (3).
3. In hfi1_mmu_rb_remove_unless_exact(), mmu_rb_node->refcount is incremented outside of mmu_rb_handler->lock. As a result, mmu_rb_node could be evicted by another thread that gets mmu_rb_handler->lock and checks mmu_rb_node->refcount before mmu_rb_node->refcount is incremented.
4. Related to #2 above, SDMA request submission failure path does not check mmu_rb_node->refcount before freeing mmu_rb_node object.
If there are other SDMA requests in progress whose iovecs have pointers to the now-freed mmu_rb_node(s), those pointers to the now-freed mmu_rb nodes will be dereferenced when those SDMA requests complete.
--- drivers/infiniband/hw/hfi1/ipoib_tx.c | 1 + drivers/infiniband/hw/hfi1/mmu_rb.c | 66 +-- drivers/infiniband/hw/hfi1/mmu_rb.h | 8 +- drivers/infiniband/hw/hfi1/sdma.c | 21 +- drivers/infiniband/hw/hfi1/sdma.h | 16 +- drivers/infiniband/hw/hfi1/sdma_txreq.h | 1 + drivers/infiniband/hw/hfi1/trace_mmu.h | 4 - drivers/infiniband/hw/hfi1/user_sdma.c | 600 +++++++++++++++--------- drivers/infiniband/hw/hfi1/user_sdma.h | 5 - drivers/infiniband/hw/hfi1/verbs.c | 4 +- drivers/infiniband/hw/hfi1/vnic_sdma.c | 1 + 11 files changed, 423 insertions(+), 304 deletions(-)
drivers/infiniband/hw/hfi1/ipoib_tx.c +1 -0
@@ -251,6 +251,7 @@ static int hfi1_ipoib_build_ulp_payload(struct ipoib_txreq *tx,const skb_frag_t *frag = &skb_shinfo (skb)->frags[i]; ret = sdma_txadd_page(dd, + NULL, txreq, skb_frag_page(frag), frag->bv_offset,
drivers/infiniband/hw/hfi1/mmu_rb.c +14 -52
90 lines not on this page · raw message
drivers/infiniband/hw/hfi1/mmu_rb.h +3 -5
@@ -52,10 +52,8 @@ void hfi1_mmu_rb_unregister(struct mmu_rb_handler *handler);int hfi1_mmu_rb_insert (struct mmu_rb_handler *handler,struct mmu_rb_node *mnode);void hfi1_mmu_rb_evict (struct mmu_rb_handler *handler,void *evict_arg); -void hfi1_mmu_rb_remove (struct mmu_rb_handler *handler, -struct mmu_rb_node *mnode); -bool hfi1_mmu_rb_remove_unless_exact (struct mmu_rb_handler *handler, -unsigned long addr,unsigned long len, -struct mmu_rb_node **rb_node); +struct mmu_rb_node *hfi1_mmu_rb_get_first (struct mmu_rb_handler *handler, +unsigned long addr, +unsigned long len);#endif /* _HFI1_MMU_RB_H */
drivers/infiniband/hw/hfi1/sdma.c +4 -17
@@ -1593,22 +1593,7 @@ static inline void sdma_unmap_desc(struct hfi1_devdata *dd, struct sdma_desc *descp) { - switch (sdma_mapping_type(descp)) { - case SDMA_MAP_SINGLE: -dma_unmap_single ( - &dd->pcidev->dev, -sdma_mapping_addr (descp ), -sdma_mapping_len (descp ), -DMA_TO_DEVICE ); -break ; -case SDMA_MAP_PAGE : -dma_unmap_page ( - &dd->pcidev->dev, -sdma_mapping_addr (descp), -sdma_mapping_len (descp), -DMA_TO_DEVICE ); -break ; - } +system_descriptor_complete (dd ,descp ); }/*
@@ -3128,7 +3113,7 @@ int ext_coal_sdma_tx_descs(struct hfi1_devdata *dd, struct sdma_txreq *tx,/* Add descriptor for coalesce buffer */ tx->desc_limit =MAX_DESC ; -return _sdma_txadd_daddr (dd,SDMA_MAP_SINGLE , tx, +return _sdma_txadd_daddr (dd,SDMA_MAP_SINGLE ,NULL , tx, addr, tx->tlen); }
@@ -3167,10 +3152,12 @@ int _pad_sdma_tx_descs(struct hfi1_devdata *dd, struct sdma_txreq *tx)return rval; } } +/* finish the one just added */ make_tx_sdma_desc ( tx,SDMA_MAP_NONE , +NULL , dd->sdma_pad_phys,sizeof (u32) - (tx->packet_len & (sizeof (u32) -1 ))); tx->num_desc++;
drivers/infiniband/hw/hfi1/sdma.h +11 -5
@@ -594,6 +594,7 @@ static inline dma_addr_t sdma_mapping_addr(struct sdma_desc *d)static inline void make_tx_sdma_desc (struct sdma_txreq *tx,int type, +void *pinning_ctx,dma_addr_t addr,size_t len) {
@@ -612,6 +613,7 @@ static inline void make_tx_sdma_desc( << SDMA_DESC0_PHY_ADDR_SHIFT) | (((u64 )len &SDMA_DESC0_BYTE_COUNT_MASK ) <<SDMA_DESC0_BYTE_COUNT_SHIFT ); + desc->pinning_ctx = pinning_ctx; }/* helper to extend txreq */
@@ -643,6 +645,7 @@ static inline void _sdma_close_tx(struct hfi1_devdata *dd,static inline int _sdma_txadd_daddr (struct hfi1_devdata *dd,int type, +void *pinning_ctx,struct sdma_txreq *tx,dma_addr_t addr,u16 len)
@@ -652,6 +655,7 @@ static inline int _sdma_txadd_daddr(make_tx_sdma_desc ( tx, type, + pinning_ctx, addr, len);WARN_ON (len > tx->tlen); tx->num_desc++;
@@ -672,6 +676,7 @@ static inline int _sdma_txadd_daddr(/** * sdma_txadd_page() - add a page to the sdma_txreq * @dd: the device to use for mapping +* @pinning_ctx: context to be released at descriptor retirement * @tx: tx request to which the page is added * @page: page to map * @offset: offset within the page
@@ -687,6 +692,7 @@ static inline int _sdma_txadd_daddr(*/ static inline int sdma_txadd_page( struct hfi1_devdata *dd, + void *pinning_ctx, struct sdma_txreq *tx, struct page *page, unsigned long offset,
@@ -714,8 +720,7 @@ static inline int sdma_txadd_page(return -ENOSPC ; } -return _sdma_txadd_daddr ( - dd,SDMA_MAP_PAGE , tx, addr, len); +return _sdma_txadd_daddr (dd,SDMA_MAP_PAGE , pinning_ctx, tx, addr, len); }/**
@@ -749,7 +754,8 @@ static inline int sdma_txadd_daddr(return rval; } -return _sdma_txadd_daddr (dd,SDMA_MAP_NONE , tx, addr, len); +return _sdma_txadd_daddr (dd,SDMA_MAP_NONE ,NULL , tx, + addr, len); }/**
@@ -795,8 +801,7 @@ static inline int sdma_txadd_kvaddr(return -ENOSPC ; } -return _sdma_txadd_daddr ( - dd,SDMA_MAP_SINGLE , tx, addr, len); +return _sdma_txadd_daddr (dd,SDMA_MAP_SINGLE ,NULL , tx, addr, len); }struct iowait_work ;
@@ -1030,4 +1035,5 @@ extern uint mod_num_sdma;void sdma_update_lmc (struct hfi1_devdata *dd,u64 mask,u32 lid); +void system_descriptor_complete (struct hfi1_devdata *dd,struct sdma_desc *descp);#endif
drivers/infiniband/hw/hfi1/sdma_txreq.h +1 -0
@@ -19,6 +19,7 @@struct sdma_desc {/* private: don't use directly */ u64 qw[2 ]; +void *pinning_ctx; };/**
drivers/infiniband/hw/hfi1/trace_mmu.h +0 -4
@@ -37,10 +37,6 @@ DEFINE_EVENT(hfi1_mmu_rb_template, hfi1_mmu_rb_search, TP_PROTO(unsigned long addr, unsigned long len), TP_ARGS(addr, len)); -DEFINE_EVENT (hfi1_mmu_rb_template, hfi1_mmu_rb_remove, - TP_PROTO(unsigned long addr, unsigned long len), -TP_ARGS (addr, len)); -DEFINE_EVENT (hfi1_mmu_rb_template, hfi1_mmu_mem_invalidate, TP_PROTO(unsigned long addr, unsigned long len),TP_ARGS (addr, len));
drivers/infiniband/hw/hfi1/user_sdma.c +386 -214
700 lines not on this page · raw message
drivers/infiniband/hw/hfi1/user_sdma.h +0 -5
@@ -112,16 +112,11 @@ struct sdma_mmu_node {struct user_sdma_iovec {struct list_head list;struct iovec iov; -/* number of pages in this vector */ -unsigned int npages; -/* array of pinned pages for this vector */ -struct page **pages;/* * offset into the virtual address space of the vector at * which we last left off. */ u64 offset; -struct sdma_mmu_node *node; };/* evict operation argument */
drivers/infiniband/hw/hfi1/verbs.c +2 -2
@@ -778,8 +778,8 @@ static int build_verbs_tx_desc(/* add icrc, lt byte, and padding to flit */ if (extra_bytes) - ret =sdma_txadd_daddr (sde->dd, &tx->txreq, - sde->dd->sdma_pad_phys, extra_bytes); + ret =sdma_txadd_daddr (sde->dd, &tx->txreq, sde->dd->sdma_pad_phys, + extra_bytes); bail_txadd:return ret;
drivers/infiniband/hw/hfi1/vnic_sdma.c +1 -0
@@ -64,6 +64,7 @@ static noinline int build_vnic_ulp_payload(struct sdma_engine *sde,/* combine physically continuous fragments later? */ ret = sdma_txadd_page(sde->dd, + NULL, &tx->txreq, skb_frag_page(frag), skb_frag_off(frag),
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 313/371 NFSv4.1: Always send a RECLAIM_COMPLETE after establishing lease
In reply to Greg Kroah-HartmanFrom: Trond Myklebust <[email protected]>
[ Upstream commit 40882deb83c29d8df4470d4e5e7f137b6acf7ad1 ]
The spec requires that we always at least send a RECLAIM_COMPLETE when we're done establishing the lease and recovering any state.
--- fs/nfs/nfs4state.c | 4 ++++ 1 file changed, 4 insertions(+)
fs/nfs/nfs4state.c +4 -0
@@ -67,6 +67,8 @@#define OPENOWNER_POOL_SIZE 8 +static void nfs4_state_start_reclaim_reboot (struct nfs_client *clp); +const nfs4_stateid zero_stateid = { { .data = {0 } }, .type =NFS4_SPECIAL_STATEID_TYPE ,
@@ -330,6 +332,8 @@ int nfs41_init_clientid(struct nfs_client *clp, const struct cred *cred) status =nfs4_proc_create_session (clp, cred);if (status !=0 ) goto out; +if (!(clp->cl_exchange_flags &EXCHGID4_FLAG_CONFIRMED_R )) +nfs4_state_start_reclaim_reboot (clp);nfs41_finish_session_reset (clp);nfs_mark_client_ready (clp,NFS_CS_READY ); out:
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 314/371 clk: qcom: regmap: add PHY clock source implementation
In reply to Greg Kroah-HartmanFrom: Dmitry Baryshkov <[email protected]>
[ Upstream commit 74e4190cdebe5a4aa099185edb4db418fc9883e3 ]
On recent Qualcomm platforms the QMP PIPE clocks feed into a set of muxes which must be parked to the "safe" source (bi_tcxo) when corresponding GDSC is turned off and on again. Currently this is handcoded in the PCIe driver by reparenting the gcc_pipe_N_clk_src clock. However the same code sequence should be applied in the pcie-qcom endpoint, USB3 and UFS drivers.
Rather than copying this sequence over and over again, follow the example of clk_rcg2_shared_ops and implement this parking in the enable() and disable() clock operations. Supplement the regmap-mux with the new clk_regmap_phy_mux type, which implements such multiplexers as a simple gate clocks.
This is possible since each of these multiplexers has just two clock
sources: one coming from the PHY and a reference (XO) one. If the clock is running off the from-PHY source, report it as enabled. Report it as disabled otherwise (if it uses reference source).
This way the PHY will disable the pipe clock before turning off the GDSC, which in turn would lead to disabling corresponding pipe_clk_src (and thus it being parked to a safe, reference clock source). And vice versa, after enabling the GDSC the PHY will enable the pipe clock, which would cause pipe_clk_src to be switched from a safe source to the working one.
Stable-dep-of: 1a500e0bc97b ("clk: qcom: gcc-sm8350: fix PCIe PIPE clocks handling")
--- drivers/clk/qcom/Makefile | 1 + drivers/clk/qcom/clk-regmap-phy-mux.c | 62 +++++++++++++++++++++++++++ drivers/clk/qcom/clk-regmap-phy-mux.h | 33 ++++++++++++++ 3 files changed, 96 insertions(+) create mode 100644 drivers/clk/qcom/clk-regmap-phy-mux.c create mode 100644 drivers/clk/qcom/clk-regmap-phy-mux.h
drivers/clk/qcom/Makefile +1 -0
@@ -11,6 +11,7 @@ clk-qcom-y += clk-branch.o clk-qcom-y += clk-regmap-divider.o clk-qcom-y += clk-regmap-mux.o clk-qcom-y += clk-regmap-mux-div.o +clk-qcom-y += clk-regmap-phy-mux.o clk-qcom-$(CONFIG_KRAIT_CLOCKS) += clk-krait.o clk-qcom-y += clk-hfpll.o clk-qcom-y += reset.o
drivers/clk/qcom/clk-regmap-phy-mux.c new file +62 -0
62 lines not on this page · raw message
drivers/clk/qcom/clk-regmap-phy-mux.h new file +33 -0
@@ -0,0 +1,33 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/* +* Copyright (c) 2022, Linaro Ltd. +*/ + +#ifndef __QCOM_CLK_REGMAP_PHY_MUX_H__ +#define __QCOM_CLK_REGMAP_PHY_MUX_H__ + +#include "clk-regmap.h" + +/* +* A clock implementation for PHY pipe and symbols clock muxes. +* +* If the clock is running off the from-PHY source, report it as enabled. +* Report it as disabled otherwise (if it uses reference source). +* +* This way the PHY will disable the pipe clock before turning off the GDSC, +* which in turn would lead to disabling corresponding pipe_clk_src (and thus +* it being parked to a safe, reference clock source). And vice versa, after +* enabling the GDSC the PHY will enable the pipe clock, which would cause +* pipe_clk_src to be switched from a safe source to the working one. +* +* For some platforms this should be used for the UFS symbol_clk_src clocks +* too. +*/ +struct clk_regmap_phy_mux { +u32 reg; +struct clk_regmap clkr; +}; + +extern const struct clk_ops clk_regmap_phy_mux_ops; + +#endif
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 315/371 clk: qcom: gcc-sm8350: fix PCIe PIPE clocks handling
In reply to Greg Kroah-HartmanFrom: Dmitry Baryshkov <[email protected]>
[ Upstream commit 1a500e0bc97b6cb3c0d9859e81973b8dd07d1b7b ]
On SM8350 platform the PCIe PIPE clocks require additional handling to function correctly. They are to be switched to the tcxo source before turning PCIe GDSCs off and should be switched to PHY PIPE source once they are working. Switch PCIe PHY clocks to use clk_regmap_phy_mux_ops, which provide support for this dance.
--- drivers/clk/qcom/gcc-sm8350.c | 47 ++++++++++------------------------- 1 file changed, 13 insertions(+), 34 deletions(-)
drivers/clk/qcom/gcc-sm8350.c +13 -34
@@ -16,6 +16,7 @@#include "clk-regmap.h" #include "clk-regmap-divider.h" #include "clk-regmap-mux.h" +#include "clk-regmap-phy-mux.h" #include "gdsc.h" #include "reset.h"
@@ -166,26 +167,6 @@ static const struct clk_parent_data gcc_parent_data_3[] = { { .fw_name = "core_bi_pll_test_se" }, }; -static const struct parent_map gcc_parent_map_4[] = { - {P_PCIE_0_PIPE_CLK ,0 }, - {P_BI_TCXO ,2 }, -}; - -static const struct clk_parent_data gcc_parent_data_4[] = { - { .fw_name ="pcie_0_pipe_clk" , }, - { .fw_name ="bi_tcxo" }, -}; - -static const struct parent_map gcc_parent_map_5[] = { - {P_PCIE_1_PIPE_CLK ,0 }, - {P_BI_TCXO ,2 }, -}; - -static const struct clk_parent_data gcc_parent_data_5[] = { - { .fw_name ="pcie_1_pipe_clk" }, - { .fw_name ="bi_tcxo" }, -}; -static const struct parent_map gcc_parent_map_6[] = { {P_BI_TCXO ,0 }, { P_GCC_GPLL0_OUT_MAIN, 1 },
@@ -288,32 +269,30 @@ static const struct clk_parent_data gcc_parent_data_14[] = { { .fw_name = "bi_tcxo" }, }; -static struct clk_regmap_mux gcc_pcie_0_pipe_clk_src = { +static struct clk_regmap_phy_mux gcc_pcie_0_pipe_clk_src = { .reg =0x6b054 , - .shift =0 , - .width =2 , - .parent_map = gcc_parent_map_4, .clkr = { .hw.init = &(struct clk_init_data ){ .name ="gcc_pcie_0_pipe_clk_src" , - .parent_data = gcc_parent_data_4, - .num_parents =ARRAY_SIZE (gcc_parent_data_4), - .ops = &clk_regmap_mux_closest_ops, + .parent_data = &(const struct clk_parent_data ){ + .fw_name ="pcie_0_pipe_clk" , + }, + .num_parents =1 , + .ops = &clk_regmap_phy_mux_ops, }, }, }; -static struct clk_regmap_mux gcc_pcie_1_pipe_clk_src = { +static struct clk_regmap_phy_mux gcc_pcie_1_pipe_clk_src = { .reg =0x8d054 , - .shift =0 , - .width =2 , - .parent_map = gcc_parent_map_5, .clkr = { .hw.init = &(struct clk_init_data ){ .name ="gcc_pcie_1_pipe_clk_src" , - .parent_data = gcc_parent_data_5, - .num_parents =ARRAY_SIZE (gcc_parent_data_5), - .ops = &clk_regmap_mux_closest_ops, + .parent_data = &(const struct clk_parent_data ){ + .fw_name ="pcie_1_pipe_clk" , + }, + .num_parents =1 , + .ops = &clk_regmap_phy_mux_ops, }, }, };
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 316/371 Input: raspberrypi-ts - fix refcount leak in rpi_ts_probe
In reply to Greg Kroah-HartmanFrom: Miaoqian Lin <[email protected]>
[ Upstream commit 5bca3688bdbc3b58a2894b8671a8e2378efe28bd ]
rpi_firmware_get() take reference, we need to release it in error paths as well. Use devm_rpi_firmware_get() helper to handling the resources. Also remove the existing rpi_firmware_put().
--- drivers/input/touchscreen/raspberrypi-ts.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/input/touchscreen/raspberrypi-ts.c +1 -2
@@ -134,7 +134,7 @@ static int rpi_ts_probe(struct platform_device *pdev)return -ENOENT ; } - fw =rpi_firmware_get (fw_node); + fw =devm_rpi_firmware_get (&pdev->dev, fw_node);of_node_put (fw_node);if (!fw)return -EPROBE_DEFER ;
@@ -160,7 +160,6 @@ static int rpi_ts_probe(struct platform_device *pdev) touchbuf = (u32 )ts->fw_regs_phys; error =rpi_firmware_property (fw,RPI_FIRMWARE_FRAMEBUFFER_SET_TOUCHBUF , &touchbuf,sizeof (touchbuf)); -rpi_firmware_put (fw);if (error || touchbuf !=0 ) {dev_warn (dev,"Failed to set touchbuf, %d\n" , error);return error;
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 317/371 RDMA/mlx5: Fix flow counter query via DEVX
In reply to Greg Kroah-HartmanFrom: Mark Bloch <[email protected]>
[ Upstream commit 3e358ea8614ddfbc59ca7a3f5dff5dde2b350b2c ]
Commit cited in "fixes" tag added bulk support for flow counters but it didn't account that's also possible to query a counter using a non-base id if the counter was allocated as bulk.
When a user performs a query, validate the flow counter id given in the mailbox is inside the valid range taking bulk value into account.
--- drivers/infiniband/hw/mlx5/devx.c | 31 ++++++++++++++++++++++++++----- include/linux/mlx5/mlx5_ifc.h | 3 ++- 2 files changed, 28 insertions(+), 6 deletions(-)
drivers/infiniband/hw/mlx5/devx.c +26 -5
@@ -666,7 +666,21 @@ static bool devx_is_valid_obj_id(struct uverbs_attr_bundle *attrs, obj_id;case MLX5_IB_OBJECT_DEVX_OBJ : -return ((struct devx_obj *)uobj->object)->obj_id == obj_id; + { +u16 opcode =MLX5_GET (general_obj_in_cmd_hdr, in, opcode); +struct devx_obj *devx_uobj = uobj->object; + +if (opcode ==MLX5_CMD_OP_QUERY_FLOW_COUNTER && + devx_uobj->flow_counter_bulk_size) { +u64 end; + + end = devx_uobj->obj_id + + devx_uobj->flow_counter_bulk_size; +return devx_uobj->obj_id <= obj_id && end > obj_id; + } + +return devx_uobj->obj_id == obj_id; + }default :return false;
@@ -1515,10 +1529,17 @@ static int UVERBS_HANDLER(MLX5_IB_METHOD_DEVX_OBJ_CREATE)( goto obj_free;if (opcode ==MLX5_CMD_OP_ALLOC_FLOW_COUNTER ) { -u8 bulk =MLX5_GET (alloc_flow_counter_in, - cmd_in, - flow_counter_bulk); - obj->flow_counter_bulk_size =128UL * bulk; +u32 bulk =MLX5_GET (alloc_flow_counter_in, + cmd_in, + flow_counter_bulk_log_size); + +if (bulk) + bulk =1 << bulk; +else + bulk =128UL *MLX5_GET (alloc_flow_counter_in, + cmd_in, + flow_counter_bulk); + obj->flow_counter_bulk_size = bulk; } uobj->object = obj;
include/linux/mlx5/mlx5_ifc.h +2 -1
@@ -8508,7 +8508,8 @@ struct mlx5_ifc_alloc_flow_counter_in_bits {u8 reserved_at_20[0x10 ];u8 op_mod[0x10 ]; -u8 reserved_at_40[0x38 ]; +u8 reserved_at_40[0x33 ]; +u8 flow_counter_bulk_log_size[0x5 ];u8 flow_counter_bulk[0x8 ]; };
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 318/371 SUNRPC: remove the maximum number of retries in call_bind_status
In reply to Greg Kroah-HartmanFrom: Dai Ngo <[email protected]>
[ Upstream commit 691d0b782066a6eeeecbfceb7910a8f6184e6105 ]
Currently call_bind_status places a hard limit of 3 to the number of retries on EACCES error. This limit was done to prevent NLM unlock requests from being hang forever when the server keeps returning garbage. However this change causes problem for cases when NLM service takes longer than 9 seconds to register with the port mapper after a restart.
This patch removes this hard coded limit and let the RPC handles the retry based on the standard hard/soft task semantics.
--- include/linux/sunrpc/sched.h | 3 +-- net/sunrpc/clnt.c | 3 --- net/sunrpc/sched.c | 1 - 3 files changed, 1 insertion(+), 6 deletions(-)
include/linux/sunrpc/sched.h +1 -2
@@ -90,8 +90,7 @@ struct rpc_task {#endif unsigned char tk_priority : 2,/* Task priority */ tk_garb_retry : 2, - tk_cred_retry : 2, - tk_rebind_retry : 2; + tk_cred_retry : 2; };typedef void (*rpc_action )(struct rpc_task *);
net/sunrpc/clnt.c +0 -3
@@ -1981,9 +1981,6 @@ call_bind_status(struct rpc_task *task) status = -EOPNOTSUPP ;break ; } -if (task->tk_rebind_retry ==0 ) -break ; - task->tk_rebind_retry--;rpc_delay (task,3 *HZ ); goto retry_timeout;case -ENOBUFS :
net/sunrpc/sched.c +0 -1
@@ -796,7 +796,6 @@ rpc_init_task_statistics(struct rpc_task *task)/* Initialize retry counters */ task->tk_garb_retry =2 ; task->tk_cred_retry =2 ; - task->tk_rebind_retry =2 ;/* starting timestamp */ task->tk_start =ktime_get ();
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 319/371 RDMA/mlx5: Use correct device num_ports when modify DC
In reply to Greg Kroah-HartmanFrom: Mark Zhang <[email protected]>
[ Upstream commit 746aa3c8cb1a650ff2583497ac646e505831b9b9 ]
Just like other QP types, when modify DC, the port_num should be compared with dev->num_ports, instead of HCA_CAP.num_ports. Otherwise Multi-port vHCA on DC may not work.
--- drivers/infiniband/hw/mlx5/qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/infiniband/hw/mlx5/qp.c +1 -1
@@ -4406,7 +4406,7 @@ static int mlx5_ib_modify_dct(struct ib_qp *ibqp, struct ib_qp_attr *attr,return -EINVAL ;if (attr->port_num ==0 || - attr->port_num >MLX5_CAP_GEN (dev->mdev, num_ports)) { + attr->port_num > dev->num_ports) {mlx5_ib_dbg (dev,"invalid port number %d. number of ports is %d\n" , attr->port_num, dev->num_ports);return -EINVAL ;
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 320/371 clocksource/drivers/davinci: Fix memory leak in davinci_timer_register when init fails
In reply to Greg Kroah-HartmanFrom: Qinrun Dai <[email protected]>
[ Upstream commit fb73556386e074e9bee9fa2d253aeaefe4e063e0 ]
Smatch reports:drivers/clocksource/timer-davinci.c:332 davinci_timer_register()
warn: 'base' from ioremap() not released on lines: 274.
Fix this and other potential memory leak problems
by adding a set of corresponding exit lables.
--- drivers/clocksource/timer-davinci.c | 30 +++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-)
drivers/clocksource/timer-davinci.c +24 -6
@@ -257,21 +257,25 @@ int __init davinci_timer_register(struct clk *clk, resource_size(&timer_cfg->reg), "davinci-timer")) {pr_err ("Unable to request memory region\n" ); -return -EBUSY ; + rv = -EBUSY ; + goto exit_clk_disable; } base =ioremap (timer_cfg->reg.start,resource_size (&timer_cfg->reg));if (!base) {pr_err ("Unable to map the register range\n" ); -return -ENOMEM ; + rv = -ENOMEM ; + goto exit_mem_region; }davinci_timer_init (base); tick_rate =clk_get_rate (clk); clockevent =kzalloc (sizeof (*clockevent),GFP_KERNEL ); -if (!clockevent) -return -ENOMEM ; +if (!clockevent) { + rv = -ENOMEM ; + goto exit_iounmap_base; + } clockevent->dev.name ="tim12" ; clockevent->dev.features =CLOCK_EVT_FEAT_ONESHOT ;
@@ -296,7 +300,7 @@ int __init davinci_timer_register(struct clk *clk, "clockevent/tim12", clockevent);if (rv) {pr_err ("Unable to request the clockevent interrupt\n" ); -return rv; + goto exit_free_clockevent; } davinci_clocksource.dev.rating =300 ;
@@ -323,13 +327,27 @@ int __init davinci_timer_register(struct clk *clk, rv =clocksource_register_hz (&davinci_clocksource.dev, tick_rate);if (rv) {pr_err ("Unable to register clocksource\n" ); -return rv; + goto exit_free_irq; }sched_clock_register (davinci_timer_read_sched_clock,DAVINCI_TIMER_CLKSRC_BITS , tick_rate);return 0 ; + +exit_free_irq: +free_irq (timer_cfg->irq[DAVINCI_TIMER_CLOCKEVENT_IRQ ].start, + clockevent); +exit_free_clockevent: +kfree (clockevent); +exit_iounmap_base: +iounmap (base); +exit_mem_region: +release_mem_region (timer_cfg->reg.start, +resource_size (&timer_cfg->reg)); +exit_clk_disable: +clk_disable_unprepare (clk); +return rv; }static int __init of_davinci_timer_register (struct device_node *np)
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 321/371 openrisc: Properly store r31 to pt_regs on unhandled exceptions
In reply to Greg Kroah-HartmanFrom: Stafford Horne <[email protected]>
[ Upstream commit 812489ac4dd91144a74ce65ecf232252a2e406fb ]
In commit 91993c8c2ed5 ("openrisc: use shadow registers to save regs on exception") the unhandled exception path was changed to do an early store of r30 instead of r31. The entry code was not updated and r31 is not getting stored to pt_regs.
This patch updates the entry handler to store r31 instead of r30. We also remove some misleading commented out store r30 and r31 instructrions.
I noticed this while working on adding floating point exception handling, This issue probably would never impact anything since we kill the process or Oops right away on unhandled exceptions.
--- arch/openrisc/kernel/entry.S | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
arch/openrisc/kernel/entry.S +2 -4
@@ -173,7 +173,6 @@ handler: ;\ l.sw PT_GPR28(r1),r28 ;\ l.sw PT_GPR29(r1),r29 ;\ /* r30 already save */ ;\ -/* l.sw PT_GPR30(r1),r30*/ ;\ l.sw PT_GPR31(r1),r31 ;\ TRACE_IRQS_OFF_ENTRY ;\ /* Store -1 in orig_gpr11 for non-syscall exceptions */ ;\
@@ -211,9 +210,8 @@ handler: ;\ l.sw PT_GPR27(r1),r27 ;\ l.sw PT_GPR28(r1),r28 ;\ l.sw PT_GPR29(r1),r29 ;\ - /* r31 already saved */ ;\ - l.sw PT_GPR30(r1),r30 ;\ -/* l.sw PT_GPR31(r1),r31 */ ;\ + /* r30 already saved */ ;\ + l.sw PT_GPR31(r1),r31 ;\ /* Store -1 in orig_gpr11 for non-syscall exceptions */ ;\ l.addi r30,r0,-1 ;\ l.sw PT_ORIG_GPR11(r1),r30 ;\
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 322/371 timekeeping: Fix references to nonexistent ktime_get_fast_ns()
In reply to Greg Kroah-HartmanFrom: Geert Uytterhoeven <[email protected]>
[ Upstream commit 158009f1b4a33bc0f354b994eea361362bd83226 ]
There was never a function named ktime_get_fast_ns(). Presumably these should refer to ktime_get_mono_fast_ns() instead.
--- kernel/time/timekeeping.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/time/timekeeping.c +2 -2
@@ -523,7 +523,7 @@ EXPORT_SYMBOL_GPL(ktime_get_raw_fast_ns);* partially updated. Since the tk->offs_boot update is a rare event, this * should be a rare occurrence which postprocessing should be able to handle. * -* The caveats vs. timestamp ordering as documented for ktime_get_fast_ns() +* The caveats vs. timestamp ordering as documented for ktime_get_mono_fast_ns() * apply as well. */ u64 notrace ktime_get_boot_fast_ns(void)
@@ -559,7 +559,7 @@ static __always_inline u64 __ktime_get_real_fast(struct tk_fast *tkf, u64 *mono)/** * ktime_get_real_fast_ns: - NMI safe and fast access to clock realtime. * -* See ktime_get_fast_ns() for documentation of the time stamp ordering. +* See ktime_get_mono_fast_ns() for documentation of the time stamp ordering. */ u64 ktime_get_real_fast_ns (void ) {
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 323/371 SMB3: Add missing locks to protect deferred close file list
In reply to Greg Kroah-HartmanFrom: Bharath SM <[email protected]>
[ Upstream commit ab9ddc87a9055c4bebd6524d5d761d605d52e557 ]
cifs_del_deferred_close function has a critical section which modifies the deferred close file list. We must acquire deferred_lock before calling cifs_del_deferred_close function.
--- fs/cifs/misc.c | 6 ++++++ 1 file changed, 6 insertions(+)
fs/cifs/misc.c +6 -0
@@ -733,7 +733,9 @@ cifs_close_deferred_file(struct cifsInodeInfo *cifs_inode)list_for_each_entry (cfile, &cifs_inode->openFileList, flist) {if (delayed_work_pending (&cfile->deferred)) {if (cancel_delayed_work (&cfile->deferred)) { +spin_lock (&cifs_inode->deferred_lock);cifs_del_deferred_close (cfile); +spin_unlock (&cifs_inode->deferred_lock); tmp_list =kmalloc (sizeof (struct file_list ),GFP_ATOMIC );if (tmp_list ==NULL )
@@ -766,7 +768,9 @@ cifs_close_all_deferred_files(struct cifs_tcon *tcon) cfile = list_entry(tmp, struct cifsFileInfo, tlist);if (delayed_work_pending (&cfile->deferred)) {if (cancel_delayed_work (&cfile->deferred)) { +spin_lock (&CIFS_I (d_inode (cfile->dentry))->deferred_lock);cifs_del_deferred_close (cfile); +spin_unlock (&CIFS_I (d_inode (cfile->dentry))->deferred_lock); tmp_list =kmalloc (sizeof (struct file_list ),GFP_ATOMIC );if (tmp_list ==NULL )
@@ -803,7 +807,9 @@ cifs_close_deferred_file_under_dentry(struct cifs_tcon *tcon, const char *path)if (strstr (full_path, path)) {if (delayed_work_pending (&cfile->deferred)) {if (cancel_delayed_work (&cfile->deferred)) { +spin_lock (&CIFS_I (d_inode (cfile->dentry))->deferred_lock);cifs_del_deferred_close (cfile); +spin_unlock (&CIFS_I (d_inode (cfile->dentry))->deferred_lock); tmp_list =kmalloc (sizeof (struct file_list ),GFP_ATOMIC );if (tmp_list ==NULL )
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 324/371 SMB3: Close deferred file handles in case of handle lease break
In reply to Greg Kroah-HartmanFrom: Bharath SM <[email protected]>
[ Upstream commit d906be3fa571f6fc9381911304a0eca99f1b6951 ]
We should not cache deferred file handles if we dont have handle lease on a file. And we should immediately close all deferred handles in case of handle lease break.
--- fs/cifs/file.c | 16 ++++++++++++++++ fs/cifs/misc.c | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-)
fs/cifs/file.c +16 -0
@@ -4870,6 +4870,8 @@ void cifs_oplock_break(struct work_struct *work)struct TCP_Server_Info *server = tcon->ses->server;int rc =0 ;bool purge_cache = false; +struct cifs_deferred_close *dclose; +bool is_deferred = false;wait_on_bit (&cinode->flags,CIFS_INODE_PENDING_WRITERS ,TASK_UNINTERRUPTIBLE );
@@ -4905,6 +4907,20 @@ void cifs_oplock_break(struct work_struct *work)cifs_dbg (VFS ,"Push locks rc = %d\n" , rc); oplock_break_ack: +/* +* When oplock break is received and there are no active +* file handles but cached, then schedule deferred close immediately. +* So, new open will not use cached handle. +*/ +spin_lock (&CIFS_I (inode)->deferred_lock); + is_deferred =cifs_is_deferred_close (cfile, &dclose); +spin_unlock (&CIFS_I (inode)->deferred_lock); + +if (!CIFS_CACHE_HANDLE (cinode) && is_deferred && + cfile->deferred_close_scheduled &&delayed_work_pending (&cfile->deferred)) { +cifs_close_deferred_file (cinode); + } +/* * releasing stale oplock after recent reconnect of smb session using * a now incorrect file handle is not a data integrity issue but do
fs/cifs/misc.c +1 -1
@@ -748,7 +748,7 @@ cifs_close_deferred_file(struct cifsInodeInfo *cifs_inode)spin_unlock (&cifs_inode->open_file_lock);list_for_each_entry_safe (tmp_list, tmp_next_list, &file_head, list) { -_cifsFileInfo_put (tmp_list->cfile, true, false); +_cifsFileInfo_put (tmp_list->cfile, false, false);list_del (&tmp_list->list);kfree (tmp_list); }
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 325/371 ext4: fix i_disksize exceeding i_size problem in paritally written case
In reply to Greg Kroah-HartmanFrom: Zhihao Cheng <[email protected]>
[ Upstream commit 1dedde690303c05ef732b7c5c8356fdf60a4ade3 ]
It is possible for i_disksize can exceed i_size, triggering a warning.
generic_perform_write
copied = iov_iter_copy_from_user_atomic(len) // copied < len ext4_da_write_end
| ext4_update_i_disksize | new_i_size = pos + copied; | WRITE_ONCE(EXT4_I(inode)->i_disksize, newsize) // update i_disksize | generic_write_end | copied = block_write_end(copied, len) // copied = 0 | if (unlikely(copied < len)) | if (!PageUptodate(page)) | copied = 0; | if (pos + copied > inode->i_size) // return false
if (unlikely(copied == 0))
goto again;
if (unlikely(iov_iter_fault_in_readable(i, bytes))) {
status = -EFAULT;
break;
}
We get i_disksize greater than i_size here, which could trigger WARNING check 'i_size_read(inode) < EXT4_I(inode)->i_disksize' while doing dio:
ext4_dio_write_iter
iomap_dio_rw
__iomap_dio_rw // return err, length is not aligned to 512
ext4_handle_inode_extension
WARN_ON_ONCE(i_size_read(inode) < EXT4_I(inode)->i_disksize) // Oops
WARNING: CPU: 2 PID: 2609 at fs/ext4/file.c:319 CPU: 2 PID: 2609 Comm: aa Not tainted 6.3.0-rc2 RIP: 0010:ext4_file_write_iter+0xbc7 Call Trace: vfs_write+0x3b1 ksys_write+0x77 do_syscall_64+0x39
Fix it by updating 'copied' value before updating i_disksize just like ext4_write_inline_data_end() does.
A reproducer can be found in the buganizer link below.
--- fs/ext4/inode.c | 3 +++ 1 file changed, 3 insertions(+)
fs/ext4/inode.c +3 -0
@@ -3065,6 +3065,9 @@ static int ext4_da_write_end(struct file *file, ext4_has_inline_data(inode))return ext4_write_inline_data_end (inode, pos, len, copied, page); +if (unlikely (copied < len) && !PageUptodate (page)) + copied =0 ; + start = pos & (PAGE_SIZE -1 ); end = start + copied -1 ;
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 326/371 ext4: fix use-after-free read in ext4_find_extent for bigalloc + inline
In reply to Greg Kroah-HartmanFrom: Ye Bin <[email protected]>
[ Upstream commit 835659598c67907b98cd2aa57bb951dfaf675c69 ]
Syzbot found the following issue:
loop0: detected capacity change from 0 to 2048
EXT4-fs (loop0): mounted filesystem 00000000-0000-0000-0000-000000000000 without journal. Quota mode: none.
==================================================================
BUG: KASAN: use-after-free in ext4_ext_binsearch_idx fs/ext4/extents.c:768 [inline] BUG: KASAN: use-after-free in ext4_find_extent+0x76e/0xd90 fs/ext4/extents.c:931 Read of size 4 at addr ffff888073644750 by task syz-executor420/5067 CPU: 0 PID: 5067 Comm: syz-executor420 Not tainted 6.2.0-rc1-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 Call Trace: <TASK> __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1b1/0x290 lib/dump_stack.c:106 print_address_description+0x74/0x340 mm/kasan/report.c:306 print_report+0x107/0x1f0 mm/kasan/report.c:417 kasan_report+0xcd/0x100 mm/kasan/report.c:517 ext4_ext_binsearch_idx fs/ext4/extents.c:768 [inline] ext4_find_extent+0x76e/0xd90 fs/ext4/extents.c:931 ext4_clu_mapped+0x117/0x970 fs/ext4/extents.c:5809 ext4_insert_delayed_block fs/ext4/inode.c:1696 [inline] ext4_da_map_blocks fs/ext4/inode.c:1806 [inline] ext4_da_get_block_prep+0x9e8/0x13c0 fs/ext4/inode.c:1870 ext4_block_write_begin+0x6a8/0x2290 fs/ext4/inode.c:1098 ext4_da_write_begin+0x539/0x760 fs/ext4/inode.c:3082 generic_perform_write+0x2e4/0x5e0 mm/filemap.c:3772 ext4_buffered_write_iter+0x122/0x3a0 fs/ext4/file.c:285 ext4_file_write_iter+0x1d0/0x18f0 call_write_iter include/linux/fs.h:2186 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x7dc/0xc50 fs/read_write.c:584 ksys_write+0x177/0x2a0 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f4b7a9737b9 RSP: 002b:00007ffc5cac3668 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f4b7a9737b9 RDX: 00000000175d9003 RSI: 0000000020000200 RDI: 0000000000000004 RBP: 00007f4b7a933050 R08: 0000000000000000 R09: 0000000000000000 R10: 000000000000079f R11: 0000000000000246 R12: 00007f4b7a9330e0 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 </TASK>
Above issue is happens when enable bigalloc and inline data feature. As commit 131294c35ed6 fixed delayed allocation bug in ext4_clu_mapped for bigalloc + inline. But it only resolved issue when has inline data, if inline data has been converted to extent(ext4_da_convert_inline_data_to_extent) before writepages, there is no EXT4_STATE_MAY_INLINE_DATA flag. However i_data is still store inline data in this scene. Then will trigger UAF when find extent.
To resolve above issue, there is need to add judge "ext4_has_inline_data(inode)" in ext4_clu_mapped().
--- fs/ext4/extents.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
fs/ext4/extents.c +2 -1
@@ -5812,7 +5812,8 @@ int ext4_clu_mapped(struct inode *inode, ext4_lblk_t lclu)* mapped - no physical clusters have been allocated, and the * file has no extents */ -if (ext4_test_inode_state (inode,EXT4_STATE_MAY_INLINE_DATA )) +if (ext4_test_inode_state (inode,EXT4_STATE_MAY_INLINE_DATA ) || +ext4_has_inline_data (inode))return 0 ;/* search for the extent closest to the first block in the cluster */
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 327/371 pinctrl: renesas: r8a779a0: Remove incorrect AVB[01] pinmux configuration
In reply to Greg Kroah-HartmanFrom: Hai Pham <[email protected]>
[ Upstream commit a145c9a8674ac8fbfa1595276e1b6cbfc5139038 ]
AVB[01]_{MAGIC,MDC,MDIO,TXCREFCLK} are registered as both PINMUX_SINGLE(fn) and PINMUX_IPSR_GPSR(fn) in the pinmux_data array.
The latter are correct, hence remove the former.
Without this fix, the Ethernet PHY is not operational on the MDIO bus.
--- drivers/pinctrl/renesas/pfc-r8a779a0.c | 8 -------- 1 file changed, 8 deletions(-)
drivers/pinctrl/renesas/pfc-r8a779a0.c +0 -8
@@ -710,16 +710,8 @@ static const u16 pinmux_data[] = {PINMUX_SINGLE (PCIE0_CLKREQ_N ),PINMUX_SINGLE (AVB0_PHY_INT ), -PINMUX_SINGLE (AVB0_MAGIC ), -PINMUX_SINGLE (AVB0_MDC ), -PINMUX_SINGLE (AVB0_MDIO ), -PINMUX_SINGLE (AVB0_TXCREFCLK ),PINMUX_SINGLE (AVB1_PHY_INT ), -PINMUX_SINGLE (AVB1_MAGIC ), -PINMUX_SINGLE (AVB1_MDC ), -PINMUX_SINGLE (AVB1_MDIO ), -PINMUX_SINGLE (AVB1_TXCREFCLK ),PINMUX_SINGLE (AVB2_AVTP_PPS ), PINMUX_SINGLE(AVB2_AVTP_CAPTURE),
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 328/371 leds: TI_LMU_COMMON: select REGMAP instead of depending on it
In reply to Greg Kroah-HartmanFrom: Randy Dunlap <[email protected]>
[ Upstream commit a61079efc87888587e463afaed82417b162fbd69 ]
REGMAP is a hidden (not user visible) symbol. Users cannot set it directly thru "make *config", so drivers should select it instead of depending on it if they need it.
Consistently using "select" or "depends on" can also help reduce Kconfig circular dependency issues.
Therefore, change the use of "depends on REGMAP" to "select REGMAP".
--- drivers/leds/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/leds/Kconfig +1 -1
@@ -821,7 +821,7 @@ config LEDS_SPI_BYTE config LEDS_TI_LMU_COMMON tristate "LED driver for TI LMU" depends on LEDS_CLASS - depends on REGMAP + select REGMAP help Say Y to enable the LED driver for TI LMU devices. This supports common features between the TI LM3532, LM3631, LM3632,
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 329/371 dmaengine: mv_xor_v2: Fix an error code.
In reply to Greg Kroah-HartmanFrom: Christophe JAILLET <[email protected]>
[ Upstream commit 827026ae2e56ec05ef1155661079badbbfc0b038 ]
If the probe is deferred, -EPROBE_DEFER should be returned, not +EPROBE_DEFER.
--- drivers/dma/mv_xor_v2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/mv_xor_v2.c +1 -1
@@ -756,7 +756,7 @@ static int mv_xor_v2_probe(struct platform_device *pdev) xor_dev->clk =devm_clk_get (&pdev->dev,NULL );if (PTR_ERR (xor_dev->clk) == -EPROBE_DEFER ) { - ret =EPROBE_DEFER ; + ret = -EPROBE_DEFER ; goto disable_reg_clk; }if (!IS_ERR (xor_dev->clk)) {
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 330/371 leds: tca6507: Fix error handling of using fwnode_property_read_string
In reply to Greg Kroah-HartmanFrom: H. Nikolaus Schaller <[email protected]>
[ Upstream commit c1087c29e96a48e9080377e168d35dcb52fb068b ]
Commit 96f524105b9c ("leds: tca6507: use fwnode API instead of OF")
changed to fwnode API but did not take into account that a missing property "linux,default-trigger" now seems to return an error and as a side effect sets value to -1. This seems to be different from of_get_property() which always returned NULL in any case of error.
Neglecting this side-effect leads to
[ 11.201965] Unable to handle kernel paging request at virtual address ffffffff when read
in the strcmp() of led_trigger_set_default() if there is no led-trigger defined in the DTS.
I don't know if this was recently introduced somewhere in the fwnode lib or if the effect was missed in initial testing. Anyways it seems to be a bug to ignore the error return value of an optional value here in the driver.
--- drivers/leds/leds-tca6507.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/leds/leds-tca6507.c +3 -2
@@ -696,8 +696,9 @@ tca6507_led_dt_init(struct device *dev)if (fwnode_property_read_string (child,"label" , &led.name)) led.name =fwnode_get_name (child); -fwnode_property_read_string (child,"linux,default-trigger" , - &led.default_trigger); +if (fwnode_property_read_string (child,"linux,default-trigger" , + &led.default_trigger)) + led.default_trigger =NULL ; led.flags =0 ; if (fwnode_property_match_string(child, "compatible",
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 331/371 pwm: mtk-disp: Disable shadow registers before setting backlight values
In reply to Greg Kroah-HartmanFrom: AngeloGioacchino Del Regno <[email protected]>
[ Upstream commit 36dd7f530ae7d9ce9e853ffb8aa337de65c6600b ]
If shadow registers usage is not desired, disable that before performing any write to CON0/1 registers in the .apply() callback, otherwise we may lose clkdiv or period/width updates.
--- drivers/pwm/pwm-mtk-disp.c | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-)
drivers/pwm/pwm-mtk-disp.c +13 -11
@@ -138,6 +138,19 @@ static int mtk_disp_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm, high_width =mul_u64_u64_div_u64 (state->duty_cycle, rate, div); value = period | (high_width <<PWM_HIGH_WIDTH_SHIFT ); +if (mdp->data->bls_debug && !mdp->data->has_commit) { +/* +* For MT2701, disable double buffer before writing register +* and select manual mode and use PWM_PERIOD/PWM_HIGH_WIDTH. +*/ +mtk_disp_pwm_update_bits (mdp, mdp->data->bls_debug, + mdp->data->bls_debug_mask, + mdp->data->bls_debug_mask); +mtk_disp_pwm_update_bits (mdp, mdp->data->con0, + mdp->data->con0_sel, + mdp->data->con0_sel); + } +mtk_disp_pwm_update_bits (mdp, mdp->data->con0,PWM_CLKDIV_MASK , clk_div <<PWM_CLKDIV_SHIFT );
@@ -152,17 +165,6 @@ static int mtk_disp_pwm_apply(struct pwm_chip *chip, struct pwm_device *pwm,mtk_disp_pwm_update_bits (mdp, mdp->data->commit, mdp->data->commit_mask,0x0 ); - }else { -/* -* For MT2701, disable double buffer before writing register -* and select manual mode and use PWM_PERIOD/PWM_HIGH_WIDTH. -*/ -mtk_disp_pwm_update_bits (mdp, mdp->data->bls_debug, - mdp->data->bls_debug_mask, - mdp->data->bls_debug_mask); -mtk_disp_pwm_update_bits (mdp, mdp->data->con0, - mdp->data->con0_sel, - mdp->data->con0_sel); } mtk_disp_pwm_update_bits(mdp, DISP_PWM_EN, mdp->data->enable_mask,
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 332/371 pwm: mtk-disp: Configure double buffering before reading in .get_state()
In reply to Greg Kroah-HartmanFrom: AngeloGioacchino Del Regno <[email protected]>
[ Upstream commit b16c310115f2084b8826a35b77ef42bab6786d9f ]
The DISP_PWM controller's default behavior is to always use register double buffering: all reads/writes are then performed on shadow registers instead of working registers and this becomes an issue in case our chosen configuration in Linux is different from the default (or from the one that was pre-applied by the bootloader).
An example of broken behavior is when the controller is configured to use shadow registers, but this driver wants to configure it
otherwise: what happens is that the .get_state() callback is called right after registering the pwmchip and checks whether the PWM is enabled by reading the DISP_PWM_EN register;
At this point, if shadow registers are enabled but their content was not committed before booting Linux, we are *not* reading the current PWM enablement status, leading to the kernel knowing that the hardware is actually enabled when, in reality, it's not.
The aforementioned issue emerged since this driver was fixed with commit 0b5ef3429d8f ("pwm: mtk-disp: Fix the parameters calculated by the enabled flag of disp_pwm") making it to read the enablement status from the right register.
Configure the controller in the .get_state() callback to avoid this desync issue and get the backlight properly working again.
--- drivers/pwm/pwm-mtk-disp.c | 10 ++++++++++ 1 file changed, 10 insertions(+)
drivers/pwm/pwm-mtk-disp.c +10 -0
@@ -196,6 +196,16 @@ static void mtk_disp_pwm_get_state(struct pwm_chip *chip,return ; } +/* +* Apply DISP_PWM_DEBUG settings to choose whether to enable or disable +* registers double buffer and manual commit to working register before +* performing any read/write operation +*/ +if (mdp->data->bls_debug) +mtk_disp_pwm_update_bits (mdp, mdp->data->bls_debug, + mdp->data->bls_debug_mask, + mdp->data->bls_debug_mask); + rate =clk_get_rate (mdp->clk_main); con0 =readl (mdp->base + mdp->data->con0); con1 =readl (mdp->base + mdp->data->con1);
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 333/371 phy: tegra: xusb: Add missing tegra_xusb_port_unregister for usb2_port and ulpi_port
In reply to Greg Kroah-HartmanFrom: Gaosheng Cui <[email protected]>
[ Upstream commit e024854048e733391b31fe5a398704b31b9af803 ]
The tegra_xusb_port_unregister should be called when usb2_port and ulpi_port map fails in tegra_xusb_add_usb2_port() or in tegra_xusb_add_ulpi_port(), fix it.
--- drivers/phy/tegra/xusb.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/phy/tegra/xusb.c +2 -0
@@ -781,6 +781,7 @@ static int tegra_xusb_add_usb2_port(struct tegra_xusb_padctl *padctl, usb2->base.lane = usb2->base.ops->map (&usb2->base);if (IS_ERR (usb2->base.lane)) { err =PTR_ERR (usb2->base.lane); +tegra_xusb_port_unregister (&usb2->base); goto out; }
@@ -847,6 +848,7 @@ static int tegra_xusb_add_ulpi_port(struct tegra_xusb_padctl *padctl, ulpi->base.lane = ulpi->base.ops->map (&ulpi->base);if (IS_ERR (ulpi->base.lane)) { err =PTR_ERR (ulpi->base.lane); +tegra_xusb_port_unregister (&ulpi->base); goto out; }
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 334/371 dma: gpi: remove spurious unlock in gpi_ch_init
In reply to Greg Kroah-HartmanFrom: Dmitry Baryshkov <[email protected]>
[ Upstream commit 91d6a468e335571f1e67e046050dea9af5fa4ebe ]
gpi_ch_init() doesn't lock the ctrl_lock mutex, so there is no need to unlock it too. Instead the mutex is handled by the function gpi_alloc_chan_resources(), which properly locks and unlocks the mutex.
=====================================
WARNING: bad unlock balance detected! 6.3.0-rc5-00253-g99792582ded1-dirty #15 Not tainted
-------------------------------------
kworker/u16:0/9 is trying to release lock (&gpii->ctrl_lock) at:
[<ffffb99d04e1284c>] gpi_alloc_chan_resources+0x108/0x5bc but there are no more locks to release!
other info that might help us debug this:
6 locks held by kworker/u16:0/9:
#0: ffff575740010938 ((wq_completion)events_unbound){+.+.}-{0:0}, at: process_one_work+0x220/0x594 #1: ffff80000809bdd0 (deferred_probe_work){+.+.}-{0:0}, at: process_one_work+0x220/0x594 #2: ffff575740f2a0f8 (&dev->mutex){....}-{3:3}, at: __device_attach+0x38/0x188
#3: ffff57574b5570f8 (&dev->mutex){....}-{3:3}, at: __device_attach+0x38/0x188
#4: ffffb99d06a2f180 (of_dma_lock){+.+.}-{3:3}, at: of_dma_request_slave_channel+0x138/0x280 #5: ffffb99d06a2ee20 (dma_list_mutex){+.+.}-{3:3}, at: dma_get_slave_channel+0x28/0x10c
stack backtrace: CPU: 7 PID: 9 Comm: kworker/u16:0 Not tainted 6.3.0-rc5-00253-g99792582ded1-dirty #15 Hardware name: Google Pixel 3 (DT) Workqueue: events_unbound deferred_probe_work_func Call trace: dump_backtrace+0xa0/0xfc show_stack+0x18/0x24 dump_stack_lvl+0x60/0xac dump_stack+0x18/0x24 print_unlock_imbalance_bug+0x130/0x148 lock_release+0x270/0x300 __mutex_unlock_slowpath+0x48/0x2cc mutex_unlock+0x20/0x2c gpi_alloc_chan_resources+0x108/0x5bc dma_chan_get+0x84/0x188 dma_get_slave_channel+0x5c/0x10c gpi_of_dma_xlate+0x110/0x1a0 of_dma_request_slave_channel+0x174/0x280 dma_request_chan+0x3c/0x2d4 geni_i2c_probe+0x544/0x63c platform_probe+0x68/0xc4 really_probe+0x148/0x2ac __driver_probe_device+0x78/0xe0 driver_probe_device+0x3c/0x160 __device_attach_driver+0xb8/0x138 bus_for_each_drv+0x84/0xe0 __device_attach+0x9c/0x188 device_initial_probe+0x14/0x20 bus_probe_device+0xac/0xb0 device_add+0x60c/0x7d8 of_device_add+0x44/0x60 of_platform_device_create_pdata+0x90/0x124 of_platform_bus_create+0x15c/0x3c8 of_platform_populate+0x58/0xf8 devm_of_platform_populate+0x58/0xbc geni_se_probe+0xf0/0x164 platform_probe+0x68/0xc4 really_probe+0x148/0x2ac __driver_probe_device+0x78/0xe0 driver_probe_device+0x3c/0x160 __device_attach_driver+0xb8/0x138 bus_for_each_drv+0x84/0xe0 __device_attach+0x9c/0x188 device_initial_probe+0x14/0x20 bus_probe_device+0xac/0xb0 deferred_probe_work_func+0x8c/0xc8 process_one_work+0x2bc/0x594 worker_thread+0x228/0x438 kthread+0x108/0x10c ret_from_fork+0x10/0x20
--- drivers/dma/qcom/gpi.c | 1 - 1 file changed, 1 deletion(-)
drivers/dma/qcom/gpi.c +0 -1
@@ -1961,7 +1961,6 @@ static int gpi_ch_init(struct gchan *gchan) error_config_int:gpi_free_ring (&gpii->ev_ring, gpii); exit_gpi_init: -mutex_unlock (&gpii->ctrl_lock);return ret; }
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 335/371 dmaengine: dw-edma: Fix to change for continuous transfer
In reply to Greg Kroah-HartmanFrom: Shunsuke Mie <[email protected]>
[ Upstream commit a251994a441ee0a69ba7062c8cd2d08ead3db379 ]
The dw-edma driver stops after processing a DMA request even if a request remains in the issued queue, which is not the expected behavior. The DMA engine API requires continuous processing.
Add a trigger to start after one processing finished if there are requests remain.
--- drivers/dma/dw-edma/dw-edma-core.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-)
drivers/dma/dw-edma/dw-edma-core.c +11 -9
@@ -171,7 +171,7 @@ static void vchan_free_desc(struct virt_dma_desc *vdesc)dw_edma_free_desc (vd2dw_edma_desc (vdesc)); } -static void dw_edma_start_transfer (struct dw_edma_chan *chan) +static int dw_edma_start_transfer (struct dw_edma_chan *chan) {struct dw_edma_chunk *child;struct dw_edma_desc *desc;
@@ -179,16 +179,16 @@ static void dw_edma_start_transfer(struct dw_edma_chan *chan) vd =vchan_next_desc (&chan->vc);if (!vd) -return ; +return 0 ; desc =vd2dw_edma_desc (vd);if (!desc) -return ; +return 0 ; child =list_first_entry_or_null (&desc->chunk->list, struct dw_edma_chunk, list);if (!child) -return ; +return 0 ;dw_edma_v0_core_start (child, !desc->xfer_sz); desc->xfer_sz += child->ll_region.sz;
@@ -196,6 +196,8 @@ static void dw_edma_start_transfer(struct dw_edma_chan *chan)list_del (&child->list);kfree (child); desc->chunks_alloc--; + +return 1 ; } static int dw_edma_device_config(struct dma_chan *dchan,
@@ -555,14 +557,14 @@ static void dw_edma_done_interrupt(struct dw_edma_chan *chan)switch (chan->request) {case EDMA_REQ_NONE : desc =vd2dw_edma_desc (vd); -if (desc->chunks_alloc) { - chan->status =EDMA_ST_BUSY ; -dw_edma_start_transfer (chan); - }else { +if (!desc->chunks_alloc) {list_del (&vd->node);vchan_cookie_complete (vd); - chan->status =EDMA_ST_IDLE ; } + +/* Continue transferring if there are remaining chunks or issued requests. +*/ + chan->status =dw_edma_start_transfer (chan) ?EDMA_ST_BUSY :EDMA_ST_IDLE ;break ;case EDMA_REQ_STOP :
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 336/371 dmaengine: dw-edma: Fix to enable to issue dma request on DMA processing
In reply to Greg Kroah-HartmanFrom: Shunsuke Mie <[email protected]>
[ Upstream commit 970b17dfe264a9085ba4e593730ecfd496b950ab ]
The issue_pending request is ignored while driver is processing a DMA request. Fix to issue the pending requests on any dma channel status.
--- drivers/dma/dw-edma/dw-edma-core.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
drivers/dma/dw-edma/dw-edma-core.c +5 -2
@@ -281,9 +281,12 @@ static void dw_edma_device_issue_pending(struct dma_chan *dchan)struct dw_edma_chan *chan =dchan2dw_edma_chan (dchan);unsigned long flags; +if (!chan->configured) +return ; +spin_lock_irqsave (&chan->vc.lock, flags); -if (chan->configured && chan->request ==EDMA_REQ_NONE && - chan->status ==EDMA_ST_IDLE &&vchan_issue_pending (&chan->vc)) { +if (vchan_issue_pending (&chan->vc) && chan->request ==EDMA_REQ_NONE && + chan->status ==EDMA_ST_IDLE ) { chan->status =EDMA_ST_BUSY ;dw_edma_start_transfer (chan); }
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 337/371 dmaengine: at_xdmac: Fix concurrency over chans completed_cookie
In reply to Greg Kroah-HartmanFrom: Tudor Ambarus <[email protected]>
[ Upstream commit 506875c30fc5bf92246060bc3b4c38799646266b ]
Caller of dma_cookie_complete is expected to hold a lock to prevent concurrency over the channel's completed cookie marker. Call dma_cookie_complete() with the lock held.
--- drivers/dma/at_xdmac.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/dma/at_xdmac.c +1 -2
@@ -1710,11 +1710,10 @@ static void at_xdmac_tasklet(struct tasklet_struct *t) } txd = &desc->tx_dma_desc; - +dma_cookie_complete (txd);at_xdmac_remove_xfer (atchan, desc);spin_unlock_irq (&atchan->lock); -dma_cookie_complete (txd);if (txd->flags &DMA_PREP_INTERRUPT )dmaengine_desc_get_callback_invoke (txd,NULL );
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 338/371 dmaengine: at_xdmac: Fix race for the tx desc callback
In reply to Greg Kroah-HartmanFrom: Tudor Ambarus <[email protected]>
[ Upstream commit b63e5cb94ad6947ab5fe38b5a9417dcfd0bc6122 ]
The transfer descriptors were wrongly moved to the free descriptors list before calling the tx desc callback. As the DMA engine drivers drop any locks before calling the callback function, txd could be taken again, resulting in its callback called prematurely. Fix the race for the tx desc callback by moving the xfer desc into the free desc list after the callback is invoked.
--- drivers/dma/at_xdmac.c | 25 ++++++++----------------- 1 file changed, 8 insertions(+), 17 deletions(-)
drivers/dma/at_xdmac.c +8 -17
@@ -1586,20 +1586,6 @@ at_xdmac_tx_status(struct dma_chan *chan, dma_cookie_t cookie,return ret; } -/* Call must be protected by lock. */ -static void at_xdmac_remove_xfer (struct at_xdmac_chan *atchan, -struct at_xdmac_desc *desc) -{ -dev_dbg (chan2dev (&atchan->chan),"%s: desc 0x%p\n" , __func__, desc); - -/* -* Remove the transfer from the transfer list then move the transfer -* descriptors into the free descriptors list. -*/ -list_del (&desc->xfer_node); -list_splice_init (&desc->descs_list, &atchan->free_descs_list); -} -static void at_xdmac_advance_work (struct at_xdmac_chan *atchan) {struct at_xdmac_desc *desc;
@@ -1711,7 +1697,8 @@ static void at_xdmac_tasklet(struct tasklet_struct *t) txd = &desc->tx_dma_desc;dma_cookie_complete (txd); -at_xdmac_remove_xfer (atchan, desc); +/* Remove the transfer from the transfer list. */ +list_del (&desc->xfer_node);spin_unlock_irq (&atchan->lock);if (txd->flags &DMA_PREP_INTERRUPT )
@@ -1720,6 +1707,8 @@ static void at_xdmac_tasklet(struct tasklet_struct *t)dma_run_dependencies (txd);spin_lock_irq (&atchan->lock); +/* Move the xfer descriptors into the free descriptors list. */ +list_splice_init (&desc->descs_list, &atchan->free_descs_list);at_xdmac_advance_work (atchan);spin_unlock_irq (&atchan->lock); }
@@ -1866,8 +1855,10 @@ static int at_xdmac_device_terminate_all(struct dma_chan *chan)cpu_relax ();/* Cancel all pending transfers. */ -list_for_each_entry_safe (desc, _desc, &atchan->xfers_list, xfer_node) -at_xdmac_remove_xfer (atchan, desc); +list_for_each_entry_safe (desc, _desc, &atchan->xfers_list, xfer_node) { +list_del (&desc->xfer_node); +list_splice_init (&desc->descs_list, &atchan->free_descs_list); + }clear_bit (AT_XDMAC_CHAN_IS_PAUSED , &atchan->status);clear_bit (AT_XDMAC_CHAN_IS_CYCLIC , &atchan->status);
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 339/371 dmaengine: at_xdmac: do not enable all cyclic channels
In reply to Greg Kroah-HartmanFrom: Claudiu Beznea <[email protected]>
[ Upstream commit f8435befd81dd85b7b610598551fadf675849bc1 ]
Do not global enable all the cyclic channels in at_xdmac_resume(). Instead save the global status in at_xdmac_suspend() and re-enable the cyclic channel only if it was active before suspend.
--- drivers/dma/at_xdmac.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/dma/at_xdmac.c +4 -1
@@ -243,6 +243,7 @@ struct at_xdmac {int irq;struct clk *clk;u32 save_gim; +u32 save_gs;struct dma_pool *at_xdmac_desc_pool;const struct at_xdmac_layout *layout;struct at_xdmac_chan chan[];
@@ -1984,6 +1985,7 @@ static int atmel_xdmac_suspend(struct device *dev) } } atxdmac->save_gim =at_xdmac_read (atxdmac,AT_XDMAC_GIM ); + atxdmac->save_gs =at_xdmac_read (atxdmac,AT_XDMAC_GS );at_xdmac_off (atxdmac);clk_disable_unprepare (atxdmac->clk);
@@ -2023,7 +2025,8 @@ static int atmel_xdmac_resume(struct device *dev)at_xdmac_chan_write (atchan,AT_XDMAC_CNDC , atchan->save_cndc);at_xdmac_chan_write (atchan,AT_XDMAC_CIE , atchan->save_cim);wmb (); -at_xdmac_write (atxdmac,AT_XDMAC_GE , atchan->mask); +if (atxdmac->save_gs & atchan->mask) +at_xdmac_write (atxdmac,AT_XDMAC_GE , atchan->mask); } }return 0 ;
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 340/371 thermal/drivers/mediatek: Use devm_of_iomap to avoid resource leak in mtk_thermal_probe
In reply to Greg Kroah-HartmanFrom: Kang Chen <[email protected]>
[ Upstream commit f05c7b7d9ea9477fcc388476c6f4ade8c66d2d26 ]
Smatch reports:
1. mtk_thermal_probe() warn: 'apmixed_base' from of_iomap() not released.
2. mtk_thermal_probe() warn: 'auxadc_base' from of_iomap() not released.
The original code forgets to release iomap resource when handling errors, fix it by switch to devm_of_iomap.
--- drivers/thermal/mtk_thermal.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-)
drivers/thermal/mtk_thermal.c +12 -2
@@ -1028,7 +1028,12 @@ static int mtk_thermal_probe(struct platform_device *pdev)return -ENODEV ; } - auxadc_base =of_iomap (auxadc,0 ); + auxadc_base =devm_of_iomap (&pdev->dev, auxadc,0 ,NULL ); +if (IS_ERR (auxadc_base)) { +of_node_put (auxadc); +return PTR_ERR (auxadc_base); + } + auxadc_phys_base =of_get_phys_base (auxadc);of_node_put (auxadc);
@@ -1044,7 +1049,12 @@ static int mtk_thermal_probe(struct platform_device *pdev)return -ENODEV ; } - apmixed_base =of_iomap (apmixedsys,0 ); + apmixed_base =devm_of_iomap (&pdev->dev, apmixedsys,0 ,NULL ); +if (IS_ERR (apmixed_base)) { +of_node_put (apmixedsys); +return PTR_ERR (apmixed_base); + } + apmixed_phys_base =of_get_phys_base (apmixedsys);of_node_put (apmixedsys);
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 341/371 mfd: tqmx86: Do not access I2C_DETECT register through io_base
In reply to Greg Kroah-HartmanFrom: Matthias Schiffer <[email protected]>
[ Upstream commit 1be1b23696b3d4b0231c694f5e0767b4471d33a9 ]
The I2C_DETECT register is at IO port 0x1a7, which is outside the range passed to devm_ioport_map() for io_base, and was only working because there aren't actually any bounds checks for IO port accesses.
Extending the range does not seem like a good solution here, as it would then conflict with the IO resource assigned to the I2C controller. As this is just a one-off access during probe, use a simple inb() instead.
While we're at it, drop the unused define TQMX86_REG_I2C_INT_EN.
--- drivers/mfd/tqmx86.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
drivers/mfd/tqmx86.c +7 -3
@@ -49,9 +49,8 @@#define TQMX86_REG_IO_EXT_INT_MASK 0x3#define TQMX86_REG_IO_EXT_INT_GPIO_SHIFT 4 -#define TQMX86_REG_I2C_DETECT 0x47 +#define TQMX86_REG_I2C_DETECT 0x1a7#define TQMX86_REG_I2C_DETECT_SOFT 0xa5 -#define TQMX86_REG_I2C_INT_EN 0x49static uint gpio_irq;module_param (gpio_irq, uint,0 );
@@ -213,7 +212,12 @@ static int tqmx86_probe(struct platform_device *pdev)"Found %s - Board ID %d, PCB Revision %d, PLD Revision %d\n" , board_name, board_id, rev >> 4, rev & 0xf); - i2c_det =ioread8 (io_base +TQMX86_REG_I2C_DETECT ); +/* +* The I2C_DETECT register is in the range assigned to the I2C driver +* later, so we don't extend TQMX86_IOSIZE. Use inb() for this one-off +* access instead of ioport_map + unmap. +*/ + i2c_det =inb (TQMX86_REG_I2C_DETECT );if (gpio_irq_cfg) { io_ext_int_val =
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 342/371 mfd: tqmx86: Specify IO port register range more precisely
In reply to Greg Kroah-HartmanFrom: Matthias Schiffer <[email protected]>
[ Upstream commit 051c69ff4f607aa114c7bbdd7c41ed881367aeee ]
Registers 0x160..0x17f are unassigned. Use 0x180 as base register and update offets accordingly.
Also change the size of the range to include 0x19f. While 0x19f is currently reserved for future extensions, so are several of the previous registers up to 0x19e, and it is weird to leave out just the last one.
--- drivers/mfd/tqmx86.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/mfd/tqmx86.c +5 -5
@@ -16,8 +16,8 @@#include <linux/platform_data/i2c-ocores.h> #include <linux/platform_device.h> -#define TQMX86_IOBASE 0x160 -#define TQMX86_IOSIZE 0x3f +#define TQMX86_IOBASE 0x180 +#define TQMX86_IOSIZE 0x20#define TQMX86_IOBASE_I2C 0x1a0#define TQMX86_IOSIZE_I2C 0xa#define TQMX86_IOBASE_WATCHDOG 0x18b
@@ -25,7 +25,7 @@#define TQMX86_IOBASE_GPIO 0x18d#define TQMX86_IOSIZE_GPIO 0x4 -#define TQMX86_REG_BOARD_ID 0x20 +#define TQMX86_REG_BOARD_ID 0x00#define TQMX86_REG_BOARD_ID_E38M 1#define TQMX86_REG_BOARD_ID_50UC 2#define TQMX86_REG_BOARD_ID_E38C 3
@@ -40,8 +40,8 @@#define TQMX86_REG_BOARD_ID_E40S 13#define TQMX86_REG_BOARD_ID_E40C1 14#define TQMX86_REG_BOARD_ID_E40C2 15 -#define TQMX86_REG_BOARD_REV 0x21 -#define TQMX86_REG_IO_EXT_INT 0x26 +#define TQMX86_REG_BOARD_REV 0x01 +#define TQMX86_REG_IO_EXT_INT 0x06#define TQMX86_REG_IO_EXT_INT_NONE 0#define TQMX86_REG_IO_EXT_INT_7 1#define TQMX86_REG_IO_EXT_INT_9 2
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 343/371 mfd: tqmx86: Correct board names for TQMxE39x
In reply to Greg Kroah-HartmanFrom: Matthias Schiffer <[email protected]>
[ Upstream commit f376c479668557bcc2fd9e9fbc0f53e7819a11cd ]
It seems that this driver was developed based on preliminary documentation. Report the correct names for all TQMxE39x variants, as they are used by the released hardware revisions:
- Fix names for TQMxE39C1/C2 board IDs
- Distinguish TQMxE39M and TQMxE39S, which use the same board ID
The TQMxE39M/S are distinguished using the SAUC (Sanctioned Alternate Uses Configuration) register of the GPIO controller. This also prepares for the correct handling of the differences between the GPIO controllers of our COMe and SMARC modules.
--- drivers/mfd/tqmx86.c | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-)
drivers/mfd/tqmx86.c +17 -15
@@ -30,9 +30,9 @@#define TQMX86_REG_BOARD_ID_50UC 2#define TQMX86_REG_BOARD_ID_E38C 3#define TQMX86_REG_BOARD_ID_60EB 4 -#define TQMX86_REG_BOARD_ID_E39M 5 -#define TQMX86_REG_BOARD_ID_E39C 6 -#define TQMX86_REG_BOARD_ID_E39x 7 +#define TQMX86_REG_BOARD_ID_E39MS 5 +#define TQMX86_REG_BOARD_ID_E39C1 6 +#define TQMX86_REG_BOARD_ID_E39C2 7#define TQMX86_REG_BOARD_ID_70EB 8#define TQMX86_REG_BOARD_ID_80UC 9#define TQMX86_REG_BOARD_ID_110EB 11
@@ -48,6 +48,7 @@#define TQMX86_REG_IO_EXT_INT_12 3#define TQMX86_REG_IO_EXT_INT_MASK 0x3#define TQMX86_REG_IO_EXT_INT_GPIO_SHIFT 4 +#define TQMX86_REG_SAUC 0x17#define TQMX86_REG_I2C_DETECT 0x1a7#define TQMX86_REG_I2C_DETECT_SOFT 0xa5
@@ -110,7 +111,7 @@ static const struct mfd_cell tqmx86_devs[] = { }, }; -static const char *tqmx86_board_id_to_name (u8 board_id) +static const char *tqmx86_board_id_to_name (u8 board_id,u8 sauc) {switch (board_id) {case TQMX86_REG_BOARD_ID_E38M :
@@ -121,12 +122,12 @@ static const char *tqmx86_board_id_to_name(u8 board_id)return "TQMxE38C" ;case TQMX86_REG_BOARD_ID_60EB :return "TQMx60EB" ; -case TQMX86_REG_BOARD_ID_E39M : -return "TQMxE39M" ; -case TQMX86_REG_BOARD_ID_E39C : -return "TQMxE39C" ; -case TQMX86_REG_BOARD_ID_E39x: -return "TQMxE39x" ; +case TQMX86_REG_BOARD_ID_E39MS : +return (sauc ==0xff ) ?"TQMxE39M" :"TQMxE39S" ; +case TQMX86_REG_BOARD_ID_E39C1 : +return "TQMxE39C1" ; +case TQMX86_REG_BOARD_ID_E39C2 : +return "TQMxE39C2" ;case TQMX86_REG_BOARD_ID_70EB :return "TQMx70EB" ;case TQMX86_REG_BOARD_ID_80UC :
@@ -159,9 +160,9 @@ static int tqmx86_board_id_to_clk_rate(struct device *dev, u8 board_id)case TQMX86_REG_BOARD_ID_E40C1 :case TQMX86_REG_BOARD_ID_E40C2 :return 24000 ; -case TQMX86_REG_BOARD_ID_E39M : -case TQMX86_REG_BOARD_ID_E39C : -case TQMX86_REG_BOARD_ID_E39x: +case TQMX86_REG_BOARD_ID_E39MS : +case TQMX86_REG_BOARD_ID_E39C1 : +case TQMX86_REG_BOARD_ID_E39C2 :return 25000 ;case TQMX86_REG_BOARD_ID_E38M :case TQMX86_REG_BOARD_ID_E38C :
@@ -175,7 +176,7 @@ static int tqmx86_board_id_to_clk_rate(struct device *dev, u8 board_id)static int tqmx86_probe (struct platform_device *pdev) { -u8 board_id, rev, i2c_det, io_ext_int_val; +u8 board_id, sauc, rev, i2c_det, io_ext_int_val;struct device *dev = &pdev->dev;u8 gpio_irq_cfg, readback;const char *board_name;
@@ -205,7 +206,8 @@ static int tqmx86_probe(struct platform_device *pdev)return -ENOMEM ; board_id =ioread8 (io_base +TQMX86_REG_BOARD_ID ); - board_name =tqmx86_board_id_to_name (board_id); + sauc =ioread8 (io_base +TQMX86_REG_SAUC ); + board_name =tqmx86_board_id_to_name (board_id, sauc); rev =ioread8 (io_base +TQMX86_REG_BOARD_REV ); dev_info(dev,
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 344/371 afs: Fix updating of i_size with dv jump from server
In reply to Greg Kroah-HartmanFrom: Marc Dionne <[email protected]>
[ Upstream commit d7f74e9a917503ee78f2b603a456d7227cf38919 ]
If the data version returned from the server is larger than expected, the local data is invalidated, but we may still want to note the remote file size.
Since we're setting change_size, we have to also set data_changed for the i_size to get updated.
--- fs/afs/inode.c | 1 + 1 file changed, 1 insertion(+)
fs/afs/inode.c +1 -0
@@ -219,6 +219,7 @@ static void afs_apply_status(struct afs_operation *op,set_bit (AFS_VNODE_ZAP_DATA , &vnode->flags); } change_size = true; + data_changed = true; }else if (vnode->status.type ==AFS_FTYPE_DIR ) {/* Expected directory change is handled elsewhere so * that we can locally edit the directory and save on a
Signature · 1 line
2.39.2
Greg Kroah-Hartman
maintainerPATCH 345/371 parisc: Fix argument pointer in real64_call_asm()
In reply to Greg Kroah-HartmanFrom: Helge Deller <[email protected]>
commit 6e3220ba3323a2c24be834aebf5d6e9f89d0993f upstream.
Fix the argument pointer (ap) to point to real-mode memory instead of virtual memory.
It's interesting that this issue hasn't shown up earlier, as this could have happened with any 64-bit PDC ROM code.
I just noticed it because I suddenly faced a HPMC while trying to execute the 64-bit STI ROM code of an Visualize-FXe graphics card for the STI text console.
--- arch/parisc/kernel/real2.S | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
arch/parisc/kernel/real2.S +2 -3
@@ -248,9 +248,6 @@ ENTRY_CFI(real64_call_asm) /* save fn */ copy %arg2, %r31 - /* set up the new ap */ - ldo 64(%arg1), %r29 - /* load up the arg registers from the saved arg area */ /* 32-bit calling convention passes first 4 args in registers */ ldd 0*REG_SZ(%arg1), %arg0 /* note overwriting arg0 */
@@ -262,7 +259,9 @@ ENTRY_CFI(real64_call_asm) ldd 7*REG_SZ(%arg1), %r19 ldd 1*REG_SZ(%arg1), %arg1 /* do this one last! */ + /* set up real-mode stack and real-mode ap */ tophys_r1 %sp + ldo -16(%sp), %r29 /* Reference param save area */ b,l rfi_virt2real,%r2 nop
Greg Kroah-Hartman
maintainerPATCH 346/371 ALSA: usb-audio: Add quirk for Pioneer DDJ-800
In reply to Greg Kroah-HartmanFrom: Geraldo Nascimento <[email protected]>
commit 7501f472977df233d039d86c6981e0641708e1ca upstream.
One more Pioneer quirk, this time for DDJ-800, which is quite similar like other DJ DDJ models but with slightly different EPs or channels.
--- sound/usb/quirks-table.h | 58 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+)
sound/usb/quirks-table.h +58 -0
@@ -3808,6 +3808,64 @@ YAMAHA_DEVICE(0x7010, "UB99"), } }, +{ +/* +* PIONEER DJ DDJ-800 +* PCM is 6 channels out, 6 channels in @ 44.1 fixed +* The Feedback for the output is the input +*/ + USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0029), + .driver_info = (unsigned long ) &(const struct snd_usb_audio_quirk ) { + .ifnum =QUIRK_ANY_INTERFACE , + .type =QUIRK_COMPOSITE , + .data = (const struct snd_usb_audio_quirk []) { + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =6 , + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .endpoint =0x01 , + .ep_attr =USB_ENDPOINT_XFER_ISOC | +USB_ENDPOINT_SYNC_ASYNC , + .rates =SNDRV_PCM_RATE_44100 , + .rate_min =44100 , + .rate_max =44100 , + .nr_rates =1 , + .rate_table = (unsigned int []) {44100 } + } + }, + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =6 , + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .endpoint =0x82 , + .ep_idx =1 , + .ep_attr =USB_ENDPOINT_XFER_ISOC | +USB_ENDPOINT_SYNC_ASYNC | +USB_ENDPOINT_USAGE_IMPLICIT_FB , + .rates =SNDRV_PCM_RATE_44100 , + .rate_min =44100 , + .rate_max =44100 , + .nr_rates =1 , + .rate_table = (unsigned int []) {44100 } + } + }, + { + .ifnum =-1 + } + } + } +}, +/* * MacroSilicon MS2100/MS2106 based AV capture cards *
Greg Kroah-Hartman
maintainerPATCH 347/371 nilfs2: do not write dirty data after degenerating to read-only
In reply to Greg Kroah-HartmanFrom: Ryusuke Konishi <[email protected]>
commit 28a65b49eb53e172d23567005465019658bfdb4d upstream.
According to syzbot's report, mark_buffer_dirty() called from nilfs_segctor_do_construct() outputs a warning with some patterns after nilfs2 detects metadata corruption and degrades to read-only mode.
After such read-only degeneration, page cache data may be cleared through nilfs_clear_dirty_page() which may also clear the uptodate flag for their buffer heads. However, even after the degeneration, log writes are still performed by unmount processing etc., which causes mark_buffer_dirty() to be called for buffer heads without the "uptodate" flag and causes the warning.
Since any writes should not be done to a read-only file system in the first place, this fixes the warning in mark_buffer_dirty() by letting nilfs_segctor_do_construct() abort early if in read-only mode.
This also changes the retry check of nilfs_segctor_write_out() to avoid unnecessary log write retries if it detects -EROFS that nilfs_segctor_do_construct() returned.
--- fs/nilfs2/segment.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
fs/nilfs2/segment.c +4 -1
@@ -2039,6 +2039,9 @@ static int nilfs_segctor_do_construct(ststruct the_nilfs *nilfs = sci->sc_super->s_fs_info;int err; +if (sb_rdonly (sci->sc_super)) +return -EROFS ; +nilfs_sc_cstage_set (sci,NILFS_ST_INIT ); sci->sc_cno = nilfs->ns_cno;
@@ -2724,7 +2727,7 @@ static void nilfs_segctor_write_out(struflush_work (&sci->sc_iput_work); - }while (ret && retrycount-- >0 ); + }while (ret && ret != -EROFS && retrycount-- >0 ); }/**
Greg Kroah-Hartman
maintainerPATCH 348/371 nilfs2: fix infinite loop in nilfs_mdt_get_block()
In reply to Greg Kroah-HartmanFrom: Ryusuke Konishi <[email protected]>
commit a6a491c048882e7e424d407d32cba0b52d9ef2bf upstream.
If the disk image that nilfs2 mounts is corrupted and a virtual block address obtained by block lookup for a metadata file is invalid, nilfs_bmap_lookup_at_level() may return the same internal return code as -ENOENT, meaning the block does not exist in the metadata file.
This duplication of return codes confuses nilfs_mdt_get_block(), causing it to read and create a metadata block indefinitely.
In particular, if this happens to the inode metadata file, ifile, semaphore i_rwsem can be left held, causing task hangs in lock_mount.
Fix this issue by making nilfs_bmap_lookup_at_level() treat virtual block address translation failures with -ENOENT as metadata corruption instead of returning the error code.
--- fs/nilfs2/bmap.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
fs/nilfs2/bmap.c +12 -4
@@ -67,20 +67,28 @@ int nilfs_bmap_lookup_at_level(struct nidown_read (&bmap->b_sem); ret = bmap->b_ops->bop_lookup (bmap, key, level, ptrp); -if (ret <0 ) { - ret =nilfs_bmap_convert_error (bmap, __func__, ret); +if (ret <0 ) goto out; - } +if (NILFS_BMAP_USE_VBN (bmap)) { ret =nilfs_dat_translate (nilfs_bmap_get_dat (bmap), *ptrp, &blocknr);if (!ret) *ptrp = blocknr; +else if (ret == -ENOENT ) { +/* +* If there was no valid entry in DAT for the block +* address obtained by b_ops->bop_lookup, then pass +* internal code -EINVAL to nilfs_bmap_convert_error +* to treat it as metadata corruption. +*/ + ret = -EINVAL ; + } } out:up_read (&bmap->b_sem); -return ret; +return nilfs_bmap_convert_error (bmap, __func__, ret); } int nilfs_bmap_lookup_contig(struct nilfs_bmap *bmap, __u64 key, __u64 *ptrp,
Greg Kroah-Hartman
maintainerPATCH 349/371 md/raid10: fix null-ptr-deref in raid10_sync_request
In reply to Greg Kroah-HartmanFrom: Li Nan <[email protected]>
commit a405c6f0229526160aa3f177f65e20c86fce84c5 upstream.
init_resync() inits mempool and sets conf->have_replacemnt at the beginning of sync, close_sync() frees the mempool when sync is completed.
After [1] recovery might be skipped and init_resync() is called but close_sync() is not. null-ptr-deref occurs with r10bio->dev[i].repl_bio.
The following is one way to reproduce the issue.
1) create a array, wait for resync to complete, mddev->recovery_cp is set to MaxSector.
2) recovery is woken and it is skipped. conf->have_replacement is set to 0 in init_resync(). close_sync() not called.
3) some io errors and rdev A is set to WantReplacement.
4) a new device is added and set to A's replacement.
5) recovery is woken, A have replacement, but conf->have_replacemnt is
0. r10bio->dev[i].repl_bio will not be alloced and null-ptr-deref occurs.
Fix it by not calling init_resync() if recovery skipped.
[1] commit 7e83ccbecd60 ("md/raid10: Allow skipping recovery when clean arrays are assembled")
--- drivers/md/raid10.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/md/raid10.c +4 -4
@@ -3278,10 +3278,6 @@ static sector_t raid10_sync_request(strusector_t chunk_mask = conf->geo.chunk_mask;int page_idx =0 ; -if (!mempool_initialized (&conf->r10buf_pool)) -if (init_resync (conf)) -return 0 ; -/* * Allow skipping a full rebuild for incremental assembly * of a clean array, like RAID1 does.
@@ -3297,6 +3293,10 @@ static sector_t raid10_sync_request(strureturn mddev->dev_sectors - sector_nr; } +if (!mempool_initialized (&conf->r10buf_pool)) +if (init_resync (conf)) +return 0 ; + skipped: max_sector = mddev->dev_sectors; if (test_bit(MD_RECOVERY_SYNC, &mddev->recovery) ||
Greg Kroah-Hartman
maintainerPATCH 350/371 mtd: core: provide unique name for nvmem device, take two
In reply to Greg Kroah-HartmanFrom: Michael Walle <[email protected]>
commit 1cd9ceaa5282ff10ea20a7fbadde5a476a1cc99e upstream.
Commit c048b60d39e1 ("mtd: core: provide unique name for nvmem device") tries to give the nvmem device a unique name, but fails badly if the mtd device doesn't have a "struct device" associated with it, i.e. if CONFIG_MTD_PARTITIONED_MASTER is not set. This will result in the name "(null)-user-otp", which is not unique. It seems the best we can do is to use the compatible name together with a unique identifier added by the nvmem subsystem by using NVMEM_DEVID_AUTO.
--- drivers/mtd/mtdcore.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/mtd/mtdcore.c +2 -3
@@ -828,8 +828,8 @@ static struct nvmem_device *mtd_otp_nvme/* OTP nvmem will be registered on the physical device */ config.dev = mtd->dev.parent; - config.name =kasprintf (GFP_KERNEL ,"%s-%s" ,dev_name (&mtd->dev), compatible); - config.id =NVMEM_DEVID_NONE ; + config.name = compatible; + config.id =NVMEM_DEVID_AUTO ; config.owner =THIS_MODULE ; config.type =NVMEM_TYPE_OTP ; config.root_only = true;
@@ -845,7 +845,6 @@ static struct nvmem_device *mtd_otp_nvme nvmem =NULL ;of_node_put (np); -kfree (config.name);return nvmem; }
Greg Kroah-Hartman
maintainerPATCH 351/371 mtd: core: fix nvmem error reporting
In reply to Greg Kroah-HartmanFrom: Michael Walle <[email protected]>
commit 8bd1d24e6ca3c599dd455b0e1b22f77bab8290eb upstream.
The master MTD will only have an associated device if CONFIG_MTD_PARTITIONED_MASTER is set, thus we cannot use dev_err() on mtd->dev. Instead use the parent device which is the physical flash memory.
--- drivers/mtd/mtdcore.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/mtd/mtdcore.c +3 -2
@@ -879,6 +879,7 @@ static int mtd_nvmem_fact_otp_reg_read(vstatic int mtd_otp_nvmem_add (struct mtd_info *mtd) { +struct device *dev = mtd->dev.parent;struct nvmem_device *nvmem;ssize_t size;int err;
@@ -892,7 +893,7 @@ static int mtd_otp_nvmem_add(struct mtd_ nvmem =mtd_otp_nvmem_register (mtd,"user-otp" , size, mtd_nvmem_user_otp_reg_read);if (IS_ERR (nvmem)) { -dev_err (&mtd->dev,"Failed to register OTP NVMEM device\n" ); +dev_err (dev,"Failed to register OTP NVMEM device\n" );return PTR_ERR (nvmem); } mtd->otp_user_nvmem = nvmem;
@@ -910,7 +911,7 @@ static int mtd_otp_nvmem_add(struct mtd_ nvmem =mtd_otp_nvmem_register (mtd,"factory-otp" , size, mtd_nvmem_fact_otp_reg_read);if (IS_ERR (nvmem)) { -dev_err (&mtd->dev,"Failed to register OTP NVMEM device\n" ); +dev_err (dev,"Failed to register OTP NVMEM device\n" ); err =PTR_ERR (nvmem); goto err; }
Greg Kroah-Hartman
maintainerPATCH 352/371 mtd: core: fix error path for nvmem provider
In reply to Greg Kroah-HartmanFrom: Michael Walle <[email protected]>
commit e0489f6e221f5ddee6cb3bd51b992b790c5fa4b9 upstream.
If mtd_otp_nvmem_add() fails, the partitions won't be removed because there is simply no call to del_mtd_partitions(). Unfortunately, add_mtd_partitions() will print all partitions to the kernel console. If mtd_otp_nvmem_add() returns -EPROBE_DEFER this would print the partitions multiple times to the kernel console. Instead move mtd_otp_nvmem_add() to the beginning of the function.
--- drivers/mtd/mtdcore.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-)
drivers/mtd/mtdcore.c +10 -3
@@ -964,10 +964,14 @@ int mtd_device_parse_register(struct mtdmtd_set_dev_defaults (mtd); + ret =mtd_otp_nvmem_add (mtd); +if (ret) + goto out; +if (IS_ENABLED (CONFIG_MTD_PARTITIONED_MASTER )) { ret =add_mtd_device (mtd);if (ret) -return ret; + goto out; }/* Prefer parsed partitions over driver-provided fallback */
@@ -1002,9 +1006,12 @@ int mtd_device_parse_register(struct mtdregister_reboot_notifier (&mtd->reboot_notifier); } - ret =mtd_otp_nvmem_add (mtd); - out: +if (ret) { +nvmem_unregister (mtd->otp_user_nvmem); +nvmem_unregister (mtd->otp_factory_nvmem); + } +if (ret &&device_is_registered (&mtd->dev))del_mtd_device (mtd);
Greg Kroah-Hartman
maintainerPATCH 353/371 mailbox: zynqmp: Fix IPI isr handling
In reply to Greg Kroah-HartmanFrom: Tanmay Shah <[email protected]>
commit 74ad37a30ffee3643bc34f9ca7225b20a66abaaf upstream.
Multiple IPI channels are mapped to same interrupt handler. Current isr implementation handles only one channel per isr. Fix this behavior by checking isr status bit of all child mailbox nodes.
--- drivers/mailbox/zynqmp-ipi-mailbox.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/mailbox/zynqmp-ipi-mailbox.c +3 -3
@@ -152,7 +152,7 @@ static irqreturn_t zynqmp_ipi_interrupt(struct zynqmp_ipi_message *msg;u64 arg0, arg3;struct arm_smccc_res res; -int ret, i; +int ret, i, status =IRQ_NONE ; (void )irq; arg0 =SMC_IPI_MAILBOX_STATUS_ENQUIRY ;
@@ -170,11 +170,11 @@ static irqreturn_t zynqmp_ipi_interrupt(memcpy_fromio (msg->data, mchan->req_buf, msg->len);mbox_chan_received_data (chan, (void *)msg); -return IRQ_HANDLED ; + status =IRQ_HANDLED ; } } } -return IRQ_NONE ; +return status; }/**
Greg Kroah-Hartman
maintainerPATCH 354/371 mailbox: zynqmp: Fix typo in IPI documentation
In reply to Greg Kroah-HartmanFrom: Tanmay Shah <[email protected]>
commit 79963fbfc233759bd8a43462f120d15a1bd4f4fa upstream.
Xilinx IPI message buffers allows 32-byte data transfer. Fix documentation that says 12 bytes
--- include/linux/mailbox/zynqmp-ipi-message.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/mailbox/zynqmp-ipi-message.h +1 -1
@@ -9,7 +9,7 @@* @data: message payload * * This is the structure for data used in mbox_send_message -* the maximum length of data buffer is fixed to 12 bytes. +* the maximum length of data buffer is fixed to 32 bytes. * Client is supposed to be aware of this. */ struct zynqmp_ipi_message {
Greg Kroah-Hartman
maintainerPATCH 355/371 wifi: rtl8xxxu: RTL8192EU always needs full init
In reply to Greg Kroah-HartmanFrom: Bitterblue Smith <[email protected]>
commit d46e04ccd40457a0119b76e11ab64a2ad403e138 upstream.
Always run the entire init sequence (rtl8xxxu_init_device()) for RTL8192EU. It's what the vendor driver does too.
This fixes a bug where the device is unable to connect after rebooting:
wlp3s0f3u2: send auth to ... (try 1/3)
wlp3s0f3u2: send auth to ... (try 2/3)
wlp3s0f3u2: send auth to ... (try 3/3)
wlp3s0f3u2: authentication with ... timed out
Rebooting leaves the device powered on (partially? at least the firmware is still running), but not really in a working state.
--- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192e.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_8192e.c +1 -0
@@ -1700,6 +1700,7 @@ struct rtl8xxxu_fileops rtl8192eu_fops = .rx_desc_size = sizeof(struct rtl8xxxu_rxdesc24), .has_s0s1 = 0, .gen2_thermal_meter = 1, + .needs_full_init = 1, .adda_1t_init = 0x0fc01616, .adda_1t_path_on = 0x0fc01616, .adda_2t_path_on_a = 0x0fc01616,
Greg Kroah-Hartman
maintainerPATCH 356/371 clk: rockchip: rk3399: allow clk_cifout to force clk_cifout_src to reparent
In reply to Greg Kroah-HartmanFrom: Quentin Schulz <[email protected]>
commit 933bf364e152cd60902cf9585c2ba310d593e69f upstream.
clk_cifout is derived from clk_cifout_src through an integer divider limited to 32. clk_cifout_src is a child of either cpll, gpll or npll without any possibility of a divider of any sort. The default clock parent is cpll.
Let's allow clk_cifout to ask its parent clk_cifout_src to reparent in order to find the real closest possible rate for clk_cifout and not one derived from cpll only.
--- drivers/clk/rockchip/clk-rk3399.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/clk/rockchip/clk-rk3399.c +1 -1
@@ -1263,7 +1263,7 @@ static struct rockchip_clk_branch rk3399 RK3399_CLKSEL_CON(56), 6, 2, MFLAGS, RK3399_CLKGATE_CON(10), 7, GFLAGS), -COMPOSITE_NOGATE (SCLK_CIF_OUT ,"clk_cifout" , mux_clk_cif_p,0 , +COMPOSITE_NOGATE (SCLK_CIF_OUT ,"clk_cifout" , mux_clk_cif_p,CLK_SET_RATE_PARENT , RK3399_CLKSEL_CON(56), 5, 1, MFLAGS, 0, 5, DFLAGS),/* gic */
Greg Kroah-Hartman
maintainerPATCH 357/371 scripts/gdb: fix lx-timerlist for Python3
In reply to Greg Kroah-HartmanFrom: Peng Liu <[email protected]>
commit 7362042f3556528e9e9b1eb5ce8d7a3a6331476b upstream.
Below incompatibilities between Python2 and Python3 made lx-timerlist fail to run under Python3.
o xrange() is replaced by range() in Python3
o bytes and str are different types in Python3
o the return value of Inferior.read_memory() is memoryview object in Python3
akpm: cc stable so that older kernels are properly debuggable under newer Python.
--- scripts/gdb/linux/timerlist.py | 4 +++- scripts/gdb/linux/utils.py | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-)
scripts/gdb/linux/timerlist.py +3 -1
@@ -73,7 +73,7 @@ def print_cpu(hrtimer_bases, cpu, max_cl ts = cpus.per_cpu(tick_sched_ptr, cpu) text = "cpu: {}\n".format(cpu) - for i in xrange(max_clock_bases): + for i in range(max_clock_bases): text += " clock {}:\n".format(i) text += print_base(cpu_base['clock_base'][i])
@@ -158,6 +158,8 @@ def pr_cpumask(mask): num_bytes = (nr_cpu_ids + 7) / 8 buf = utils.read_memoryview(inf, bits, num_bytes).tobytes() buf = binascii.b2a_hex(buf) + if type(buf) is not str: + buf=buf.decode() chunks = [] i = num_bytes
scripts/gdb/linux/utils.py +4 -1
@@ -88,7 +88,10 @@ def get_target_endianness(): def read_memoryview(inf, start, length): - return memoryview(inf.read_memory(start, length)) + m = inf.read_memory(start, length) + if type(m) is memoryview: + return m + return memoryview(m) def read_u16(buffer, offset):
Greg Kroah-Hartman
maintainerPATCH 358/371 btrfs: scrub: reject unsupported scrub flags
In reply to Greg Kroah-HartmanFrom: Qu Wenruo <[email protected]>
commit 604e6681e114d05a2e384c4d1e8ef81918037ef5 upstream.
Since the introduction of scrub interface, the only flag that we support is BTRFS_SCRUB_READONLY. Thus there is no sanity checks, if there are some undefined flags passed in, we just ignore them.
This is problematic if we want to introduce new scrub flags, as we have no way to determine if such flags are supported.
Address the problem by introducing a check for the flags, and if unsupported flags are set, return -EOPNOTSUPP to inform the user space.
This check should be backported for all supported kernels before any new scrub flags are introduced.
--- fs/btrfs/ioctl.c | 5 +++++ include/uapi/linux/btrfs.h | 1 + 2 files changed, 6 insertions(+)
fs/btrfs/ioctl.c +5 -0
@@ -3715,6 +3715,11 @@ static long btrfs_ioctl_scrub(struct filif (IS_ERR (sa))return PTR_ERR (sa); +if (sa->flags & ~BTRFS_SCRUB_SUPPORTED_FLAGS ) { + ret = -EOPNOTSUPP ; + goto out; + } +if (!(sa->flags &BTRFS_SCRUB_READONLY )) { ret =mnt_want_write_file (file);if (ret)
include/uapi/linux/btrfs.h +1 -0
@@ -181,6 +181,7 @@ struct btrfs_scrub_progress { };#define BTRFS_SCRUB_READONLY 1 +#define BTRFS_SCRUB_SUPPORTED_FLAGS (BTRFS_SCRUB_READONLY)struct btrfs_ioctl_scrub_args {__u64 devid;/* in */ __u64 start;/* in */
Greg Kroah-Hartman
maintainerPATCH 359/371 s390/dasd: fix hanging blockdevice after request requeue
In reply to Greg Kroah-HartmanFrom: Stefan Haberland <[email protected]>
commit d8898ee50edecacdf0141f26fd90acf43d7e9cd7 upstream.
The DASD driver does not kick the requeue list when requeuing IO requests to the blocklayer. This might lead to hanging blockdevice when there is no other trigger for this.
Fix by automatically kick the requeue list when requeuing DASD requests to the blocklayer.
--- drivers/s390/block/dasd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/s390/block/dasd.c +1 -1
@@ -2963,7 +2963,7 @@ static int _dasd_requeue_request(structreturn 0 ;spin_lock_irq (&cqr->dq->lock); req = (struct request *) cqr->callback_data; -blk_mq_requeue_request (req, false); +blk_mq_requeue_request (req, true);spin_unlock_irq (&cqr->dq->lock);return 0 ;
Greg Kroah-Hartman
maintainerPATCH 360/371 ia64: fix an addr to taddr in huge_pte_offset()
In reply to Greg Kroah-HartmanFrom: Hugh Dickins <[email protected]>
commit 3647ebcfbfca384840231fe13fae665453238a61 upstream.
I know nothing of ia64 htlbpage_to_page(), but guess that the p4d line should be using taddr rather than addr, like everywhere else.
--- arch/ia64/mm/hugetlbpage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/ia64/mm/hugetlbpage.c +1 -1
@@ -58,7 +58,7 @@ huge_pte_offset (struct mm_struct *mm, u pgd =pgd_offset (mm, taddr);if (pgd_present (*pgd)) { - p4d =p4d_offset (pgd, addr); + p4d =p4d_offset (pgd, taddr);if (p4d_present (*p4d)) { pud =pud_offset (p4d, taddr);if (pud_present (*pud)) {
Greg Kroah-Hartman
maintainerPATCH 361/371 dm verity: fix error handling for check_at_most_once on FEC
In reply to Greg Kroah-HartmanFrom: Yeongjin Gil <[email protected]>
commit e8c5d45f82ce0c238a4817739892fe8897a3dcc3 upstream.
In verity_end_io(), if bi_status is not BLK_STS_OK, it can be return directly. But if FEC configured, it is desired to correct the data page through verity_verify_io. And the return value will be converted to blk_status and passed to verity_finish_io().
BTW, when a bit is set in v->validated_blocks, verity_verify_io() skips verification regardless of I/O error for the corresponding bio. In this case, the I/O error could not be returned properly, and as a result, there is a problem that abnormal data could be read for the corresponding block.
To fix this problem, when an I/O error occurs, do not skip verification even if the bit related is set in v->validated_blocks.
--- drivers/md/dm-verity-target.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/md/dm-verity-target.c +1 -1
@@ -482,7 +482,7 @@ static int verity_verify_io(struct dm_vesector_t cur_block = io->block + b;struct ahash_request *req =verity_io_hash_req (v, io); -if (v->validated_blocks && +if (v->validated_blocks && bio->bi_status ==BLK_STS_OK &&likely (test_bit (cur_block, v->validated_blocks))) {verity_bv_skip_block (v, io, &io->iter);continue ;
Greg Kroah-Hartman
maintainerPATCH 362/371 dm clone: call kmem_cache_destroy() in dm_clone_init() error path
In reply to Greg Kroah-HartmanFrom: Mike Snitzer <[email protected]>
commit 6827af4a9a9f5bb664c42abf7c11af4978d72201 upstream.
Otherwise the _hydration_cache will leak if dm_register_target() fails.
--- drivers/md/dm-clone-target.c | 1 + 1 file changed, 1 insertion(+)
drivers/md/dm-clone-target.c +1 -0
@@ -2214,6 +2214,7 @@ static int __init dm_clone_init(void) r =dm_register_target (&clone_target);if (r <0 ) {DMERR ("Failed to register clone target" ); +kmem_cache_destroy (_hydration_cache);return r; }
Greg Kroah-Hartman
maintainerPATCH 363/371 dm integrity: call kmem_cache_destroy() in dm_integrity_init() error path
In reply to Greg Kroah-HartmanFrom: Mike Snitzer <[email protected]>
commit 6b79a428c02769f2a11f8ae76bf866226d134887 upstream.
Otherwise the journal_io_cache will leak if dm_register_target() fails.
--- drivers/md/dm-integrity.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
drivers/md/dm-integrity.c +5 -3
@@ -4632,11 +4632,13 @@ static int __init dm_integrity_init(void } r =dm_register_target (&integrity_target); - -if (r <0 ) +if (r <0 ) {DMERR ("register failed %d" , r); +kmem_cache_destroy (journal_io_cache); +return r; + } -return r; +return 0 ; } static void __exit dm_integrity_exit(void)
Greg Kroah-Hartman
maintainerPATCH 364/371 dm flakey: fix a crash with invalid table line
In reply to Greg Kroah-HartmanFrom: Mikulas Patocka <[email protected]>
commit 98dba02d9a93eec11bffbb93c7c51624290702d2 upstream.
This command will crash with NULL pointer dereference:
dmsetup create flakey --table \
"0 blockdev --getsize /dev/ram0 flakey /dev/ram0 0 0 1 2 corrupt_bio_byte 512"
Fix the crash by checking if arg_name is non-NULL before comparing it.
--- drivers/md/dm-flakey.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/md/dm-flakey.c +2 -2
@@ -124,9 +124,9 @@ static int parse_features(struct dm_arg_* Direction r or w? */ arg_name =dm_shift_arg (as); -if (!strcasecmp (arg_name,"w" )) +if (arg_name && !strcasecmp (arg_name,"w" )) fc->corrupt_bio_rw =WRITE ; -else if (!strcasecmp (arg_name,"r" )) +else if (arg_name && !strcasecmp (arg_name,"r" )) fc->corrupt_bio_rw =READ ;else { ti->error ="Invalid corrupt bio direction (r or w)" ;
Greg Kroah-Hartman
maintainerPATCH 365/371 dm ioctl: fix nested locking in table_clear() to remove deadlock concern
In reply to Greg Kroah-HartmanFrom: Mike Snitzer <[email protected]>
commit 3d32aaa7e66d5c1479a3c31d6c2c5d45dd0d3b89 upstream.
syzkaller found the following problematic rwsem locking (with write lock already held):
down_read+0x9d/0x450 kernel/locking/rwsem.c:1509 dm_get_inactive_table+0x2b/0xc0 drivers/md/dm-ioctl.c:773 __dev_status+0x4fd/0x7c0 drivers/md/dm-ioctl.c:844 table_clear+0x197/0x280 drivers/md/dm-ioctl.c:1537
In table_clear, it first acquires a write lock
https://elixir.bootlin.com/linux/v6.2/source/drivers/md/dm-ioctl.c#L1520down_write(&_hash_lock);
Then before the lock is released at L1539, there is a path shown above:table_clear -> __dev_status -> dm_get_inactive_table -> down_read
https://elixir.bootlin.com/linux/v6.2/source/drivers/md/dm-ioctl.c#L773down_read(&_hash_lock);
It tries to acquire the same read lock again, resulting in the deadlock problem.
Fix this by moving table_clear()'s __dev_status() call to after its up_write(&_hash_lock);
--- drivers/md/dm-ioctl.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
drivers/md/dm-ioctl.c +4 -3
@@ -1533,11 +1533,12 @@ static int table_clear(struct file *filp has_new_map = true; } - param->flags &= ~DM_INACTIVE_PRESENT_FLAG ; - -__dev_status (hc->md, param); md = hc->md;up_write (&_hash_lock); + + param->flags &= ~DM_INACTIVE_PRESENT_FLAG ; +__dev_status (md, param); +if (old_map) {dm_sync_table (md);dm_table_destroy (old_map);
Greg Kroah-Hartman
maintainerPATCH 366/371 dm: dont lock fs when the map is NULL in process of resume
In reply to Greg Kroah-HartmanFrom: Li Lingfeng <[email protected]>
commit 38d11da522aacaa05898c734a1cec86f1e611129 upstream.
Commit fa247089de99 ("dm: requeue IO if mapping table not yet available") added a detection of whether the mapping table is available in the IO submission process. If the mapping table is unavailable, it returns BLK_STS_RESOURCE and requeues the IO.
This can lead to the following deadlock problem:
dm create mountioctl(DM_DEV_CREATE_CMD)ioctl(DM_TABLE_LOAD_CMD)
do_mount
vfs_get_tree
ext4_get_tree
get_tree_bdev
sget_fc
alloc_super
// got &s->s_umount
down_write_nested(&s->s_umount, ...);
ext4_fill_super
ext4_load_super
ext4_read_bh
submit_bio
// submit and wait io endioctl(DM_DEV_SUSPEND_CMD)dev_suspend
do_resume
dm_suspend
__dm_suspend
lock_fs
freeze_bdev
get_active_super
grab_super
// wait for &s->s_umount
down_write(&s->s_umount);
dm_swap_table
__bind
// set md->map(can't get here)IO will be continuously requeued while holding the lock since mapping table is NULL. At the same time, mapping table won't be set since the lock is not available.
Like request-based DM, bio-based DM also has the same problem.
It's not proper to just abort IO if the mapping table not available. So clear DM_SKIP_LOCKFS_FLAG when the mapping table is NULL, this allows the DM table to be loaded and the IO submitted upon resume.
--- drivers/md/dm-ioctl.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/md/dm-ioctl.c +4 -1
@@ -1145,10 +1145,13 @@ static int do_resume(struct dm_ioctl *pa/* Do we need to load a new map ? */ if (new_map) {sector_t old_size, new_size; +int srcu_idx;/* Suspend if it isn't already suspended */ -if (param->flags &DM_SKIP_LOCKFS_FLAG ) + old_map =dm_get_live_table (md, &srcu_idx); +if ((param->flags &DM_SKIP_LOCKFS_FLAG ) || !old_map) suspend_flags &= ~DM_SUSPEND_LOCKFS_FLAG ; +dm_put_live_table (md, srcu_idx);if (param->flags &DM_NOFLUSH_FLAG ) suspend_flags |=DM_SUSPEND_NOFLUSH_FLAG ;if (!dm_suspended_md (md))
Greg Kroah-Hartman
maintainerPATCH 367/371 perf auxtrace: Fix address filter entire kernel size
In reply to Greg Kroah-HartmanFrom: Adrian Hunter <[email protected]>
commit 1f9f33ccf0320be21703d9195dd2b36a1c9a07cb upstream.
kallsyms is not completely in address order.
In find_entire_kern_cb(), calculate the kernel end from the maximum address not the last symbol.
Example:
Before:
$ sudo cat /proc/kallsyms | grep ' [twTw] ' | tail -1
ffffffffc00b8bd0 t bpf_prog_6deef7357e7b4530 [bpf]
$ sudo cat /proc/kallsyms | grep ' [twTw] ' | sort | tail -1
ffffffffc15e0cc0 t iwl_mvm_exit [iwlmvm]
$ perf.d093603a05aa record -v --kcore -e intel_pt// --filter 'filter *' -- uname |& grep filter
Address filter: filter 0xffffffff93200000/0x2ceba000After:
$ perf.8fb0f7a01f8e record -v --kcore -e intel_pt// --filter 'filter *' -- uname |& grep filter
Address filter: filter 0xffffffff93200000/0x2e3e2000--- tools/perf/util/auxtrace.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
tools/perf/util/auxtrace.c +4 -1
@@ -2378,6 +2378,7 @@ static int find_entire_kern_cb(void *arg char type, u64 start) {struct sym_args *args = arg; +u64 size;if (!kallsyms__is_function (type))return 0 ;
@@ -2387,7 +2388,9 @@ static int find_entire_kern_cb(void *arg args->start = start; }/* Don't know exactly where the kernel ends, so we add a page */ - args->size =round_up (start, page_size) + page_size - args->start; + size =round_up (start, page_size) + page_size - args->start; +if (size > args->size) + args->size = size;return 0 ; }
Greg Kroah-Hartman
maintainerPATCH 368/371 perf intel-pt: Fix CYC timestamps after standalone CBR
In reply to Greg Kroah-HartmanFrom: Adrian Hunter <[email protected]>
commit 430635a0ef1ce958b7b4311f172694ece2c692b8 upstream.
After a standalone CBR (not associated with TSC), update the cycles reference timestamp and reset the cycle count, so that CYC timestamps are calculated relative to that point with the new frequency.
--- tools/perf/util/intel-pt-decoder/intel-pt-decoder.c | 2 ++ 1 file changed, 2 insertions(+)
tools/perf/util/intel-pt-decoder/intel-pt-decoder.c +2 -0
@@ -1859,6 +1859,8 @@ static void intel_pt_calc_cbr(struct int decoder->cbr = cbr; decoder->cbr_cyc_to_tsc = decoder->max_non_turbo_ratio_fp / cbr; + decoder->cyc_ref_timestamp = decoder->timestamp; + decoder->cycle_cnt =0 ;intel_pt_mtc_cyc_cnt_cbr (decoder); }
Greg Kroah-Hartman
maintainerPATCH 369/371 debugobject: Ensure pool refill (again)
In reply to Greg Kroah-HartmanFrom: Thomas Gleixner <[email protected]>
commit 0af462f19e635ad522f28981238334620881badc upstream.
The recent fix to ensure atomicity of lookup and allocation inadvertently broke the pool refill mechanism.
Prior to that change debug_objects_activate() and debug_objecs_assert_init() invoked debug_objecs_init() to set up the tracking object for statically initialized objects. That's not longer the case and debug_objecs_init() is now the only place which does pool refills.
Depending on the number of statically initialized objects this can be enough to actually deplete the pool, which was observed by Ido via a debugobjects OOM warning.
Restore the old behaviour by adding explicit refill opportunities to debug_objects_activate() and debug_objecs_assert_init().
--- lib/debugobjects.c | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-)
lib/debugobjects.c +15 -6
@@ -590,6 +590,16 @@ static struct debug_obj *lookup_object_oreturn NULL ; } +static void debug_objects_fill_pool (void ) +{ +/* +* On RT enabled kernels the pool refill must happen in preemptible +* context: +*/ +if (!IS_ENABLED (CONFIG_PREEMPT_RT ) ||preemptible ()) +fill_pool (); +} +static void __debug_object_init (void *addr,const struct debug_obj_descr *descr,int onstack) {
@@ -598,12 +608,7 @@ __debug_object_init(void *addr, const ststruct debug_obj *obj;unsigned long flags; -/* -* On RT enabled kernels the pool refill must happen in preemptible -* context: -*/ -if (!IS_ENABLED (CONFIG_PREEMPT_RT ) ||preemptible ()) -fill_pool (); +debug_objects_fill_pool (); db =get_bucket ((unsigned long ) addr);
@@ -688,6 +693,8 @@ int debug_object_activate(void *addr, coif (!debug_objects_enabled)return 0 ; +debug_objects_fill_pool (); + db =get_bucket ((unsigned long ) addr);raw_spin_lock_irqsave (&db->lock, flags);
@@ -897,6 +904,8 @@ void debug_object_assert_init(void *addrif (!debug_objects_enabled)return ; +debug_objects_fill_pool (); + db =get_bucket ((unsigned long ) addr);raw_spin_lock_irqsave (&db->lock, flags);
Greg Kroah-Hartman
maintainerPATCH 370/371 sound/oss/dmasound: fix dmasound_setup defined but not used
In reply to Greg Kroah-HartmanFrom: Miles Chen <[email protected]>
commit 357ad4d898286b94aaae0cb7e3f573459e5b98b9 upstream.
We observed: 'dmasound_setup' defined but not used error with COMPILER=gcc ARCH=m68k DEFCONFIG=allmodconfig build.
Fix it by adding __maybe_unused to dmasound_setup.
Error(s):sound/oss/dmasound/dmasound_core.c:1431:12: error: 'dmasound_setup' defined but not used [-Werror=unused-function]
--- sound/oss/dmasound/dmasound_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/oss/dmasound/dmasound_core.c +1 -1
@@ -1428,7 +1428,7 @@ void dmasound_deinit(void)unregister_sound_dsp (sq_unit); } -static int dmasound_setup (char *str) +static int __maybe_unused dmasound_setup (char *str) {int ints[6 ], size;
Greg Kroah-Hartman
maintainerPATCH 371/371 arm64: dts: qcom: sdm845: correct dynamic power coefficients - again
In reply to Greg Kroah-HartmanFrom: Vincent Guittot <[email protected]>
commit 44750f153699b6e4f851a399287e5c8df208d696 upstream.
While stressing EAS on my dragonboard RB3, I have noticed that LITTLE cores where never selected as the most energy efficient CPU whatever the utilization level of waking task.
energy model framework uses its cost field to estimate the energy with the formula:
nrg = cost of the selected OPP * utilization / CPU's max capacity
which ends up selecting the CPU with lowest cost / max capacity ration as long as the utilization fits in the OPP's capacity.
If we compare the cost of a little OPP with similar capacity of a big OPP like :
OPP(kHz) OPP capacity cost max capacity cost/max capacity LITTLE 1766400 407 351114 407 863 big 1056000 408 520267 1024 508
This can be interpreted as the LITTLE core consumes 70% more than big core for the same compute capacity.
According to [1], LITTLE consumes 10% less than big core for Coremark benchmark at those OPPs. If we consider that everything else stays unchanged, the dynamic-power-coefficient of LITTLE core should be only 53% of the current value: 290 * 53% = 154
Set the dynamic-power-coefficient of CPU0-3 to 154 to fix the energy model.
[1] https://github.com/kdrag0n/freqbench/tree/master/results/sdm845/main
--- arch/arm64/boot/dts/qcom/sdm845.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
arch/arm64/boot/dts/qcom/sdm845.dtsi +4 -4
@@ -197,7 +197,7 @@ &LITTLE_CPU_SLEEP_1 &CLUSTER_SLEEP_0>; capacity-dmips-mhz = <611>; - dynamic-power-coefficient = <290>; + dynamic-power-coefficient = <154>; qcom,freq-domain = <&cpufreq_hw 0>; operating-points-v2 = <&cpu0_opp_table>; interconnects = <&gladiator_noc MASTER_APPSS_PROC 3 &mem_noc SLAVE_EBI1 3>,
@@ -222,7 +222,7 @@ &LITTLE_CPU_SLEEP_1 &CLUSTER_SLEEP_0>; capacity-dmips-mhz = <611>; - dynamic-power-coefficient = <290>; + dynamic-power-coefficient = <154>; qcom,freq-domain = <&cpufreq_hw 0>; operating-points-v2 = <&cpu0_opp_table>; interconnects = <&gladiator_noc MASTER_APPSS_PROC 3 &mem_noc SLAVE_EBI1 3>,
@@ -244,7 +244,7 @@ &LITTLE_CPU_SLEEP_1 &CLUSTER_SLEEP_0>; capacity-dmips-mhz = <611>; - dynamic-power-coefficient = <290>; + dynamic-power-coefficient = <154>; qcom,freq-domain = <&cpufreq_hw 0>; operating-points-v2 = <&cpu0_opp_table>; interconnects = <&gladiator_noc MASTER_APPSS_PROC 3 &mem_noc SLAVE_EBI1 3>,
@@ -266,7 +266,7 @@ &LITTLE_CPU_SLEEP_1 &CLUSTER_SLEEP_0>; capacity-dmips-mhz = <611>; - dynamic-power-coefficient = <290>; + dynamic-power-coefficient = <154>; qcom,freq-domain = <&cpufreq_hw 0>; operating-points-v2 = <&cpu0_opp_table>; interconnects = <&gladiator_noc MASTER_APPSS_PROC 3 &mem_noc SLAVE_EBI1 3>,
Quoted 9 lines · Greg Kroah-Hartman
This is the start of the stable review cycle for the 5.15.111 release. There are 371 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Responses should be made by Wed, 10 May 2023 09:47:07 +0000. Anything received after that time might be too late.
The whole patch series can be found in one patch at:
Quoted 8 lines
https://www.kernel.org/pub/linux/kernel/v5.x/stable-review/patch-5.15.111-rc1.gzor in the git tree and branch at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.gitlinux-5.15.y
and the diffstat can be found below.thanks,
greg k-h
On ARCH_BRCMSTB using 32-bit and 64-bit ARM kernels, build tested on BMIPS_GENERIC:
Signature · 1 line
Florian
Quoted 9 lines · Greg Kroah-Hartman
This is the start of the stable review cycle for the 5.15.111 release. There are 371 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Responses should be made by Wed, 10 May 2023 09:47:07 +0000. Anything received after that time might be too late.
The whole patch series can be found in one patch at:
Quoted 9 lines
https://www.kernel.org/pub/linux/kernel/v5.x/stable-review/patch-5.15.111-rc1.gzor in the git tree and branch at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.gitlinux-5.15.y
and the diffstat can be found below.thanks,
greg k-h
Compiled and booted on my test system. No dmesg regressions.
thanks,
-- Shuah
Quoted 5 lines · Greg Kroah-Hartman
This is the start of the stable review cycle for the 5.15.111 release. There are 371 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Successfully built bindeb-pkgs for my computer (Acer Aspire E15, Intel Core i3 Haswell) and booted. No noticeable regressions.
Signature · 1 line
An old man doll... just what I always wanted! - Clara
Quoted 5 lines · Greg Kroah-Hartman
This is the start of the stable review cycle for the 5.15.111 release. There are 371 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Successfully compiled and installed bindeb-pkgs on my computer (Acer Aspire E15, Intel Core i3 Haswell). No noticeable regressions.
Signature · 1 line
An old man doll... just what I always wanted! - Clara