Skip to content
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

tests: subsys: usb: bos: Remove dummy_descriptor struct #87591

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

thughes
Copy link
Contributor

@thughes thughes commented Mar 24, 2025

When building with clang, it warns:

tests/subsys/usb/bos/src/test_bos.c:24:22: error: variable
'dummy_descriptor' is not needed and will not be emitted
[-Werror,-Wunneeded-internal-declaration]
static const uint8_t dummy_descriptor[] = {
^

Only the size of dummy_descriptor is used, not the contents. Replace the
struct with a constant for the size.

@thughes thughes marked this pull request as ready for review March 24, 2025 20:49
@zephyrbot zephyrbot added the area: USB Universal Serial Bus label Mar 24, 2025
When building with clang, it warns:

tests/subsys/usb/bos/src/test_bos.c:24:22: error: variable
'dummy_descriptor' is not needed and will not be emitted
[-Werror,-Wunneeded-internal-declaration]
static const uint8_t dummy_descriptor[] = {
                     ^

Only the size of dummy_descriptor is used, not the contents. Replace the
struct with a constant for the size.

Signed-off-by: Tom Hughes <tomhughes@chromium.org>
@thughes thughes force-pushed the push-xyzytzqprnqt branch from 4bfb3b9 to a5fcc0b Compare March 25, 2025 16:18
@thughes thughes requested a review from jfischer-no March 25, 2025 16:18
@thughes
Copy link
Contributor Author

thughes commented Mar 28, 2025

@kartben Is this one that you could help with for a second approval?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: USB Universal Serial Bus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants