Note that the failure case can only be reached when PCI is enabled.
Otherwise, the if-block is always false, which reduces code size
for non-PCI platforms.
Change-Id: I71656468eaee702bc481f5fbd490677b7bc491c1
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Note that the failure case can only be reached when PCI is enabled.
Otherwise, the if-block is always false, which reduces code size
for non-PCI platforms.
Change-Id: I1f9def66b2ce7f08fc13b8f03e675ce4cd469e6d
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Note that the failure case can only be reached when PCI is enabled.
Otherwise, the if-block is always false, which reduces code size
for non-PCI platforms.
Change-Id: Ib98b78a75cc2a5f124e67f32f2bf82960a963aec
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This converts the pinmux/dev drivers to use DEVICE_AND_API_INIT(),
since the driver_api assignment will never change.
Change-Id: I0063b19e2afe932e1daf3255e718455aaa200ff1
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds the DEVICE_AND_API_INIT() macro to take in a parameter
to assign to device->driver_api. This eliminates the need to
assign to driver_api during runtime device initialization.
This provides an alternative way to declare devices. This should
save a few bytes in ROM for those devices that will never fail
initialization (in other words, never need to manipulate
driver_api pointer at all).
Also clean up the documentation a bit to remove duplicated
block of information.
Change-Id: I6abed1abe75db2e8babfcf1ecf590491132a5543
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Enables to get right channel reference on both connection transports,
LE and BR/EDR.
Change-Id: Ia577963132e3a600cd9a95b90f218a5bffee8e58
Signed-off-by: Arkadiusz Lichwa <arkadiusz.lichwa@tieto.com>
Adds the missing @ingroup for counter API so it appears
under device driver category.
Change-Id: I763faab802d3a6453ab46ee969b5ffd082282f1d
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The L2CAP reject command can now be propagated over both connection
transports, LE and BR/EDR.
Change-Id: Ie8466490ed205e194a586646f496ebfce5ceea70
Signed-off-by: Arkadiusz Lichwa <arkadiusz.lichwa@tieto.com>
Primary and secondary service attributes discovery uses att_find_type,
include service and characteristic uses att_read_type.
Change-Id: Ia3539b446a4afb5c72bc1aba443167be6f893d0d
Signed-off-by: Grzegorz Kolodziejczyk <grzegorz.kolodziejczyk@tieto.com>
With this patch net_buf based heap will be used to store attribute
user_data and UUID. This is the first step to remove gatt_buf.
Change-Id: I578f26b781e01f5f3464c05f7210dc27cdea8edf
Signed-off-by: Mariusz Skamra <mariusz.skamra@tieto.com>
We have not found any use-cases for dynamic IRQs where a static
IRQ did not also suffice. Deprecate so that we can eventually
remove from Zephyr and nontrivially decrease the complexity of
the kernel.
Change-Id: I509655371773aeaca7d01134dd850eb4cd95f387
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This mechanism does not add enough value to the kernel to be worth
maintaining it. Drivers that need deferred processing of interrupts
can simply define their own task and have the interrupt handler
release an event that the task waits on.
The API is marked as deprecated and it is removed from unit test
coverage as well as the documentation.
Change-Id: Ib87b91cb41e9b6d7fdf0dc62b240a531b6a8889f
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
Most iuts data base are intended to have its attribute database builded
in sequence and its constant (except attribute values, parameters,
permissions). Patch allows btp specification to cover also devices
which cannot assign an ID right after issuing add attribute command or
set attribute component (which points to defined attribute ID).
Change-Id: Ie8e5ed223609cca2b6e3fb8444065f33b1408142
Signed-off-by: Grzegorz Kolodziejczyk <grzegorz.kolodziejczyk@tieto.com>
This fixes conn->gatt_private = NULL pointer dereference that occurs
in the next Read Blob Response, here:
/* TODO: Get params from user_data pointer, not working at the moment */
params = conn->gatt_private;
Change-Id: Icf280c856133a4c91fc10475d3a047809f917f46
Signed-off-by: Mariusz Skamra <mariusz.skamra@tieto.com>
This allows to accept or decline incoming pairing that would
otherwise result in JustWorks pairing.
Change-Id: I759ea067ef298b437e0112b8b7ef3bedf106dc52
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
GPIO is not needed for quark_se_devboard for now when dealing with
NBLE.
Change-Id: I0dedf2bee0af153e1d6e224d90f4662f5601b2b7
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
GPIO would be selected by BLUETOOTH_NRF51_PM
Change-Id: I5d920723a46c1455d34c90c9dc43b21b91569ce1
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
If incoming pairing request would result in JustWorks pairing this
can be used to request consent from user for accepting it.
Change-Id: If0695d0e1bb010bade6a16abe1b57a2ce07856cc
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
This is in preparation for adding support to confirm incoming pairing
requests. smp_pairing_req is now more similar to smp_pairing_rsp making
code easier to follow.
Change-Id: Ie5a77ae5092b7bbf76a482d0bd49e022c4d19d70
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
Parse include function intention is to return last parsed included
service handle. Next discovery iteration of included services should be
started from last found included service handle instead of end handle
from included handle value (which contains attribute handle of included
service declaration and the end group handle, BLUETOOTH SPECIFICATION
Version 4.2 [Vol 3, Part G], 4.5.1).
Change-Id: I73fe4027cb616242e838ea54c61b7780f1838e52
Signed-off-by: Grzegorz Kolodziejczyk <grzegorz.kolodziejczyk@tieto.com>
If on_nble_gattc_read_rsp returns an error, this error shall be
passed to the application to let know that Read Request/Read Blob Request
was aborted due to ATT error received.
Change-Id: I0efe26ec90fe27a1ab3c791e555ebe682927ab57
Signed-off-by: Mariusz Skamra <mariusz.skamra@tieto.com>
The Read Response only contains a Characteristic Value that is less
than or equal to (ATT_MTU – 1) octets in length so, condition
(length < bt_att_get_mtu(conn)) is always true, and the full
Characteristic Value will not be read.
Change-Id: Ib18fbedf277c880dc5cf0ce21fd7d550d12a64ef
Signed-off-by: Mariusz Skamra <mariusz.skamra@tieto.com>
Disable reception and the oscillator as well when stopping. Revert
when starting.
Change-Id: I2a61066602267ac61e691ec9c20eb243de6fa076
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
This prevents false packets to get accepted/generated into RX fifo.
Also, this will make AUTOACK working properly, when enabled. For some
reasons FRMFILT1 and SRCMATCH need to get their reset values written at
initialization, or then hw filtering won't work. This behavior is not
documented as it seems.
Change-Id: Ic0fe664dbc3b17d85d794c12b77bdbaafeb601f5
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
For hw filtering and autoack to work, all the information should be
properly set in the chip.
That's a fix for the legacy radio/net API. From original code, these
were set from the application which is bad. But setting it from the
driver is not any better. ieee802154 and net stack should know what to
do, that will be fixed in the future.
Change-Id: I1688223e9488d10a423e788eb88ba1e251cb3f88
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
It will not build without it. Generalize it then.
Change-Id: I334586f629de1f057e654a13a1c705cd559b44d8
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Changed conf.py to use env var in the version of documentation.
CI can take advantage of this to name documentation using
tag version from git.
Change-Id: If59f800ccd37648a9c0dab6c948b13166a7f4aed
Signed-off-by: Javier B Perez <javier.b.perez.hernandez@intel.com>
Slope threshold attribute values should be received in m/s^2 instead
of Gs, since accel channels return data in m/s^2.
Change-Id: I0669345ff8af8559e47895bca8225e15d2576a06
Signed-off-by: Bogdan Davidoaia <bogdan.m.davidoaia@intel.com>
Use the SENSOR_G constant from sensor.h in all accelerometer
drivers, instead of having the constant redefined in each
driver header file.
Since GRAVITY_CONST was measured in mili-m/s^2 and SENSOR_G
is measured in micro-m/s^2, some changes to the calculation
of the acceleration data were added.
Change-Id: Ia323dfc46bee00035e24b37e1b7fbc886dfbe029
Signed-off-by: Bogdan Davidoaia <bogdan.m.davidoaia@intel.com>
Edited the microkernel API sections to get the proper linakage.
Change-Id: I1bc95c6e21ed996c4c5d72188c5f018038e3e958
Signed-off-by: Gerardo Aceves <gerardo.aceves@intel.com>
If the driver fails initializations, do not set the driver_api.
This follows the idea that device_get_binding() will not return
a reference to the driver instance when driver init fails.
Change-Id: Iff56b4150658a76567928b1fd166bde5d2848d52
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
- Put everything in one page and simplify workflow.
- Fix indent and layout
Change-Id: Ifd9d11531c9b906324cf87cf401cbce416cc01a4
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Integrate the notes into the actual steps, notes are usually understood
as optional and disturb the actual flow.
Change-Id: If3168581ca130bd506bc44c353acc082dfa003fd
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Merge documents and improve structure. Avoid too many jumps to get
to the information and avoid single paragraph pages.
Change-Id: Ifed4fa90d1105022bfe87e6d078845938e13bd3a
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add sensors and networking into the new section and seperate
those from the kernel documentation.
Change-Id: I585845c3ba09173ced7caa0b7fbc1f1a81a26f96
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Put all device drivers and device model documentation into one
section.
Change-Id: Iba6a50796b02b7f9234c23dca706be62fd7b4259
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Because the random number generator is very dumb at the moment,
the generated MAC address has always last byte set to 0.
The MAC address is used when generating IPv6 address.
In order to avoid IPv6 address collision, swap the last four
bytes of the MAC address so that the most random data is
at the end of the MAC.
Change-Id: I96c03654359e32f407bab3b29be0e3b08ee91bd7
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
On each net_receive() call with different destination and/or port,
µIP stack consumes a uip_udp_conns[UIP_UDP_CONNS] entry.
As net_context_put() doesn't free it up, Zephyr applications can very
quickly reach the point where it can no more create new UDP connection
(default UIP_UDP_CONNS value is 10).
This patch is both IPv4 and IPv6 compliant.
It modifies net_context_put() so that it frees up such entries if
a UDP connection is registered for the context provided as argument.
Change-Id: I9abe686c81368231d4443fc53da9038761a1787d
Signed-off-by: Jeremie GARCIA <jeremie.garcia@intel.com>
() The test names are getting longer so adds more padding.
() Aligns the numerical size numbers for easier visual
comparison when scrolling in shell.
Change-Id: Id218a641e9d5dffb77bf813ffbd828c48d14020f
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Some boards require a newer version of openocd, this will
allow overriding the default version that comes with the SDK.
Change-Id: I70113182c3a2c8610e3b36542c6057ff3f0df547
Signed-off-by: Anas Nashif <anas.nashif@intel.com>