Skip to content

Commit 945564b

Browse files
committed
Merge tag 'v6.1.124' into orange-pi-6.1-rk35xx
This is the 6.1.124 stable release * tag 'v6.1.124' of https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux: Linux 6.1.124 zram: check comp is non-NULL before calling comp_destroy mptcp: don't always assume copied data in mptcp_cleanup_rbuf() mptcp: fix recvbuffer adjust on sleeping rcvmsg mptcp: fix TCP options overflow. mm: vmscan: account for free pages to prevent infinite Loop in throttle_direct_reclaim() mm/readahead: fix large folio support in async readahead dt-bindings: display: adi,adv7533: Drop single lane support drm: adv7511: Drop dsi single lane support net/sctp: Prevent autoclose integer overflow in sctp_association_init() sky2: Add device ID 11ab:4373 for Marvell 88E8075 pinctrl: mcp23s08: Fix sleeping in atomic context due to regmap locking RDMA/uverbs: Prevent integer overflow issue kcov: mark in_softirq_really() as __always_inline ALSA: seq: oss: Fix races at processing SysEx messages ALSA hda/realtek: Add quirk for Framework F111:000C modpost: fix the missed iteration for the max bit in do_input() modpost: fix input MODULE_DEVICE_TABLE() built for 64-bit on 32-bit host usb: xhci: Avoid queuing redundant Stop Endpoint commands ARC: build: Try to guess GCC variant of cross compiler irqchip/gic: Correct declaration of *percpu_base pointer in union gic_base Bluetooth: hci_core: Fix sleeping function called from invalid context net: usb: qmi_wwan: add Telit FE910C04 compositions ksmbd: retry iterate_dir in smb2_query_dir bpf: fix potential error return sound: usb: format: don't warn that raw DSD is unsupported sound: usb: enable DSD output for ddHiFi TC44C ALSA: hda/realtek: Add new alc2xx-fixup-headset-mic model btrfs: flush delalloc workers queue before stopping cleaner kthread during unmount drm/amdkfd: Correct the migration DMA map direction wifi: mac80211: wake the queues in case of failure in resume btrfs: fix use-after-free when COWing tree bock and tracing is enabled btrfs: rename and export __btrfs_cow_block() ila: serialize calls to nf_register_net_hooks() af_packet: fix vlan_get_protocol_dgram() vs MSG_PEEK af_packet: fix vlan_get_tci() vs MSG_PEEK net: wwan: iosm: Properly check for valid exec stage in ipc_mmio_init() net: restrict SO_REUSEPORT to inet sockets net: reenable NETIF_F_IPV6_CSUM offload for BIG TCP packets RDMA/rtrs: Ensure 'ib_sge list' is accessible net: wwan: t7xx: Fix FSM command timeout issue net: mv643xx_eth: fix an OF node reference leak eth: bcmsysport: fix call balance of priv->clk handling routines ALSA: usb-audio: US16x08: Initialize array before use net: llc: reset skb->transport_header netfilter: nft_set_hash: unaligned atomic read on struct nft_set_ext drm/i915/dg1: Fix power gate sequence. netrom: check buffer length before accessing it net: Fix netns for ip_tunnel_init_flow() ipv4: ip_tunnel: Unmask upper DSCP bits in ip_tunnel_xmit() ipv4: ip_tunnel: Unmask upper DSCP bits in ip_md_tunnel_xmit() ipv4: ip_tunnel: Unmask upper DSCP bits in ip_tunnel_bind_dev() ip_tunnel: annotate data-races around t->parms.link ipip,ip_tunnel,sit: Add FOU support for externally controlled ipip devices net: fix memory leak in tcp_conn_request() net: stmmac: restructure the error path of stmmac_probe_config_dt() net: stmmac: don't create a MDIO bus if unnecessary net: stmmac: platform: provide devm_stmmac_probe_config_dt() RDMA/hns: Fix missing flush CQE for DWQE RDMA/hns: Fix warning storm caused by invalid input in IO path RDMA/hns: Fix mapping error of zero-hop WQE buffer RDMA/hns: Remove unused parameters and variables RDMA/hns: Refactor mtr find net: dsa: microchip: Fix LAN937X set_ageing_time function net: dsa: microchip: add ksz_rmw8() function net: dsa: microchip: Fix KSZ9477 set_ageing_time function drm/bridge: adv7511_audio: Update Audio InfoFrame properly RDMA/bnxt_re: Fix the locking while accessing the QP table RDMA/bnxt_re: Fix max_qp_wrs reported RDMA/bnxt_re: Fix reporting hw_ver in query_device RDMA/bnxt_re: Add check for path mtu in modify_qp RDMA/mlx5: Enforce same type port association for multiport RoCE net: mctp: handle skb cleanup on sock_queue failures xhci: Turn NEC specific quirk for handling Stop Endpoint errors generic usb: xhci: Limit Stop Endpoint retries xhci: retry Stop Endpoint on buggy NEC controllers thunderbolt: Don't display nvm_version unless upgrade supported thunderbolt: Add support for Intel Panther Lake-M/P thunderbolt: Add support for Intel Lunar Lake tracing: Have process_string() also allow arrays btrfs: fix use-after-free in btrfs_encoded_read_endio() selinux: ignore unknown extended permissions x86/hyperv: Fix hv tsc page based sched_clock for hibernation Signed-off-by: Khusika Dhamar Gusti <[email protected]>
2 parents b0a8bf4 + c63962b commit 945564b

