Skip to content

Commit 3403134

Browse files
committed
Merge tag 'v5.10.6' into 5.10.x+fslc
This is the 5.10.6 stable release Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
2 parents 48fc9e6 + 5650152 commit 3403134

File tree

45 files changed

+362
-256
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+362
-256
lines changed

Documentation/devicetree/bindings/rtc/rtc.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,11 @@ properties:
6363
description:
6464
Enables wake up of host system on alarm.
6565

66+
reset-source:
67+
$ref: /schemas/types.yaml#/definitions/flag
68+
description:
69+
The RTC is able to reset the machine.
70+
6671
additionalProperties: true
6772

6873
...

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0
22
VERSION = 5
33
PATCHLEVEL = 10
4-
SUBLEVEL = 5
4+
SUBLEVEL = 6
55
EXTRAVERSION =
66
NAME = Kleptomaniac Octopus
77

drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2278,8 +2278,7 @@ void amdgpu_dm_update_connector_after_detect(
22782278

22792279
drm_connector_update_edid_property(connector,
22802280
aconnector->edid);
2281-
aconnector->num_modes = drm_add_edid_modes(connector, aconnector->edid);
2282-
drm_connector_list_update(connector);
2281+
drm_add_edid_modes(connector, aconnector->edid);
22832282

22842283
if (aconnector->dc_link->aux_mode)
22852284
drm_dp_cec_set_edid(&aconnector->dm_dp_aux.aux,

drivers/gpu/drm/i915/display/intel_dpll_mgr.c

Lines changed: 25 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2622,11 +2622,22 @@ static bool cnl_ddi_hdmi_pll_dividers(struct intel_crtc_state *crtc_state)
26222622
return true;
26232623
}
26242624

2625+
/*
2626+
* Display WA #22010492432: tgl
2627+
* Program half of the nominal DCO divider fraction value.
2628+
*/
2629+
static bool
2630+
tgl_combo_pll_div_frac_wa_needed(struct drm_i915_private *i915)
2631+
{
2632+
return IS_TIGERLAKE(i915) && i915->dpll.ref_clks.nssc == 38400;
2633+
}
2634+
26252635
static int __cnl_ddi_wrpll_get_freq(struct drm_i915_private *dev_priv,
26262636
const struct intel_shared_dpll *pll,
26272637
int ref_clock)
26282638
{
26292639
const struct intel_dpll_hw_state *pll_state = &pll->state.hw_state;
2640+
u32 dco_fraction;
26302641
u32 p0, p1, p2, dco_freq;
26312642

26322643
p0 = pll_state->cfgcr1 & DPLL_CFGCR1_PDIV_MASK;
@@ -2669,8 +2680,13 @@ static int __cnl_ddi_wrpll_get_freq(struct drm_i915_private *dev_priv,
26692680
dco_freq = (pll_state->cfgcr0 & DPLL_CFGCR0_DCO_INTEGER_MASK) *
26702681
ref_clock;
26712682

2672-
dco_freq += (((pll_state->cfgcr0 & DPLL_CFGCR0_DCO_FRACTION_MASK) >>
2673-
DPLL_CFGCR0_DCO_FRACTION_SHIFT) * ref_clock) / 0x8000;
2683+
dco_fraction = (pll_state->cfgcr0 & DPLL_CFGCR0_DCO_FRACTION_MASK) >>
2684+
DPLL_CFGCR0_DCO_FRACTION_SHIFT;
2685+
2686+
if (tgl_combo_pll_div_frac_wa_needed(dev_priv))
2687+
dco_fraction *= 2;
2688+
2689+
dco_freq += (dco_fraction * ref_clock) / 0x8000;
26742690

26752691
if (drm_WARN_ON(&dev_priv->drm, p0 == 0 || p1 == 0 || p2 == 0))
26762692
return 0;
@@ -2948,16 +2964,6 @@ static const struct skl_wrpll_params tgl_tbt_pll_24MHz_values = {
29482964
/* the following params are unused */
29492965
};
29502966

2951-
/*
2952-
* Display WA #22010492432: tgl
2953-
* Divide the nominal .dco_fraction value by 2.
2954-
*/
2955-
static const struct skl_wrpll_params tgl_tbt_pll_38_4MHz_values = {
2956-
.dco_integer = 0x54, .dco_fraction = 0x1800,
2957-
/* the following params are unused */
2958-
.pdiv = 0, .kdiv = 0, .qdiv_mode = 0, .qdiv_ratio = 0,
2959-
};
2960-
29612967
static bool icl_calc_dp_combo_pll(struct intel_crtc_state *crtc_state,
29622968
struct skl_wrpll_params *pll_params)
29632969
{
@@ -2991,14 +2997,12 @@ static bool icl_calc_tbt_pll(struct intel_crtc_state *crtc_state,
29912997
MISSING_CASE(dev_priv->dpll.ref_clks.nssc);
29922998
fallthrough;
29932999
case 19200:
3000+
case 38400:
29943001
*pll_params = tgl_tbt_pll_19_2MHz_values;
29953002
break;
29963003
case 24000:
29973004
*pll_params = tgl_tbt_pll_24MHz_values;
29983005
break;
2999-
case 38400:
3000-
*pll_params = tgl_tbt_pll_38_4MHz_values;
3001-
break;
30023006
}
30033007
} else {
30043008
switch (dev_priv->dpll.ref_clks.nssc) {
@@ -3065,9 +3069,14 @@ static void icl_calc_dpll_state(struct drm_i915_private *i915,
30653069
const struct skl_wrpll_params *pll_params,
30663070
struct intel_dpll_hw_state *pll_state)
30673071
{
3072+
u32 dco_fraction = pll_params->dco_fraction;
3073+
30683074
memset(pll_state, 0, sizeof(*pll_state));
30693075

3070-
pll_state->cfgcr0 = DPLL_CFGCR0_DCO_FRACTION(pll_params->dco_fraction) |
3076+
if (tgl_combo_pll_div_frac_wa_needed(i915))
3077+
dco_fraction = DIV_ROUND_CLOSEST(dco_fraction, 2);
3078+
3079+
pll_state->cfgcr0 = DPLL_CFGCR0_DCO_FRACTION(dco_fraction) |
30713080
pll_params->dco_integer;
30723081

30733082
pll_state->cfgcr1 = DPLL_CFGCR1_QDIV_RATIO(pll_params->qdiv_ratio) |

drivers/infiniband/core/device.c

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1177,25 +1177,6 @@ static int assign_name(struct ib_device *device, const char *name)
11771177
return ret;
11781178
}
11791179

1180-
static void setup_dma_device(struct ib_device *device,
1181-
struct device *dma_device)
1182-
{
1183-
/*
1184-
* If the caller does not provide a DMA capable device then the IB
1185-
* device will be used. In this case the caller should fully setup the
1186-
* ibdev for DMA. This usually means using dma_virt_ops.
1187-
*/
1188-
#ifdef CONFIG_DMA_VIRT_OPS
1189-
if (!dma_device) {
1190-
device->dev.dma_ops = &dma_virt_ops;
1191-
dma_device = &device->dev;
1192-
}
1193-
#endif
1194-
WARN_ON(!dma_device);
1195-
device->dma_device = dma_device;
1196-
WARN_ON(!device->dma_device->dma_parms);
1197-
}
1198-
11991180
/*
12001181
* setup_device() allocates memory and sets up data that requires calling the
12011182
* device ops, this is the only reason these actions are not done during
@@ -1341,7 +1322,14 @@ int ib_register_device(struct ib_device *device, const char *name,
13411322
if (ret)
13421323
return ret;
13431324

1344-
setup_dma_device(device, dma_device);
1325+
/*
1326+
* If the caller does not provide a DMA capable device then the IB core
1327+
* will set up ib_sge and scatterlist structures that stash the kernel
1328+
* virtual address into the address field.
1329+
*/
1330+
WARN_ON(dma_device && !dma_device->dma_parms);
1331+
device->dma_device = dma_device;
1332+
13451333
ret = setup_device(device);
13461334
if (ret)
13471335
return ret;
@@ -2676,6 +2664,21 @@ void ib_set_device_ops(struct ib_device *dev, const struct ib_device_ops *ops)
26762664
}
26772665
EXPORT_SYMBOL(ib_set_device_ops);
26782666

2667+
#ifdef CONFIG_INFINIBAND_VIRT_DMA
2668+
int ib_dma_virt_map_sg(struct ib_device *dev, struct scatterlist *sg, int nents)
2669+
{
2670+
struct scatterlist *s;
2671+
int i;
2672+
2673+
for_each_sg(sg, s, nents, i) {
2674+
sg_dma_address(s) = (uintptr_t)sg_virt(s);
2675+
sg_dma_len(s) = s->length;
2676+
}
2677+
return nents;
2678+
}
2679+
EXPORT_SYMBOL(ib_dma_virt_map_sg);
2680+
#endif /* CONFIG_INFINIBAND_VIRT_DMA */
2681+
26792682
static const struct rdma_nl_cbs ibnl_ls_cb_table[RDMA_NL_LS_NUM_OPS] = {
26802683
[RDMA_NL_LS_OP_RESOLVE] = {
26812684
.doit = ib_nl_handle_resolve_resp,

drivers/infiniband/core/rw.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,8 +285,11 @@ static void rdma_rw_unmap_sg(struct ib_device *dev, struct scatterlist *sg,
285285
static int rdma_rw_map_sg(struct ib_device *dev, struct scatterlist *sg,
286286
u32 sg_cnt, enum dma_data_direction dir)
287287
{
288-
if (is_pci_p2pdma_page(sg_page(sg)))
288+
if (is_pci_p2pdma_page(sg_page(sg))) {
289+
if (WARN_ON_ONCE(ib_uses_virt_dma(dev)))
290+
return 0;
289291
return pci_p2pdma_map_sg(dev->dma_device, sg, sg_cnt, dir);
292+
}
290293
return ib_dma_map_sg(dev, sg, sg_cnt, dir);
291294
}
292295

drivers/infiniband/sw/rdmavt/Kconfig

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,5 @@ config INFINIBAND_RDMAVT
44
depends on INFINIBAND_VIRT_DMA
55
depends on X86_64
66
depends on PCI
7-
select DMA_VIRT_OPS
87
help
98
This is a common software verbs provider for RDMA networks.

drivers/infiniband/sw/rdmavt/mr.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -324,8 +324,6 @@ static void __rvt_free_mr(struct rvt_mr *mr)
324324
* @acc: access flags
325325
*
326326
* Return: the memory region on success, otherwise returns an errno.
327-
* Note that all DMA addresses should be created via the functions in
328-
* struct dma_virt_ops.
329327
*/
330328
struct ib_mr *rvt_get_dma_mr(struct ib_pd *pd, int acc)
331329
{
@@ -766,7 +764,7 @@ int rvt_lkey_ok(struct rvt_lkey_table *rkt, struct rvt_pd *pd,
766764

767765
/*
768766
* We use LKEY == zero for kernel virtual addresses
769-
* (see rvt_get_dma_mr() and dma_virt_ops).
767+
* (see rvt_get_dma_mr()).
770768
*/
771769
if (sge->lkey == 0) {
772770
struct rvt_dev_info *dev = ib_to_rvt(pd->ibpd.device);
@@ -877,7 +875,7 @@ int rvt_rkey_ok(struct rvt_qp *qp, struct rvt_sge *sge,
877875

878876
/*
879877
* We use RKEY == zero for kernel virtual addresses
880-
* (see rvt_get_dma_mr() and dma_virt_ops).
878+
* (see rvt_get_dma_mr()).
881879
*/
882880
rcu_read_lock();
883881
if (rkey == 0) {

drivers/infiniband/sw/rdmavt/vt.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -524,7 +524,6 @@ static noinline int check_support(struct rvt_dev_info *rdi, int verb)
524524
int rvt_register_device(struct rvt_dev_info *rdi)
525525
{
526526
int ret = 0, i;
527-
u64 dma_mask;
528527

529528
if (!rdi)
530529
return -EINVAL;
@@ -579,13 +578,6 @@ int rvt_register_device(struct rvt_dev_info *rdi)
579578
/* Completion queues */
580579
spin_lock_init(&rdi->n_cqs_lock);
581580

582-
/* DMA Operations */
583-
rdi->ibdev.dev.dma_parms = rdi->ibdev.dev.parent->dma_parms;
584-
dma_mask = IS_ENABLED(CONFIG_64BIT) ? DMA_BIT_MASK(64) : DMA_BIT_MASK(32);
585-
ret = dma_coerce_mask_and_coherent(&rdi->ibdev.dev, dma_mask);
586-
if (ret)
587-
goto bail_wss;
588-
589581
/* Protection Domain */
590582
spin_lock_init(&rdi->n_pds_lock);
591583
rdi->n_pds_allocated = 0;

drivers/infiniband/sw/rxe/Kconfig

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ config RDMA_RXE
55
depends on INFINIBAND_VIRT_DMA
66
select NET_UDP_TUNNEL
77
select CRYPTO_CRC32
8-
select DMA_VIRT_OPS
98
help
109
This driver implements the InfiniBand RDMA transport over
1110
the Linux network stack. It enables a system with a

0 commit comments

Comments
 (0)