Skip to content

Commit

Permalink
Merge tag 'v4.19.286' into 4.19-main
Browse files Browse the repository at this point in the history
This is the 4.19.286 stable release

# -----BEGIN PGP SIGNATURE-----
#
# iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmSJgPQACgkQONu9yGCS
# aT4W0hAAglgQC8Y56QZhtPj7HS6M/Kgxu7TN/1Ob26xirtjcmJX6he4xKVTdBt4u
# dWxhpEZqXmtzwGEBeg2aBAUuuzIsKHdroBWTJ3aNnuVBpdsoE7gHYiTrN+wNvI2U
# e3rO3auf7wXZddP87+61w1Dt1yRwKwLHZwA0vLwQ4qtcKedSV2SxKCRO6CG2+xmK
# Dtc/0krwQgwYbbkQ1fHiO/5xBIAXH9mj0Jf963xZMZdxRiGRt4JWzSOyE8V0zOBK
# pq2QDink2pddfljEMOWbNNcFQISUiPlCf9W+L2aATN7Q6kvRp89XXnUlLZVjGgN3
# 6viaikupLw4zEWKAQJOts+vePd463rNf6EUAW7O9Q/jfFaH9s/9LLvm6gcVB7rCW
# MdebTixleJKCkIFXtm5udzPwcLPWa4i4IfuD75HJ5HMAsFQDW2kzH994vNpzjxAr
# R/WTWUL5yw6pTwwHJNcYqdYOixDtV04nEzF8WW5Y41djEdmUPgCZb/EW0MERVgNg
# L8oAuhL0IQOXdTPf+H+awb11FjbCGtqWbyFBoOdZ98/IjM2qb1kYFPqaYtgjDoRT
# d3FDX9Cf5r9gd0Y4X5AHVEMSBXlYcRQYcYPqoPf4EziFXWOLEyiMNMn7TR4cg+J4
# axmpX38lH1kgne12helxfcBrYErnkvLOkacrnOW6kc723Vob2Ok=
# =Vo4F
# -----END PGP SIGNATURE-----
# gpg: Signature made Wed Jun 14 10:57:24 2023 CEST
# gpg:                using RSA key 647F28654894E3BD457199BE38DBBDC86092693E
# gpg: Can't check signature: No public key
  • Loading branch information
frank-w committed Jun 19, 2023
2 parents 2518d01 + c111487 commit 422d868
Show file tree
Hide file tree
Showing 25 changed files with 121 additions and 74 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: GPL-2.0
VERSION = 4
PATCHLEVEL = 19
SUBLEVEL = 285
SUBLEVEL = 286
EXTRAVERSION =
NAME = "People's Front"

Expand Down
11 changes: 9 additions & 2 deletions drivers/gpu/drm/amd/amdgpu/vi.c
Original file line number Diff line number Diff line change
Expand Up @@ -328,8 +328,15 @@ static u32 vi_get_xclk(struct amdgpu_device *adev)
u32 reference_clock = adev->clock.spll.reference_freq;
u32 tmp;

if (adev->flags & AMD_IS_APU)
return reference_clock;
if (adev->flags & AMD_IS_APU) {
switch (adev->asic_type) {
case CHIP_STONEY:
/* vbios says 48Mhz, but the actual freq is 100Mhz */
return 10000;
default:
return reference_clock;
}
}

tmp = RREG32_SMC(ixCG_CLKPIN_CNTL_2);
if (REG_GET_FIELD(tmp, CG_CLKPIN_CNTL_2, MUX_TCLK_TO_XCLK))
Expand Down
6 changes: 4 additions & 2 deletions drivers/i2c/busses/i2c-sprd.c
Original file line number Diff line number Diff line change
Expand Up @@ -581,10 +581,12 @@ static int sprd_i2c_remove(struct platform_device *pdev)

ret = pm_runtime_get_sync(i2c_dev->dev);
if (ret < 0)
return ret;
dev_err(&pdev->dev, "Failed to resume device (%pe)\n", ERR_PTR(ret));

i2c_del_adapter(&i2c_dev->adap);
clk_disable_unprepare(i2c_dev->clk);

if (ret >= 0)
clk_disable_unprepare(i2c_dev->clk);