File tree

91 files changed

+1031
-443
lines changed

Some content is hidden

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

91 files changed

+1031
-443
lines changed

Documentation/devicetree/bindings/display/bridge/adi,adv7533.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ properties:
8787
adi,dsi-lanes:
8888
description: Number of DSI data lanes connected to the DSI host.
8989
$ref: /schemas/types.yaml#/definitions/uint32
90-
enum: [ 1, 2, 3, 4 ]
90+
enum: [ 2, 3, 4 ]
9191

9292
ports:
9393
description:

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 = 6
33
PATCHLEVEL = 1
4-
SUBLEVEL = 123
4+
SUBLEVEL = 124
55
EXTRAVERSION =
66
NAME = Curry Ramen
77

arch/arc/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
KBUILD_DEFCONFIG := haps_hs_smp_defconfig
77

88
ifeq ($(CROSS_COMPILE),)
9-
CROSS_COMPILE := $(call cc-cross-prefix, arc-linux- arceb-linux-)
9+
CROSS_COMPILE := $(call cc-cross-prefix, arc-linux- arceb-linux- arc-linux-gnu-)
1010
endif
1111

1212
cflags-y += -fno-common -pipe -fno-builtin -mmedium-calls -D__linux__

arch/x86/kernel/cpu/mshyperv.c

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,63 @@ static void hv_machine_crash_shutdown(struct pt_regs *regs)
152152
hyperv_cleanup();
153153
}
154154
#endif /* CONFIG_KEXEC_CORE */
155+
156+
static u64 hv_ref_counter_at_suspend;
157+
static void (*old_save_sched_clock_state)(void);
158+
static void (*old_restore_sched_clock_state)(void);
159+
160+
/*
161+
* Hyper-V clock counter resets during hibernation. Save and restore clock
162+
* offset during suspend/resume, while also considering the time passed
163+
* before suspend. This is to make sure that sched_clock using hv tsc page
164+
* based clocksource, proceeds from where it left off during suspend and
165+
* it shows correct time for the timestamps of kernel messages after resume.
166+
*/
167+
static void save_hv_clock_tsc_state(void)
168+
{
169+
hv_ref_counter_at_suspend = hv_read_reference_counter();
170+
}
171+
172+
static void restore_hv_clock_tsc_state(void)
173+
{
174+
/*
175+
* Adjust the offsets used by hv tsc clocksource to
176+
* account for the time spent before hibernation.
177+
* adjusted value = reference counter (time) at suspend
178+
* - reference counter (time) now.
179+
*/
180+
hv_adj_sched_clock_offset(hv_ref_counter_at_suspend - hv_read_reference_counter());
181+
}
182+
183+
/*
184+
* Functions to override save_sched_clock_state and restore_sched_clock_state
185+
* functions of x86_platform. The Hyper-V clock counter is reset during
186+
* suspend-resume and the offset used to measure time needs to be
187+
* corrected, post resume.
188+
*/
189+
static void hv_save_sched_clock_state(void)
190+
{
191+
old_save_sched_clock_state();
192+
save_hv_clock_tsc_state();
193+
}
194+
195+
static void hv_restore_sched_clock_state(void)
196+
{
197+
restore_hv_clock_tsc_state();
198+
old_restore_sched_clock_state();
199+
}
200+
201+
static void __init x86_setup_ops_for_tsc_pg_clock(void)
202+
{
203+
if (!(ms_hyperv.features & HV_MSR_REFERENCE_TSC_AVAILABLE))
204+
return;
205+
206+
old_save_sched_clock_state = x86_platform.save_sched_clock_state;
207+
x86_platform.save_sched_clock_state = hv_save_sched_clock_state;
208+
209+
old_restore_sched_clock_state = x86_platform.restore_sched_clock_state;
210+
x86_platform.restore_sched_clock_state = hv_restore_sched_clock_state;
211+
}
155212
#endif /* CONFIG_HYPERV */
156213

