Commit Graph

1596 Commits

Author SHA1 Message Date
Sebastian Huber
b99013e580 bsp/tms570: Remove reset source handling
Do not clear SYSESR and let the application handle the reset source.

Update #4982.
2024-01-15 10:33:37 +01:00
Tyler Miller
ec79400503 bsp/tms570: Add HCLKCNTL register
Update #4982.
2024-01-15 10:33:36 +01:00
Tyler Miller
2bbacdb557 bsp/tms570: TMS570LC4x Errata DEVICE#60
Update #4982.
2024-01-15 10:33:34 +01:00
Sebastian Huber
75dd824079 bsp/tms570: Add errata SSWF021#45 handling
Update #4982.
2024-01-15 10:33:33 +01:00
Sebastian Huber
4d9c9c52ae bsp/tms570: Conditionalize TMS570LS3137 errata
Update #4982.
2024-01-15 10:33:31 +01:00
Sebastian Huber
eeaa318dc6 bsp/tms570: Simplify expression
Update #4982.
2024-01-15 10:33:29 +01:00
Tyler Miller
c14efe493b bsp/tms570: Add TMS570LC4357 power support
Update #4982.
2024-01-15 10:33:28 +01:00
Tyler Miller
4f6fa9746d bsp/tms570: Add TMS570LC4357 pin config support
Update #4982.
2024-01-15 10:33:26 +01:00
Tyler Miller
39fd4b142e bsp/tms570: Remove double pin configuration
Do not set pins to the default function before the actual setting is
applied.  If a pin setting needs to be done in a certain order, then
this should be done explicitly through multiple calls to
tms570_bsp_pinmmr_config().

Update #4982.
2024-01-15 10:33:24 +01:00
Tyler Miller
b995211907 bsp/tms570: Add tms570_pbist_run_and_check()
Update #4982.
2024-01-15 10:33:22 +01:00
Tyler Miller
048d81a076 bsp/tms570: Add TMS570LC4357 PBIST support
Update #4982.
2024-01-15 10:33:19 +01:00
Sebastian Huber
36192165e2 bsp/tms570: Fix PBIST clock enable
Bit 1 of the PACT is reserved (writes have no effect).

Update #4982.
2024-01-15 10:33:17 +01:00
Sebastian Huber
eb97cd148c bsp/tms570: Add TMS570LC4357 BSP variants
Update #4982.
2024-01-15 10:33:15 +01:00
Sebastian Huber
437da01f80 bsp/tms570: Add linkcmds.memory
Remove obsolete tms570ls3137_hdk_with_loader BSP variant.  With the new
memory origin/size build options this variant is no longer required.

Update #4982.
2024-01-15 10:33:13 +01:00
Sebastian Huber
285d1a4056 bsp/tms570: Avoid vector overlay memory region
Reserve the space in a section.  This makes it possible to use a common
memory region definition.

Update #4982.
2024-01-15 10:33:09 +01:00
Sebastian Huber
df067e5b69 bsp/tms570: Add TM27 support
Update #4982.
2024-01-15 10:33:06 +01:00
Sebastian Huber
cf01329e24 bsp/tms570: Avoid spurious interrupts
Update #4982.
2024-01-15 10:33:05 +01:00
Sebastian Huber
8753604ed5 bsp/tms570: Implement interrupt is enabled/pending
Update #4982.
2024-01-15 10:33:03 +01:00
Sebastian Huber
a6482ebfaa bsp/tms570: Implement set/get interrupt priority
Update #4982.
2024-01-15 10:33:01 +01:00
Sebastian Huber
27e0abbdb5 bsp/tms570: Avoid errno for debug console
Update #4982.
2024-01-15 10:33:00 +01:00
Sebastian Huber
849210fff6 bsp/tms570: Fix bsp_reset()
Update #4982.
2024-01-15 10:32:58 +01:00
Sebastian Huber
8240caecc8 bsp/tms570: Rename tms570_initialize_and_clear()
Rename tms570_initialize_and_clear() in
tms570_pom_initialize_and_clear().

