405 Commits

Author SHA1 Message Date
Kinsey Moore
89db1bb27c rtemsbsd: Remove old DHCP init prototype
This prototype should have been removed with commit
ac4db4cec5b6b1e0a25e910851e50831afb0749d.
2024-03-27 12:12:24 -05:00
Christian Mauderer
e07b74b88a rtemsbsd/sys/arm: Add imxrt1166 USBPHY driver
Adds a driver for the i.MXRT1166 USB PHY and enable USB for the
imxrt11xx BSPs.
2023-08-21 09:17:02 +02:00
Christian Mauderer
3393edcb4b bsp/imxrt: Enable cache handling
The BSP needs the CPU_DATA_CACHE_ALIGNMENT set to enable correct cache
handling in libbsd. Otherwise for example USB doesn't work reliable.
2023-08-21 09:17:02 +02:00
Sebastian Huber
30116094a9 Define IFCAP_NOMAP for Newlib compatibility 2022-07-07 14:23:25 +02:00
Sebastian Huber
2f7103677c Define IN_HISTORICAL_NETS for kernel space
Required by FreeBSD commit:

Author: Mike Karels <karels@FreeBSD.org>
Date:   Tue Oct 26 22:01:09 2021 -0500

    kernel: deprecate Internet Class A/B/C

    Hide historical Class A/B/C macros unless IN_HISTORICAL_NETS is defined;
    define it for user level.  Define IN_MULTICAST separately from IN_CLASSD,
    and use it in pf instead of IN_CLASSD.  Stop using class for setting
    default masks when not specified; instead, define new default mask
    (24 bits).  Warn when an Internet address is set without a mask.

    MFC after:      1 month
    Reviewed by:    cy
    Differential Revision: https://reviews.freebsd.org/D32708
2022-07-07 14:23:25 +02:00
Konstantin Belousov
7974c8b9db Kernel-side infrastructure to implement nvlist-based set/get ifcaps
Reviewed by:	hselasky, jhb, kp (previous version)
Sponsored by:	NVIDIA Networking
MFC after:	3 weeks
Differential revision:	https://reviews.freebsd.org/D32551
2022-07-07 14:23:25 +02:00
Rick Macklem
e86ac20e9f uipc_socket.c: Modify MSG_TLSAPPDATA to only do Alert Records
Without this patch, the MSG_TLSAPPDATA flag would cause
soreceive_generic() to return ENXIO for any non-application
data record in a TLS receive stream.

This works ok for TLS1.2, since Alert records appear to be
the only non-application data records received.
However, for TLS1.3, there can be post-handshake handshake
records, such as NewSessionKey sent to the client from the
server. These handshake records cannot be handled by the
upcall which does an SSL_read() with length == 0.

It appears that the client can simply throw away these
NewSessionKey records, but to do so, it needs to receive
them within the kernel.

This patch modifies the semantics of MSG_TLSAPPDATA slightly,
so that it only applies to Alert records and not Handshake
records. It is needed to allow the krpc to work with KTLS1.3.

Reviewed by:	hselasky
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D35170
2022-07-07 14:23:25 +02:00
Kristof Provost
d9027851bd Widen ifnet_detach_sxlock coverage
Widen the ifnet_detach_sxlock to cover the entire vnet sysuninit code.
This ensures that we can't end up having the vnet_sysuninit free the UDP
pcb while the detach code is running and trying to purge the UDP pcb.

MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28530
2022-07-07 14:23:25 +02:00
Rick Macklem
4de7ab7e97 Add the MSG_TLSAPPDATA flag to indicate "return ENXIO" for non-application TLS data records.
The kernel RPC cannot process non-application data records when
using TLS. It must to an upcall to a userspace daemon that will
call SSL_read() to process them.

This patch adds a new flag called MSG_TLSAPPDATA that the kernel
RPC can use to tell sorecieve() to return ENXIO instead of a non-application
data record, when that is what is at the top of the receive queue.
I put the code in #ifdef KERN_TLS/#endif, although it will build without
that, so that it is recognized as only useful when KERN_TLS is enabled.
The alternative to doing this is to have the kernel RPC re-queue the
non-application data message after receiving it, but that seems more
complicated and might introduce message ordering issues when there
are multiple non-application data records one after another.

I do not know what, if any, changes will be required to support TLS1.3.

Reviewed by:	glebius
Differential Revision:	https://reviews.freebsd.org/D25923
2022-07-07 14:23:25 +02:00
Sebastian Huber
f009252227 user-space: Request FreeBSD bitset API
This is required for recent Newlib versions.

Update #4667.
2022-06-30 17:41:02 +02:00
Sebastian Huber
c6212520ab Add program destructor support
Update #4650.
2022-05-12 07:48:02 +02:00
Heinz Junkes
878713ba45 if_mve: Add MV643XX Ethernet driver
Close #4345.
2022-03-07 10:53:16 +01:00
Sebastian Huber
1b6529ee94 rtems-bsd-program.h: Remove stray ';' 2022-02-23 15:57:30 +01:00
Gedare Bloom
8f870a3593 aarch64/nexus: add GEM definitions for Versal 2021-06-25 13:02:38 -06:00
Jan Sommer
5b82fcf06a i386: Remove unneeded include header files 2021-06-07 10:39:46 +02:00
Vijay Kumar Banerjee
9b9a976847 Revert "Import telnetd from RTEMS repository"
This reverts commit 1b07480ddc93c10777eff5072e7621ed0c96d30c.
2021-04-13 12:16:50 -06:00
Vijay Kumar Banerjee
1b07480ddc Import telnetd from RTEMS repository
The files have been taken from RTEMS repository with head commit at
bd9e45d91f77657445400bc2c814f251c9e37cef
2021-04-07 19:15:51 -06:00
Christian Mauderer
1bb4a56e4d STM32H7: Add SDMMC driver
Update #4372
2021-04-01 09:05:53 +02:00
G S Niteesh Babu
3cdf289424 arm/ti/ti_pinmux: Remove TI pinmux driver
The TI driver has been moved to RTEMS so the driver can be removed
from libBSD.

