Home
last modified time | relevance | path

Searched refs:mps (Results 1 – 25 of 58) sorted by relevance

123

/Zephyr-latest/drivers/usb/udc/
Dudc_skeleton.c263 uint16_t mps = 1023; in udc_skeleton_driver_preinit() local
277 mps = 1024; in udc_skeleton_driver_preinit()
284 config->ep_cfg_out[i].caps.mps = 64; in udc_skeleton_driver_preinit()
289 config->ep_cfg_out[i].caps.mps = mps; in udc_skeleton_driver_preinit()
304 config->ep_cfg_in[i].caps.mps = 64; in udc_skeleton_driver_preinit()
309 config->ep_cfg_in[i].caps.mps = mps; in udc_skeleton_driver_preinit()
Dudc_common.c242 const uint16_t mps, in ep_check_config() argument
255 cfg->caps.mps); in ep_check_config()
265 if (USB_MPS_EP_SIZE(mps) > USB_MPS_EP_SIZE(cfg->caps.mps)) { in ep_check_config()
277 (USB_MPS_ADDITIONAL_TRANSACTIONS(mps) && in ep_check_config()
284 (USB_MPS_ADDITIONAL_TRANSACTIONS(mps) && in ep_check_config()
304 uint16_t *const mps) in ep_update_mps() argument
317 *mps = MIN(cfg->caps.mps, spec_bulk_mps); in ep_update_mps()
320 *mps = MIN(cfg->caps.mps, spec_int_mps); in ep_update_mps()
334 uint16_t *const mps, in udc_ep_try_config() argument
348 ret = ep_check_config(dev, cfg, ep, attributes, *mps, interval); in udc_ep_try_config()
[all …]
Dudc_nrf.c636 uint16_t mps; in udc_nrf_ep_enable() local
639 mps = (udc_mps_ep_size(cfg) == 0) ? cfg->caps.mps : udc_mps_ep_size(cfg); in udc_nrf_ep_enable()
640 nrf_usbd_common_ep_max_packet_size_set(cfg->addr, mps); in udc_nrf_ep_enable()
868 ep_cfg_out[i].caps.mps = NRF_USBD_COMMON_EPSIZE; in udc_nrf_driver_init()
872 ep_cfg_out[i].caps.mps = NRF_USBD_COMMON_EPSIZE; in udc_nrf_driver_init()
875 ep_cfg_out[i].caps.mps = NRF_USBD_COMMON_ISOSIZE / 2; in udc_nrf_driver_init()
890 ep_cfg_in[i].caps.mps = NRF_USBD_COMMON_EPSIZE; in udc_nrf_driver_init()
894 ep_cfg_in[i].caps.mps = NRF_USBD_COMMON_EPSIZE; in udc_nrf_driver_init()
897 ep_cfg_in[i].caps.mps = NRF_USBD_COMMON_ISOSIZE / 2; in udc_nrf_driver_init()
Dudc_renesas_ra.c383 ep_desc.wMaxPacketSize = cfg->mps; in udc_renesas_ra_ep_enable()
581 uint16_t mps = 1023; in udc_renesas_ra_driver_preinit() local
595 mps = 1024; in udc_renesas_ra_driver_preinit()
602 config->ep_cfg_out[i].caps.mps = 64; in udc_renesas_ra_driver_preinit()
607 config->ep_cfg_out[i].caps.mps = mps; in udc_renesas_ra_driver_preinit()
622 config->ep_cfg_in[i].caps.mps = 64; in udc_renesas_ra_driver_preinit()
627 config->ep_cfg_in[i].caps.mps = mps; in udc_renesas_ra_driver_preinit()
Dudc_virtual.c554 uint16_t mps = 1023; in udc_vrt_driver_preinit() local
564 mps = 1024; in udc_vrt_driver_preinit()
571 config->ep_cfg_out[i].caps.mps = 64; in udc_vrt_driver_preinit()
576 config->ep_cfg_out[i].caps.mps = mps; in udc_vrt_driver_preinit()
591 config->ep_cfg_in[i].caps.mps = 64; in udc_vrt_driver_preinit()
596 config->ep_cfg_in[i].caps.mps = mps; in udc_vrt_driver_preinit()
Dudc_smartbond.c278 const uint16_t mps = udc_mps_ep_size(ep_cfg); in fill_tx_fifo() local
283 if (remaining > mps - ep_state->last_packet_size) { in fill_tx_fifo()
284 remaining = mps - ep_state->last_packet_size; in fill_tx_fifo()
303 if (ep_idx == 0 || ep_cfg->mps <= EP_FIFO_SIZE) { in fill_tx_fifo()
366 const uint16_t mps = udc_mps_ep_size(ep_cfg); in start_rx_packet() local
373 if (mps > config->dma_min_transfer_size) { in start_rx_packet()
376 (uintptr_t)net_buf_tail(buf), mps); in start_rx_packet()
377 } else if (mps > EP_FIFO_SIZE) { in start_rx_packet()
418 const uint16_t mps = udc_mps_ep_size(ep_cfg); in start_tx_packet() local
419 uint16_t size = MIN(remaining, mps); in start_tx_packet()
[all …]
/Zephyr-latest/include/zephyr/usb/
Dusb_ch9.h357 #define USB_MPS_EP_SIZE(mps) ((mps) & BIT_MASK(11)) argument
360 #define USB_MPS_ADDITIONAL_TRANSACTIONS(mps) (((mps) & 0x1800) >> 11) argument
363 #define USB_MPS_TO_TPL(mps) \ argument
364 ((1 + USB_MPS_ADDITIONAL_TRANSACTIONS(mps)) * USB_MPS_EP_SIZE(mps))
/Zephyr-latest/subsys/bluetooth/host/
Dl2cap.c538 req->mps = sys_cpu_to_le16(ch->rx.mps); in l2cap_le_conn_req()
578 req->mps = sys_cpu_to_le16(ch->rx.mps); in l2cap_ecred_conn_req()
863 return MIN(buf->len, lechan->tx.mps); in get_pdu_len()
1199 if (chan->rx.mps > BT_L2CAP_RX_MTU) { in l2cap_chan_seg_recv_rx_init()
1201 chan->rx.mps = BT_L2CAP_RX_MTU; in l2cap_chan_seg_recv_rx_init()
1232 chan->rx.mps = MIN(chan->rx.mtu + BT_L2CAP_SDU_HDR_SIZE, in l2cap_chan_rx_init()
1239 (chan->rx.mps < chan->rx.mtu + BT_L2CAP_SDU_HDR_SIZE)) { in l2cap_chan_rx_init()
1241 chan->rx.mtu = chan->rx.mps - BT_L2CAP_SDU_HDR_SIZE; in l2cap_chan_rx_init()
1347 uint16_t mtu, uint16_t mps, uint16_t credits, in l2cap_chan_accept() argument
1395 le_chan->tx.mps = mps; in l2cap_chan_accept()
[all …]
Dl2cap_internal.h87 uint16_t mps; member
108 uint16_t mps; member
123 uint16_t mps; member
131 uint16_t mps; member
140 uint16_t mps; member
/Zephyr-latest/tests/bsim/bluetooth/host/l2cap/split/tester/src/
Dmain.c182 uint16_t mps = sys_le16_to_cpu(rsp->mps); in handle_l2cap_connected() local
184 peer_mps = mps; in handle_l2cap_connected()
186 LOG_DBG("l2cap connected: mtu %d mps %d credits: %d", mtu, mps, credits); in handle_l2cap_connected()
535 req->mps = sys_cpu_to_le16(23); in open_l2cap()
543 static void send_l2cap_sdu(uint8_t *data, uint16_t sdu_len, uint16_t mps) in send_l2cap_sdu() argument
548 bool shenanigans = !mps; in send_l2cap_sdu()
551 if (!mps) { in send_l2cap_sdu()
553 mps = 2; in send_l2cap_sdu()
562 pdu_len = MIN(sdu_len, mps); in send_l2cap_sdu()
576 if (mps == 1) { in send_l2cap_sdu()
[all …]
/Zephyr-latest/include/zephyr/drivers/usb/
Dudc.h70 uint32_t mps : 16; member
122 uint16_t mps; member
548 uint16_t *const mps,
572 const uint16_t mps,
741 return USB_MPS_EP_SIZE(cfg->mps); in udc_mps_ep_size()
Duhc.h63 uint16_t mps; member
353 const uint16_t mps,
379 const uint16_t mps,
/Zephyr-latest/subsys/usb/host/
Dusbh_device.h45 const uint16_t mps, in usbh_xfer_alloc() argument
51 return uhc_xfer_alloc(ctx->dev, udev->addr, ep, attrib, mps, timeout, udev, cb); in usbh_xfer_alloc()
/Zephyr-latest/drivers/usb/device/
Dusb_dc_sam_usbc.c91 uint16_t mps; member
201 int mps; in usb_dc_sam_usbc_ep_alloc_buf() local
209 mps = dev_data.ep_data[ep_idx].mps_x2 in usb_dc_sam_usbc_ep_alloc_buf()
210 ? dev_data.ep_data[ep_idx].mps * 2 in usb_dc_sam_usbc_ep_alloc_buf()
211 : dev_data.ep_data[ep_idx].mps; in usb_dc_sam_usbc_ep_alloc_buf()
220 ? dev_data.ep_data[i].mps * 2 in usb_dc_sam_usbc_ep_alloc_buf()
221 : dev_data.ep_data[i].mps; in usb_dc_sam_usbc_ep_alloc_buf()
224 if ((desc_mem_alloc + mps) > USBC_RAM_SIZE) { in usb_dc_sam_usbc_ep_alloc_buf()
244 ? dev_data.ep_data[i].mps * 2 in usb_dc_sam_usbc_ep_alloc_buf()
245 : dev_data.ep_data[i].mps; in usb_dc_sam_usbc_ep_alloc_buf()
[all …]
Dusb_dc_native_posix.c55 uint16_t mps; member
203 usbip_ctrl.out_ep_ctrl[ep_idx].mps = ep_mps; in usb_dc_ep_configure()
205 usbip_ctrl.in_ep_ctrl[ep_idx].mps = ep_mps; in usb_dc_ep_configure()
507 return usbip_ctrl.out_ep_ctrl[ep_idx].mps; in usb_dc_ep_mps()
509 return usbip_ctrl.in_ep_ctrl[ep_idx].mps; in usb_dc_ep_mps()
Dusb_dc_smartbond.c117 uint16_t mps; /** Endpoint max packet size */ member
373 if (remaining > ep_state->mps - ep_state->last_packet_size) { in fill_tx_fifo()
374 remaining = ep_state->mps - ep_state->last_packet_size; in fill_tx_fifo()
452 if (ep_state->mps > DMA_MIN_TRANSFER_SIZE) { in start_rx_packet()
456 ep_state->mps); in start_rx_packet()
457 } else if (ep_state->mps > EP_FIFO_SIZE) { in start_rx_packet()
494 uint16_t size = MIN(remaining, ep_state->mps); in start_tx_packet()
528 uint16_t remaining = ep_state->mps - ep_state->last_packet_size; in read_rx_fifo()
1150 dev_state.ep_state[0][0].mps = EP0_FIFO_SIZE; in usb_init()
1151 dev_state.ep_state[1][0].mps = EP0_FIFO_SIZE; in usb_init()
[all …]
/Zephyr-latest/drivers/usb/uhc/
Duhc_common.c98 const uint16_t mps, in uhc_xfer_alloc() argument
124 xfer->mps = mps; in uhc_xfer_alloc()
139 const uint16_t mps, in uhc_xfer_alloc_with_buf() argument
153 xfer = uhc_xfer_alloc(dev, addr, ep, attrib, mps, timeout, udev, cb); in uhc_xfer_alloc_with_buf()
Duhc_virtual.c104 length = MIN(net_buf_tailroom(buf), xfer->mps); in vrt_xfer_control()
107 length = MIN(buf->len, xfer->mps); in vrt_xfer_control()
163 length = MIN(net_buf_tailroom(buf), xfer->mps); in vrt_xfer_bulk()
166 length = MIN(buf->len, xfer->mps); in vrt_xfer_bulk()
228 length = MIN(buf->len, xfer->mps); in vrt_hrslt_success()
241 if (pkt->length > xfer->mps) { in vrt_hrslt_success()
247 if (pkt->length < xfer->mps || !net_buf_tailroom(buf)) { in vrt_hrslt_success()
/Zephyr-latest/tests/drivers/udc/src/
Dmain.c99 uint16_t mps = sys_le16_to_cpu(ed->wMaxPacketSize); in test_udc_ep_try_config() local
103 ed->bmAttributes, &mps, in test_udc_ep_try_config()
116 mps = 0; in test_udc_ep_try_config()
118 ed->bmAttributes, &mps, in test_udc_ep_try_config()
121 zassert_not_equal(mps, 0, "Failed to test endpoint configuration"); in test_udc_ep_try_config()
365 uint16_t mps[] = {8, 16, 32, 64, 512, 1024}; in test_udc_ep_mps() local
403 for (int i = 0; i < ARRAY_SIZE(mps); i++) { in test_udc_ep_mps()
404 if (mps[i] > supported) { in test_udc_ep_mps()
408 ed.wMaxPacketSize = sys_cpu_to_le16(mps[i]); in test_udc_ep_mps()
/Zephyr-latest/tests/bsim/bluetooth/host/l2cap/credits_seg_recv/src/
Dmain.c122 LOG_DBG("%x (tx mtu %d mps %d) (tx mtu %d mps %d)", l2cap_chan, chan->tx.mtu, chan->tx.mps, in l2cap_chan_connected_cb()
123 chan->rx.mtu, chan->rx.mps); in l2cap_chan_connected_cb()
151 le_chan->rx.mps = BT_L2CAP_RX_MTU; in server_accept_cb()
336 .rx.mps = BT_L2CAP_RX_MTU, in connect_l2cap_channel()
363 .rx.mps = BT_L2CAP_RX_MTU, in connect_l2cap_ecred_channel()
/Zephyr-latest/tests/bluetooth/tester/src/
Dbtp_l2cap.c126 ev.mps_remote = sys_cpu_to_le16(chan->le.tx.mps); in connected_cb()
128 ev.mps_local = sys_cpu_to_le16(chan->le.rx.mps); in connected_cb()
191 ev.mps_remote = sys_cpu_to_le16(chan->le.tx.mps); in reconfigured_cb()
193 ev.mps_local = sys_cpu_to_le16(chan->le.rx.mps); in reconfigured_cb()
267 chan->le.rx.mps = L2CAP_MPS; in connect()
338 uint16_t mps; in reconfigure() local
371 mps = MIN(L2CAP_MPS, BT_L2CAP_RX_MTU); in reconfigure()
372 err = bt_l2cap_ecred_chan_reconfigure_explicit(reconf_channels, cp->num, mtu, mps); in reconfigure()
506 chan->le.rx.mps = L2CAP_MPS; in accept()
/Zephyr-latest/samples/subsys/usb/webusb/src/
Dwebusb.c57 #define INITIALIZER_IF_EP(addr, attr, mps, interval) \ argument
63 .wMaxPacketSize = sys_cpu_to_le16(mps), \
/Zephyr-latest/tests/bsim/bluetooth/host/misc/hfc_multilink/tester/src/
Dtester.c194 uint16_t mps = sys_le16_to_cpu(rsp->mps); in handle_l2cap_connected() local
196 peer_mps = mps; in handle_l2cap_connected()
198 LOG_DBG("l2cap connected: mtu %d mps %d credits: %d", mtu, mps, credits); in handle_l2cap_connected()
564 req->mps = sys_cpu_to_le16(23); in open_l2cap()
572 static void send_l2cap_sdu(uint8_t *data, uint16_t data_len, uint16_t mps, uint16_t on_air_size) in send_l2cap_sdu() argument
578 __ASSERT_NO_MSG(data_len <= (mps - BT_L2CAP_SDU_HDR_SIZE)); in send_l2cap_sdu()
/Zephyr-latest/subsys/usb/device_next/
Dusbd_init.c31 uint16_t mps = sys_le16_to_cpu(ed->wMaxPacketSize); in assign_ep_addr() local
47 ed->bmAttributes, &mps, in assign_ep_addr()
53 ed->wMaxPacketSize = sys_cpu_to_le16(mps); in assign_ep_addr()
/Zephyr-latest/tests/subsys/usb/device/src/
Dmain.c43 #define INITIALIZER_IF_EP(addr, attr, mps, interval) \ argument
49 .wMaxPacketSize = sys_cpu_to_le16(mps), \

123