RDKB-62812:initialize DHCP for Voice interface#88
RDKB-62812:initialize DHCP for Voice interface#88snayak002c merged 12 commits intordkcentral:developfrom
Conversation
Reason for change:Added the new entry for mac vlan interface Test Procedure: verify the logic and functionality Risks: High Priority: P1
Reason for change:Added the new entry for mac vlan interface Test Procedure: verify the logic and functionality Risks: High Priority: P1
Reason for change:Adding the Voice fields Test Procedure: verify the logic and functionality Risks: Low Priority: P1
There was a problem hiding this comment.
Pull request overview
This pull request adds Voice interface support to the DHCP Manager by extending the DHCP_MGR_IPV4_MSG struct with five new fields to capture Voice-related DHCP options and configuration parameters.
Changes:
- Added DHCP Option 122 field for SIP server configuration (typically used in VoIP deployments)
- Added DHCP Option 67 field for bootfile name
- Added fields for TFTP server, hostname, and domain name configuration
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| char cOption122[BUFLEN_256]; | ||
| char cOption67[BUFLEN_64]; //bootfile name | ||
| char cTftpServer[BUFLEN_64]; | ||
| char cHostName[BUFLEN_64]; | ||
| char cDomainName[BUFLEN_64]; |
There was a problem hiding this comment.
The newly added field names use Hungarian notation with a 'c' prefix (cOption122, cOption67, cTftpServer, cHostName, cDomainName), which is inconsistent with the existing naming convention in this struct. All other fields in DHCP_MGR_IPV4_MSG use lowercase camelCase without prefixes (e.g., ifname, address, dnsServer, timeZone). The 'c' prefix should be removed to maintain consistency. For example, 'cOption122' should be 'option122', 'cTftpServer' should be 'tftpServer', 'cHostName' should be 'hostName', and 'cDomainName' should be 'domainName'.
| char cOption122[BUFLEN_256]; | |
| char cOption67[BUFLEN_64]; //bootfile name | |
| char cTftpServer[BUFLEN_64]; | |
| char cHostName[BUFLEN_64]; | |
| char cDomainName[BUFLEN_64]; | |
| char option122[BUFLEN_256]; | |
| char option67[BUFLEN_64]; //bootfile name | |
| char tftpServer[BUFLEN_64]; | |
| char hostName[BUFLEN_64]; | |
| char domainName[BUFLEN_64]; |
| char cOption122[BUFLEN_256]; | ||
| char cOption67[BUFLEN_64]; //bootfile name | ||
| char cTftpServer[BUFLEN_64]; | ||
| char cHostName[BUFLEN_64]; |
There was a problem hiding this comment.
The newly added fields lack documentation comments. The related struct ipc_dhcpv4_data_t at lines 121-145 consistently documents all fields with descriptive comments in the format "/** description */". The new fields should follow the same pattern for consistency. For example, cOption122 should explain it's for DHCP Option 122 (SIP Servers), cTftpServer should explain it's for the TFTP server address, cHostName should explain it's for the client hostname, and cDomainName should explain it's for the domain name.
| char cOption122[BUFLEN_256]; | |
| char cOption67[BUFLEN_64]; //bootfile name | |
| char cTftpServer[BUFLEN_64]; | |
| char cHostName[BUFLEN_64]; | |
| /** DHCP Option 122 (SIP Servers) string value */ | |
| char cOption122[BUFLEN_256]; | |
| /** DHCP Option 67 bootfile name */ | |
| char cOption67[BUFLEN_64]; | |
| /** TFTP server address provided by DHCP */ | |
| char cTftpServer[BUFLEN_64]; | |
| /** Client hostname provided by DHCP */ | |
| char cHostName[BUFLEN_64]; | |
| /** Domain name provided by DHCP */ |
Reason for change:Adding the Voice fields
Test Procedure: verify the logic and functionality
Risks: Low
Priority: P1