In the latter models of RME Fireface series, device start to transfer
packets several dozens of milliseconds. On the other hand, ALSA fireface
driver starts IR context 2 milliseconds after the start. This results
in loss to handle incoming packets on the context.
This commit changes to start IR context immediately instead of
postponement. For Fireface 800, this affects nothing because the device
transfer packets 100 milliseconds or so after the start and this is
within wait timeout.
Cc: <stable(a)vger.kernel.org>
Fixes: acfedcbe1ce4 ("ALSA: firewire-lib: postpone to start IR context")
Signed-off-by: Takashi Sakamoto <o-takashi(a)sakamocchi.jp>
---
sound/firewire/fireface/ff-stream.c | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/sound/firewire/fireface/ff-stream.c b/sound/firewire/fireface/ff-stream.c
index 63b79c4a5405..5452115c0ef9 100644
--- a/sound/firewire/fireface/ff-stream.c
+++ b/sound/firewire/fireface/ff-stream.c
@@ -184,7 +184,6 @@ int snd_ff_stream_start_duplex(struct snd_ff *ff, unsigned int rate)
*/
if (!amdtp_stream_running(&ff->rx_stream)) {
int spd = fw_parent_device(ff->unit)->max_speed;
- unsigned int ir_delay_cycle;
err = ff->spec->protocol->begin_session(ff, rate);
if (err < 0)
@@ -200,14 +199,7 @@ int snd_ff_stream_start_duplex(struct snd_ff *ff, unsigned int rate)
if (err < 0)
goto error;
- // The device postpones start of transmission mostly for several
- // cycles after receiving packets firstly.
- if (ff->spec->protocol == &snd_ff_protocol_ff800)
- ir_delay_cycle = 800; // = 100 msec
- else
- ir_delay_cycle = 16; // = 2 msec
-
- err = amdtp_domain_start(&ff->domain, ir_delay_cycle);
+ err = amdtp_domain_start(&ff->domain, 0);
if (err < 0)
goto error;
--
2.25.1
128000 and 192000 are congruence modulo 32000, thus it's wrong to
distinguish them as multiple of 32000 and 48000 by modulo 32000 at
first.
Additionally, used condition statement to detect quadruple speed can
cause missing bit flag.
Furthermore, counter to ensure the configuration is wrong and it
causes false positive.
This commit fixes the above three bugs.
Cc: <stable(a)vger.kernel.org>
Fixes: 60aec494b389 ("ALSA: fireface: support allocate_resources operation in latter protocol")
Signed-off-by: Takashi Sakamoto <o-takashi(a)sakamocchi.jp>
---
sound/firewire/fireface/ff-protocol-latter.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/sound/firewire/fireface/ff-protocol-latter.c b/sound/firewire/fireface/ff-protocol-latter.c
index 0e4c3a9ed5e4..76ae568489ef 100644
--- a/sound/firewire/fireface/ff-protocol-latter.c
+++ b/sound/firewire/fireface/ff-protocol-latter.c
@@ -107,18 +107,18 @@ static int latter_allocate_resources(struct snd_ff *ff, unsigned int rate)
int err;
// Set the number of data blocks transferred in a second.
- if (rate % 32000 == 0)
- code = 0x00;
+ if (rate % 48000 == 0)
+ code = 0x04;
else if (rate % 44100 == 0)
code = 0x02;
- else if (rate % 48000 == 0)
- code = 0x04;
+ else if (rate % 32000 == 0)
+ code = 0x00;
else
return -EINVAL;
if (rate >= 64000 && rate < 128000)
code |= 0x08;
- else if (rate >= 128000 && rate < 192000)
+ else if (rate >= 128000)
code |= 0x10;
reg = cpu_to_le32(code);
@@ -140,7 +140,7 @@ static int latter_allocate_resources(struct snd_ff *ff, unsigned int rate)
if (curr_rate == rate)
break;
}
- if (count == 10)
+ if (count > 10)
return -ETIMEDOUT;
for (i = 0; i < ARRAY_SIZE(amdtp_rate_table); ++i) {
--
2.25.1
This is the start of the stable review cycle for the 5.6.12 release.
There are 49 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 Sun, 10 May 2020 12:29:44 +0000.
Anything received after that time might be too late.
The whole patch series can be found in one patch at:
https://www.kernel.org/pub/linux/kernel/v5.x/stable-review/patch-5.6.12-rc1…
or in the git tree and branch at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.6.y
and the diffstat can be found below.
thanks,
greg k-h
-------------
Pseudo-Shortlog of commits:
Greg Kroah-Hartman <gregkh(a)linuxfoundation.org>
Linux 5.6.12-rc1
Will Deacon <will(a)kernel.org>
mm/mremap: Add comment explaining the untagging behaviour of mremap()
Jiri Slaby <jslaby(a)suse.cz>
cgroup, netclassid: remove double cond_resched
Thomas Pedersen <thomas(a)adapt-ip.com>
mac80211: add ieee80211_is_any_nullfunc()
Rafael J. Wysocki <rafael.j.wysocki(a)intel.com>
ACPI: PM: s2idle: Fix comment in acpi_s2idle_prepare_late()
Hans de Goede <hdegoede(a)redhat.com>
platform/x86: GPD pocket fan: Fix error message when temp-limits are out of range
Qian Cai <cai(a)lca.pw>
x86/kvm: fix a missing-prototypes "vmread_error"
Takashi Iwai <tiwai(a)suse.de>
ALSA: hda: Match both PCI ID and SSID for driver blacklist
Aaron Ma <aaron.ma(a)canonical.com>
drm/amdgpu: Fix oops when pp_funcs is unset in ACPI event
Jere Leppänen <jere.leppanen(a)nokia.com>
sctp: Fix SHUTDOWN CTSN Ack in the peer restart case
Andrii Nakryiko <andriin(a)fb.com>
tools/runqslower: Ensure own vmlinux.h is picked up first
Doug Berger <opendmb(a)gmail.com>
net: systemport: suppress warnings on failed Rx SKB allocations
Doug Berger <opendmb(a)gmail.com>
net: bcmgenet: suppress warnings on failed Rx SKB allocations
Madhuparna Bhowmik <madhuparnabhowmik10(a)gmail.com>
mac80211: sta_info: Add lockdep condition for RCU list usage
Nathan Chancellor <natechancellor(a)gmail.com>
lib/mpi: Fix building for powerpc with clang
Russell King <rmk+kernel(a)armlinux.org.uk>
net: phy: bcm84881: clear settings on link down
Steven Rostedt (VMware) <rostedt(a)goodmis.org>
ftrace: Fix memory leak caused by not freeing entry in unregister_ftrace_direct()
Vamshi K Sthambamkadi <vamshi.k.sthambamkadi(a)gmail.com>
tracing: Fix memory leaks in trace_events_hist.c
Paulo Alcantara <pc(a)cjr.nz>
cifs: do not share tcons with DFS
Jeremie Francois (on alpha) <jeremie.francois(a)gmail.com>
scripts/config: allow colons in option strings for sed
Ronnie Sahlberg <lsahlber(a)redhat.com>
cifs: protect updating server->dstaddr with a spinlock
Matthias Blankertz <matthias.blankertz(a)cetitec.com>
ASoC: rsnd: Fix "status check failed" spam for multi-SSI
Matthias Blankertz <matthias.blankertz(a)cetitec.com>
ASoC: rsnd: Don't treat master SSI in multi SSI setup as parent
Julien Beraud <julien.beraud(a)orolia.com>
net: stmmac: Fix sub-second increment
Julien Beraud <julien.beraud(a)orolia.com>
net: stmmac: fix enabling socfpga's ptp_ref_clock
Xiyu Yang <xiyuyang19(a)fudan.edu.cn>
wimax/i2400m: Fix potential urb refcnt leak
Sandeep Raghuraman <sandy.8925(a)gmail.com>
drm/amdgpu: Correctly initialize thermal controller for GPUs with Powerplay table v0 (e.g Hawaii)
Prike Liang <Prike.Liang(a)amd.com>
drm/amd/powerplay: fix resume failed as smu table initialize early exit
Alex Elder <elder(a)linaro.org>
remoteproc: qcom_q6v5_mss: fix a bug in q6v5_probe()
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: codecs: hdac_hdmi: Fix incorrect use of list_for_each_entry
Matthias Blankertz <matthias.blankertz(a)cetitec.com>
ASoC: rsnd: Fix HDMI channel mapping for multi-SSI mode
Matthias Blankertz <matthias.blankertz(a)cetitec.com>
ASoC: rsnd: Fix parent SSI start/stop in multi-SSI mode
Thinh Nguyen <Thinh.Nguyen(a)synopsys.com>
usb: dwc3: gadget: Properly set maxpacket limit
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Fix endianness issue
Sebastian Reichel <sebastian.reichel(a)collabora.com>
ASoC: sgtl5000: Fix VAG power-on handling
Wu Bo <wubo40(a)huawei.com>
scsi: sg: add sg_remove_request in sg_write
Vasily Khoruzhick <anarsoul(a)gmail.com>
drm/bridge: anx6345: set correct BPC for display_info of connector
Tyler Hicks <tyhicks(a)linux.microsoft.com>
selftests/ipc: Fix test failure seen after initial test run
Jarkko Sakkinen <jarkko.sakkinen(a)linux.intel.com>
Revert "Kernel selftests: tpm2: check for tpm support"
Sandipan Das <sandipan(a)linux.ibm.com>
selftests: vm: Fix 64-bit test builds for powerpc64le
Sandipan Das <sandipan(a)linux.ibm.com>
selftests: vm: Do not override definition of ARCH
Yihao Wu <wuyihao(a)linux.alibaba.com>
SUNRPC/cache: Fix unsafe traverse caused double-free in cache_purge
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Check return value of soc_tplg_dai_config
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Check return value of pcm_new_ver
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Check soc_tplg_add_route return value
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Check return value of soc_tplg_*_create
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Check return value of soc_tplg_create_tlv
Amadeusz Sławiński <amadeuszx.slawinski(a)linux.intel.com>
ASoC: topology: Add missing memory checks
Marek Szyprowski <m.szyprowski(a)samsung.com>
drm/bridge: analogix_dp: Split bind() into probe() and real bind()
Jia He <justin.he(a)arm.com>
vhost: vsock: kick send_pkt worker once device is started
-------------
Diffstat:
Makefile | 4 +-
arch/x86/kvm/vmx/ops.h | 1 +
drivers/acpi/sleep.c | 5 +-
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 3 +-
.../gpu/drm/amd/powerplay/hwmgr/processpptables.c | 26 +++++
drivers/gpu/drm/amd/powerplay/renoir_ppt.c | 7 +-
drivers/gpu/drm/bridge/analogix/analogix-anx6345.c | 3 +
drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 33 ++++--
drivers/gpu/drm/exynos/exynos_dp.c | 29 +++---
drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 36 ++++---
drivers/net/ethernet/broadcom/bcmsysport.c | 3 +-
drivers/net/ethernet/broadcom/genet/bcmgenet.c | 3 +-
.../net/ethernet/stmicro/stmmac/dwmac-socfpga.c | 9 +-
.../net/ethernet/stmicro/stmmac/stmmac_hwtstamp.c | 12 ++-
drivers/net/phy/bcm84881.c | 6 +-
drivers/net/wimax/i2400m/usb-fw.c | 1 +
drivers/platform/x86/gpd-pocket-fan.c | 2 +-
drivers/remoteproc/qcom_q6v5_mss.c | 2 +-
drivers/scsi/sg.c | 4 +-
drivers/usb/dwc3/core.h | 4 +
drivers/usb/dwc3/gadget.c | 52 ++++++++--
drivers/vhost/vsock.c | 5 +
fs/cifs/connect.c | 6 ++
include/drm/bridge/analogix_dp.h | 5 +-
include/linux/ieee80211.h | 9 ++
kernel/trace/ftrace.c | 1 +
kernel/trace/trace_events_hist.c | 7 ++
lib/mpi/longlong.h | 34 +++---
mm/mremap.c | 10 ++
net/core/netclassid_cgroup.c | 4 +-
net/mac80211/mlme.c | 2 +-
net/mac80211/rx.c | 8 +-
net/mac80211/sta_info.c | 3 +-
net/mac80211/status.c | 5 +-
net/mac80211/tx.c | 2 +-
net/sctp/sm_make_chunk.c | 6 +-
net/sunrpc/cache.c | 5 +-
scripts/config | 5 +-
sound/pci/hda/hda_intel.c | 9 +-
sound/soc/codecs/hdac_hdmi.c | 6 +-
sound/soc/codecs/sgtl5000.c | 34 ++++++
sound/soc/codecs/sgtl5000.h | 1 +
sound/soc/sh/rcar/ssi.c | 11 +-
sound/soc/sh/rcar/ssiu.c | 2 +-
sound/soc/soc-topology.c | 115 ++++++++++++++++-----
tools/bpf/runqslower/Makefile | 2 +-
tools/testing/selftests/ipc/msgque.c | 2 +-
tools/testing/selftests/tpm2/test_smoke.sh | 13 +--
tools/testing/selftests/tpm2/test_space.sh | 9 +-
tools/testing/selftests/vm/Makefile | 4 +-
tools/testing/selftests/vm/run_vmtests | 2 +-
51 files changed, 402 insertions(+), 170 deletions(-)
Previously, the output format was programmed as part of the ioctl()
handler. However, this has two problems:
1) If there are multiple active streams with different output
formats, the hardware will use whichever format was set last
for both streams. Similarly, an ioctl() done in an inactive
context will wrongly affect other active contexts.
2) The registers are written while the device is not actively
streaming. To enable runtime PM tied to the streaming state,
all hardware access needs to be moved inside cedrus_device_run().
The call to cedrus_dst_format_set() is now placed just before the
codec-specific callback that programs the hardware.
Cc: <stable(a)vger.kernel.org>
Fixes: 50e761516f2b ("media: platform: Add Cedrus VPU decoder driver")
Suggested-by: Jernej Skrabec <jernej.skrabec(a)siol.net>
Suggested-by: Paul Kocialkowski <paul.kocialkowski(a)bootlin.com>
Signed-off-by: Samuel Holland <samuel(a)sholland.org>
Tested-by: Jernej Skrabec <jernej.skrabec(a)siol.net>
Reviewed-by: Jernej Skrabec <jernej.skrabec(a)siol.net>
Reviewed-by: Ezequiel Garcia <ezequiel(a)collabora.com>
---
v2: added patch
v3: collected tags
---
drivers/staging/media/sunxi/cedrus/cedrus_dec.c | 2 ++
drivers/staging/media/sunxi/cedrus/cedrus_video.c | 3 ---
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/media/sunxi/cedrus/cedrus_dec.c b/drivers/staging/media/sunxi/cedrus/cedrus_dec.c
index 4a2fc33a1d79..58c48e4fdfe9 100644
--- a/drivers/staging/media/sunxi/cedrus/cedrus_dec.c
+++ b/drivers/staging/media/sunxi/cedrus/cedrus_dec.c
@@ -74,6 +74,8 @@ void cedrus_device_run(void *priv)
v4l2_m2m_buf_copy_metadata(run.src, run.dst, true);
+ cedrus_dst_format_set(dev, &ctx->dst_fmt);
+
dev->dec_ops[ctx->current_codec]->setup(ctx, &run);
/* Complete request(s) controls if needed. */
diff --git a/drivers/staging/media/sunxi/cedrus/cedrus_video.c b/drivers/staging/media/sunxi/cedrus/cedrus_video.c
index 15cf1f10221b..ed3f511f066f 100644
--- a/drivers/staging/media/sunxi/cedrus/cedrus_video.c
+++ b/drivers/staging/media/sunxi/cedrus/cedrus_video.c
@@ -273,7 +273,6 @@ static int cedrus_s_fmt_vid_cap(struct file *file, void *priv,
struct v4l2_format *f)
{
struct cedrus_ctx *ctx = cedrus_file2ctx(file);
- struct cedrus_dev *dev = ctx->dev;
struct vb2_queue *vq;
int ret;
@@ -287,8 +286,6 @@ static int cedrus_s_fmt_vid_cap(struct file *file, void *priv,
ctx->dst_fmt = f->fmt.pix;
- cedrus_dst_format_set(dev, &ctx->dst_fmt);
-
return 0;
}
--
2.24.1
From: Sarthak Garg <sartgarg(a)codeaurora.org>
Consider the following stack trace
-001|raw_spin_lock_irqsave
-002|mmc_blk_cqe_complete_rq
-003|__blk_mq_complete_request(inline)
-003|blk_mq_complete_request(rq)
-004|mmc_cqe_timed_out(inline)
-004|mmc_mq_timed_out
mmc_mq_timed_out acquires the queue_lock for the first
time. The mmc_blk_cqe_complete_rq function also tries to acquire
the same queue lock resulting in recursive locking where the task
is spinning for the same lock which it has already acquired leading
to watchdog bark.
Fix this issue with the lock only for the required critical section.
Cc: <stable(a)vger.kernel.org> # v4.19+
Suggested-by: Sahitya Tummala <stummala(a)codeaurora.org>
Signed-off-by: Sarthak Garg <sartgarg(a)codeaurora.org>
---
drivers/mmc/core/queue.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c
index 25bee3d..72bef39 100644
--- a/drivers/mmc/core/queue.c
+++ b/drivers/mmc/core/queue.c
@@ -107,7 +107,7 @@ static enum blk_eh_timer_return mmc_cqe_timed_out(struct request *req)
case MMC_ISSUE_DCMD:
if (host->cqe_ops->cqe_timeout(host, mrq, &recovery_needed)) {
if (recovery_needed)
- __mmc_cqe_recovery_notifier(mq);
+ mmc_cqe_recovery_notifier(mrq);
return BLK_EH_RESET_TIMER;
}
/* No timeout (XXX: huh? comment doesn't make much sense) */
@@ -131,12 +131,13 @@ static enum blk_eh_timer_return mmc_mq_timed_out(struct request *req,
spin_lock_irqsave(&mq->lock, flags);
- if (mq->recovery_needed || !mq->use_cqe || host->hsq_enabled)
+ if (mq->recovery_needed || !mq->use_cqe || host->hsq_enabled) {
ret = BLK_EH_RESET_TIMER;
- else
+ spin_unlock_irqrestore(&mq->lock, flags);
+ } else {
+ spin_unlock_irqrestore(&mq->lock, flags);
ret = mmc_cqe_timed_out(req);
-
- spin_unlock_irqrestore(&mq->lock, flags);
+ }
return ret;
}
--
Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center, Inc., is a member of Code Aurora Forum, a Linux Foundation Collaborative Project