bsps/shared/xnandpsu: Parameterize number of active chipselects

This makes the number of active chipselects a BSP configuration
parameter. The name of the macro in upstream source is misleading and
suggests that the driver can support up to the selected value when in
actuality it requires that number of chips to be present. If this number
of chips is not present, the driver will hang on initialization waiting
for a chip to respond that does not exist.
This commit is contained in:
Kinsey Moore
2025-12-03 08:25:50 -06:00
committed by Kinsey Moore
parent ff52b009b5
commit 1a99eb52dc
3 changed files with 25 additions and 2 deletions
+1 -1
View File
@@ -189,7 +189,7 @@ extern "C" {
#define XNANDPSU_DEBUG
#ifdef __rtems__
#define XNANDPSU_MAX_TARGETS 2U /**< ce_n0, ce_n1 */
#define XNANDPSU_MAX_TARGETS BSP_NANDPSU_TOTAL_CHIPS
#else
#define XNANDPSU_MAX_TARGETS 1U /**< ce_n0, ce_n1 */
#endif