Commit Graph

14 Commits

Author SHA1 Message Date
Jonathan Hui 48b9299544 Clean up error names. (#1764) 2017-05-23 09:34:35 -07:00
Jonathan Hui fbfd76a990 Apply #include code style. (#1723) 2017-05-05 11:28:29 -07:00
Abtin Keshavarzian 41b82d3a89 Fix typos in comments (#1688) 2017-05-01 14:46:30 -07:00
Jonathan Hui 1eabda6a08 Change top-level namespace from 'Thread' to 'ot'. (#1664) 2017-04-27 22:29:05 -07:00
DuaneEllis-TI d65418c12f Add support for wrap_string.h and others (#1642) 2017-04-27 10:17:09 -07:00
Nick Banks 2549d03f1f Add Dynamic Memory Support to otLwf.sys (#1414)
* Add Dynamic Memory Support

* Use single list for free buffers. Null mNext on return of new buffer.

* Use Paged memory for Buffers.
2017-03-06 13:39:56 -08:00
Jonathan Hui 31b389fb4e Change otMessage type to not hide pointer. (#1416) 2017-03-02 12:43:59 -08:00
Jonathan Hui d0c687505b Move openthread.h to openthread/openthread.h. 2017-03-02 10:24:55 -08:00
Jonathan Hui 98da7f3166 IPv6 API cleanup. 2017-03-02 10:24:55 -08:00
Jonathan Hui 1455b612f9 Message API cleanup. 2017-03-02 10:24:55 -08:00
Jorge Vergara f3817e76cf Enable mbedTLS dynamic memory allocation in user mode on Windows (#1373)
* change user mode openthread to enable dynamic memory allocation in mbedtls

* complete merge by adding OPENTHREAD_MULTIPLE_INSTANCE to last file

* remove some extraneous changes that got pulled in accidentally

* fix spacing

* fix crash in existing tests due to this change

* fix x86 build
2017-02-23 22:01:59 -08:00
Abtin Keshavarzian 3fbba0eced Adding otMessageQueue OpenThread C APIs and their unit test (#1115) 2017-01-09 08:33:26 -08:00
Abtin Keshavarzian d0cf21e3ba PriorityQueue and MessagePool::Iterator and their unit-test (#1096)
This commit contains the following:

- It adds methods to `Message` to assign a priority level to messages.
  Currently there are four priority levels: High, Medium, Low, VeryLow
  but this is easily changeable.

- It introduces a new class `PriorityQueue` which implements a FIFO queue
  for storing messages based on their priority level in addition to oder
  in which they are added.
  If the priority level of an already queued message in a `PriorityQueue`
  is changed, the associated queue will automatically move the message
  within the queue based on its new priority level.
  Internally the implementation uses a circular doubly linked-list with
  an array of tail pointers associated with different priority levels.

- It adds new methods and an `Iterator` class  in `MessagePool` to access
  the priority queue where all allocated and queued messages from this
  pool are stored.  The `Iterator` class allows bi-directional iteration
  through the list (from highest priority to lowest or reverse).

- This commit also contain detailed unit-test for all the newly added
  features/methods.
2016-12-21 13:50:57 -08:00
Abtin Keshavarzian 9d3bd7802b Update the MessageQueue and add unit test for it. (#1089)
This commit makes the following changes:

- It adds a unit test for testing different `MessageQueue` operations.

- It modifies how the `MessageQueue` determines the lists (the `kListAll`
  is maintained by the message pool and the `kListInterface` is accessed
  from the `MessageQueue` associated with the list).

- It modifies the underlying list implementation to use a circular doubly
  linked-list.
2016-12-20 08:46:58 -08:00