Commit graph

42249 commits

Author SHA1 Message Date
Anas Nashif
35360df9be doc: index config variable only once
The index.rst file should reference variables only once.

Jira: ZEP-148
Change-Id: Ia5aad1d3ccd0f7c93fca94f1fa0ad88171eaf5c1
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-23 01:02:19 +00:00
Anas Nashif
e8bc8af602 quark_d2000: remove unused code
For Quark D2000 we use QMSI drivers, so the initialisation code is no
longer needed.

Change-Id: I22aaa35288e230c455a19b9e67dc6cfb7dc0ff12
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
b0c0040894 quark_se: quark_d2000: remove all defines that now come from qmsi
QMSI defines all the registers of the SoC and other values in
qm_soc_regs.h, so cleanup soc.h and rely on the data from the BSP
contained in qm_soc_regs.h.

Change-Id: I672925cf1c0144a9ed64073ea289c691285a8082
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
7c332df43b qmsi: use QMSI_LIBRARY instead of QMSI_DRIVERS
For linking with external library, use QMSI_LIBRARY and point
to path of the library using QMSI_INSTALL_PATH

Change-Id: Icd954188a26cc02074aa8fe08a4afdea31879f60
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
dcf2f48413 qmsi: pinmux: use built-in qmsi driver
Change-Id: I84064cd42d85a687a505473a012a07763b4301e8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
a6915c070d qmsi: spi: use built-in qmsi driver
Change-Id: Ic7e86e015d4beb11a01d75aa50bc50f95c784e5e
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
8e4f04d735 qmsi: spi: fixed warning due to const paramter in API call
Change-Id: I0cc6f5948a9f3d93aec970950c7b2db441bff570
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
a91b35b506 qmsi: flash: use built-in qmsi driver
Change-Id: I7e9fa271956c4e02998fa7f9cf19afcc3372f46f
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
1797c8f108 qmsi: uart: use built-in qmsi driver
Change-Id: Ie19aee8dad8ba082891f92a2d42dc71f4ac34dbe
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
b3e02b406a qmsi: adc: use built-in qmsi driver
Fix naming and use a global driver name for instance.

Change-Id: I30a54cb9c20773e1b6fdc57b934aa564612a6c45
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
85b3c2c62a qmsi: gpio: use built-in qmsi driver
Change-Id: I11444bcc146dbc477bb605f6b405bee559716f2a
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:55:36 -04:00
Anas Nashif
324a83bed7 nble: Use string name for GPIO driver
Do not depend on specific implementation of the driver, use
well-known driver name used across multiple IPs.

Change-Id: I823fcfa01ce1484dd89f6ade8fbe7017f2084bc6
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-23 00:54:34 +00:00
Anas Nashif
01aa9a1d37 samples: power: use string for driver name
Change-Id: I2a5d02cf13ce4ed304c0ebb3d81310aec9325add
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-23 00:54:33 +00:00
Anas Nashif
f4feacf8b2 qmsi: aon_counters: use built-in qmsi driver
Change-Id: I5df98e9eacf429f017a094c861dcf54ab61566c1
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
e6ab39a9c2 aio: rename sample name and make it generic
Change-Id: I3bd0a8b50551bec0bf4afeb6a912f558bc106de8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
b512681f8c qmsi: aio: use built-in qmsi driver
Change-Id: I24b227d9367a4f0144cb9fa968a51827f8c2dfc5
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
940d539834 qmsi: pwm: use built-in qmsi driver
Change-Id: I154840f704b9cfec269addaf3cbd7e71bb6310af
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
b46f9db04b spi: use global init priority
Do not have priority per IP, use one config instead.

Change-Id: Ieb2923d4749a294e2a1c677d47d56a14cee3f36d
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
82d4c96bd4 pwm: unify driver names
Use same string for driver name used for binding and fix
sample app to work with multiple drivers, not only DW driver.

Change-Id: I4d40aa9d4e83fcf16dc883bb74c3f0e3e30e3502
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
a7d3329694 qmsi: i2c: use built-in qmsi driver
Change-Id: I2e650198117128cec79a64abcd2cc065b5f9804c
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
98c09140f1 qmsi: watchdog: use built-in qmsi driver
Change-Id: I0cff75181bb2a51c91e6589f9624f0891db0b6e9
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:29 -04:00
Anas Nashif
80e9d63dec qmsi: rtc: use built-in qmsi driver
Change-Id: If8e70c946f73abf03a695fecaeff30a9881f6e94
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:28 -04:00
Anas Nashif
987016b954 drivers: add qmsi files for Quark MCUs
This is from QMSI porject at https://github.com/01org/qmsi

The version included in this change is 1.0.1:

https://github.com/01org/qmsi/releases/tag/v1.0.1

commit: c902bc5143546b76a3708ddb465ea9b7a8bd314a