157214
static uint32_t __init ms_hyperv_platform(void)
@@ -454,6 +511,7 @@ static void __init ms_hyperv_init_platform(void)
454511

455512
/* Register Hyper-V specific clocksource */
456513
hv_init_clocksource();
514+
x86_setup_ops_for_tsc_pg_clock();
457515
#endif
458516
/*
459517
* TSC should be marked as unstable only after Hyper-V

drivers/block/zram/zram_drv.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1733,7 +1733,8 @@ static void zram_reset_device(struct zram *zram)
17331733
zram_meta_free(zram, zram->disksize);
17341734
zram->disksize = 0;
17351735
memset(&zram->stats, 0, sizeof(zram->stats));
1736-
zcomp_destroy(zram->comp);
1736+
if (zram->comp)
1737+
zcomp_destroy(zram->comp);
17371738
zram->comp = NULL;
17381739
reset_bdev(zram);
17391740

drivers/clocksource/hyperv_timer.c

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@
2727
#include <asm/mshyperv.h>
2828

2929
static struct clock_event_device __percpu *hv_clock_event;
30-
static u64 hv_sched_clock_offset __ro_after_init;
30+
/* Note: offset can hold negative values after hibernation. */
31+
static u64 hv_sched_clock_offset __read_mostly;
3132

