The following fix:
commit c8b17ec403
Author: Tobias Aschenbrenner <tobias.aschenbrenner@blik.io>
Date: Tue Dec 18 14:16:00 2018 +0100
fix: kw41z: Use correct mapping for dBm
Was using SYS_LOG_INFO and should be using LOG_INFO.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
A parallel PCI implementation ("pcie") is added with features for PCIe.
In particular, message-signaled interrupts (MSI) are supported, which
are essential to the use of any non-trivial PCIe device.
The NS16550 UART driver is modified to use pcie.
pcie is a complete replacement for the old PCI support ("pci"). It is
smaller, by an order of magnitude, and cleaner. Both pci and pcie can
(and do) coexist in the same builds, but the intent is to rework any
existing drivers that depend on pci and ultimately remove pci entirely.
This patch is large, but things in mirror are smaller than they appear.
Most of the modified files are configuration-related, and are changed
only slightly to accommodate the modified UART driver.
Deficiencies:
64-bit support is minimal. The code works fine with 64-bit capable
devices, but will not cooperate with MMIO regions (or MSI targets) that
have high bits set. This is not needed on any current boards, and is
unlikely to be needed in the future. Only superficial changes would
be required if we change our minds.
The method specifying PCI endpoints in devicetree is somewhat kludgey.
The "right" way would be to hang PCI devices off a topological tree;
while this would be more aesthetically pleasing, I don't think it's
worth the effort, given our non-standard use of devicetree.
Signed-off-by: Charles E. Youse <charles.youse@intel.com>
Right now only numerical values are printed which must
be looked up in the Designware ARCv2 ISA Programmer's
Reference, which is not public.
Add a non-default Kconfig to print more information at
the expense of footprint, and enable it for all the simulator
targets.
We only print code/parameter details for machine check and
protection violations, more may be added later as desired.
This should cover all the exceptions we commonly encounter
for memory protection.
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
Enable the clock for GPIO ports on the RV32M1 SoC before attempting to
access the port controller registers.
Fixes: #15339
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
In addition to checking that the ARP entry does not exist as the
implementation is done currently, also check if the ARP packet
is due to IPv4 link local address configuration. In both cases
use the provided IPv4 address instead of the one set for the
interface.
Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
IPv4 link local uses ARP to detect conflicting addresses. Properly
set the ethernet packet type to NET_ETH_PTYPE_ARP when probing
for address duplicates.
Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
The source address in unicast DHCPv4 Request packets was found out
to be all zeros address 0.0.0.0. This address is only acceptable if
the destination is a multicast one, where the host in question is
acquiring a DHCP address lease. This is true for the DHCP Discover
and the initial DHCP Request message from the client towards the
server. As subsequent DHCP Request renewal messages are sent as
unicast to the server, the server will drop such packets.
Fix this issue by explicitely specifying what source IP address is
to be used, if none is specified, the all zeros address 0.0.0.0 is
used in multicast addresses. The source address in the other
unicast cases is identical to the 'ciaddr' in the DHCP message.
Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
After the rework in #12403, specifying a shield which has overlay
out of the tree causes unnecessary inclusions of overlays.
For every board root, overlays that have same index as
expected overlay are being included.
Fix this by removing already included overlays from SHIELD list.
Signed-off-by: Marcin Szymczyk <Marcin.Szymczyk@nordicsemi.no>
According to documentation Compare event will not be triggered
if CC=0 and CLEAR task is set. Added handling of that situation.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
SAMD20 does not have the DMA or USB peripherals and as a result
the IRQs for all subsequent lines are shifted down from SAMD21.
This splits the interrupt assignment for the SERCOMs into the
SoC specific DTS file and moves the USB definition to SAMD21 only.
Signed-off-by: Derek Hageman <hageman@inthat.cloud>
The radio API expects the setting of the TX-power in dBm. The actual
TX-power is however set by a 6bit register, which mapping between
register value and power in dBm is a lookup-table in the datasheet.
This mapping for the kw41z was off, which not only lead to incorrect
output power, but also to a maximal output power of only -1.9 dBm
instead of the possible +3.5 dBm.
Signed-off-by: Tobias Aschenbrenner <tobias.aschenbrenner@blik.io>
Signed-off-by: Franco Saworski <f.saworski@posteo.de>
If the user attempts to send data before the USB connection is
established (see the HID sample for an example of such code), the
DataInCallback never gets called which leaves the write semaphore in a
taken state forever.
Signed-off-by: Josef Gajdusek <atx@atx.name>
The SYSCFG_CFGR1_PA11_PA12_RMP define is present even on packages where
the remap isn't strictly required. This commit makes the remap optional
based on a DT property.
Also fixes syntax error caused by a missing );.
Signed-off-by: Josef Gajdusek <atx@atx.name>
Write the net_pkt using net_pkt_write() and then verify that the
data is actually written into net_buf.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Add a new command-line and build config option, `pristine`, that the
user can pass to `west build` or set in its configuration file(s) in
order to automatically trigger a pristine build on every build or
whenever west considers it required.
The option can take the following values:
- never: Never run the target
- always: Always run the pristine target before building
- auto: Run the pristine target when required
With `auto`, the pristine target will be run when running
west with an existing build folder containing a build system and:
- Selecting a different board from the one currently in the build system
- Selecting a different application from the one currently in the build
system
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
The -B option has always existed but was first officially documented in
CMake 3.13.0. In that same release the -S option was introduced,
replacing the old undocumented -H. Switch to using the officially
documented options.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
If promiscuous mode support is disabled in Kconfig and promiscuous.h is
included the build will fail. The returned errno should be ENOTSUP.
Signed-off-by: Brett Witherspoon <spoonb@cdspooner.com>
This is needed to remove noise when comparing binaries across git
commits and more generally for anyone who wants to manual
control/override the version number when building with or without a
.git/ subdirectory.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
One of the first things needed when comparing builds of tests across
different environments/systems is to make sure the same (sub)tests were
selected and run in the first place. For that purpose sort the output of
--testcase-report and --discard-report as they were in random order.
Actually make the entire class TestInstance sortable by adding a
standard __lt__() method comparing unique instance names; it could be
useful again.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
While this race seems unlikely and harmless let's play it safe and
implement the usual solution: temporary file + atomic rename.
The race is unlikely and maybe even harmless because:
- Only sanitycheck seems to invoke cmake concurrently.
- Users rarely delete their ~/.cache/zephyr/ToolchainCapabilityDatabase/
- All concurrent cmake processes write the same, single byte to the same
files.
- Creating a single byte is at least very fast, so extremely short
window for others to read an empty file.
For additional background see links in issue #9992
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
This makes the output of file2hex.py deterministic by default while also
letting the user set the mtime in the gzip header manually if desired.
Use the option without any argument to restore the previous behavior
that sets the current (and obviously changing) "now" timestamp.
To test: ./sanitycheck --tag gen_inc_file
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
If the compiler supports it, strip the ${ZEPHYR_BASE} prefix from the
__FILE__ macro used in __ASSERT* macros, in the
.noinit."/home/joe/zephyr/fu/bar.c" section names and in any application
code. This saves some memory, stops leaking user locations in binaries,
makes failure logs more deterministic and most importantly makes builds
more deterministic.
- .noinit section names now look like this in objdump -h:
17 .noinit."./kernel/init.c".2 00001100 00000000 ...
18 .noinit."./kernel/init.c".1 00001200 00000000 ...
19 .noinit."./kernel/init.c".3 00001800 00000000 ...
- The output of __ASSERT* macros now looks like this:
ASSERTION FAIL [0] @ ./samples/hello_world/src/main.c:13
The world comes crashing down
***** Kernel Panic! *****
Current thread ID = 0x00400040
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
This commit enable Bluetooth SMP Service which will help
us to do Device Firmware Upgrade over thr air. By default
it is not enable.
Reference: $zephyr/samples/subsys/mgmt/mcumgr/smp_svr
Signed-off-by: Vikrant More <vikrant8051@gmail.com>
General MIC fix for AAD lengths up to 14 bytes.
This case doesn't concern the mesh stack because it uses 16 bytes.
Signed-off-by: Reham Tarek <reham.tarek@si-vision.com>
This stores the database hash and check if it has changed on commit
skipping service changed if hash matches.
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Custom handlers without any arguments don't since there is a check for
argc > 1, to fix this behavior removing the check.
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
If handle is over the range end return since handles are always placed
in ascending order.
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This reduces bt_gatt_foreach_attr complexity (O(n)) so it can skip
ahead when the start handle is not within its service handles.
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
It may be very important information for the developer if scanning
fails to start or stop, so add proper logs. There's no need to log
EALREADY errors, since the mesh stack doesn't track the current scan
state and simply relies on the under lying GAP layer to return this
error if the desired state is already set.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
All docs should have a label at the top that would
permit cross-document linking via :ref:`labelname`.
Update "testing" label that would have conflicted and fix the only
reference to the old "testing" label in development process
documentation.
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
.object_access.* sections should be with
GROUP_LINK_IN(ROMABLE_REGION) as other sections in
common-rom.ld
Fixes#15481
Signed-off-by: Wayne Ren <wei.ren@synopsys.com>
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
SPI is not normally enabled, but some tests assume that there's a device
available. Conditionally enable SPI_2 which is associated with the
on-board flash.
Closes#15374
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
bt_gatt_connected should be only called, when there is no
connection error. Change fixes problem with receiving notifications
before connection.
Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
Add config overlay for cdc_acm+dfu composite configuration.
Manual configuration over menuconfig may be error-prone for
the user because then FLASH_LOAD_OFFSET and FLASH_LOAD_SIZE
should also to be set to appropriate values.
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
Set bwPollTimeout for DFU_GETSTATUS request dynamically.
For now, adjust bwPollTimeout only during DNLOAD stage.
Fixes: #8734
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
Remove 'counter' as a supported feature on several NRF boards as these
boards fail to build tests/drivers/counter/counter_basic_api. This is
due to the fact that we either need explicit board conf files for the
test or have the counter driver enabled via Kconfig.
Fixes#15460
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>