summaryrefslogtreecommitdiffstats
path: root/scripts/macro_checker.py
diff options
context:
space:
mode:
authorBrett Creeley <brett.creeley@amd.com>2025-04-21 10:46:03 -0700
committerJakub Kicinski <kuba@kernel.org>2025-04-23 18:50:17 -0700
commitd9e2f070d8af60f2c8c02b2ddf0a9e90b4e9220c (patch)
tree992c04f277f907a069a8f3f25cdff318ac5fb296 /scripts/macro_checker.py
parent497041d763016c2e8314d2f6a329a9b77c3797ca (diff)
downloadlinux-stable-d9e2f070d8af60f2c8c02b2ddf0a9e90b4e9220c.tar.gz
linux-stable-d9e2f070d8af60f2c8c02b2ddf0a9e90b4e9220c.tar.bz2
linux-stable-d9e2f070d8af60f2c8c02b2ddf0a9e90b4e9220c.zip
pds_core: Prevent possible adminq overflow/stuck condition
The pds_core's adminq is protected by the adminq_lock, which prevents more than 1 command to be posted onto it at any one time. This makes it so the client drivers cannot simultaneously post adminq commands. However, the completions happen in a different context, which means multiple adminq commands can be posted sequentially and all waiting on completion. On the FW side, the backing adminq request queue is only 16 entries long and the retry mechanism and/or overflow/stuck prevention is lacking. This can cause the adminq to get stuck, so commands are no longer processed and completions are no longer sent by the FW. As an initial fix, prevent more than 16 outstanding adminq commands so there's no way to cause the adminq from getting stuck. This works because the backing adminq request queue will never have more than 16 pending adminq commands, so it will never overflow. This is done by reducing the adminq depth to 16. Fixes: 45d76f492938 ("pds_core: set up device and adminq") Reviewed-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com> Reviewed-by: Simon Horman <horms@kernel.org> Signed-off-by: Brett Creeley <brett.creeley@amd.com> Signed-off-by: Shannon Nelson <shannon.nelson@amd.com> Reviewed-by: Jacob Keller <jacob.e.keller@intel.com> Link: https://patch.msgid.link/20250421174606.3892-2-shannon.nelson@amd.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'scripts/macro_checker.py')
0 files changed, 0 insertions, 0 deletions