Commit graph

9 commits

Author SHA1 Message Date
Dinesh Maniyam
2b2745b189 drivers: mtd: nand: cadence: Use bounce buffer
Enable nand to use bounce buffer. In bounce buffer,
read/write buf will use cadence->buf which has been allocated
using malloc. This will align the memory and avoid memory to be
allocated in different addresses.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:01 +01:00
Dinesh Maniyam
880c317230 drivers: mtd: nand: cadence: Poll for desc complete status
Poll for thread complete status to ensure the
descriptor processing is complete. If complete then can ensure
controller already update the descriptor status.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:01 +01:00
Dinesh Maniyam
b820fa9577 drivers: mtd: nand: cadence: Flush & invalidate dma descriptor
Ensure ddr memory is updated with the data from dcache.
This would help to ensure cdma always reading the latest dma descriptor
from ddr memory.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:01 +01:00
Dinesh Maniyam
36b2a5d676 drivers: mtd: nand: cadence: Support cmd SET_FEATURES & GET_FEATURES
Support NAND_CMD_SET_FEATURES & NAND_CMD_GET_FEATURES.
These commands is one of the basic commands of NAND. The parameters get
from these commands will be used to set timing mode
of NAND data interface.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:01 +01:00
Dinesh Maniyam
dfba71f965 drivers: mtd: nand: cadence: Add support for NAND_CMD_RESET
Support nand reset command for Cadence Nand Driver.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:01 +01:00
Dinesh Maniyam
5045ab8bd3 drivers: mtd: nand: cadence: Add support for NAND_CMD_PARAM
Add support for reading param page of NAND device.
These paramaters are unique and used for identification purpose.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:00 +01:00
Dinesh Maniyam
1d23aca355 drivers: mtd: nand: cadence: Add support for readid command
Add support for readid command in Cadence NAND driver.
The id is unique and used for flash identification.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:00 +01:00
Dinesh Maniyam
ac682c4da9 drivers: mtd: nand: cadence: Add support for read status command
Add support for read status command
in Cadence NAND driver. This status bit is important to check
whether the flash is write-protected.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:00 +01:00
Dinesh Maniyam
ebc41cadc6 drivers: mtd: nand: Add driver for Cadence Nand
Enable driver for Cadence NAND for the family
device agilex5. This driver is leveraged from the path
/drivers/mtd/nand/raw/cadence-nand-controller.c from the
stable version 6.11.2.

Signed-off-by: Dinesh Maniyam <dinesh.maniyam@intel.com>
2025-03-15 10:35:00 +01:00