patchlwIP - A Lightweight TCP/IP stack - Patches: patch #9831, Move core lock macros to...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

patch #9831: Move core lock macros to include/lwip/sys.h

Submitter:  Joan Lledó <jllledo>
Submitted:  Sat 13 Jul 2019 08:31:32 AM UTC
   
 
Category:  None Priority:  5 - Normal
Status:  Done Privacy:  Public
Assigned to:  goldsimon Open/Closed:  Closed
Planned Release:  None

Fri 26 Jul 2019 06:11:29 PM UTC, comment #3: 

Applied file #47254 with tiny fixes. Thanks for the patch.

Simon Goldschmidt <goldsimon>
Group administrator
Wed 24 Jul 2019 05:13:37 PM UTC, comment #2: 

It seems LWIP_MARK_TCPIP_THREAD it's only used when !NO_SYS, and same for LOCK_TCPIP_CORE and UNLOCK_TCPIP_CORE. So I could move LWIP_MARK_TCPIP_THREAD declaration to sys.h and [UN]LOCK_TCPIP_CORE to sys_arch.h in the linux port.

About LWIP_ASSERT_CORE_LOCKED, I couldn't find a way to move it to sys.h w/o updating all #includes, so I left it in opt.h, but at least now it's only one macro.

(file #47254)

Joan Lledó <jllledo>
Sat 13 Jul 2019 07:01:25 PM UTC, comment #1: 


> [..] is this the proper place? why aren't they declared in sys_arch.h?


Because sys.h is meant for files depending on NO_SYS=0, in other words, lwIP compiled with NO_SYS=1 (single threaded callback style without OS) would not need sys.h at all.

But yes, I see your problem of defining a function in lwipopts.h, which is not that ideal. Can you come up with a patch that allows you to declare those functions in sys_arch.h while preventing to change all those files to include sys.h?

Simon Goldschmidt <goldsimon>
Group administrator
Sat 13 Jul 2019 08:31:32 AM UTC, original submission:  

contrib/ports/unix/lib/lwipopts.h: sys_check_core_locking() and pals are declared in lwipopts.h, is this the proper place? why aren't they declared in sys_arch.h?

More info at:

https://lists.nongnu.org/archive/html/lwip-devel/2019-07/msg00001.html

Joan Lledó <jllledo>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by goldsimon (Posted a comment)
  • -email is unavailable- added by jllledo (Submitted the item)
  •  

    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 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-07-26 goldsimon StatusNone Done
        Assigned toNone goldsimon
        Open/ClosedOpen Closed
    2019-07-24 jllledo Attached File- Added 0001-Move-LWIP_MARK_TCPIP_THREAD-to-include-lwip-sys.h.patch, #47254
    2019-07-13 jllledo Attached File- Added 0001-Move-core-lock-macros-to-include-lwip-sys.h.patch, #47209

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code