Update #4982.
2024-01-15 10:32:56 +01:00
Sebastian Huber
2110125f7c bsp/tms570: Add bsp_restart()
Update #4982.
2024-01-15 10:32:54 +01:00
Sebastian Huber
600bd56543 bsp/tms570: Use new pin define
Update #4982.
2024-01-15 10:32:52 +01:00
Sebastian Huber
8e8b9bc0b7 bsp/tms570: Relicense to BSD-2-Clause
Change license to BSD-2-Clause according to file history and contributor
agreements.  Add Doxygen file comments.

Update #3053.
Update #3707.
Update #4982.
2024-01-15 10:32:45 +01:00
Sebastian Huber
58521f15f3 bsp/tms570: Remove empty <bsp/tms570-vim.h>
Update #4982.
2024-01-15 10:32:44 +01:00
Sebastian Huber
72ec63e7d8 bsp/tms570: Remove empty <bsp/tms570-sci.h>
Update #4982.
2024-01-15 10:32:42 +01:00
Sebastian Huber
222c98903f bsp/tms570: Remove empty <bsp/tms570-rti.h>
Update #4982.
2024-01-15 10:32:41 +01:00
Sebastian Huber
7427caa1ae bsps/arm: Use shared empty bsp_start_hook_0()
Update #4982.
2024-01-15 10:32:23 +01:00
Kinsey Moore
150dcf5e47 libio: Clean up usage of rtems_termios_device_mode
This cleans up outputUsesInterrupts usage with rtems_termios_device_mode
enum values. The outputUsesInterrupts member was typed as an int, named
as if it were a boolean value, and used as if it were a
rtems_termios_device_mode enum. In this patch, values assigned to
outputUsesInterrupts have been converted to the corresponding
rtems_termios_device_mode enum value, conversions from
deviceOutputUsesInterrupts have been made explicit, and uses of
rtems_termios_device_mode enum values with deviceOutputUsesInterrupts
have been converted to booleans.
2024-01-10 14:43:53 -06:00
Kinsey Moore
4092fbb2c0 bsps/aarch64/cache: Clean up unused fuctions
When the CPU_CACHE_SUPPORT_PROVIDES_RANGE_FUNCTIONS definition was added
to AArch64 cache management, it obsoleted the *_1_data/instruction_line
functions. These have been removed since they are no longer referenced.
The AArch64_instruction_cache_inner_shareable_invalidate_all function is
only used when RTEMS_SMP is defined, so only define it in that
circumstance.
2024-01-10 14:43:53 -06:00
Bernd Moessner
9d07bf67a9 xparameters.h: fix typo in comment 2024-01-08 17:42:58 -06:00
Sebastian Huber
2e71bd08ba tm27: Add optional TM27_INTERRUPT_VECTOR_DEFAULT
Let the BSP define TM27_INTERRUPT_VECTOR_DEFAULT to more efficiently and
reliably get the TM27 default interrupt vector.

Update #3716.
2023-12-19 08:22:37 +01:00
Kinsey Moore
3798c5735d bsps/xnandpsu: Allow manipulation of BBT
Expose functions to directly manipulate the bad block table (BBT). These
functions are necessary to correct possible BBT corruption caused by
bugs in the BBT management layer.
2023-12-14 13:40:03 -06:00
Kinsey Moore
437053282d bsps/xnandpsu: Constrain block erasure to device
The XNandPsu_EraseBlock function takes a target device and a block
offset for erasure. Ensure the block offset is within the size of the
target device.
2023-12-14 13:40:03 -06:00
Kinsey Moore
d77a873ddb bsps/xnandpsu: Mark correct reserved blocks
When marking the trailing blocks on a device as reserved for Bad Block
Table usage, ensure that the correct blocks are marked. This resolves an
off-by-one error that was marking one block too low and leaving the last
block in the device unmarked.
2023-12-14 13:40:03 -06:00
Kinsey Moore
f823dba027 bsps/xnandpsu: Write BBT to correct location
When writing out the Bad Block Table, write it to the targeted device
and ensure the block is appropriately mapped to the targeted device.
2023-12-14 13:40:03 -06:00
Kinsey Moore
757fbd6bc7 bsps/xnandpsu: Detect missing BBTs
Mark the BBT descriptor as invalid before scanning to ensure that
missing BBTs are detected and written correctly if necessary.
2023-12-14 13:40:03 -06:00
Kinsey Moore
d6b75cc248 bsps/xnandpsu: Read correct BBT size
The Bad Block Table is a per-device catalog of the dispositions of each
block in the device. Only read enough data to determine the dispositions
of blocks for the device being read.
2023-12-14 13:40:03 -06:00
Kinsey Moore
7946cff0bc bsps/xnandpsu: Fix BBT mapping functions
The xnandpsu driver includes functionality to map back and forth between
the flash-based BBT and the memory-based BBT with the values in each
being a bitwise inversion of each other. This resolves several bugs in
this process and simplifies the inversion from operating on the block
representation to operating on the entire BBT entry (4 blocks, 2 bits
per block, one byte total).