pm_runtime_put_noidle(i2c_dev->dev);
pm_runtime_disable(i2c_dev->dev);
Expand Down
5 changes: 2 additions & 3 deletions drivers/infiniband/hw/i40iw/i40iw.h
Original file line number Diff line number Diff line change
Expand Up @@ -411,9 +411,8 @@ void i40iw_manage_arp_cache(struct i40iw_device *iwdev,
bool ipv4,
u32 action);

int i40iw_manage_apbvt(struct i40iw_device *iwdev,
u16 accel_local_port,
bool add_port);
enum i40iw_status_code i40iw_manage_apbvt(struct i40iw_device *iwdev,
u16 accel_local_port, bool add_port);

struct i40iw_cqp_request *i40iw_get_cqp_request(struct i40iw_cqp *cqp, bool wait);
void i40iw_free_cqp_request(struct i40iw_cqp *cqp, struct i40iw_cqp_request *cqp_request);
Expand Down
1 change: 0 additions & 1 deletion drivers/input/joystick/xpad.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,6 @@ static const struct xpad_device {
{ 0x1430, 0xf801, "RedOctane Controller", 0, XTYPE_XBOX360 },
{ 0x146b, 0x0601, "BigBen Interactive XBOX 360 Controller", 0, XTYPE_XBOX360 },
{ 0x146b, 0x0604, "Bigben Interactive DAIJA Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 },
{ 0x1532, 0x0037, "Razer Sabertooth", 0, XTYPE_XBOX360 },
{ 0x1532, 0x0a00, "Razer Atrox Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE },
{ 0x1532, 0x0a03, "Razer Wildcat", 0, XTYPE_XBOXONE },
{ 0x15e4, 0x3f00, "Power A Mini Pro Elite", 0, XTYPE_XBOX360 },
Expand Down
9 changes: 5 additions & 4 deletions drivers/input/mouse/elantech.c
Original file line number Diff line number Diff line change
Expand Up @@ -590,10 +590,11 @@ static void process_packet_head_v4(struct psmouse *psmouse)
struct input_dev *dev = psmouse->dev;
struct elantech_data *etd = psmouse->private;
unsigned char *packet = psmouse->packet;
int id = ((packet[3] & 0xe0) >> 5) - 1;
int id;
int pres, traces;

if (id < 0)
id = ((packet[3] & 0xe0) >> 5) - 1;
if (id < 0 || id >= ETP_MAX_FINGERS)
return;

etd->mt[id].x = ((packet[1] & 0x0f) << 8) | packet[2];
Expand Down Expand Up @@ -623,7 +624,7 @@ static void process_packet_motion_v4(struct psmouse *psmouse)
int id, sid;

id = ((packet[0] & 0xe0) >> 5) - 1;
if (id < 0)
if (id < 0 || id >= ETP_MAX_FINGERS)
return;

sid = ((packet[3] & 0xe0) >> 5) - 1;
Expand All @@ -644,7 +645,7 @@ static void process_packet_motion_v4(struct psmouse *psmouse)
input_report_abs(dev, ABS_MT_POSITION_X, etd->mt[id].x);
input_report_abs(dev, ABS_MT_POSITION_Y, etd->mt[id].y);

if (sid >= 0) {
if (sid >= 0 && sid < ETP_MAX_FINGERS) {
etd->mt[sid].x += delta_x2 * weight;
etd->mt[sid].y -= delta_y2 * weight;
input_mt_slot(dev, sid);
Expand Down
4 changes: 0 additions & 4 deletions drivers/net/dsa/lan9303-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1191,8 +1191,6 @@ static int lan9303_port_fdb_add(struct dsa_switch *ds, int port,
struct lan9303 *chip = ds->priv;

dev_dbg(chip->dev, "%s(%d, %pM, %d)\n", __func__, port, addr, vid);
if (vid)
return -EOPNOTSUPP;

return lan9303_alr_add_port(chip, addr, port, false);
}
Expand All @@ -1204,8 +1202,6 @@ static int lan9303_port_fdb_del(struct dsa_switch *ds, int port,
struct lan9303 *chip = ds->priv;

dev_dbg(chip->dev, "%s(%d, %pM, %d)\n", __func__, port, addr, vid);
if (vid)
return -EOPNOTSUPP;
lan9303_alr_del_port(chip, addr, port);

return 0;
Expand Down
17 changes: 6 additions & 11 deletions drivers/net/ethernet/intel/i40e/i40e_alloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,11 @@ enum i40e_memory_type {
};

/* prototype for functions used for dynamic memory allocation */
i40e_status i40e_allocate_dma_mem(struct i40e_hw *hw,
struct i40e_dma_mem *mem,
enum i40e_memory_type type,
u64 size, u32 alignment);
i40e_status i40e_free_dma_mem(struct i40e_hw *hw,
struct i40e_dma_mem *mem);
i40e_status i40e_allocate_virt_mem(struct i40e_hw *hw,
struct i40e_virt_mem *mem,
u32 size);
i40e_status i40e_free_virt_mem(struct i40e_hw *hw,
struct i40e_virt_mem *mem);
int i40e_allocate_dma_mem(struct i40e_hw *hw, struct i40e_dma_mem *mem,
enum i40e_memory_type type, u64 size, u32 alignment);
int i40e_free_dma_mem(struct i40e_hw *hw, struct i40e_dma_mem *mem);
int i40e_allocate_virt_mem(struct i40e_hw *hw, struct i40e_virt_mem *mem,
u32 size);
int i40e_free_virt_mem(struct i40e_hw *hw, struct i40e_virt_mem *mem);

#endif /* _I40E_ALLOC_H_ */
1 change: 1 addition & 0 deletions drivers/pinctrl/meson/pinctrl-meson-axg.c
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,7 @@ static struct meson_pmx_group meson_axg_periphs_groups[] = {
GPIO_GROUP(GPIOA_15),
GPIO_GROUP(GPIOA_16),
GPIO_GROUP(GPIOA_17),
GPIO_GROUP(GPIOA_18),
GPIO_GROUP(GPIOA_19),
GPIO_GROUP(GPIOA_20),

Expand Down
37 changes: 18 additions & 19 deletions drivers/spi/spi-qup.c
Original file line number Diff line number Diff line change
Expand Up @@ -1003,23 +1003,8 @@ static int spi_qup_probe(struct platform_device *pdev)
return -ENXIO;
}

ret = clk_prepare_enable(cclk);
if (ret) {
dev_err(dev, "cannot enable core clock\n");
return ret;
}

ret = clk_prepare_enable(iclk);
if (ret) {
clk_disable_unprepare(cclk);
dev_err(dev, "cannot enable iface clock\n");
return ret;
}

master = spi_alloc_master(dev, sizeof(struct spi_qup));
if (!master) {
clk_disable_unprepare(cclk);
clk_disable_unprepare(iclk);
dev_err(dev, "cannot allocate master\n");
return -ENOMEM;
}
Expand Down Expand Up @@ -1065,6 +1050,19 @@ static int spi_qup_probe(struct platform_device *pdev)
spin_lock_init(&controller->lock);
init_completion(&controller->done);

ret = clk_prepare_enable(cclk);
if (ret) {
dev_err(dev, "cannot enable core clock\n");
goto error_dma;
}

ret = clk_prepare_enable(iclk);
if (ret) {
clk_disable_unprepare(cclk);
dev_err(dev, "cannot enable iface clock\n");
goto error_dma;
}

iomode = readl_relaxed(base + QUP_IO_M_MODES);

size = QUP_IO_M_OUTPUT_BLOCK_SIZE(iomode);
Expand Down Expand Up @@ -1094,7 +1092,7 @@ static int spi_qup_probe(struct platform_device *pdev)
ret = spi_qup_set_state(controller, QUP_STATE_RESET);
if (ret) {
dev_err(dev, "cannot set RESET state\n");
goto error_dma;
goto error_clk;
}

writel_relaxed(0, base + QUP_OPERATIONAL);
Expand All @@ -1118,7 +1116,7 @@ static int spi_qup_probe(struct platform_device *pdev)
ret = devm_request_irq(dev, irq, spi_qup_qup_irq,
IRQF_TRIGGER_HIGH, pdev->name, controller);
if (ret)
goto error_dma;
goto error_clk;

pm_runtime_set_autosuspend_delay(dev, MSEC_PER_SEC);
pm_runtime_use_autosuspend(dev);
Expand All @@ -1133,11 +1131,12 @@ static int spi_qup_probe(struct platform_device *pdev)

disable_pm:
pm_runtime_disable(&pdev->dev);
error_clk:
clk_disable_unprepare(cclk);
clk_disable_unprepare(iclk);
error_dma:
spi_qup_release_dma(master);
error:
clk_disable_unprepare(cclk);
clk_disable_unprepare(iclk);
spi_master_put(master);
return ret;
}
Expand Down
6 changes: 3 additions & 3 deletions drivers/staging/rtl8192e/rtl8192e/rtl_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@ static const struct rtl819x_ops rtl819xp_ops = {
};

static struct pci_device_id rtl8192_pci_id_tbl[] = {
{PCI_DEVICE(0x10ec, 0x8192)},
{PCI_DEVICE(0x07aa, 0x0044)},
{PCI_DEVICE(0x07aa, 0x0047)},
{RTL_PCI_DEVICE(0x10ec, 0x8192, rtl819xp_ops)},
{RTL_PCI_DEVICE(0x07aa, 0x0044, rtl819xp_ops)},
{RTL_PCI_DEVICE(0x07aa, 0x0047, rtl819xp_ops)},
{}
};

Expand Down
5 changes: 5 additions & 0 deletions drivers/staging/rtl8192e/rtl8192e/rtl_core.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@
#define IS_HARDWARE_TYPE_8192SE(_priv) \
(((struct r8192_priv *)rtllib_priv(dev))->card_8192 == NIC_8192SE)

#define RTL_PCI_DEVICE(vend, dev, cfg) \
.vendor = (vend), .device = (dev), \
.subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID, \
.driver_data = (kernel_ulong_t)&(cfg)

#define TOTAL_CAM_ENTRY 32
#define CAM_CONTENT_COUNT 8

Expand Down
14 changes: 10 additions & 4 deletions fs/btrfs/relocation.c
Original file line number Diff line number Diff line change
Expand Up @@ -2341,7 +2341,7 @@ int prepare_to_merge(struct reloc_control *rc, int err)
list_splice(&reloc_roots, &rc->reloc_roots);

if (!err)
btrfs_commit_transaction(trans);
err = btrfs_commit_transaction(trans);
else
btrfs_end_transaction(trans);
return err;
Expand Down Expand Up @@ -3930,8 +3930,12 @@ int prepare_to_relocate(struct reloc_control *rc)
*/
return PTR_ERR(trans);
}
btrfs_commit_transaction(trans);
return 0;

ret = btrfs_commit_transaction(trans);
if (ret)
unset_reloc_control(rc);

return ret;
}

static noinline_for_stack int relocate_block_group(struct reloc_control *rc)
Expand Down Expand Up @@ -4097,7 +4101,9 @@ static noinline_for_stack int relocate_block_group(struct reloc_control *rc)
err = PTR_ERR(trans);
goto out_free;
}
btrfs_commit_transaction(trans);
ret = btrfs_commit_transaction(trans);
if (ret && !err)
err = ret;
out_free:
btrfs_free_block_rsv(fs_info, rc->block_rsv);
btrfs_free_path(path);
Expand Down
6 changes: 6 additions & 0 deletions fs/ceph/caps.c
Original file line number Diff line number Diff line change
Expand Up @@ -1554,6 +1554,7 @@ void ceph_flush_snaps(struct ceph_inode_info *ci,
struct inode *inode = &ci->vfs_inode;
struct ceph_mds_client *mdsc = ceph_inode_to_client(inode)->mdsc;
struct ceph_mds_session *session = NULL;
bool need_put = false;
int mds;

dout("ceph_flush_snaps %p\n", inode);
Expand Down Expand Up @@ -1607,8 +1608,13 @@ void ceph_flush_snaps(struct ceph_inode_info *ci,
}
/* we flushed them all; remove this inode from the queue */
spin_lock(&mdsc->snap_flush_lock);
if (!list_empty(&ci->i_snap_flush_item))
need_put = true;
list_del_init(&ci->i_snap_flush_item);
spin_unlock(&mdsc->snap_flush_lock);

if (need_put)
iput(inode);
}

/*
Expand Down
4 changes: 3 additions & 1 deletion fs/ceph/snap.c
Original file line number Diff line number Diff line change
Expand Up @@ -623,8 +623,10 @@ int __ceph_finish_cap_snap(struct ceph_inode_info *ci,
capsnap->size);

spin_lock(&mdsc->snap_flush_lock);
if (list_empty(&ci->i_snap_flush_item))
if (list_empty(&ci->i_snap_flush_item)) {
ihold(inode);
list_add_tail(&ci->i_snap_flush_item, &mdsc->snap_flush_list);
}
spin_unlock(&mdsc->snap_flush_lock);
return 1; /* caller may want to ceph_flush_snaps */
}
Expand Down
6 changes: 4 additions & 2 deletions fs/ext4/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -2041,8 +2041,9 @@ ext4_xattr_block_set(handle_t *handle, struct inode *inode,
else {
u32 ref;

#ifdef EXT4_XATTR_DEBUG
WARN_ON_ONCE(dquot_initialize_needed(inode));

#endif
/* The old block is released after updating
the inode. */
error = dquot_alloc_block(inode,
Expand Down Expand Up @@ -2104,8 +2105,9 @@ ext4_xattr_block_set(handle_t *handle, struct inode *inode,
/* We need to allocate a new block */
ext4_fsblk_t goal, block;

#ifdef EXT4_XATTR_DEBUG
WARN_ON_ONCE(dquot_initialize_needed(inode));

#endif
goal = ext4_group_first_block_no(sb,
EXT4_I(inode)->i_block_group);
block = ext4_new_meta_blocks(handle, inode, goal, 0,
Expand Down
7 changes: 5 additions & 2 deletions include/linux/netdevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -695,8 +695,11 @@ static inline void rps_record_sock_flow(struct rps_sock_flow_table *table,
/* We only give a hint, preemption can change CPU under us */
val |= raw_smp_processor_id();

if (table->ents[index] != val)
table->ents[index] = val;
/* The following WRITE_ONCE() is paired with the READ_ONCE()
* here, and another one in get_rps_cpu().
*/
if (READ_ONCE(table->ents[index]) != val)
WRITE_ONCE(table->ents[index], val);
}
}

Expand Down
2 changes: 2 additions & 0 deletions include/net/pkt_sched.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ static inline void qdisc_run(struct Qdisc *q)
}
}

extern const struct nla_policy rtm_tca_policy[TCA_MAX + 1];

/* Calculate maximal size of packet seen by hard_start_xmit
routine of this device.
*/
Expand Down
18 changes: 13 additions & 5 deletions include/net/sock.h
Original file line number Diff line number Diff line change
Expand Up @@ -988,8 +988,12 @@ static inline void sock_rps_record_flow(const struct sock *sk)
* OR an additional socket flag
* [1] : sk_state and sk_prot are in the same cache line.
*/
if (sk->sk_state == TCP_ESTABLISHED)
sock_rps_record_flow_hash(sk->sk_rxhash);
if (sk->sk_state == TCP_ESTABLISHED) {
/* This READ_ONCE() is paired with the WRITE_ONCE()
* from sock_rps_save_rxhash() and sock_rps_reset_rxhash().
*/
sock_rps_record_flow_hash(READ_ONCE(sk->sk_rxhash));
}
}
#endif
}
Expand All @@ -998,15 +1002,19 @@ static inline void sock_rps_save_rxhash(struct sock *sk,
const struct sk_buff *skb)
{
#ifdef CONFIG_RPS
if (unlikely(sk->sk_rxhash != skb->hash))
sk->sk_rxhash = skb->hash;
/* The following WRITE_ONCE() is paired with the READ_ONCE()
* here, and another one in sock_rps_record_flow().
*/
if (unlikely(READ_ONCE(sk->sk_rxhash) != skb->hash))
WRITE_ONCE(sk->sk_rxhash, skb->hash);
#endif
}

static inline void sock_rps_reset_rxhash(struct sock *sk)
{
#ifdef CONFIG_RPS
sk->sk_rxhash = 0;
/* Paired with READ_ONCE() in sock_rps_record_flow() */
WRITE_ONCE(sk->sk_rxhash, 0);
#endif
}

Expand Down

0 comments on commit 422d868

Please sign in to comment.