To make it clearer that these helpers are intended only for
Bluetooth-subsystem internal code, move them to a separate file.
Change-Id: Iea64780f5c61c1c96e12c9df378676bc49498fe4
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This allows to easily checks if all samples builds with supported
configurations. Also tester application is (unlike other samples)
build with all Bluetooth debugs enabled.
Change-Id: Ia151b97d14c75b0509243e2c1dc8d26211f70e83
Signed-off-by: Szymon Janc <szymon.janc@tieto.com>
Always prefix UUIDS for characteristics with service name.
Change-Id: Ic435fa725e6bc8918af631632156b071121cd0e0
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This makes use of new guidelines to document Bluetooth UUID API.
Change-Id: Ib4c96f97709610b762f6e839294a4db3ac447e73
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Adds internal HCI interface routine for creation of basic ACL LE link.
Most of the command interface parameters are fixed.
The internal interface is then used directly by simple public interface with
no connection validation.
Change-Id: I8ed72a9d01348e2a05b62facc9e85060e4500631
Signed-off-by: Arkadiusz Lichwa <arkadiusz.lichwa@tieto.com>
According to section 3.7 of Documentation/kbuild/makefiles.txt, using
EXTRA_CFLAGS in Makefiles is "still supported but their usage is
deprecated."
Change-Id: I585a9f84e8239a59b0f5b29eed0dc70efa253522
Signed-off-by: Szymon Janc <szymon.janc@tieto.com>
Now that we have a publicly exposed connection object it makes sense
to pass that to the connection callbacks rather than an address.
Change-Id: I8e9b17733d1789539a83c3dbc7a778336d2b71ff
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
For consistency, when including public header files, use <> rather
than "".
Change-Id: Id780388759c33d865f49c9e0faf9cde2251ca869
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This one should be used for all public connection related APIs. Right
now it includes the reference counting and connection callback APIs.
Change-Id: Ib9b67e6115bb2e51322644757da1170851c3ca17
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
We'll have a public conn.h header file soon, so to avoid confusion
rename the existing conn.h to conn_internal.h.
Change-Id: I5e5c89ec184a0a2de63e244b034c55a3d97af9dc
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This fix a build issue after last rename of TIMO -> ZEPHYR in build
system variables.
Change-Id: Iba9fb2ae13df0c66c7c1031b3a27795a9ead0e97
Signed-off-by: Szymon Janc <szymon.janc@tieto.com>
Add build test for beacon app for following targets: pentium4 and
ti_lm3s6965.
Change-Id: I4b8949b4f21d3554465bbf8c229462c026db5e29
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
This commit sends a draft of the topics that will be included
as a section for Kbuild documentation.
It also includes content for the Kconfig Structure section.
The intention of this draft is to start gathering comments on
the content sent and the initial menu of topics.
Change-Id: I11f62b015ef0fc722f5e0a089ec83cb0a08b3889
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@linux.intel.com>
export TMP if you want the out of tree tests to write
to something else other then /tmp
Change-Id: I77b1dffe5fa5e61db66a8d754370a0cd47511ab4
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit fix an error with the clean targets.
The package directory does not exist anymore.
Change-Id: I415085cb35eda9a1f30d6b53a5529e1fb2a8447a
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@linux.intel.com>
Kconfig creates a header file per each Kconfig symbol that changes
in between configuration changes and rebuilds.
This commit creates the files in the output directory specified by the
O environment variable.
Change-Id: I01b3482e9497f70961268505865788385b41ca8f
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@linux.intel.com>
File name had wrong extension.
Change-Id: I9b8f57d21b2a497bf53e159a62dfee24a4c5de21
Reported-by: Rick Demers <richard.demers@windriver.com>
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The type of the handler variable was missing, causing compile failures.
Change-Id: I33c0f8d2893de0c6ad14f33ecb03b106c87cf758
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Some files were left in bsp/ after a failed rebase.
Change-Id: I26d34387d751ddd831b2dfef5c8cb6a1a8904b3c
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
As the macros ALIGN_STRUCT(x) and PACK_STRUCT are no longer used, it is safe
to remove them. (Their replacement macros are __aligned(x) and __packed.)
Change-Id: If52302b6fba91ac707af828396592ecc3016934d
Signed-off-by: Peter Mitsis <peter.mitsis@windriver.com>
Simple tests to verify whether the microkernel timer system works
alongside the nanokernel timeouts and timers system.
Once the timer test is started, the nanokernel fifo timeout test is
started in parallel: each other's timeout times should not be affected
by the other. Also, a fiber is started, pending on a nanokernel timer,
and awakens in the middle of the microkernel timers expiring.
Change-Id: I05b307e58ac942961a4163cbe845a9bb732ecfb7
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Test the nano_xxx_fifo_wait_timeout() APIs.
First, the task waits with a timeout and times out. Then it wait with a
timeout, but gets the data in time.
Then, multiple timeout tests are done for the fibers, to test the ordering
of queueing/dequeueing when timeout occurs, first on one fifo, then on
multiple fifos.
Finally, multiple fibers pend on one fifo, and they all get the
data in time, except the last one: this tests that the timeout is
recomputed correctly when timeouts are aborted.
NOTE: The timeout APIs test is contained within its own file so that it
is easily reusable by a microkernel test that verifies that nano
timeouts and microkernel timers can coexist.
Change-Id: I5aae2d89651914fb6c39d8d09a56c7fa54533453
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Test the nano_xxx_lifo_wait_timeout() APIs.
First, the task waits with a timeout and times out. Then it wait with a
timeout, but gets the data in time.
Then, multiple timeout tests are done for the fibers, to test the ordering
of queueing/dequeueing when timeout occurs, first on one lifo, then on
multiple lifos.
Finally, multiple fibers pend on one lifo, and they all get the
data in time, except the last one: this tests that the timeout is
recomputed correctly when timeouts are aborted.
Change-Id: Ida951fda746539253b9a165f48be6931d6bee05c
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Test the nano_xxx_sem_wait_timeout() APIs.
First, the task waits with a timeout and times out. Then it wait with a
timeout, but gets the semaphore in time.
Then, multiple timeout tests are done for the fibers, to test the
ordering of queueing/dequeueing when timeout occurs, first on one
semaphore, then on multiple semaphores.
Finally, multiple fibers pend on one semaphore, and they all get the
semaphore in time, except the last one: this tests that the timeout is
recomputed correctly when timeouts are aborted.
Change-Id: I73c174e6f15f38377a14573cb7f531e5e6ca4c07
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The test verifies that delayed fibers are started in the right order,
and that cancelling delayed fibers recomputes correctly the timeouts in
the queue. Also test the fiber_sleep() API.
Change-Id: Ic3169a90b434a81c96e7c5d3c74c39431c988f39
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Allow configuring nano timeouts. They are disabled by default.
Change-Id: I9db0b632681ae149295acd3ed81fccdee2c4f91a
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The microkernel now announces the nanokernel ticks, and takes them into
account when computing the amount of time to stay in tickless idle.
This allows code linked against a microkernel to use the nanokernel
timers and timeouts.
Change-Id: I9436347e22fe76c2c1a314589ffc041a9a1a99a4
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The nanokernel time tracking code (ticker) can now exist in microkernel
systems. This allows the ticker that drives nano timers and timeouts to
advance the tick count for these in a microkernel, thus allow their
presence there. Previously, nano timers could not be used in a
microkernel.
Change-Id: I17f2b659691a081b0f9bf3961ed030533aa02a15
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
This interface can be called by the microkernel to obtain the earliest
expiring nanokernel between the timers and timeouts, to allow the idle
code to take the correct decision w.r.t. tickless idle.
Change-Id: I9598ec2a0dd013a6a8ccc95d50105bb98ca27f54
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The system clock code only references it, it should not own it.
Change-Id: I38eb61599eb66458d5a3c3c9713cf11dc14e8a63
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Add the necessary call to dequeue the nano timeouts when a tick occurs
in the nanokernel.
Change-Id: I26fdfc4084d7564e232d8240eab8915076deaa31
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The nanokernel timers and timeouts won't be dependent on each other, so
the expiry handling code needs to be able to only contain the necessary
code depending on what is enabled in the kernel.
Change-Id: Ibb7c31e926a56ebd3e22b8eac6db05faa1c8ddd3
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The nanokernel timers will be available in the microkernel, but can be
disabled if not needed. A kconfig option is needed for that: the option
is enabled by default, and only available in the nanokernel for now. It
will be made available in the microkernel in the future.
Change-Id: I3910affde7bd2e7b25ab0a3c655255a9be01c9b8
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The nanokernel timers are now available to microkernels, alongside
nanokernel object timeouts.
Change-Id: Ia2f0b93e8f848fd02b7260e35c0322d6501c8280
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The nanokernel needs access to these values since the nanokernel objects
API will provide a way of waiting with timeouts.
Change-Id: I2b39fccc1c2a2b5ba937aff774ab2ebc649e643b
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Add the _timeout() variants to the _get_wait() routines. Those allow
waiting with a timeout. The return values are the same as for the
regular _get() routines: a valid pointer on success, NULL on failure.
Note that the task_ variant is still polling, and the task is not put on
a timeout queue, instead polling for the ticker change in addition to
data arriving on the LIFO.
Change-Id: Iad8fa00b3fa0656fee9a67b2dd8b316e1e8aac74
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Add the _timeout() variants to the _get_wait() routines. Those allow
waiting with a timeout. The return values are the same as for the
regular _get() routines: a valid pointer on success, NULL on failure.
Note that the task_ variant is still polling, and the task is not put on
a timeout queue, instead polling for the ticker change in addition to
data arriving on the FIFO.
Change-Id: I6650d0de8494c15698d670442da1e9c8d8c89910
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Add the _timeout() variants to the _take_wait() routines. Those allow
waiting with a timeout. The return values are the same as for the
regular _take() routines: 1 for success, 0 for failure.
Note that the task_ variant is still polling, and the task is not put on
a timeout queue, instead polling for the ticker change in addition to a
semaphore state change.
Change-Id: Idef357f99a5ca30e20665a25abc54d253a848a52
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
This new API allows starting a fiber with a delay. It returns a handle
to allow cancelling it before the fiber starts, via the cancel API.
It also adds an API allowing a fiber to sleep for a given amount of
ticks.
NOTE: CONFIG_NANO_TIMEOUTS must be enabled.
Change-Id: I608dc47b5f08321cfd0c1dd9bb18d1d77eab87e3
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
s_NANO contains the timeout queue, and each ccs needs a struct
_nano_timeout object that gets linked in the nanokernel timeout queue.
Change-Id: Iad027eaaebcffe190e95f0b9d068f047062559c2
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
The timeout queue interface will allow having fiber interacting with the
nanokernel objects wait with a timeout. It can be completely excluded
from the kernel if not needed, via the CONFIG_NANO_TIMEOUTS option.
Most of the timeout queue interface is contained within timeout_q.h.
However, this file should never be included directly: rather, the
wait_q.h file is to be included instead, which itself provides NOOP
abstractions for some timeout functions when timeouts are not enabled in
the kernel.
Change-Id: Ifeb1b934e0c71d00c59ebc88a54ab26e49686807
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>