Home
last modified time | relevance | path

Searched full:ppp (Results 1 – 25 of 73) sorted by relevance

123

/Zephyr-latest/subsys/modem/
Dmodem_ppp.c7 #include <zephyr/net/ppp.h>
9 #include <zephyr/modem/ppp.h>
51 static uint8_t modem_ppp_wrap_net_pkt_byte(struct modem_ppp *ppp) in modem_ppp_wrap_net_pkt_byte() argument
55 switch (ppp->transmit_state) { in modem_ppp_wrap_net_pkt_byte()
62 ppp->transmit_state = MODEM_PPP_TRANSMIT_STATE_HDR_FF; in modem_ppp_wrap_net_pkt_byte()
66 net_pkt_cursor_init(ppp->tx_pkt); in modem_ppp_wrap_net_pkt_byte()
67 ppp->tx_pkt_fcs = modem_ppp_fcs_init(0xFF); in modem_ppp_wrap_net_pkt_byte()
68 ppp->transmit_state = MODEM_PPP_TRANSMIT_STATE_HDR_7D; in modem_ppp_wrap_net_pkt_byte()
72 ppp->tx_pkt_fcs = modem_ppp_fcs_update(ppp->tx_pkt_fcs, 0x03); in modem_ppp_wrap_net_pkt_byte()
73 ppp->transmit_state = MODEM_PPP_TRANSMIT_STATE_HDR_23; in modem_ppp_wrap_net_pkt_byte()
[all …]
DKconfig52 bool "Modem PPP module"
/Zephyr-latest/drivers/net/
Dppp.c10 * PPP driver using uart_pipe. This is meant for network connectivity between
25 #include <zephyr/net/ppp.h>
83 /* ppp data is read into this buf */
90 /* ppp buf use when sending data */
93 /* ppp buf use when sending data */
276 struct ppp_driver_context *ppp = in uart_recovery() local
280 ret = ring_buf_space_get(&ppp->rx_ringbuf); in uart_recovery()
281 if (ret >= (sizeof(ppp->rx_buf) / 2)) { in uart_recovery()
282 ret = ppp_async_uart_rx_enable(ppp); in uart_recovery()
291 k_work_schedule(&ppp->uart_recovery_work, in uart_recovery()
[all …]
DKconfig10 # PPP options
13 bool "Point-to-point (PPP) UART based driver"
26 string "PPP Driver name"
27 default "ppp"
32 int "PPP MTU and MRU"
35 This options sets MTU and MRU for PPP link.
45 int "PPP ring buffer size"
48 PPP ring buffer size when passing data from RX ISR to worker
55 Sets the stack size which will be used by the PPP RX workqueue.
72 bool "Capture received PPP packets"
[all …]
DCMakeLists.txt10 zephyr_library_sources_ifdef(CONFIG_NET_PPP ppp.c)
/Zephyr-latest/include/zephyr/modem/
Dppp.h25 * @brief Modem PPP
26 * @defgroup modem_ppp Modem PPP
79 /* Hook for PPP L2 network interface initialization */
89 /* Wrapped PPP frames are sent and received through this pipe */
92 /* Receive PPP frame state */
105 /* Ring buffer used for transmitting partial PPP frame */
131 * @param ppp Modem PPP instance
132 * @param pipe Pipe to attach to modem PPP instance
134 int modem_ppp_attach(struct modem_ppp *ppp, struct modem_pipe *pipe);
137 * @brief Get network interface modem PPP instance is bound to
[all …]
/Zephyr-latest/subsys/net/l2/ppp/
DKconfig5 bool "Point-to-point (PPP) support"
9 Add support for PPP.
66 Enable support for serving IP address to PPP peer.
71 Enable support for serving DNS addresses to PPP peer.
75 module-str = Log level for ppp L2 layer
76 module-help = Enables ppp L2 to output debug messages.
80 bool "Ppp network management interface"
84 Enable support net_mgmt ppp interface which can be used to
85 configure at run-time ppp drivers and L2 settings.
95 int "Priority of the PPP TX thread"
[all …]
Dppp_stats.c14 #include <zephyr/net/ppp.h>
25 const struct ppp_api *ppp; in ppp_stats_get() local
29 if (net_if_l2(iface) != &NET_L2_GET_NAME(PPP)) { in ppp_stats_get()
33 ppp = net_if_get_device(iface)->api; in ppp_stats_get()
34 if (ppp->get_stats == NULL) { in ppp_stats_get()
39 src = ppp->get_stats(net_if_get_device(iface)); in ppp_stats_get()
Dppp_l2.c16 #include <zephyr/net/ppp.h>
136 /* If we are running a PPP unit test, then feed the packet in ppp_recv()
176 /* If PPP is not yet ready, then just give error to caller as there in ppp_send()
177 * is no way to send before the PPP handshake is finished. in ppp_send()
213 const struct ppp_api *ppp = net_if_get_device(iface)->api; in ppp_up() local
215 if (ppp->start) { in ppp_up()
216 ppp->start(net_if_get_device(iface)); in ppp_up()
270 const struct ppp_api *ppp = net_if_get_device(iface)->api; in ppp_down() local
285 if (ppp->stop) { in ppp_down()
286 /* Inform L2 PPP device that PPP link is down */ in ppp_down()
[all …]
Dppp_internal.h2 @brief PPP private header
13 #include <zephyr/net/ppp.h>
22 * PPP packet format.
60 /** PPP protocol number */
Dppp_mgmt.c7 #include <zephyr/net/ppp.h>
Dlcp.c16 #include <zephyr/net/ppp.h>
31 NET_DBG("PPP Protocol-Rej"); in lcp_handle_ext()
35 NET_DBG("PPP Echo-Req"); in lcp_handle_ext()
39 NET_DBG("PPP Echo-Reply"); in lcp_handle_ext()
43 NET_DBG("PPP Discard-Req"); in lcp_handle_ext()
Dfsm.c14 #include <zephyr/net/ppp.h>
376 /* Note that the data parameter is the received PPP packet if in ppp_send_pkt()
382 struct ppp_packet ppp; in ppp_send_pkt() local
419 len = sizeof(ppp) + data_len; in ppp_send_pkt()
426 len = sizeof(ppp) + sizeof(uint32_t) + data_len; in ppp_send_pkt()
430 len = sizeof(ppp) + net_pkt_remaining_data(req_pkt); in ppp_send_pkt()
434 len = sizeof(ppp) + sizeof(uint16_t) + in ppp_send_pkt()
441 len = sizeof(ppp); in ppp_send_pkt()
448 if (len < sizeof(ppp)) { in ppp_send_pkt()
452 ppp.code = type; in ppp_send_pkt()
[all …]
/Zephyr-latest/doc/connectivity/networking/api/
Dppp.rst3 Point-to-Point Protocol (PPP) Support
14 <https://en.wikipedia.org/wiki/Point-to-Point_Protocol>`_ (PPP) is a data link
16 between two nodes. PPP is used over many types of serial links since IP packets
20 In Zephyr, each individual PPP link is modelled as a network interface. This
21 is similar to how Linux implements PPP.
23 PPP support must be enabled at compile time by setting option
25 The PPP implementation supports only these protocols:
36 For using PPP with a cellular modem, see :zephyr:code-sample:`cellular-modem` sample
42 See the `net-tools README`_ file for more details on how to test the Zephyr PPP
46 https://github.com/zephyrproject-rtos/net-tools/blob/master/README.md#ppp-connectivity
Dnet_tech.rst12 ppp.rst
/Zephyr-latest/include/zephyr/net/
Dppp.h9 * @brief PPP (Point-to-Point Protocol)
25 * @brief Point-to-point (PPP) L2/driver support functions
26 * @defgroup ppp PPP L2/driver Support Functions
33 /** PPP maximum receive unit (MRU) */
36 /** PPP maximum transfer unit (MTU) */
45 /** PPP L2 API */
63 /** Collect optional PPP specific statistics. This pointer
72 * PPP API struct (it is the first one).
77 * PPP protocol types.
78 * See https://www.iana.org/assignments/ppp-numbers/ppp-numbers.xhtml
[all …]
/Zephyr-latest/subsys/net/lib/shell/
Dppp.c11 #include <zephyr/net/ppp.h>
16 #include <zephyr/net/ppp.h>
17 #include "ppp/ppp_internal.h"
33 PR_INFO("PPP Echo-Req timeout.\n"); in cmd_net_ppp_ping()
35 PR_INFO("Not a PPP interface (%d)\n", idx); in cmd_net_ppp_ping()
37 PR_INFO("PPP Echo-Req failed (%d)\n", ret); in cmd_net_ppp_ping()
42 "Received PPP Echo-Reply in ", in cmd_net_ppp_ping()
46 "Received PPP Echo-Reply in ", ret); in cmd_net_ppp_ping()
50 PR_INFO("PPP network interface must be given.\n"); in cmd_net_ppp_ping()
54 PR_INFO("Set %s to enable %s support.\n", "CONFIG_NET_L2_PPP", "PPP"); in cmd_net_ppp_ping()
[all …]
DCMakeLists.txt28 zephyr_library_sources_ifdef(CONFIG_NET_SHELL_PPP_SUPPORTED ppp.c)
/Zephyr-latest/tests/net/ppp/driver/
Dtestcase.yaml5 - ppp
7 net.ppp:
/Zephyr-latest/doc/services/modem/
Dindex.rst33 Modem PPP
36 This module defines and binds a L2 PPP network interface, described in
37 :ref:`net_l2_interface`, to a modem backend. The L2 PPP interface sends
39 in PPP frames before being transported via a modem backend. This module
/Zephyr-latest/drivers/modem/
Dmodem_cellular.c16 #include <zephyr/modem/ppp.h>
18 #include <zephyr/net/ppp.h>
127 /* PPP */
128 struct modem_ppp *ppp; member
608 modem_ppp_release(data->ppp); in modem_cellular_on_idle_state_enter()
856 net_if_set_link_addr(modem_ppp_get_iface(data->ppp), data->imei, in modem_cellular_run_init_script_event_handler()
1028 if (modem_ppp_attach(data->ppp, data->dlci1_pipe) < 0) { in modem_cellular_on_await_registered_state_enter()
1073 net_if_carrier_on(modem_ppp_get_iface(data->ppp)); in modem_cellular_on_carrier_on_state_enter()
1110 net_if_carrier_off(modem_ppp_get_iface(data->ppp)); in modem_cellular_on_carrier_on_state_leave()
1112 modem_ppp_release(data->ppp); in modem_cellular_on_carrier_on_state_leave()
[all …]
DKconfig.cellular24 with the standard protocols CMUX and PPP, to configure
/Zephyr-latest/tests/subsys/modem/modem_ppp/src/
Dmain.c15 #include <zephyr/net/ppp.h>
19 #include <zephyr/modem/ppp.h>
40 /* PPP frames */
115 /* Modem PPP */
125 static struct modem_ppp ppp = { variable
133 /* Modem PPP net device */
136 static const struct device ppp_net_dev = {.data = &ppp};
268 net_if_flag_set(modem_ppp_get_iface(&ppp), NET_IF_UP); in test_modem_ppp_setup()
280 modem_ppp_attach(&ppp, mock_pipe); in test_modem_ppp_setup()
309 /* Give modem ppp time to process received frame */ in ZTEST()
[all …]
/Zephyr-latest/subsys/net/l2/
DCMakeLists.txt20 add_subdirectory(ppp)
/Zephyr-latest/subsys/net/ip/
DKconfig.stats118 bool "Point-to-point (PPP) statistics"
122 Keep track of PPP related statistics

123