Skip to content

DLPX-91889 scsi: target: iscsi: Handle abort for WRITE_PENDING cmds #53

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 9, 2024

Conversation

pcd1193182
Copy link
Contributor

@pcd1193182 pcd1193182 commented Aug 9, 2024

To quote the upstream patch notes:

Sometimes an initiator does not send data for a WRITE command and tries to abort it.
The abort hangs waiting for frontend driver completion. iSCSI driver waits for data and
that timeout eventually initiates connection reinstatment. The connection closing
releases the commands in the connection, but those aborted commands still did not
handle the abort and did not decrease a command ref counter. Because of that the
connection reinstatement hangs indefinitely and prevents re-login for that initiator.

Add handling in TCM of the abort for the WRITE_PENDING commands at connection
closing moment to make it possible to release them.

No additional testing was performed on this patch aside from running it through ab-pre-push, because the customer's issue is difficult to reproduce. However, the patch is small and relatively easy to understand, and to the best of my knowledge it should fix the customer's issue without breaking other flows.

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
[mnc: Rebase and expand comment]
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
@pcd1193182 pcd1193182 merged commit 1680638 into delphix:develop Aug 9, 2024
2 of 3 checks passed
delphix-devops-bot pushed a commit that referenced this pull request Aug 15, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Aug 22, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Aug 23, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
prakashsurya pushed a commit that referenced this pull request Sep 23, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Oct 20, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Oct 21, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
palash-gandhi pushed a commit that referenced this pull request Oct 24, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Nov 10, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 18, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 19, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 20, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 21, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 22, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 23, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 24, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 25, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 26, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 27, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 28, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 29, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 30, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Dec 31, 2024
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Jan 1, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Jan 2, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Jan 3, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Jan 4, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Jan 5, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Jan 7, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Feb 12, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Feb 13, 2025
)

Link: https://lore.kernel.org/r/20230319015620.96006-10-michael.christie@oracle.com

Signed-off-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
Signed-off-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Co-authored-by: Dmitry Bogdanov <d.bogdanov@yadro.com>
delphix-devops-bot pushed a commit that referenced this pull request Mar 29, 2025
BugLink: https://bugs.launchpad.net/bugs/2097298

[ Upstream commit 3699f2c43ea9984e00d70463f8c29baaf260ea97 ]

There is a race condition at startup between disabling power domains not
used and disabling clocks not used on the rk3328. When the clocks are
disabled first, the hevc power domain fails to shut off leading to a
splat of failures. Add the hevc core clock to the rk3328 power domain
node to prevent this condition.