3233
/*
3334
* If false, we're using the old mechanism for stimer0 interrupts
@@ -417,6 +418,17 @@ static void resume_hv_clock_tsc(struct clocksource *arg)
417418
hv_set_register(HV_REGISTER_REFERENCE_TSC, tsc_msr.as_uint64);
418419
}
419420

421+
/*
422+
* Called during resume from hibernation, from overridden
423+
* x86_platform.restore_sched_clock_state routine. This is to adjust offsets
424+
* used to calculate time for hv tsc page based sched_clock, to account for
425+
* time spent before hibernation.
426+
*/
427+
void hv_adj_sched_clock_offset(u64 offset)
428+
{
429+
hv_sched_clock_offset -= offset;
430+
}
431+
420432
#ifdef HAVE_VDSO_CLOCKMODE_HVCLOCK
421433
static int hv_cs_enable(struct clocksource *cs)
422434
{

drivers/gpu/drm/amd/amdkfd/kfd_migrate.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ svm_migrate_copy_to_vram(struct amdgpu_device *adev, struct svm_range *prange,
324324
spage = migrate_pfn_to_page(migrate->src[i]);
325325
if (spage && !is_zone_device_page(spage)) {
326326
src[i] = dma_map_page(dev, spage, 0, PAGE_SIZE,
327-
DMA_TO_DEVICE);
327+
DMA_BIDIRECTIONAL);
328328
r = dma_mapping_error(dev, src[i]);
329329
if (r) {
330330
dev_err(adev->dev, "%s: fail %d dma_map_page\n",
@@ -623,7 +623,7 @@ svm_migrate_copy_to_ram(struct amdgpu_device *adev, struct svm_range *prange,
623623
goto out_oom;
624624
}
625625

626-
dst[i] = dma_map_page(dev, dpage, 0, PAGE_SIZE, DMA_FROM_DEVICE);
626+
dst[i] = dma_map_page(dev, dpage, 0, PAGE_SIZE, DMA_BIDIRECTIONAL);
627627
r = dma_mapping_error(dev, dst[i]);
628628
if (r) {
629629
dev_err(adev->dev, "%s: fail %d dma_map_page\n", __func__, r);

drivers/gpu/drm/bridge/adv7511/adv7511_audio.c

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,16 @@ static int adv7511_hdmi_hw_params(struct device *dev, void *data,
153153
ADV7511_AUDIO_CFG3_LEN_MASK, len);
154154
regmap_update_bits(adv7511->regmap, ADV7511_REG_I2C_FREQ_ID_CFG,
155155
ADV7511_I2C_FREQ_ID_CFG_RATE_MASK, rate << 4);
156-
regmap_write(adv7511->regmap, 0x73, 0x1);
156+
157+
/* send current Audio infoframe values while updating */
158+
regmap_update_bits(adv7511->regmap, ADV7511_REG_INFOFRAME_UPDATE,
159+
BIT(5), BIT(5));
160+
161+
regmap_write(adv7511->regmap, ADV7511_REG_AUDIO_INFOFRAME(0), 0x1);
162+
163+
/* use Audio infoframe updated info */
164+
regmap_update_bits(adv7511->regmap, ADV7511_REG_INFOFRAME_UPDATE,
165+
BIT(5), 0);
157166

158167
return 0;
159168
}
@@ -184,8 +193,9 @@ static int audio_startup(struct device *dev, void *data)
184193
regmap_update_bits(adv7511->regmap, ADV7511_REG_GC(0),
185194
BIT(7) | BIT(6), BIT(7));
186195
/* use Audio infoframe updated info */
187-
regmap_update_bits(adv7511->regmap, ADV7511_REG_GC(1),
196+
regmap_update_bits(adv7511->regmap, ADV7511_REG_INFOFRAME_UPDATE,
188197
BIT(5), 0);
198+
189199
/* enable SPDIF receiver */
190200
if (adv7511->audio_source == ADV7511_AUDIO_SOURCE_SPDIF)
191201
regmap_update_bits(adv7511->regmap, ADV7511_REG_AUDIO_CONFIG,

drivers/gpu/drm/bridge/adv7511/adv7533.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ int adv7533_parse_dt(struct device_node *np, struct adv7511 *adv)
179179

180180
of_property_read_u32(np, "adi,dsi-lanes", &num_lanes);
181181

182-
if (num_lanes < 1 || num_lanes > 4)
182+
if (num_lanes < 2 || num_lanes > 4)
183183
return -EINVAL;
184184

185185
adv->num_dsi_lanes = num_lanes;

drivers/gpu/drm/i915/gt/intel_rc6.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ static void gen11_rc6_enable(struct intel_rc6 *rc6)
134134
GEN9_MEDIA_PG_ENABLE |
135135
GEN11_MEDIA_SAMPLER_PG_ENABLE;
136136

137-
if (GRAPHICS_VER(gt->i915) >= 12) {
137+
if (GRAPHICS_VER(gt->i915) >= 12 && !IS_DG1(gt->i915)) {
138138
for (i = 0; i < I915_MAX_VCS; i++)
139139
if (HAS_ENGINE(gt, _VCS(i)))
140140
pg_enable |= (VDN_HCP_POWERGATE_ENABLE(i) |

0 commit comments

Comments
 (0)