Commit Graph

3142 Commits

Author SHA1 Message Date
hathach 1cc7c5d030
add hcd_edpt_abort_xfer() API 2023-07-21 12:43:48 +07:00
hathach 16ad918d96
prefer application callback over built-in driver 2023-07-20 17:37:06 +07:00
hathach 77495cf119
improve logging, allow easier to turn off usbd, driver logging
can be useful when focusing on let's say usbh
2023-07-20 17:12:00 +07:00
Aladdin Bakosh 3fdd2a40b2 osal_none: make it possible to override the task delay function 2023-07-18 14:14:23 +02:00
Ha Thach 2bab947e38
Merge pull request #2146 from tannewt/host_cache_align
Fix host buffer alignment setting
2023-07-18 16:39:48 +07:00
hathach b56c4fe945
Merge branch 'master' into renesas_ra_hs_rebased 2023-07-18 15:13:58 +07:00
Aladdin Bakosh 3230d5b1ea debugging can be configured on renesas dcd 2023-07-17 11:54:09 +02:00
Aladdin Bakosh 41b608562a debugging can be configured on renesas hcd 2023-07-17 11:54:09 +02:00
Aladdin Bakosh 1923b1845d fix(RA_hcd): STALL status can be also 3 not only 2 2023-07-17 11:54:09 +02:00
Scott Shawcroft 8b6d0a166b
Fix host buffer alignment setting 2023-07-14 15:30:22 -07:00
hathach 0f53e746ff move check highspeed to rusb_ra 2023-07-07 18:41:16 +07:00
hathach 88478a9d05
add PORT selection for makefile 2023-07-07 16:24:22 +07:00
hathach e0f1ba8b0e
fully work with multiple ports without CFG_TUSB_RHPORT0/1 2023-07-07 16:07:11 +07:00
hathach 4c156100fa
use unaligned access read for hw fifo 2023-07-07 12:27:18 +07:00
hathach c53acb1455
fix build with rx 2023-07-06 20:10:58 +07:00
hathach 1eefc2b3ef
more multiple ports update 2023-07-06 19:35:42 +07:00
hathach 95b77a0e73
add rusb2_module_start(), more update for multiple ports for dcd rusb2 2023-07-06 15:54:07 +07:00
hathach f308435b64
update ra type to include usbhs registers 2023-07-06 09:34:33 +07:00
hathach 4f4c93594d
minor pipe clean up 2023-07-05 17:51:36 +07:00
hathach f79529c09c
usb hs work with ra 6m5 ek 2023-07-05 17:13:01 +07:00
hathach 04b1a67898
Merge branch 'master' into renesas_ra_hs_rebased 2023-07-03 13:09:43 +07:00
Ha Thach f1e006d09b
Merge pull request #2137 from hathach/cmake-ra
enhance RA family
2023-07-03 12:25:29 +07:00
Ha Thach 942eb0f323
Merge pull request #2129 from dauc/patch-1
Fix minor spelling issues
2023-07-02 23:40:37 +07:00
Lars Pötter 2029ca9536 also fixed pico_trac() log messages. 2023-07-02 10:53:08 +02:00
Lars Pötter 0693462eba made line ends consistent. 2023-07-02 09:02:24 +02:00
hathach e7431f54f2
fix undef with fsp 2023-07-01 17:46:21 +07:00
hathach 99e75e6a8a
rework ra build 2023-07-01 12:41:12 +07:00
hathach 6284f2d722
add hcd_frame_number() for pio-usb host 2023-06-29 18:58:33 +07:00
Dave Nadler 11fba59319 Name queues for easier FreeRTOS debugging with task- and queue-aware debuggers 2023-06-28 17:25:22 -04:00
Dave Nadler cca4be6c67
Merge branch 'hathach:master' into master 2023-06-28 17:05:19 -04:00
Devin Auclair 98fb10a724
Fix minor spelling 2023-06-28 14:03:18 -04:00
Ha Thach fe77b6713b
Merge pull request #2085 from georgeboc/msc-ready-bug-fix
Fixes bug in tuh_msc_ready
2023-06-27 17:57:35 +07:00
hathach e43387abac
rework cmake with rtos support add RTOS to family_configure_device/host/dual_example() 2023-06-27 15:45:38 +07:00
hathach 8aa28e63fb
minor clean up with include_guard() 2023-06-26 17:54:31 +07:00
hathach 3cfb838ba7
fix warnings when enable rtt with rp2040 2023-06-26 17:03:45 +07:00
Dave Nadler bd897d9c14
Merge branch 'hathach:master' into master 2023-06-24 11:53:24 -04:00
hathach b59b65d2ed
rename to kinetis_k32l2, rename OPT_MCU_KINETIS_K32 to OPT_MCU_KINETIS_K32L 2023-06-24 18:26:51 +07:00
hathach edbf06aaab
separate iar and gcc build for clean make, also add cpu specific make 2023-06-24 17:35:37 +07:00
Ha Thach 50e61e0e16
Merge pull request #2101 from eustas/patch-1
Fix typos
2023-06-21 15:51:03 +07:00
hathach e754795d3a
fix build warnings 2023-06-16 15:29:34 +07:00
hathach a7f330fa94
fix build, update freertos config for cmake 2023-06-16 14:17:25 +07:00
hathach 65d6acdbfa
fix build warnings 2023-06-16 12:02:42 +07:00
hathach 8af8869d3b
renam OPT_MCU_MIMXRT to OPT_MCU_MIMXRT1XXX
fix build util with makefile
2023-06-16 11:26:38 +07:00
hathach 96f7cd09dc
remove legacy transdimension driver 2023-06-16 10:45:59 +07:00
Ha Thach 433ffe2152
Merge pull request #1985 from kkitayam/uvc_bulk
Add the capability for video class to handle a bulk endpoint in the streaming interface.
2023-06-15 16:28:33 +07:00
hathach d70403f1f4
refactor khci to chipidea fs driver for device (host is not yet) 2023-06-15 13:06:27 +07:00
hathach 05969d2a58
rename typec driver 2023-06-14 11:07:58 +07:00
hathach 9593ab7acc
fix usbh issue when device genreate multiple attach/detach/attach when plugging in 2023-06-13 16:40:29 +07:00
Ha Thach bbc76e7777
Merge pull request #2104 from hathach/g4-pd
Initial support for USB PD stack
2023-06-12 23:14:48 +07:00
hathach 6941a5af81
wrap up initial PD support for G4 2023-06-12 16:42:27 +07:00
hathach c28503060c
ad pd_types.h 2023-06-12 14:57:50 +07:00
hathach debde4cc97
response with request safe5v, get passed PS_READY 2023-06-12 12:14:55 +07:00
hathach bb4fb0543b
able to parse SOURCE_CAP message from dfp 2023-06-09 19:38:50 +07:00
hathach 912802456b
move protocol message to stack, disable battery in PWR's CR3
there is still issue with CC1/CC2 pull down resistor and vstate is not
correct.
2023-06-09 18:15:28 +07:00
Eugene Kliuchnikov 0833806980 Fix typos 2023-06-08 15:38:30 +02:00
hathach 8181d470e5
enable DMA for both pd rx, tx 2023-06-08 18:55:54 +07:00
hathach 9c2a8490af
dma rx works well 2023-06-08 13:37:37 +07:00
hathach fc761953b3
define tuc_int_handler() to empty if TUC not enabled 2023-06-08 09:34:15 +07:00
hathach 7fd0a17bc3
default CFG_TUC_ENABLED to 0 2023-06-08 09:11:29 +07:00
hathach 9b7dee563e
able to response with good crc 2023-06-07 18:57:48 +07:00
Aladdin Bakosh 8bb012e50b fix(RA): static assert RUSB2 register 2023-06-07 12:01:59 +02:00
hathach b893f1d541
inital support for usb typec and pd example 2023-06-07 15:10:40 +07:00
hathach b3fda4a354
able to get usbpd irq handler
- handle cc1, cc2 voltage changes
- get order set, rx message end interrupt
- add  segger rtt support for cmake
2023-06-06 23:55:33 +07:00
hathach f6a45a7aab
clean up 2023-06-05 15:41:45 +07:00
Martino Facchin 2b735ee8f5 renesas_ra: fix wrong ifdef
Since CFG_TUSB_RHPORT1_MODE is always defined now for backwards compatibility
2023-06-05 09:48:06 +02:00
Martino Facchin cdbd3a0b4e Merge remote-tracking branch 'mainline/master' into HEAD
Update fsp to 4.0.0
2023-06-05 09:12:50 +02:00
Martino Facchin cdae66c837 renesas_rx: fix compilation on latest GCC
__CCRX__ only applyes to version 4 of RX family compiler http://tool-support.renesas.com/autoupdate/support/onlinehelp/csp/V4.01.00/CS+.chm/Compiler-CCRX.chm/Output/ccrx04c0201y.html

