Added noprompt command to shell. It will disable printing
the prompt.
For the native port, when feeding commands from a file or
pipe the prompt reprinting after each command (without echoing)
just confuses the user.
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Now the native console driver also handles stdin
so we can drive the shell from the command line,
a pipe or a file
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
Added a new config variable with the recommended stack
size for threads which are only meant for the posix architecture
Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com>
net_pkt_append() has been changed. If payload reached max value
of 'data_len' in net packet, net_pkt_append will not append.
So the caller has to create new packet and append remaining payload.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Unlinking of neighbor also needed after nbr_unref. Otherwise
neighbor id is still in use and can not be linked further.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
When a node receives DIO message from peer then node adds peer as
a neighbor (nbr with linklayer address). But when a node receives
DAO message from different peer (chances are peer selected
different route to reach this node), remove peer with previous
link layer address and add as a neighbor with new link layer address
with new route information. Now node can properly route packets to
peer from neighbor table or based on nexthop information from
routing table.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
When a node joins in DAG network, it chooses neighbor (node or border
router) as its parent. But if it receives DIO message from another
peer, it can only act as a neighbor, not as a parent. If peer rank
is better than current preferred parent rank then node will select
new peer as it's best parent.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
RPL prints lot of debug information which is difficult to track.
Minimized debugs in timer specific information and parsing of
DIO and DAO options. Also fixed alignment issues (no changes in
functionality)
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Do not even consider the push event if CONFIG_NET_MGMT_EVENT_INFO
enabled and info length is more than NET_EVENT_INFO_MAX_SIZE.
Print error message and ignore the event.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Driver is 'Busy' can be a warning message which can be enabled with
minimum debug level CONFIG_SYS_LOG_IEEE802154_DRIVER_LEVEL=2.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Current default value for NET_RPL_INIT_LINK_METRIC is 2, changing it
to 1.
e.g. NET_RPL_MIN_HOP_RANK_INC is 256 and NET_RPL_MC_ETX_DIVISOR is 256.
Rank calculation for nodes is
rank_increase = CONFIG_NET_RPL_INIT_LINK_METRIC *
NET_RPL_MC_ETX_DIVISOR;
Which gives 768 for first set of child nodes. It would be good if
CONFIG_NET_RPL_INIT_LINK_METRIC value is 1 and nodes ranks will be
245, 512, 768 based on the path they choose.
User can absolutely change their configuration to maintain proper ranks.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
When CONFIG_NET_RPL enabled, do not run DAD (duplicate address
detection) for global addresses. In RPL mesh network global addresses
for nodes are determined by prefix from Border Router. DAD is not
necessary in this case.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
If CONFIG_NET_MGMT_EVENT_INFO is enabled then provide mgmt info
about the route, which is added or deleted.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
If CONFIG_NET_MGMT_EVENT_INFO is enabled then provide mgmt info
about the neighbor, which is added or deleted.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Remove any routes with neighbor as a nexthop first and then remove
neighbor from neighbor table.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Provided separate event information structs based on events. This way
user will know what kind of information will be received to that
particular event.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
When net_ipv6_prepare_for_send() needs to route packets, it missed
updating of RPL header.
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
Doing neighbor discovery in RPL network is not necessary and
that can be disabled in RPL nodes. Unfortunately the border
router needs to have ND enabled as it has also non-RPL network
interfaces in use. So in this case, mark RPL node as always
reachable.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
As this is very specialized info which is not normally needed,
do not print it by default.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Introduce CONFIG_NET_ROUTING option that allows the IP stack
to route IPv6 packets between multiple network interfaces.
No support for IPv4 routing is implemented by this commit.
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Removes variable shadowing another declared
previously but does not change anything
functionally.
Signed-off-by: Juan Manuel Torres Palma <j.m.torrespalma@gmail.com>
Some mcu's have USART_PRESC_PRESCALER defined in the function call. Add
a prescaler of div1 to it.
Signed-off-by: Pushpal Sidhu <psidhu.devel@gmail.com>
Fix HCI LE Set PHY command for invalid behavior testing for
invalid parameters and unsupported features.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix generation of redundant length update event when no
change in effective octets or time.
Fixes LL.TS.5.0.2 conformance tests:
LL/CON/MAS/BV-73-C [Master Data Length Update - Responding
to Data Length Update Procedure; LE 1M PHY]
LL/CON/MAS/BV-74-C [Master Data Length Update - Initiating
Data Length Update Procedure; LE 1M PHY]
LL/CON/MAS/BV-76-C [Master Data Length Update - Responding
to Data Length Update Procedure; LE 2M PHY]
LL/CON/MAS/BV-77-C [Master Data Length Update - Initiating
Data Length Update Procedure; LE 2M PHY]
LL/CON/SLA/BV-77-C [Slave Data Length Update - Responding
to Data Length Update Procedure; LE 1M PHY]
LL/CON/SLA/BV-78-C [Slave Data Length Update - Initiating
Data Length Update Procedure; LE 1M PHY]
LL/CON/SLA/BV-80-C [Slave Data Length Update - Responding
to Data Length Update Procedure; LE 2M PHY]
LL/CON/SLA/BV-81-C [Slave Data Length Update - Initiating
Data Length Update Procedure; LE 2M PHY]
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
The expected order for heading levels in our ReST documents is # for H1,
* for H2, = for H3, and - for H4. Some documents snuck in without
following this guideline.
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
Fixed implementation to use Connection Parameter Request
Procedure Preferred Periodicity value in calculating the new
connection interval used by the master role in Connection
Update Indication.
Fixes LL.TS.5.0.2 conformance tests:
LL/CON/MAS/BV-32-C [Accepting Connection Parameter Request –
Preferred_Periodicity]
LL/CON/MAS/BV-33-C [Accepting Connection Parameter Request –
Preferred_Periodicity and preferred anchor points]
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
In case of split host & controller we may need to do ACL segmentation
of packets. Sending the composition data will already have allocated
three TX buffers, so trying to segment the first one further will
result in a deadlock. Increase the buffer count from the default (3)
to 4 to work around this risk.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Increasing the IPv6 multicast address count from 2 to 5 so that
tests will always run ok.
Fixes#4401
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
prepare_segment() returned NULL in case of any error, which then
net_context_send() translated into -EINVAL. That's highly confusing
though, because a common case of failure for prepare_segment() is
being unable to allocate data fragment(s) (for TCP header, etc.)
So, return output pkt by reference, and detailed error status as
a return value.
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
The default PWM polarity was 'inversed', which is not aligned with the
other PWM drivers. Unfortunately there is not yet an API to define the
default polarity to be used by the driver, but assume that 'normal'
(signal starts high for the duration of the duty cycle) should be the
default.
Signed-off-by: Ricardo Salveti <ricardo@opensourcefoundries.com>
Uses the new flash erase-block-size dts property to implement the flash
page layout api in the mcux flash driver.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Defines the FLASH_DRIVER_NAME macro in soc.h for kinetis kl2x and kwx
SoC series. This macro is used by the storage and dfu subsystems, as
well as the flash_shell sample.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Adds a new optional dts property to define the erase block size of a
flash device. This will be used by the mcux flash driver to implement
the flash page layout function.
The value is set for all kinetis devices to match
FSL_FEATURE_FLASH_PFLASH_BLOCK_SECTOR_SIZE.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
The vendor variants of the model publication client messages were not
passing onward the CID, rather passing CID_NVAL which is clearly not
right.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Fix controller implementation to restrict HCI LE Set Random
Address command when advertising and/or active scanning
and/or initiator state is enable.
Fixes LL.TS.5.0.2 conformance tests:
LL/CON/INI/BV-01-C [Connection Initiation]
LL/SEC/ADV/BV-01-C [Advertising With Static Address]
LL/SEC/SCN/BV-01-C [Random Address Scanning]
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>