Origin: https://github.com/01org/qmsi
Change-Id: I983deb2cffe2f84b7b7f2dd381367863eab7c6d1
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 20:46:28 -04:00
Anas Nashif
3aab249aa0 Bluetooth: add drivers to include path
Compiling without the drivers prefix causes the following type of
compiler error:

include/uart.h:42:21: fatal error: pci/pci.h: No such file or directory

Change-Id: I99cd814708e74ed4722e5e906819497010263337
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 17:58:39 -04:00
Anas Nashif
7c27d8ab3a soc: arm: add Makefiles one level up
It was not possible to add directories under an SoC family
because of the direct call to Makefile in the SoC series from the
architecture level.

While we have SoC still using the old structure, add a conditional
to still support old structure and allow Makefiles directly under
an SoC family directory. 

This is useful for adding drivers and BSP files common to one family.

Change-Id: I85dc8341523b41949de91d78675153ce0baa5aac
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 21:33:26 +00:00
Bogdan Davidoaia
ef26bf7848 i2c: add register access API
Add API for reading, writing and updating internal registers of I2C
devices. This API is meant to be used as a simpler way of communicating
with I2C devices that have 8-bit internal registers.

Change-Id: I7280eb530039aa10ad9cc19c1c309c7a2f473eb4
Signed-off-by: Bogdan Davidoaia <bogdan.m.davidoaia@intel.com>
2016-04-22 20:01:08 +00:00
Benjamin Walsh
1040509670 doc: add architecture porting guide
Explanations and guidelines when porting Zephyr to a new processor
architecture or ABI.

Change-Id: Ibb3a26636dca6b248103e4744c333911c2af0e50
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
2016-04-22 19:11:03 +00:00
Johan Hedberg
dd59f2704e Bluetooth: Add recently added SPI & I2C HCI bus defines
Change-Id: I23b9e32f21b279a4a830bfa5685fe7d8250a5afc
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-04-22 18:49:11 +03:00
Johan Hedberg
e3e91d3280 Bluetooth: Add name member to HCI driver struct
This is more of a convenience to let the driver identify itself in
debug logs and the monitor protocol.

Change-Id: I73351477e98d45d6344c180b8088bde29df6f7d9
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-04-22 18:49:11 +03:00
Johan Hedberg
4488fc6cab Bluetooth: Move HCI device bus information to the driver
The bus that we notify over the monitor protocol is really driver
specific, so let each driver specify their bus type.

Change-Id: Ic3a086fcc06352dbf051e52cef5bf6b8696349ae
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-04-22 18:49:11 +03:00
Johan Hedberg
8c3add2b6a Bluetooth: tests: Add automated tests for new monitor code
Add two new test cases to exercise the code in monitor.c.

Change-Id: I66ae70e0d3b61d3b852916333019e1ed2c5c6cf4
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-04-22 18:49:11 +03:00
Johan Hedberg
264c207f4f Bluetooth: Add custom "monitor" protocol logging over UART
With most boards there's no simple way to get access to the HCI
traffic. Simultaneously these boards only have one external UART for
the console. This patch introduces a protocol which combines both
normal logs and HCI logs over a single binary protocol sent over the
console UART.

The protocol is modeled based on the btsnoop/monitor protocols used by
BlueZ, and the first tool that's able to decode this is btmon from
BlueZ ("btmon --tty <tty>").

For platforms with two or more external UARTs it is still possible to
use CONFIG_UART_CONSOLE as long as the UART devices used are
different, however on platforms with a single external UART
UART_CONSOLE should be disabled if BLUETOOTH_DEBUG_MONITOR is enabled
(in this case printk/printf get encoded to the monitor protocol).

Origin: Original
Change-Id: I9d3997c7a06fe48e7decb212b2ac9bd8b8f9b74c
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-04-22 18:49:11 +03:00
Szymon Janc
ad475d863a Bluetooth: Remove RX priority fiber
Processing command complete and status events in separate fiber is not
really needed as those handlers doesn't block nor do heavy computation.
This work can be done directly from ISR making code simpler.
Additionaly priority fiber stack is no longer needed resulting in 256
bytes memory savings.

Change-Id: I2ecb29b720d3a886e7881a2208f697a834f4cdaf
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 15:41:32 +00:00
Grzegorz Kolodziejczyk
9ac1782cd8 quark_se_devboard: Configure default UART for UART_PIPE
This UART config is needed to handle properly btp tester serial data
flow.

Change-Id: Id013a232e105247414d44148f5ccfe708b19c4a8
Signed-off-by: Grzegorz Kolodziejczyk <grzegorz.kolodziejczyk@tieto.com>
2016-04-22 16:52:21 +02:00
Juan Manuel Cruz
401d67f91c debug: interrupt event logger sample for arc
Jira: ZEP-53
Change-Id: Idb24bb28d5f4b5f31f1cc32d9a9ec2b8c622543e
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@intel.com>
2016-04-22 12:39:22 +00:00
Juan Manuel Cruz
b17258b536 debug: interrupt event logger support for arc
Jira: ZEP-53
Change-Id: Id6ee505a7e89122a47fc22162b4c257ac2126d09
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@intel.com>
2016-04-22 12:39:22 +00:00
Daniel Leung
267e6e639c i2c/quark_se_ss: make structs and functions const and static
() Make driver API into const, as it is not being modified
   at runtime. Saves 24 bytes of RAM by putting it into ROM.
() Make device config structs as static as they are local to
   the source file, and should not be referenced from outside at all.
() Same goes for the IRQ configuration functions, by declaring them
   static.

Change-Id: I5225dc550bdd65ec88a8930944da063efe16a3b2
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2016-04-22 12:32:26 +00:00
Szymon Janc
85d44978a5 Bluetooth: shell: Add support for advertising with RPA
This allows to test local privacy feature.

Change-Id: Ib231f9187e353f79fee9237acef0d1ffe9cb2b7d
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 11:07:19 +00:00
Szymon Janc
68c707884e Bluetooth: Fail if advertise with unsupported address type
This allows to gracefully handle case when privacy is not enabled.

Change-Id: I3f4ebafd05abe186212b554161d8a8982f58ff45
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 11:07:11 +00:00
Andrei Emeltchenko
ac7a43a177 arduino_101: Correct UART name configuration
Change NBLE_UART_ON_DEV_NAME to BLUETOOTH_UART_ON_DEV_NAME for H:4

Change-Id: I4391b32c75c738478c964d4c79f6eb80d737b043
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-04-22 11:06:42 +00:00
Andrei Emeltchenko
45736940b9 quark_se_devboard: Add configuration for nimble HCI stack
Enable Power Management handling also for quark_se_devboard with
nimble HCI stack.

Change-Id: I6e5bb85c4f2370f52904be9dff14ce8e7fb1eb44
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-04-22 11:06:37 +00:00
Anas Nashif
13ce2d6285 doc: show information about documentation current version
show different information based on the state of the current
documentation and link to development version and released
versions depending on where the user lands.

Change-Id: Ifa6263900222db483efa0388e2588dd97222ecb6
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-04-22 10:54:38 +00:00
Szymon Janc
828fe15bbe Bluetooth: Always use RPA for connection if privacy is enabled
We should always use RPA for outgoing connection if privacy is enabled.
Otherwise privacy might be compromised if connecting to devices that
don't support pairing.

Change-Id: Ib12a5d9dfdc9285b5ff721f0fdb8f824ff1a8f0f
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 07:58:03 +00:00
Szymon Janc
7ba5715ae0 Bluetooth: Remove double address comparison
set_random_address already checks if current random address needs
to be updated so there is no need to double check that before it
is called.

Change-Id: If5fe16f1b886aa877bf014a8977ccaea2c8ba6e0
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 07:57:43 +00:00
Szymon Janc
605f7a0979 Bluetooth: Simplify creation of LE connection
hci_le_create_conn sets controller random address to one from
connection so there is no need to do that again in command status
event.

Change-Id: I22a24a46946413489445e577341cbf6ea68c0964
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 07:57:02 +00:00
Szymon Janc
4e4b81f06f Bluetooth: Simplify setting advertising parameters
There is no need for special handling of command complete when
using bt_hci_cmd_send_sync for sending HCI command.

Change-Id: I60671e490958e67f5d20dc8c6ddbf51ca839c338
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 07:55:53 +00:00
Szymon Janc
e5493c9ac8 Bluetooth: Simplify setting random address
There is no need for special handling of command complete when
using bt_hci_cmd_send_sync for sending HCI command.

Change-Id: Ib67f06d47249d24854c07be34b0e39f70f5d5170
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-04-22 07:55:42 +00:00
Andrei Emeltchenko
1b737d4cf4 quark_se_devboard: Enable PM for the board
Enable Power Management and enable logic for quark_se_devboard,
without the patch BLE Radio module might be enabled with JTAG tools
or right after boot.

Note that some boards do not have the GPIO pins connected to BLE
module but this should be still OK wrt to board functionality.

Change-Id: I9019e406afa36fe2dea52c07075c947e8c50a961
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-04-21 15:31:17 +00:00
Andrei Emeltchenko
5860325b4f drivers/nble: Cleanup Nordic RPC code
Remove handling not used and obsolete function prototypes.

Change-Id: I6086f2e13efe7fc219f237dda710a545bec07612
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-04-21 15:31:09 +00:00
Andrei Emeltchenko
642d596d69 drivers/nble: Update RPC to 0422 revision
Update RPC adding gap_tx_power request and event. Corresponds to BLE
version ATLASEDGE/PVT/FACTORY-386-gc1f694b.

Change-Id: I7e47553af63c3c3405522e37f86d9004dcca46f7
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-04-21 15:30:54 +00:00