DHCP request fields insufficiency fixed
This commit is contained in:
parent
99e7d26e67
commit
048aa6f1db
@ -36,7 +36,7 @@ EthInterface *ethintf_new(EthIODef * io) {
|
|||||||
ethIntf->txQ = mq_create(ETHLIB_DEF_MQ_SIZE);
|
ethIntf->txQ = mq_create(ETHLIB_DEF_MQ_SIZE);
|
||||||
ethIntf->rxQ = mq_create(ETHLIB_DEF_MQ_SIZE);
|
ethIntf->rxQ = mq_create(ETHLIB_DEF_MQ_SIZE);
|
||||||
ETHLIB_OS_SEM_CREATE(ðIntf->rxSem);
|
ETHLIB_OS_SEM_CREATE(ðIntf->rxSem);
|
||||||
ETHLIB_OS_THREAD_DEFINE(ethinf_proc_thread, ipp, 10, 4096, ethIntf);
|
ETHLIB_OS_THREAD_DEFINE(ethinf_proc_thread, ipp, osPriorityHigh, 4096, ethIntf);
|
||||||
ETHLIB_OS_THREAD_CREATE(ipp, ethIntf);
|
ETHLIB_OS_THREAD_CREATE(ipp, ethIntf);
|
||||||
|
|
||||||
ethIntf->ipra = ipra_new();
|
ethIntf->ipra = ipra_new();
|
||||||
|
@ -249,6 +249,8 @@ void dhcp_request(ip4_addr reqAddr, ip4_addr dhcpServerAddr) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void dhcp_process(DhcpProps *props, DhcpOption *opts) {
|
static void dhcp_process(DhcpProps *props, DhcpOption *opts) {
|
||||||
|
MSG("ENTER\n");
|
||||||
|
|
||||||
ETHLIB_OS_MTX_LOCK(&s.procMtx); // LOCK!
|
ETHLIB_OS_MTX_LOCK(&s.procMtx); // LOCK!
|
||||||
|
|
||||||
switch (s.state) {
|
switch (s.state) {
|
||||||
@ -314,6 +316,8 @@ static void dhcp_process(DhcpProps *props, DhcpOption *opts) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ETHLIB_OS_MTX_UNLOCK(&s.procMtx); // RELEASE!
|
ETHLIB_OS_MTX_UNLOCK(&s.procMtx); // RELEASE!
|
||||||
|
|
||||||
|
MSG("EXIT\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
static int dhcp_resp_cb(const Pckt *pckt, PcktSieveLayerTag tag) {
|
static int dhcp_resp_cb(const Pckt *pckt, PcktSieveLayerTag tag) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user