rcu: INFO: rcu_sched detected expedited stalls on CPUs/tasks: { 3-.... }
1087 jiffies s: 89 root: 0x8/.
rcu: blocking rcu_node structures (internal RCU debug):
Sending NMI from CPU 0 to CPUs 3:
NMI backtrace for cpu 3
CPU: 3 UID: 0 PID: 86 Comm: kworker/3:3 Not tainted 6.12.0-rc5+ #53
Hardware name: Firefly ROC-RK3328-CC (DT)
Workqueue: pm genpd_power_off_work_fn
pstate: 20400005 (nzCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : regmap_unlock_spinlock+0x18/0x30
lr : regmap_read+0x60/0x88
sp : ffff800081123c00
x29: ffff800081123c00 x28: ffff2fa4c62cad80 x27: 0000000000000000
x26: ffffd74e6e660eb8 x25: ffff2fa4c62cae00 x24: 0000000000000040
x23: ffffd74e6d2f3ab8 x22: 0000000000000001 x21: ffff800081123c74
x20: 0000000000000000 x19: ffff2fa4c0412000 x18: 0000000000000000
x17: 77202c31203d2065 x16: 6c6469203a72656c x15: 6c6f72746e6f632d
x14: 7265776f703a6e6f x13: 2063766568206e69 x12: 616d6f64202c3431
x11: 347830206f742030 x10: 3430303034783020 x9 : ffffd74e6c7369e0
x8 : 3030316666206e69 x7 : 205d383738353733 x6 : 332e31202020205b
x5 : ffffd74e6c73fc88 x4 : ffffd74e6c73fcd4 x3 : ffffd74e6c740b40
x2 : ffff800080015484 x1 : 0000000000000000 x0 : ffff2fa4c0412000
Call trace:
regmap_unlock_spinlock+0x18/0x30
rockchip_pmu_set_idle_request+0xac/0x2c0
rockchip_pd_power+0x144/0x5f8
rockchip_pd_power_off+0x1c/0x30
_genpd_power_off+0x9c/0x180
genpd_power_off.part.0.isra.0+0x130/0x2a8
genpd_power_off_work_fn+0x6c/0x98
process_one_work+0x170/0x3f0
worker_thread+0x290/0x4a8
kthread+0xec/0xf8
ret_from_fork+0x10/0x20
rockchip-pm-domain ff100000.syscon:power-controller: failed to get ack on domain 'hevc', val=0x88220

Fixes: 52e02d3 ("arm64: dts: rockchip: add core dtsi file for RK3328 SoCs")
Signed-off-by: Peter Geis <pgwipeout@gmail.com>
Reviewed-by: Dragan Simic <dsimic@manjaro.org>
Link: https://lore.kernel.org/r/20241214224339.24674-1-pgwipeout@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Noah Wager <noah.wager@canonical.com>
Signed-off-by: Koichiro Den <koichiro.den@canonical.com>
delphix-devops-bot pushed a commit that referenced this pull request May 17, 2025
BugLink: https://bugs.launchpad.net/bugs/2106770

[ Upstream commit 3699f2c43ea9984e00d70463f8c29baaf260ea97 ]

There is a race condition at startup between disabling power domains not
used and disabling clocks not used on the rk3328. When the clocks are
disabled first, the hevc power domain fails to shut off leading to a
splat of failures. Add the hevc core clock to the rk3328 power domain
node to prevent this condition.

rcu: INFO: rcu_sched detected expedited stalls on CPUs/tasks: { 3-.... }
1087 jiffies s: 89 root: 0x8/.
rcu: blocking rcu_node structures (internal RCU debug):
Sending NMI from CPU 0 to CPUs 3:
NMI backtrace for cpu 3
CPU: 3 UID: 0 PID: 86 Comm: kworker/3:3 Not tainted 6.12.0-rc5+ #53
Hardware name: Firefly ROC-RK3328-CC (DT)
Workqueue: pm genpd_power_off_work_fn
pstate: 20400005 (nzCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : regmap_unlock_spinlock+0x18/0x30
lr : regmap_read+0x60/0x88
sp : ffff800081123c00
x29: ffff800081123c00 x28: ffff2fa4c62cad80 x27: 0000000000000000
x26: ffffd74e6e660eb8 x25: ffff2fa4c62cae00 x24: 0000000000000040
x23: ffffd74e6d2f3ab8 x22: 0000000000000001 x21: ffff800081123c74
x20: 0000000000000000 x19: ffff2fa4c0412000 x18: 0000000000000000
x17: 77202c31203d2065 x16: 6c6469203a72656c x15: 6c6f72746e6f632d
x14: 7265776f703a6e6f x13: 2063766568206e69 x12: 616d6f64202c3431
x11: 347830206f742030 x10: 3430303034783020 x9 : ffffd74e6c7369e0
x8 : 3030316666206e69 x7 : 205d383738353733 x6 : 332e31202020205b
x5 : ffffd74e6c73fc88 x4 : ffffd74e6c73fcd4 x3 : ffffd74e6c740b40
x2 : ffff800080015484 x1 : 0000000000000000 x0 : ffff2fa4c0412000
Call trace:
regmap_unlock_spinlock+0x18/0x30
rockchip_pmu_set_idle_request+0xac/0x2c0
rockchip_pd_power+0x144/0x5f8
rockchip_pd_power_off+0x1c/0x30
_genpd_power_off+0x9c/0x180
genpd_power_off.part.0.isra.0+0x130/0x2a8
genpd_power_off_work_fn+0x6c/0x98
process_one_work+0x170/0x3f0
worker_thread+0x290/0x4a8
kthread+0xec/0xf8
ret_from_fork+0x10/0x20
rockchip-pm-domain ff100000.syscon:power-controller: failed to get ack on domain 'hevc', val=0x88220

Fixes: 52e02d3 ("arm64: dts: rockchip: add core dtsi file for RK3328 SoCs")
Signed-off-by: Peter Geis <pgwipeout@gmail.com>
Reviewed-by: Dragan Simic <dsimic@manjaro.org>
Link: https://lore.kernel.org/r/20241214224339.24674-1-pgwipeout@gmail.com
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Manuel Diewald <manuel.diewald@canonical.com>
Signed-off-by: Mehmet Basaran <mehmet.basaran@canonical.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants