Skip to content
This repository was archived by the owner on Oct 31, 2024. It is now read-only.

Commit 7c69258

Browse files
committed
Merge tag 'v6.6.42' into 6.6
This is the 6.6.42 stable release
2 parents cc6b5f1 + 31cf7eb commit 7c69258

File tree

144 files changed

+1167
-567
lines changed

Some content is hidden

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

144 files changed

+1167
-567
lines changed

Documentation/cdrom/cdrom-standard.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ current *struct* is::
217217
int (*media_changed)(struct cdrom_device_info *, int);
218218
int (*tray_move)(struct cdrom_device_info *, int);
219219
int (*lock_door)(struct cdrom_device_info *, int);
220-
int (*select_speed)(struct cdrom_device_info *, int);
220+
int (*select_speed)(struct cdrom_device_info *, unsigned long);
221221
int (*get_last_session) (struct cdrom_device_info *,
222222
struct cdrom_multisession *);
223223
int (*get_mcn)(struct cdrom_device_info *, struct cdrom_mcn *);
@@ -396,7 +396,7 @@ action need be taken, and the return value should be 0.
396396

397397
::
398398

399-
int select_speed(struct cdrom_device_info *cdi, int speed)
399+
int select_speed(struct cdrom_device_info *cdi, unsigned long speed)
400400

401401
Some CD-ROM drives are capable of changing their head-speed. There
402402
are several reasons for changing the speed of a CD-ROM drive. Badly

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 = 6
4-
SUBLEVEL = 41
4+
SUBLEVEL = 42
55
EXTRAVERSION =
66
NAME = Hurr durr I'ma ninja sloth
77

arch/arm/include/asm/uaccess.h

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -109,24 +109,14 @@ extern int __get_user_64t_1(void *);
109109
extern int __get_user_64t_2(void *);
110110
extern int __get_user_64t_4(void *);
111111

112-
#define __GUP_CLOBBER_1 "lr", "cc"
113-
#ifdef CONFIG_CPU_USE_DOMAINS
114-
#define __GUP_CLOBBER_2 "ip", "lr", "cc"
115-
#else
116-
#define __GUP_CLOBBER_2 "lr", "cc"
117-
#endif
118-
#define __GUP_CLOBBER_4 "lr", "cc"
119-
#define __GUP_CLOBBER_32t_8 "lr", "cc"
120-
#define __GUP_CLOBBER_8 "lr", "cc"
121-
122112
#define __get_user_x(__r2, __p, __e, __l, __s) \
123113
__asm__ __volatile__ ( \
124114
__asmeq("%0", "r0") __asmeq("%1", "r2") \
125115
__asmeq("%3", "r1") \
126116
"bl __get_user_" #__s \
127117
: "=&r" (__e), "=r" (__r2) \
128118
: "0" (__p), "r" (__l) \
129-
: __GUP_CLOBBER_##__s)
119+
: "ip", "lr", "cc")
130120

131121
/* narrowing a double-word get into a single 32bit word register: */
132122
#ifdef __ARMEB__
@@ -148,7 +138,7 @@ extern int __get_user_64t_4(void *);
148138
"bl __get_user_64t_" #__s \
149139
: "=&r" (__e), "=r" (__r2) \
150140
: "0" (__p), "r" (__l) \
151-
: __GUP_CLOBBER_##__s)
141+
: "ip", "lr", "cc")
152142
#else
153143
#define __get_user_x_64t __get_user_x
154144
#endif

arch/arm64/kernel/armv8_deprecated.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -464,6 +464,9 @@ static int run_all_insn_set_hw_mode(unsigned int cpu)
464464
for (int i = 0; i < ARRAY_SIZE(insn_emulations); i++) {
465465
struct insn_emulation *insn = insn_emulations[i];
466466
bool enable = READ_ONCE(insn->current_mode) == INSN_HW;
467+
if (insn->status == INSN_UNAVAILABLE)
468+
continue;
469+
467470
if (insn->set_hw_mode && insn->set_hw_mode(enable)) {
468471
pr_warn("CPU[%u] cannot support the emulation of %s",
469472
cpu, insn->name);

arch/mips/kernel/syscalls/syscall_o32.tbl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
17 o32 break sys_ni_syscall
2828
# 18 was sys_stat
2929
18 o32 unused18 sys_ni_syscall
30-
19 o32 lseek sys_lseek
30+
19 o32 lseek sys_lseek compat_sys_lseek
3131
20 o32 getpid sys_getpid
3232
21 o32 mount sys_mount
3333
22 o32 umount sys_oldumount

arch/powerpc/kernel/eeh_pe.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -849,6 +849,7 @@ struct pci_bus *eeh_pe_bus_get(struct eeh_pe *pe)
849849
{
850850
struct eeh_dev *edev;
851851
struct pci_dev *pdev;
852+
struct pci_bus *bus = NULL;
852853

853854
if (pe->type & EEH_PE_PHB)
854855
return pe->phb->bus;
@@ -859,9 +860,11 @@ struct pci_bus *eeh_pe_bus_get(struct eeh_pe *pe)
859860

860861
/* Retrieve the parent PCI bus of first (top) PCI device */
861862
edev = list_first_entry_or_null(&pe->edevs, struct eeh_dev, entry);
863+
pci_lock_rescan_remove();
862864
pdev = eeh_dev_to_pci_dev(edev);
863865
if (pdev)
864-
return pdev->bus;
866+
bus = pdev->bus;
867+
pci_unlock_rescan_remove();
865868

866-
return NULL;
869+
return bus;
867870
}

arch/powerpc/kvm/book3s_64_vio.c

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,14 +129,16 @@ extern long kvm_spapr_tce_attach_iommu_group(struct kvm *kvm, int tablefd,
129129
}
130130
rcu_read_unlock();
131131

132-
fdput(f);
133-
134-
if (!found)
132+
if (!found) {
133+
fdput(f);
135134
return -EINVAL;
135+
}
136136

137137
table_group = iommu_group_get_iommudata(grp);
138-
if (WARN_ON(!table_group))
138+
if (WARN_ON(!table_group)) {
139+
fdput(f);
139140
return -EFAULT;
141+
}
140142

141143
for (i = 0; i < IOMMU_TABLE_GROUP_MAX_TABLES; ++i) {
142144
struct iommu_table *tbltmp = table_group->tables[i];
@@ -157,8 +159,10 @@ extern long kvm_spapr_tce_attach_iommu_group(struct kvm *kvm, int tablefd,
157159
break;
158160
}
159161
}
160-
if (!tbl)
162+
if (!tbl) {
163+
fdput(f);
161164
return -EINVAL;
165+
}
162166

163167
rcu_read_lock();
164168
list_for_each_entry_rcu(stit, &stt->iommu_tables, next) {
@@ -169,20 +173,23 @@ extern long kvm_spapr_tce_attach_iommu_group(struct kvm *kvm, int tablefd,
169173
/* stit is being destroyed */
170174
iommu_tce_table_put(tbl);
171175
rcu_read_unlock();
176+
fdput(f);
172177
return -ENOTTY;
173178
}
174179
/*
175180
* The table is already known to this KVM, we just increased
176181
* its KVM reference counter and can return.
177182
*/
178183
rcu_read_unlock();
184+
fdput(f);
179185
return 0;
180186
}
181187
rcu_read_unlock();
182188

183189
stit = kzalloc(sizeof(*stit), GFP_KERNEL);
184190
if (!stit) {
185191
iommu_tce_table_put(tbl);
192+
fdput(f);
186193
return -ENOMEM;
187194
}
188195

@@ -191,6 +198,7 @@ extern long kvm_spapr_tce_attach_iommu_group(struct kvm *kvm, int tablefd,
191198

192199
list_add_rcu(&stit->next, &stt->iommu_tables);
193200

201+
fdput(f);
194202
return 0;
195203
}
196204

arch/powerpc/platforms/pseries/setup.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -343,8 +343,8 @@ static int alloc_dispatch_log_kmem_cache(void)
343343
{
344344
void (*ctor)(void *) = get_dtl_cache_ctor();
345345

346-
dtl_cache = kmem_cache_create("dtl", DISPATCH_LOG_BYTES,
347-
DISPATCH_LOG_BYTES, 0, ctor);
346+
dtl_cache = kmem_cache_create_usercopy("dtl", DISPATCH_LOG_BYTES,
347+
DISPATCH_LOG_BYTES, 0, 0, DISPATCH_LOG_BYTES, ctor);
348348
if (!dtl_cache) {
349349
pr_warn("Failed to create dispatch trace log buffer cache\n");
350350
pr_warn("Stolen time statistics will be unreliable\n");

arch/riscv/kernel/stacktrace.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ void notrace walk_stackframe(struct task_struct *task, struct pt_regs *regs,
3232
bool (*fn)(void *, unsigned long), void *arg)
3333
{
3434
unsigned long fp, sp, pc;
35+
int graph_idx = 0;
3536
int level = 0;
3637

3738
if (regs) {
@@ -68,7 +69,7 @@ void notrace walk_stackframe(struct task_struct *task, struct pt_regs *regs,
6869
pc = regs->ra;
6970
} else {
7071
fp = frame->fp;
71-
pc = ftrace_graph_ret_addr(current, NULL, frame->ra,
72+
pc = ftrace_graph_ret_addr(current, &graph_idx, frame->ra,
7273
&frame->ra);
7374
if (pc == (unsigned long)ret_from_exception) {
7475
if (unlikely(!__kernel_text_address(pc) || !fn(arg, pc)))

drivers/acpi/ec.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1333,10 +1333,13 @@ acpi_ec_space_handler(u32 function, acpi_physical_address address,
13331333
if (ec->busy_polling || bits > 8)
13341334
acpi_ec_burst_enable(ec);
13351335

1336-
for (i = 0; i < bytes; ++i, ++address, ++value)
1336+
for (i = 0; i < bytes; ++i, ++address, ++value) {
13371337
result = (function == ACPI_READ) ?
13381338
acpi_ec_read(ec, address, value) :
13391339
acpi_ec_write(ec, address, *value);
1340+
if (result < 0)
1341+
break;
1342+
}
13401343

13411344
if (ec->busy_polling || bits > 8)
13421345
acpi_ec_burst_disable(ec);
@@ -1348,8 +1351,10 @@ acpi_ec_space_handler(u32 function, acpi_physical_address address,
13481351
return AE_NOT_FOUND;
13491352
case -ETIME:
13501353
return AE_TIME;
1351-
default:
1354+
case 0:
13521355
return AE_OK;
1356+
default:
1357+
return AE_ERROR;
13531358
}
13541359
}
13551360

drivers/block/null_blk/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2013,8 +2013,8 @@ static int null_validate_conf(struct nullb_device *dev)
20132013
return -EINVAL;
20142014
}
20152015

2016-
dev->blocksize = round_down(dev->blocksize, 512);
2017-
dev->blocksize = clamp_t(unsigned int, dev->blocksize, 512, 4096);
2016+
if (blk_validate_block_size(dev->blocksize))
2017+
return -EINVAL;
20182018

20192019
if (dev->queue_mode == NULL_Q_MQ && dev->use_per_node_hctx) {
20202020
if (dev->submit_queues != nr_online_nodes)

drivers/bluetooth/btnxpuart.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ static u8 crc8_table[CRC8_TABLE_SIZE];
280280

281281
/* Default configurations */
282282
#define DEFAULT_H2C_WAKEUP_MODE WAKEUP_METHOD_BREAK
283-
#define DEFAULT_PS_MODE PS_MODE_DISABLE
283+
#define DEFAULT_PS_MODE PS_MODE_ENABLE
284284
#define FW_INIT_BAUDRATE HCI_NXP_PRI_BAUDRATE
285285

286286
static struct sk_buff *nxp_drv_send_cmd(struct hci_dev *hdev, u16 opcode,

drivers/firmware/efi/libstub/zboot.lds

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ SECTIONS
4141
}
4242

4343
/DISCARD/ : {
44+
*(.discard .discard.*)
4445
*(.modinfo .init.modinfo)
4546
}
4647
}

drivers/gpio/gpio-pca953x.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -766,6 +766,8 @@ static void pca953x_irq_bus_sync_unlock(struct irq_data *d)
766766
int level;
767767

768768
if (chip->driver_data & PCA_PCAL) {
769+
guard(mutex)(&chip->i2c_lock);
770+
769771
/* Enable latch on interrupt-enabled inputs */
770772
pca953x_write_regs(chip, PCAL953X_IN_LATCH, chip->irq_mask);
771773

drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4290,9 +4290,10 @@ static u32 gfx_v9_4_3_get_cu_active_bitmap(struct amdgpu_device *adev, int xcc_i
42904290
static int gfx_v9_4_3_get_cu_info(struct amdgpu_device *adev,
42914291
struct amdgpu_cu_info *cu_info)
42924292
{
4293-
int i, j, k, counter, xcc_id, active_cu_number = 0;
4294-
u32 mask, bitmap, ao_bitmap, ao_cu_mask = 0;
4293+
int i, j, k, prev_counter, counter, xcc_id, active_cu_number = 0;
4294+
u32 mask, bitmap, ao_bitmap, ao_cu_mask = 0, tmp;
42954295
unsigned disable_masks[4 * 4];
4296+
bool is_symmetric_cus;
42964297

42974298
if (!adev || !cu_info)
42984299
return -EINVAL;
@@ -4310,6 +4311,7 @@ static int gfx_v9_4_3_get_cu_info(struct amdgpu_device *adev,
43104311

43114312
mutex_lock(&adev->grbm_idx_mutex);
43124313
for (xcc_id = 0; xcc_id < NUM_XCC(adev->gfx.xcc_mask); xcc_id++) {
4314+
is_symmetric_cus = true;
43134315
for (i = 0; i < adev->gfx.config.max_shader_engines; i++) {
43144316
for (j = 0; j < adev->gfx.config.max_sh_per_se; j++) {
43154317
mask = 1;
@@ -4337,6 +4339,15 @@ static int gfx_v9_4_3_get_cu_info(struct amdgpu_device *adev,
43374339
ao_cu_mask |= (ao_bitmap << (i * 16 + j * 8));
43384340
cu_info->ao_cu_bitmap[i][j] = ao_bitmap;
43394341
}
4342+
if (i && is_symmetric_cus && prev_counter != counter)
4343+
is_symmetric_cus = false;
4344+
prev_counter = counter;
4345+
}
4346+
if (is_symmetric_cus) {
4347+
tmp = RREG32_SOC15(GC, GET_INST(GC, xcc_id), regCP_CPC_DEBUG);
4348+
tmp = REG_SET_FIELD(tmp, CP_CPC_DEBUG, CPC_HARVESTING_RELAUNCH_DISABLE, 1);
4349+
tmp = REG_SET_FIELD(tmp, CP_CPC_DEBUG, CPC_HARVESTING_DISPATCH_DISABLE, 1);
4350+
WREG32_SOC15(GC, GET_INST(GC, xcc_id), regCP_CPC_DEBUG, tmp);
43404351
}
43414352
gfx_v9_4_3_xcc_select_se_sh(adev, 0xffffffff, 0xffffffff, 0xffffffff,
43424353
xcc_id);

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

Lines changed: 51 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10630,6 +10630,49 @@ static bool parse_edid_cea(struct amdgpu_dm_connector *aconnector,
1063010630
return ret;
1063110631
}
1063210632

10633+
static void parse_edid_displayid_vrr(struct drm_connector *connector,
10634+
struct edid *edid)
10635+
{
10636+
u8 *edid_ext = NULL;
10637+
int i;
10638+
int j = 0;
10639+
u16 min_vfreq;
10640+
u16 max_vfreq;
10641+
10642+
if (edid == NULL || edid->extensions == 0)
10643+
return;
10644+
10645+
/* Find DisplayID extension */
10646+
for (i = 0; i < edid->extensions; i++) {
10647+
edid_ext = (void *)(edid + (i + 1));
10648+
if (edid_ext[0] == DISPLAYID_EXT)
10649+
break;
10650+
}
10651+
10652+
if (edid_ext == NULL)
10653+
return;
10654+
10655+
while (j < EDID_LENGTH) {
10656+
/* Get dynamic video timing range from DisplayID if available */
10657+
if (EDID_LENGTH - j > 13 && edid_ext[j] == 0x25 &&
10658+
(edid_ext[j+1] & 0xFE) == 0 && (edid_ext[j+2] == 9)) {
10659+
min_vfreq = edid_ext[j+9];
10660+
if (edid_ext[j+1] & 7)
10661+
max_vfreq = edid_ext[j+10] + ((edid_ext[j+11] & 3) << 8);
10662+
else
10663+
max_vfreq = edid_ext[j+10];
10664+
10665+
if (max_vfreq && min_vfreq) {
10666+
connector->display_info.monitor_range.max_vfreq = max_vfreq;
10667+
connector->display_info.monitor_range.min_vfreq = min_vfreq;
10668+
10669+
return;
10670+
}
10671+
}
10672+
j++;
10673+
}
10674+
}
10675+
1063310676
static int parse_amd_vsdb(struct amdgpu_dm_connector *aconnector,
1063410677
struct edid *edid, struct amdgpu_hdmi_vsdb_info *vsdb_info)
1063510678
{
@@ -10752,16 +10795,23 @@ void amdgpu_dm_update_freesync_caps(struct drm_connector *connector,
1075210795
if (!adev->dm.freesync_module)
1075310796
goto update;
1075410797

10798+
/* Some eDP panels only have the refresh rate range info in DisplayID */
10799+
if ((connector->display_info.monitor_range.min_vfreq == 0 ||
10800+
connector->display_info.monitor_range.max_vfreq == 0))
10801+
parse_edid_displayid_vrr(connector, edid);
10802+
1075510803
if (edid && (sink->sink_signal == SIGNAL_TYPE_DISPLAY_PORT ||
1075610804
sink->sink_signal == SIGNAL_TYPE_EDP)) {
1075710805
bool edid_check_required = false;
1075810806

1075910807
if (is_dp_capable_without_timing_msa(adev->dm.dc,
1076010808
amdgpu_dm_connector)) {
1076110809
if (edid->features & DRM_EDID_FEATURE_CONTINUOUS_FREQ) {
10762-
freesync_capable = true;
1076310810
amdgpu_dm_connector->min_vfreq = connector->display_info.monitor_range.min_vfreq;
1076410811
amdgpu_dm_connector->max_vfreq = connector->display_info.monitor_range.max_vfreq;
10812+
if (amdgpu_dm_connector->max_vfreq -
10813+
amdgpu_dm_connector->min_vfreq > 10)
10814+
freesync_capable = true;
1076510815
} else {
1076610816
edid_check_required = edid->version > 1 ||
1076710817
(edid->version == 1 &&

drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_32.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3364,6 +3364,9 @@ void dml32_ModeSupportAndSystemConfigurationFull(struct display_mode_lib *mode_l
33643364
&mode_lib->vba.UrgentBurstFactorLumaPre[k],
33653365
&mode_lib->vba.UrgentBurstFactorChromaPre[k],
33663366
&mode_lib->vba.NotUrgentLatencyHidingPre[k]);
3367+
3368+
v->cursor_bw_pre[k] = mode_lib->vba.NumberOfCursors[k] * mode_lib->vba.CursorWidth[k][0] * mode_lib->vba.CursorBPP[k][0] /
3369+
8.0 / (mode_lib->vba.HTotal[k] / mode_lib->vba.PixelClock[k]) * v->VRatioPreY[i][j][k];
33673370
}
33683371

33693372
{

drivers/gpu/drm/drm_panel_orientation_quirks.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,12 @@ static const struct dmi_system_id orientation_data[] = {
202202
DMI_MATCH(DMI_BOARD_NAME, "NEXT"),
203203
},
204204
.driver_data = (void *)&lcd800x1280_rightside_up,
205+
}, { /* AYA NEO KUN */
206+
.matches = {
207+
DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "AYANEO"),
208+
DMI_MATCH(DMI_BOARD_NAME, "KUN"),
209+
},
210+
.driver_data = (void *)&lcd1600x2560_rightside_up,
205211
}, { /* Chuwi HiBook (CWI514) */
206212
.matches = {
207213
DMI_MATCH(DMI_BOARD_VENDOR, "Hampoo"),

0 commit comments

Comments
 (0)