The following files have been removed from libBSD and moved to
RTEMS.
1) ti/am335x/am335x_scm_padconf.c
2) ti/am335x/am335x_scm_padconf.h
3) ti/ti_pinmux.c
4) ti/ti_pinmux.h

Update #3784
2021-03-21 12:35:04 +01:00
Kinsey Moore
98d197895b Add CGEM definitions for ZynqMP 2020-11-24 08:49:49 -06:00
Christian Mauderer
5cb4146627 imxrt: Add support
Update #4180
2020-11-20 08:56:30 +01:00
Kinsey Moore
9f52a0df17 Update arm64/aarch64 support 2020-11-13 12:34:01 -06:00
Sebastian Huber
6c83023331 dwc_otg: Add support for nexus bus
Update #3910.
2020-10-27 06:33:05 +01:00
Sebastian Huber
c28f67a9be if_stmac: Add driver for STM32H7 ethernet module
Update #3910.
2020-10-27 06:33:02 +01:00
Chris Johns
bff15c3326 powerpc/nexus: Add legacy PCI support to PowerPC Motorola Shared BSP family 2020-10-26 07:42:09 +11:00
Jan Sommer
66019c3e78 i386: Delete old machine dependent files
- The files in the i386 directory have been moved to common x86 directories by FreeBSD:
  - freebsd/sys/i386/include/machine/bus.h
  - 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-09-16 15:52:58 +10:00
Sebastian Huber
d56d9b6d3b ifmcstat: Port to RTEMS 2020-09-10 13:24:18 +02:00
Christian Mauderer
828969e525 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 11:19:14 +02:00
Christian Mauderer
4820ccecc9 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 11:19:14 +02:00
Christian Mauderer
7e5d93bb6b imx: Use RTEMS GPIO driver instead of FreeBSD one
Update 3869
2020-07-29 11:19:00 +02:00
Christian Mauderer
469cc8fbb7 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 11:15:42 +02:00
Christian Mauderer
f33b6a0f3b ehci_imx: Add to build. 2020-04-15 16:32:34 +02:00
Christian Mauderer
c54699f40f Add support for i.mx cache.
Update #3869.
2020-04-15 16:32:34 +02:00
Christian Mauderer
e518d8c72c regulator: Add to build.
Update #3869.
2020-04-15 16:32:24 +02:00
Christian Mauderer
6624d6ee32 imx6_ccm: Add and build module.
Update #3869.
2020-04-15 16:18:44 +02:00
Sebastian Huber
bd7af5fcee 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-15 16:18:43 +02:00
Jan Sommer
af291fa3a0 i386: Port to RTEMS
- Update imported files to compile rtems-libbsd for i386 based BSPs
- Currently does not support the option "dev_nic_e1000 = on"
2020-02-10 10:44:28 +01:00
Sebastian Huber
e6acc15bc9 NVMECONTROL(8): Port to RTEMS
Update #3821.
2019-11-13 13:04:09 +01:00
Sebastian Huber
53145c7232 NVME(4): Port to RTEMS
Update #3821.
2019-11-13 13:03:49 +01:00
Sebastian Huber
a5ddb0ea69 Update to FreeBSD head 2019-09-24
Git mirror commit 6b0307a0a5184339393f555d5d424190d8a8277a.
2019-11-13 10:47:04 +01:00
Sebastian Huber
5f2d63683a Add support for EARLY_COUNTER 2019-09-25 10:58:17 +02:00
Sebastian Huber
bf9681316a Remove obsolete header files 2019-09-24 14:20:08 +02:00
Sebastian Huber
747c6165b8 Compatibility for next Newlib update 2019-09-24 14:10:43 +02:00
Sebastian Huber
e9730d5fc5 Fix pgsigio() warnings 2019-09-24 14:07:12 +02:00
Sebastian Huber
5173168252 C++ compatiblity for kernel space header 2019-09-23 10:55:44 +02:00
Sebastian Huber
7b1aea98a1 Add wrapper for strndup() 2019-09-11 10:25:49 +02:00
Vijay Kumar Banerjee
951c4b92cf rtemsbsd: remove dead code fb.c 2019-08-31 20:32:38 +02:00
Sebastian Huber
8bf5f93ac1 atomic.h: Add atomic_load_long() 2019-08-27 10:31:42 +02:00
Vijay Kumar Banerjee
530f8f5abd am335x display drivers: Port to RTEMS 2019-08-11 15:57:54 +02:00
Vijay Kumar Banerjee
d7c01f4569 fbd: Port to RTEMS 2019-08-11 15:57:54 +02:00