Skip to content

Conversation

@kv2019i
Copy link
Collaborator

@kv2019i kv2019i commented Sep 3, 2025

Remove old XTOS spinlock code, including the legacy DEBUG_LOCKS and DEBUG_LOGS_VERBOSE Kconfig options.

The posix implementation of spinlock.h is simplified. The operations were no-ops already before, but there were multiple layers of abstractions left in the code. Remove all of these.

Copilot AI review requested due to automatic review settings September 3, 2025 18:42
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Removes the legacy XTOS spinlock implementation and associated debugging infrastructure. This cleanup simplifies the codebase by eliminating obsolete spinlock debugging features and streamlining the POSIX spinlock implementation to use simple no-op operations.

Key changes:

  • Removes entire spinlock.c implementation file and related Kconfig options
  • Simplifies POSIX spinlock.h to basic no-op inline functions
  • Removes DEBUG_LOCKS and DEBUG_LOCKS_VERBOSE configuration options

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/spinlock.c Completely removed XTOS spinlock implementation
src/include/sof/debug/debug.h Removed DEBUG_LOCKS references from firmware ready flags
src/arch/host/include/arch/spinlock.h Removed host architecture spinlock header
src/CMakeLists.txt Removed spinlock.c from build sources
posix/include/rtos/wait.h Removed DEBUG_LOCKS conditional code
posix/include/rtos/spinlock.h Simplified to basic no-op implementation
Kconfig.sof Removed DEBUG_LOCKS and DEBUG_LOCKS_VERBOSE options

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Remove old XTOS spinlock code, including the legacy DEBUG_LOCKS
and DEBUG_LOGS_VERBOSE Kconfig options.

The posix implementation of spinlock.h is simplified. The operations
were no-ops already before, but there were multiple layers of
abstractions left in the code. Remove all of these.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
@kv2019i kv2019i force-pushed the 202508-xtos-spinlock-remove branch from 3b858de to c0b7138 Compare September 3, 2025 18:48
@kv2019i
Copy link
Collaborator Author

kv2019i commented Sep 3, 2025

cmocka fail is now same as on other recent PRs. @singalsu @jsarha is this knwon failure, do we have a bug?

https://github.com/thesofproject/sof/actions/runs/17443083884/job/49530645871?pr=10214

``

The following tests FAILED:
16 - eq_iir_process (Subprocess aborted)
17 - eq_fir_process (Subprocess aborted)
``

Same fail in #10176

@jsarha
Copy link
Contributor

jsarha commented Sep 4, 2025

cmocka fail is now same as on other recent PRs. @singalsu @jsarha is this knwon failure, do we have a bug?

https://github.com/thesofproject/sof/actions/runs/17443083884/job/49530645871?pr=10214

``

The following tests FAILED: 16 - eq_iir_process (Subprocess aborted) 17 - eq_fir_process (Subprocess aborted) ``

Same fail in #10176

This PR should fix the issue: #10216

Copy link
Contributor

@jsarha jsarha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed the earlier implementation in /src/arch/host/include/arch/spinlock.h was dummy too.

@lgirdwood lgirdwood merged commit c5ff120 into thesofproject:main Sep 8, 2025
38 of 45 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants