Refactor wpanusb sample using new descriptor API, use endpoint index
instead of hardcoded endpoint address.
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Refactor device api test using standard placement for descriptor table
and configuration data.
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Remove duplicated execution path for composite configuration, USB
device stack initialization is done inside stack for both cases.
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Now that Standard, Class and Vendor request handlers are using the same
buffer, we do not need to keep and array installed request data pointer.
This simplifies the code.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Now that we have merged the class and vendor request buffers into the
USB device code, we can also merge the standard request buffer. We just
need to ensure it is at least 8 bytes, by using the range option in
Kconfig. The 64KiB limit is arbitrary.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
In order to unify the legacy and composite code, move the class and
vendor request handler buffer into the USB device code, just like in
composite mode. The option is renamed from USB_COMPOSITE_BUFFER_SIZE
into USB_REQUEST_BUFFER_SIZE and also replaces the USB_DFU_MAX_XFER_SIZE
and USB_HID_MAX_PAYLOAD_SIZE options.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Use the generic pinmux APIs provided by zephyr to select
alternate functions.
This also contains a fix for a formatting issue in the
documentation for this board. Additionally, the serial
console is now on UART2.
Signed-off-by: Francisco Munoz <francisco.munoz.ruiz@intel.com>
Define pinmux base addresses from gpio bases. Pinmux
and gpio functionality are located in the same PCR register
for each pin.
Introduce pinmux Kconfig switches for the SOC.
Signed-off-by: Francisco Munoz <francisco.munoz.ruiz@intel.com>
This driver introduces pinmux configuration capabilities
using zephyr apis for XEC SOCs.
Signed-off-by: Francisco Munoz <francisco.munoz.ruiz@intel.com>
Clarify that the async receive event length is relative to the
offset, rather than representing an absolute length of data
received.
Signed-off-by: Derek Hageman <hageman@inthat.cloud>
Add an explict test for the length of the receive event when
doing incremental receives. This was not tested anywhere in the
normal code path (only implicitly in the abort, which wasn't
exercised on the only current implementation, nrfx). So add an
explicit check for it during the chained reads, so that the
test can catch the case where multiple receive events do not set
the length correctly on events past the first.
Tested on nrf52840_pca10056.
Signed-off-by: Derek Hageman <hageman@inthat.cloud>
This reverts commit d09b91f5. I was incorrect in my interpretation
of the async API: the number of bytes received is relative
to the previous event, so it does "reset" between calls.
Signed-off-by: Derek Hageman <hageman@inthat.cloud>
USB_DC_STM32 comes from Kconfig. We have to add the CONFIG_ prefix
to use USB_DC_STM32 in C code.
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Non-XIP system with FLASH_SIZE = 0 is no-flash system. And no-flash
system makes text, rodata, and data all in SRAM, so define the marco
ROM_ADDR to RAM_ADDR.
Fixes: #16027.
Signed-off-by: Wentong Wu <wentong.wu@intel.com>
This commit enforces platform-specific initialization
for nRF SoC family. The specific platform initialization
hook is invoked directly after reset and calls the nRFx
SystemInit() function.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
Rename function _PlatformInit() to z_platform_init() to
comply with naming conventions.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
Allow further extention of counter API by replacing count_up bool in
the structure with u8_t flags where one bit is used for count up
feature.
Change is not breaking API as count up property is read using
counter_is_counting_up() that didn't change.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
OpenISA Vega board has Arduino headers which can be configured for
use with Arduino-compatible shields. To enable this in Zephyr,
let's define the gpio-map for Vega and set the appropriate
arduino_serial linkage.
Signed-off-by: Michael Scott <mike@foundries.io>
Having a checksum of zeros in UDP means "missing checksum" and is a
valid case as per RFC 768:
"An all zero transmitted checksum value means that the transmitter
generated no checksum (for debugging or for higher level protocols
that don't care)."
Such support is made possible by adding a new Kconfig option named
CONFIG_NET_UDP_MISSING_CHECKSUM.
However, that is valid only for IPv4. For IPv6, see the RFC 2460
section 8.1:
"Unlike IPv4, when UDP packets are originated by an IPv6 node, the UDP
checksum is not optional."
So the UDP checksum will always be verified in IPv6.
Fixes#16375
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
From RFC 768, in "Fields":
"If the computed checksum is zero, it is transmitted as all ones"
Fixes#16379
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
If CONFIG_POSIX_API is defined, automatically use time() function.
The alternative to that is to explicitly configure mbedTLS' timing
source via API, as required for "raw code", but if user enables
POSIX API, we as well might use existing mbedTLS integration.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Added support for the LE SC pairing with the OOB data. The peripheral
side is only supported for now.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
This change extends the Bluetooth API to support pairing with the OOB
data that are used in the Authentication Stage of the pairing procedure.
The LE Secure Connections specific API for OOB pairing is also added.
The general OOB API should be able to accomodate the LE legacy pairing
later on.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
The the footer structure and extra bytes (rssi, resolving index etc.)
were overlapping in memory, rx_ftr was moved into the header, but the
extra and footer are still being read from the same place, extra was
written to the end. So this avoided memory corruption, but reading extra
reads wrong information.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Added a test case with corner case scenario, in which sector closing
operation is interrupted (e. g. due to power-down).
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
Added a new runtime parameter to the Flash Simulator. It can be used to
ignore part of the data that is written to the simulated flash memory.
This parameter works together with max write calls parameter.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
Added a new runtime parameter to the Flash Simulator. It can be used to
ignore erases to the simulated flash memory after a certain number
of flash erase calls has been executed.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
Added option profiling instrumentation which can help determine
string duplicates pool configuration. Added shell command to
read current peak utilization of the pool.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
Create a dedicated connector file to hold arduino connector
information for disco_l475_iot board.
This should enhance board dts file readability.
Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
CONFIG_MPU_REQUIRES_POWER_OF_TWO_ALIGNMENT is taken into
account when allocating the area for the interrupt stack
using the K_THREAD_STACK_DEFINE macro. Therefore, we can
simplify how the top of the stack is derived during the
initialization of the system, by removing one more
occurrence of CONFIG_MPU_REQUIRES_POWER_OF_TWO_ALIGNMENT.
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
Adds a new argument to the jlink runner to reset the device after
loading code to flash. This fixes a problem with the lpcxpresso54114
board where it was necessary to manually reset the board to get new code
to start running after the 'ninja flash' command. This new argument is
optional and false by default because there are some cases were we must
not reset after load, such as when we load the application into ITCM on
imx rt devices.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Kconfig symbols I2C_STM32_V1 and I2C_STM32_V2 depends on SoC reference
and user should not have the possibility to choose one or the other.
Remove prompt on these symbols.
Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
I2C_STM32_V1 and I2C_STM32_V2 are Kconfig symbols used to
select STM32 I2C driver variant based on I2C IP available on a
given STM32 SoC.
Being SoC dependent, they are automatically selected in soc/
if CONFIG_I2C is set. Then there is no need to define them at board
level, nor for a specific application like this is done in
some sample or test applications. Remove these definitions when
this is the case.
Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
If the QMSI is not configured in (in the west manifest) we get kconfig
whitelisting errors because the type is declared within the module
itself.
Change default to def_bool to set the type.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>