__RX__ is one of the macros exported by latest gcc (gcc_8.3.0.202305_rx_elf)
2023-06-05 09:04:55 +02:00
Aladdin Bakosh 268ab5863a fix(RA Host Portable): git rid of the IAR warnings for packed 2023-06-02 14:14:57 +02:00
Ha Thach c7686f8d5e
Merge pull request #2092 from hathach/stm32g4
Stm32g4
2023-06-02 17:07:28 +07:00
hathach fcf7791454
add IAR support for G0 with cmake 2023-06-02 13:27:18 +07:00
hathach e7090c7514
cmake refactor 2023-06-02 11:42:17 +07:00
Dave Nadler e8b7f21af6 For FreeRTOS kernel-aware debugging, when queue registry is enabled, label tinyUSB queue 2023-06-01 12:57:44 -04:00
Dave Nadler 70a92291fe Fix diagnostic format string (missing %u) 2023-06-01 10:58:03 -04:00
hathach af59864ab5
Merge branch 'master' into feature/STM32G0 2023-06-01 13:28:28 +07:00
hathach 20ef6c4ef7
slightly clean up 2023-05-29 13:29:11 +07:00
hathach 5c428d35a6
check status_change is not zero first 2023-05-29 13:27:20 +07:00
Ivo Popov 8ad024e51b
Even when we get an empty "status change" interrupt from the hub, schedule another interrupt poll.
During enumeration, when there are multiple devices attached to the
hub as it's plugged into the Pi Pico, enumeration hangs, because we
get a "status change" callback with value zero. With this patch, we
retry several times on "zero" status change callbacks, until
eventually we succeed.

