Uploaded image for project: 'Zephyr'
  1. Zephyr
  2. ZEP-916

Eliminate kernel object API anomalies



      Most of this is already done, but keep for reference until this list is gone through with a fine comb:

      A potpourri of API inconsistencies that should be fixed:

      • Complete elimination of K_type_OBJ_DEFINE() macros.
        • These still exist for mutex and thread types.
      • Complete elimination of kernel object typdefs that aren't wanted.
        • These still exist for mutex and memory pool.
        • May also want to get rid of for timer?
        • May also want to get rid of for thread? (I think Ben has a good argument for keeping this one, but I'm not sure ...)
      • Add missing delay argument support for K_THREAD_DEFINE().
        • Currently can specify delay via k_thread_spawn() only ...
      • Ensure kernel object init API arguments match what's specified in the Kernel Primer (v2).
        • In some cases you may need to change the code – in other cases you may need to change the documentation.
        • Should review all kernel object types, but at one point there were issues with thread, memory map, stack, message queue, and pipe.
        • Issues to watch for:
          • Missing arguments; extra arguments; arguments in the wrong order.
          • Should try to have consistency when specifying "related" arguments. One thing in particular to try and ensure is that whenever an object is passed a pointer to a memory region and a size for that region, the pointer should be first and the size (or, in some cases, sizes) should be second. Right now we seem to have cases where the pointer comes last ...
      • ... other anomalies? ...


        No reviews matched the request. Check your Options in the drop-down menu of this sections header.



            • Assignee:
              pmitsis Peter Mitsis
              ajnebnim Benjamin Walsh
            • Votes:
              0 Vote for this issue
              5 Start watching this issue


              • Created: