738 Commits

Author SHA1 Message Date
Stephen Clark
c41318075e nexus: Added SDHCI driver to ZynqMP
Made ZynqMP build with the SDHCI driver.
2021-07-15 11:29:09 -05:00
Kinsey Moore
a53aeb5eb9 rtemsbsd: Present all ZynqMP interfaces by default
Now that the issue with false PHY detection on unterminated MII busses
has been resolved, present all hardware interfaces for use on ZynqMP.
2021-07-15 10:07:16 -05:00
Kinsey Moore
b0c8153d54 rtemsbsd: Use config.inc to control ZynqMP ethernet
This alters the selection of the 4 Cadence GEM interfaces on the Zynq
Ultrascale+ MPSoC BSP to be provided by config.inc instead of being
provided by options in the RTEMS BSP itself since those options appear
to be dead code when not used in conjunction with LibBSD.
2021-07-01 10:33:39 -05:00
Stephen Clark
6cc63cbe65 rtemsbsd: Made TTCP command build for RTEMS
Updated ttcp.c to build clean for RTEMS 6 and the machines it
originally built for. Also fixed ttcp.c to close network
sockets after completion. Defined a shell command for TTCP in
rtems-bsd-shell-ttcp.c. Added TTCP to the list of RTEMS network
commands in netcmds-config.h. Added declaration of the TTCP shell
command to rtems-bsd-commands.h. Modified libbsd.py to make waf
build TTCP and its shell command.
2021-06-29 16:03:42 -05:00
Stephen Clark
7960ab7a43 rtemsbsd:Updated TTCP code with network demo code
Updated the TTCP code to match the ttcp.c in RTEMS network-demos
repository (https://git.rtems.org/network-demos/).
2021-06-29 16:03:42 -05:00
Stephen Clark
af06b267c5 rtemsbsd: Added original TTCP code
Added the original Test TCP (TTCP) program in unmodified form.
Also added the original README for TTCP. Both the README and the
TTCP program were sourced from the first commit in the RTEMS
network demos repository.
2021-06-29 16:03:42 -05:00
Kinsey Moore
4ce914cb90 rtemsbsd: Make ZynqMP CGEM interfaces selectable
Use the new options from the ZynqMP BSPs to allow selection of the
available CGEM ethernet interfaces.
2021-06-28 09:15:13 -05:00
Sebastian Huber
158c270ded EPOCH(9): Fix epoch call and drain
Since the epoch call callbacks may lock/unlock a mutex the callbacks must be
called from within thread context with thread dispatching enabled.  Use thread
pinning to ensure that the calling thread stays on the right processor.  Use
the interrupt server to ensure the thread context for the epoch drain.
2021-06-15 18:46:08 +02:00
Sebastian Huber
cb94a7443d EPOCH(9): Use PER_CPU_DATA_NEED_INITIALIZATION()
Use the PER_CPU_DATA_NEED_INITIALIZATION() macro if necessary to request an
initialization of the per-CPU data.
2021-06-11 08:46:37 +02:00
Ryan Long
34862dd273 libbsd nfs.c: Change filesystem utime_h handler to utimens_h
Changed nfs_utime() to nfs_utimens(), changed the arguments to use
a timespec array instead of individual variables for access and
modified time.

Updates #4400
2021-05-28 16:32:42 -05:00
Christian Mauderer
b1ecc253ee st-sdmmc: Handle short not cache aligned buffers
Possible data sources for SD driver:

- mmc_sd_switch():
    - length: 64 byte;
    - buffer on stack
- mmc_test_bus_width():
    - length: 4 or 8 byte
    - buffer in program memory or on stack
- mmc_app_send_scr():
    - length: 8 byte
    - buffer from device ivar structure
- mmc_app_sd_status():
    - length: 64 byte
    - buffer from device ivar structure
- mmc_send_ext_csd():
    - length: MMC_EXTCSD_SIZE = 512
    - buffer from device ivar structure
- rtems_bsd_mmcsd_disk_read_write():
    - length: depends on read
    - buffer from rtems_blkdev buffer -> already aligned
- mmcsd_ioctl_cmd():
    - length: depends on call
    - buffer malloced, not aligned -> patched in RTEMS

So the problematic buffers are only the ones up to 512 bytes. Copy these data
into a buffer to avoid that problem.
2021-04-19 09:02:30 +02:00
Christian Mauderer
aef7a74b94 STM32H7: Fix SDMMC build for all other BSPs 2021-04-01 16:04:44 +02:00
Christian Mauderer
e0fcb31f01 STM32H7: Add SDMMC driver
Update #4372
2021-04-01 09:05:13 +02:00
Kinsey Moore
023e94fd8b nexus: Add UKPHY driver to ZynqMP
ZynqMP hardware comes with many different Ethernet PHYs depending on
which board is used. Add the UKPHY driver to handle basic PHY
interaction for any unrecognized PHYs.
2021-03-10 08:57:59 -06:00
Kinsey Moore
e256668d6e nexus: Add ZynqMP SLCR driver
Add a System Level Control Register driver for the Xilinx Zynq
Ultrascale+ MPSoC with basic clock control functionality for use with
the Cadence GEM. This also removes the Zynq-7000 clock control weakref
from compilation depending on the BSP in use.
2021-03-10 08:57:59 -06:00
Kinsey Moore
1d9f93cbaa nexus: Switch ZynqMP platforms to CGEM3
Similar to the UARTs, ZynqMP hardware platforms use the highest
memory-mapped CGEM peripheral as the primary instance of that
peripheral. This change allows operation on hardware as well as QEMU.
2021-03-10 08:57:59 -06:00
Kinsey Moore
0c60fe524e rtembsd: Fix alignment of allocations for 64bit
Alignment on 64bit hardware is strict in comparison to running in an
emulator. This resolves an alignment exception when allocating memory on
real hardware.
2021-03-10 08:57:59 -06:00
Kinsey Moore
68e79b6d18 zynq: Add support for SDHCI devices 2020-12-22 16:12:58 -06:00
Kinsey Moore
0ad342ae5f Add CGEM definitions for ZynqMP 2020-11-24 08:50:07 -06:00
Christian Mauderer
9cd28904cf imxrt: Add support
Update #4180
2020-11-17 11:33:01 +01:00
Kinsey Moore
19d98d3a19 Update arm64/aarch64 support 2020-11-13 12:33:17 -06:00
Sebastian Huber
9ebb4e2025 dwc_otg: Enable voltage detector
Update #3910.
2020-10-27 06:29:39 +01:00
Sebastian Huber
0e7108f940 dwc_otg: Add support for nexus bus
Update #3910.
2020-10-27 06:29:37 +01:00
Sebastian Huber
1189f7147a if_stmac: Add driver for STM32H7 ethernet module
Update #3910.
2020-10-27 06:28:47 +01:00
Sebastian Huber
06896e4842 NVD(4): Fix logical block count calculation
Update #4164.
2020-10-27 06:26:34 +01:00
Sebastian Huber
b057293e6b NVD(4): Fix NULL pointer access in nvd_sync()
Update #4164.
2020-10-27 06:26:22 +01:00
Chris Johns
c99a1ab00e powerpc/nexus: Add legacy PCI support to PowerPC Motorola Shared BSP family 2020-10-20 12:54:54 +11:00
Sebastian Huber
6b38edaf21 tsc_lpc32xx.c: Update due to API changes 2020-09-29 14:09:53 +02:00
Sebastian Huber
5eed6acb5f rtems-bsd-cxx: Undefine _GNU_SOURCE
At least the powerpc C++ compiler defines currently _GNU_SOURCE due to a GCC
configuration error.  This leads to conflicting qsort_r() definitions.

As a workaround undefine _GNU_SOURCE for this C++ compatibility test file.

Update #4078.
2020-09-14 17:13:12 +02:00
Sebastian Huber
272d5f522d ifmcstat: Port to RTEMS 2020-09-07 10:12:44 +02:00
Sebastian Huber
03d7f76a81 nfsclient: Next attempt to fix 64-bit targets
In serporidok use the same structures used to hand over to the XDR
encode/decode routines.  We must not mix packed and unpacked structures.

Update #4025.
2020-08-18 07:32:20 +02:00
Sebastian Huber
bd7e6eeb31 Conditionally include <bsp/linker-symbols.h>
Remove superfluous <bsp.h> include.
2020-08-05 15:04:48 +02:00
Christian Mauderer
7e453ad5c9 imx: Don't use USB_NEED_BUSDMA_COHERENT_ALLOC
That option makes problems with some drivers because the buffers are not
allways cache line aligned.

Update 3869
2020-07-29 13:09:11 +02:00
Christian Mauderer
5e3780023c busdma: Don't sync nocache memory on ARM
The busdma shouldn't try to flush or invalidate cache in a nocache area.
2020-07-29 13:09:11 +02:00
Christian Mauderer
cdd6003eb8 busdma: Option to round to cache lines on sync
Some targets support only flushing or invalidating complete cache lines.
In this cases misaligned buffers might lead to unexpected results. This
patch adds a flag that allows drivers to signal to the bus dma driver
that it is OK to round a buffer to the next full cache line. That's for
example necessary if a driver wants to send out 14 byte via a USB DMA.
Only the driver knows whether these 14 bytes are located in an otherwise
unused cache line aligned buffer.
2020-07-29 13:09:11 +02:00
Christian Mauderer
1398d9329f imx: Use RTEMS GPIO driver instead of FreeBSD one
Update 3869
2020-07-29 13:09:11 +02:00
Christian Mauderer
4c762de2fd gpioregulator: Remove.
There is a bug in the #ifdef regarding FDT so this file hasn't been
compiled. If that bug is solved, the driver doesn't work for some other
reason.

With the FDT-bug the driver hasn't been used by anyone. So just remove
it again.
2020-07-29 13:09:11 +02:00
Sebastian Huber
26866d2c1f Fix linker errors with minimal build set 2020-07-08 10:21:20 +02:00
Jan Sommer
a69293ca57 i386: Port to RTEMS
- Update imported files to compile rtems-libbsd for i386 based BSPs
- Mostly commenting out parts which create compile or link errors in
RTEMS, but aren't needed
2020-04-17 13:18:06 +02:00
Jan Sommer
dc86c55f51 i386: Delete old machine dependent files
- The files in the i386 directory have been moved to common x86 directories by FreeBSD:
  - freebsd/sys/x86/x86/legacy.c
  - freebsd/sys/x86/include/machine/legacyvar.h
  - freebsd/sys/x86/include/machine/specialreg.h
- Add header files in rtemsbsd directory to direct compiler to new files
2020-04-17 13:15:51 +02:00
Christian Mauderer
c5455b03ed ehci_imx: Add to build. 2020-04-15 16:14:18 +02:00
Christian Mauderer
113662dfaf Add support for i.mx cache.
Update #3869.
2020-04-14 16:39:21 +02:00
Christian Mauderer
24806eec09 regulator: Add to build.
Update #3869.
2020-04-14 16:39:20 +02:00
Christian Mauderer
3a1d48c70c imx6_ccm: Add and build module.
Update #3869.
2020-04-14 16:39:20 +02:00
Sebastian Huber
64c45b5a1a usb_busdma: Add USB_NEED_BUSDMA_COHERENT_ALLOC
Some BSPs have a cache-coherent memory area, however, it should not be
used for the USB controller.
2020-04-14 16:39:20 +02:00
Sebastian Huber
039afd9816 nfsclient: Use a system event for RPC
Aviod conflicts with application events.
2020-03-18 08:26:09 +01:00
Sebastian Huber
46b3858b27 Update to FreeBSD stable/12 2020-02-10
Git mirror commit 0d1c391321b34b3025cf0e72f2231d836ff76da8.
2020-02-18 15:00:48 +01:00
Sebastian Huber
afaeccc05a NVMECONTROL(8): Port to RTEMS
Update #3821.
2019-11-13 13:22:36 +01:00
Sebastian Huber
e7291f7ac3 NVD(4): Add RTEMS-specific NVMe disk driver
Update #3821.
2019-11-13 13:22:23 +01:00
Sebastian Huber
da6b9a1891 NVME(4): Port to RTEMS
Update #3821.
2019-11-13 13:22:10 +01:00