This is the cheapo hub that exhibits this behavior, but I assume it's
not the only one: https://www.amazon.com/gp/product/B083RQMC7S.

While debugging this, I consulted the implementation in the Linux
kernel. There, hub setup explicitly checks each port individually,
before starting to depend on "status change" interrupts:
https://elixir.bootlin.com/linux/latest/source/drivers/usb/core/hub.c#L1133.
We probably should do something like that here, but it's a much bigger
change.
2023-05-29 13:18:16 +07:00
gitlab acfaa4494f Fixes bug in tuh_msc_ready 2023-05-28 15:40:01 +01:00
hathach 7ac85d08c7
move lpc18 and rp2040 to cmake workflow since rp2040 often failed randomly with make 2023-05-26 16:37:47 +07:00
hathach b262164a35
fix build with net_lwip_webserver example 2023-05-26 15:16:18 +07:00
Ha Thach 23c8670e79
Merge pull request #2081 from hathach/more-build-system
More build system
2023-05-25 21:54:31 +07:00
hathach 26d05d7fc9
fix issue with ftdi host driver with status bytes
add workflow_dispatch to all ci workflow
2023-05-25 16:53:32 +07:00
Ha Thach eedafb23f7
Merge pull request #2063 from abakosh/develop
fix(RA Host Portable): implement missing function __builtin_ctz(x)
2023-05-24 20:11:50 +07:00
Aladdin Bakosh 57d2eb603b fix(RA Host Portable): implement missing function __builtin_ctz(x) for IAR 2023-05-24 11:38:40 +02:00
Ha Thach 1ef820ecfe
Enhance chipidea (#2075)
* update chipidea dcd, remove manual ep_count and use DCCPARAMS to get number of endpoint instead
* add dcd dcache for chipidea
* add cmake for lpc18
* add makefile build for mcx
* use fork of mcu sdk
* fix ci build with nrf
* flash rp2040 with openocd
2023-05-23 21:45:00 +07:00
hathach 7211dd18b4
more dcache fix 2023-05-19 13:42:26 +07:00
hathach 5dae5e1292
ehci fix dcache clean when control endpoint failed 2023-05-19 13:32:49 +07:00
hathach f26a93908e
only clean/invalidate dcache on imxrt if memory is not in DTCM 2023-05-19 10:56:52 +07:00
hathach ec4bd39a92
refactor ehci: add attached_buffer for dcache invalidate for IN transfer 2023-05-18 16:41:06 +07:00
hathach 27acaa013b
refactor ehci, since usbh only queue 1 TD per queue head 2023-05-18 15:44:08 +07:00
hathach 49e2aabc81
EHCI more improvement
- more dcache clean/invalidate
- extract init_periodic_list()
- improve isr list handling
2023-05-18 13:45:38 +07:00
hathach a0aea52a11
more cache, fix an similar issue with OHCI when removing an queue head 2023-05-18 12:39:53 +07:00
hathach e4f4ad5bc3
use weak local for dcache function to skip if() 2023-05-18 10:21:11 +07:00
hathach a3e017bfd2
EHCI adding dcahe support, passing enumertaion 2023-05-18 10:04:48 +07:00
Martino Facchin 32f9f452af renesas: provide default for CFG_TUSB_RHPORT1_MODE
Should fix CI failure for Renesas RX family
2023-05-17 12:13:28 +02:00
hathach eb89df4115
adding hcd_dcache_clean/hcd_dcache_invalidate 2023-05-17 16:14:35 +07:00
hathach a9aa0e3a1a
fix error on EHCI causes xfer error in non-queued qhd which cause memory fault 2023-05-16 11:10:44 +07:00
hathach 1e998ce3bd
usbd: fix control transfer issue for chipidea hs when previous status and new setup complete in the same isr frame
change usbd edpt busy/stalled/claimed value to 0/1 instead of
(true/false) since they are 1-bit field.
2023-05-16 11:09:23 +07:00
hathach 2c48050993
add various check for disconncted device, also fix #1511 un-roll recursive hub removal with usbh queue 2023-05-16 11:09:22 +07:00
hathach 1c4f22a54c
EHCI: fix xfer failed with disconnected device as stalled
- change CFG_TUH_ENDPOINT_MAX to 16 (max endpoint pair per device) if
not defined
- change QHD_MAX for EHCI, should be user configurable and more
optimized in the future
2023-05-16 11:09:22 +07:00