Bugs resolved in XNandPsu_ConvertBbt():
* The calculation of memory BBT entry offset was off by a factor of 4
* The entry offset into the flash BBT has been removed since each flash
  BBT directly describes the flash space it is contained within and has
  no reference to other devices in the chip

Bugs resolved in XNandPsu_WriteBbt():
* The BBT length calculated was reduced to NumTargetBlocks from
  NumBlocks since only the relevant portion of the in-memory BBT should
  be written to the flash-based BBT space
* An offset was applied to values retrieved from the in-memory BBT so
  that only the relevant portion was converted and written to the
  flash-based BBT
2023-12-14 13:40:03 -06:00
Kinsey Moore
a6aa6c6385 bsps/zynqmp/jffs2: Use BBT information directly
The XNandPsu_IsBlockBad() function is insufficient for JFFS2 to
determine whether a block is usable since the function does not report
reserved blocks. JFFS2 is also unable to use the last 4 blocks of each
target attached to the NAND controller since they are reserved for the
Bad Block Table (BBT), but not necessarily marked as such.
2023-12-14 13:40:03 -06:00
Jacob Killelea
0883f7ec58 bsps/arm/stm32f4: Enable USART RX interrupts
Hi all, this is my first email patch submission and my first contribution to RTEMS, so please give any
feedback you have!

This patch enables interrupt driven data reception on USART ports on
STM32F4 series chips. This feature is gated behind the config flag
BSP_CONSOLE_USE_INTERRUPTS. If this flag is not set to True, the older
polling implementation will be used. I tested this feature on STM32F401CE
(blackpill) and STM32 Nucleo F411RE boards, with both capable of keeping
up with a 115200 baud continous data stream. With the older polling
implementation, both would drop bytes at 9600 baud. In addition, I
updated the implementation of usart_set_attributes to support changing
the baud rate of the USART port based on the input speed.
2023-12-14 13:40:03 -06:00
Sebastian Huber
2286a2ec19 bsp/tms570: Do not use POM for internal flash 2023-12-06 17:04:46 +01:00
Sebastian Huber
05a4c70aa9 bsp/tms570: Improve POM handling
Place the vector table in the start section so that the overlay can be
avoided if we execute from internal flash.  The problem is that when the
POM is enabled, the ECC cannot be enabled for the internal flash.
2023-12-06 14:27:48 +01:00
Sebastian Huber
c374727c63 bsp/tms570: Adjust BSP_OSCILATOR_CLOCK 2023-12-06 13:35:40 +01:00
Sebastian Huber
c65466929f bsp/tms570: Fix debug console baud setting 2023-12-06 13:35:40 +01:00
Sebastian Huber
232180a502 bsp/tms570: Use internal RAM for fast data 2023-12-06 13:35:40 +01:00
Sebastian Huber
47c4093ad3 bsp/tms570: Add TMS570LC4357 support 2023-12-06 13:35:40 +01:00
Sebastian Huber
e13b7340fe bsp/tms570: Use 0x for hex constants 2023-12-06 13:35:40 +01:00
Sebastian Huber
3a0dcd5ee9 bsp/tms570: Replace TMS570_MMR_SELECT_GMII_SEL
Replace TMS570_MMR_SELECT_GMII_SEL with TMS570_MMR_SELECT_MII_MODE and
TMS570_MMR_SELECT_RMII_MODE.
2023-12-06 13:35:40 +01:00