lwIP - A Lightweight TCP/IP stack - Bugs: bug #52770, mdns: move the announcements to a...
You are not allowed to post comments on this tracker with your current authentication level.
bug #52770: mdns: move the announcements to a timer callback
Submitter: | Douglas <ourairquality> | ||
Submitted: | Sun 31 Dec 2017 07:33:25 AM UTC | ||
Category: | DNS | Severity: | 3 - Normal |
Item Group: | Change Request | Status: | None |
Privacy: | Public | Assigned to: | None |
Open/Closed: | Closed | Planned Release: | None |
lwIP version: | git head |
Jump to the original submission
Thu 04 Jan 2018 07:04:48 AM UTC, comment #24: |
Simon Goldschmidt <goldsimon> |
Wed 03 Jan 2018 07:18:39 PM UTC, comment #23: You say stack usage is the main problem. Wouldn't the simplest solution for you be to configure your netif via tcpip_callback() instead of from your application thread using the netif API? This should solve your problem, or am I wrong?
|
Dirk Ziegelmeier <dziegel> |
Wed 03 Jan 2018 07:02:06 PM UTC, comment #22:
|
Simon Goldschmidt <goldsimon> |
Wed 03 Jan 2018 03:02:25 PM UTC, comment #21:
|
Douglas <ourairquality> |
Wed 03 Jan 2018 02:34:04 PM UTC, comment #20: Douglas, any response to my comment #17? |
Simon Goldschmidt <goldsimon> |
Tue 02 Jan 2018 07:34:22 PM UTC, comment #19: I'm OK with using a timer if we need one. But even in this case, we would start the collision test phase as soon as possible, right? Not after an arbitrary delay. I still say that 50ms delay is hiding things we should fix. That's why I still take part in this discussion.
|
Simon Goldschmidt <goldsimon> |
Tue 02 Jan 2018 07:28:24 PM UTC, comment #18: I think the timer is a reasonable start. Before the announcement is done, we really should query our names for collisions - and this will need a timer. |
Erik Ekman <yarrick> |
Tue 02 Jan 2018 07:01:27 PM UTC, comment #17:
|
Simon Goldschmidt <goldsimon> |
Tue 02 Jan 2018 12:24:02 PM UTC, comment #16:
|
Douglas <ourairquality> |
Tue 02 Jan 2018 11:34:28 AM UTC, comment #15: I'm afraid I don't understand. What's missing for you now? You can pass 'mdns_resp_announce' to tcpip_callback() (which won't get removed!) or sys_timeout(). That will fix your stack requirements. Or is stack usage still too high?
|
Simon Goldschmidt <goldsimon> |
Tue 02 Jan 2018 11:03:59 AM UTC, comment #14:
|
Douglas <ourairquality> |
Tue 02 Jan 2018 10:04:41 AM UTC, comment #13: I just committed that adding netifs/services does not automatically announce any more. You can now call mdns_resp_announce() via mdnsapi_mdns_resp_announce() or using tcpip_callback() - is your problem solved now?
|
Dirk Ziegelmeier <dziegel> |
Tue 02 Jan 2018 09:46:43 AM UTC, comment #12:
|
Douglas <ourairquality> |
Tue 02 Jan 2018 09:30:31 AM UTC, comment #11: What I meant was the administative "up" of a network - before calling "netif_set_up()", not before the link is up or an IP was assigned. |
Dirk Ziegelmeier <dziegel> |
Tue 02 Jan 2018 09:20:34 AM UTC, comment #10:
|
Douglas <ourairquality> |
Tue 02 Jan 2018 08:23:46 AM UTC, comment #9: I don't like to add another timer for this, its not worth it (yet another thing to configure in lwIP for MDNS - NUM_TIMOUTS needs to be increased). There are two solutions:
|
Dirk Ziegelmeier <dziegel> |
Sun 31 Dec 2017 01:40:38 PM UTC, comment #8:
|
Simon Goldschmidt <goldsimon> |
Sun 31 Dec 2017 01:37:18 PM UTC, comment #7:
|
Douglas <ourairquality> |
Sun 31 Dec 2017 01:16:20 PM UTC, comment #6: Let me phrase it differently. Up to now, there has been a more or less clean separation between "core" code (callback apis, single thread only) and the "API" layer (tcpip_thread, netconns, sockets, etc).
|
Simon Goldschmidt <goldsimon> |
Sun 31 Dec 2017 11:46:19 AM UTC, comment #5:
|
Douglas <ourairquality> |
Sun 31 Dec 2017 10:44:12 AM UTC, comment #4:
|
Simon Goldschmidt <goldsimon> |
Sun 31 Dec 2017 10:24:59 AM UTC, comment #3:
|
Dirk Ziegelmeier <dziegel> |
Sun 31 Dec 2017 10:22:36 AM UTC, comment #2:
|
Douglas <ourairquality> |
Sun 31 Dec 2017 09:40:46 AM UTC, comment #1: I'd rather like to fix the real problem - heavy stack usage by MDNS (aka bug #48953) instead of trying to hide the symptoms.
|
Dirk Ziegelmeier <dziegel> |
Sun 31 Dec 2017 07:33:25 AM UTC, original submission:
The guts of the mdns code uses a significant amount of stack for a small system. This makes it problematic calling into this code from the various paths that trigger announcements. This patch has these code paths queue an announcement that will be performed via a timer callback.
|
Douglas <ourairquality> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 2 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2018-01-04 | goldsimon | Open/Closed | Open | Closed | |
2017-12-31 | ourairquality | Attached File | - | Added 0001-mdns-move-the-announcements-to-a-timer-callback.patch, #42770 |
Powered by Savane 3.13-02a9.
Corresponding source code
This is more or less a duplicate to bug #48953.
And since it seems noone continues here, I'll close this for now.