[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [bug #48510] DHCP requires ARP
From: |
Jens Nielsen |
Subject: |
[lwip-devel] [bug #48510] DHCP requires ARP |
Date: |
Thu, 14 Jul 2016 09:31:22 +0000 (UTC) |
User-agent: |
Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36 |
URL:
<http://savannah.nongnu.org/bugs/?48510>
Summary: DHCP requires ARP
Project: lwIP - A Lightweight TCP/IP stack
Submitted by: deft
Submitted on: Thu 14 Jul 2016 09:31:19 AM GMT
Category: DHCP
Severity: 3 - Normal
Item Group: Faulty Behaviour
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Planned Release: None
lwIP version: git head
_______________________________________________________
Details:
Correct me if I'm wrong but there's a snippet in dhcp_start() that
unnecessarily rejects all netif's without ARP
/* check hwtype of the netif */
if ((netif->flags & NETIF_FLAG_ETHARP) == 0) {
LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): No ETHARP
netif\n"));
return ERR_ARG;
}
I have a non-ethernet interface which may require DHCP (USB MBIM profile), I
have never seen this actually happen but I would still like to implement it.
I suggest two options:
Patch 1: Surround the check with #if DHCP_DOES_ARP_CHECK
Patch 2: Remove the check and only do the check if the netif has
NETIF_FLAG_ETHARP.
Option 2 would allow my netif to coexist with an ethernet one but I guess it
makes the code more confusing and maybe not worth it for a corner case.
I haven't been able to test this properly since I don't really have a
non-ethernet dhcp setup but I can put some effort into it unless someone knows
something I don't and/or think this is a bad idea...
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: Thu 14 Jul 2016 09:31:19 AM GMT Name: dhcp_arp_1.patch Size: 1004B
By: deft
<http://savannah.nongnu.org/bugs/download.php?file_id=37870>
-------------------------------------------------------
Date: Thu 14 Jul 2016 09:31:19 AM GMT Name: dhcp_arp_2.patch Size: 2kB By:
deft
<http://savannah.nongnu.org/bugs/download.php?file_id=37871>
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?48510>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
- [lwip-devel] [bug #48510] DHCP requires ARP,
Jens Nielsen <=