Skip to content

Conversation

@PragatiGarg-eaton
Copy link

Overview

Fixes Kconfig conflict between POSIX networking and unique hostname updates that was introduced in v3.7.1.

Problem

Enabling CONFIG_POSIX_API=y auto-selects CONFIG_POSIX_NETWORKING=y, which force-selects CONFIG_NET_HOSTNAME_DYNAMIC=y. This conflicts with CONFIG_NET_HOSTNAME_UNIQUE_UPDATE=y, preventing the use of POSIX networking with unique hostname updates.

Solution

Decouple NET_HOSTNAME_MAX_LEN from NET_HOSTNAME_DYNAMIC dependency:

  • Remove forced selection of NET_HOSTNAME_DYNAMIC from POSIX networking
  • Make hostname length configuration available independently
  • Add build assertions - Ensure proper validation at compile time

Testing

  • Verified fix resolves Kconfig conflicts
  • Validated unique hostname update operations
  • Confirmed hostname length constants are properly defined
  • Build tests pass for various configuration combinations

Fixes #95811

@github-actions
Copy link

Hello @PragatiGarg-eaton, and thank you very much for your first pull request to the Zephyr project!
Our Continuous Integration pipeline will execute a series of checks on your Pull Request commit messages and code, and you are expected to address any failures by updating the PR. Please take a look at our commit message guidelines to find out how to format your commit messages, and at our contribution workflow to understand how to update your Pull Request. If you haven't already, please make sure to review the project's Contributor Expectations and update (by amending and force-pushing the commits) your pull request if necessary.
If you are stuck or need help please join us on Discord and ask your question there. Additionally, you can escalate the review when applicable. 😊

@cfriedt
Copy link
Member

cfriedt commented Oct 19, 2025

@PragatiGarg-eaton - tests need to pass in order for the change to be merged. Can you revisit?

Please feel free to jump on discord to ask for pointers for running failing tests.

@PragatiGarg-eaton
Copy link
Author

@PragatiGarg-eaton - tests need to pass in order for the change to be merged. Can you revisit?

Please feel free to jump on discord to ask for pointers for running failing tests.

yes, I'll check the failures.

@PragatiGarg-eaton PragatiGarg-eaton force-pushed the fix-95811-posix-net-hostname-conflict branch from 7f28ab5 to 8ad0a48 Compare November 10, 2025 07:36
@github-actions
Copy link

github-actions bot commented Nov 10, 2025

The following west manifest projects have changed revision in this Pull Request:

Name Old Revision New Revision Diff

All manifest checks OK

Note: This message is automatically posted and updated by the Manifest GitHub Action.

Decouple NET_HOSTNAME_MAX_LEN from NET_HOSTNAME_DYNAMIC to resolve
Kconfig conflict when using POSIX networking with unique hostname
updates. This restores functionality that worked in Zephyr 3.6.

- Remove forced selection of NET_HOSTNAME_DYNAMIC from POSIX_NETWORKING
- Make NET_HOSTNAME_MAX_LEN available independently
- Add build assertions for hostname length validation
- Update test configurations for new dependency structure

Fixes zephyrproject-rtos#95811

Signed-off-by: Pragati Garg <[email protected]>
Signed-off-by: PragatiGarg-eaton <[email protected]>
@PragatiGarg-eaton PragatiGarg-eaton force-pushed the fix-95811-posix-net-hostname-conflict branch from afaf16a to 72c0a13 Compare November 10, 2025 10:29
@sonarqubecloud
Copy link

Please retry analysis of this Pull-Request directly on SonarQube Cloud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: Networking area: POSIX POSIX API Library area: Tests Issues related to a particular existing or missing test

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Conflict Between POSIX Networking and NET_HOSTNAME_UNIQUE_UPDATE in Zephyr v3.7.1

3 participants