summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2022-10-10 15:17:08 +0300
committerTom Rini <trini@konsulko.com>2022-10-10 15:17:08 +0300
commit73e741b8ee46eba4e02a3bcc758dbd70540ed3c1 (patch)
tree54ddc86ed44eff230bc0aa3a69ba4742334323fc /include
parent11ef7f07ce60b60fb78c330b3ae35fd1037e50c1 (diff)
parent7676811867b54d4cb7b3356505d41511614884f3 (diff)
downloadu-boot-73e741b8ee46eba4e02a3bcc758dbd70540ed3c1.tar.xz
Merge tag 'u-boot-nand-20221009' of https://source.denx.de/u-boot/custodians/u-boot-nand-flash
- mtd: Update the function name to 'rfree' - Support NAND ONFI EDO mode for imx8mn architecture - dm: clk: add missing stub when CONFIG_CLK is deactivated
Diffstat (limited to 'include')
-rw-r--r--include/clk.h32
-rw-r--r--include/linux/mtd/mtd.h2
-rw-r--r--include/mxs_nand.h3
3 files changed, 35 insertions, 2 deletions
diff --git a/include/clk.h b/include/clk.h
index 76bb64bb5e..407513e0fa 100644
--- a/include/clk.h
+++ b/include/clk.h
@@ -88,8 +88,9 @@ struct clk_bulk {
unsigned int count;
};
-#if CONFIG_IS_ENABLED(OF_CONTROL) && CONFIG_IS_ENABLED(CLK)
struct phandle_1_arg;
+
+#if CONFIG_IS_ENABLED(OF_CONTROL) && CONFIG_IS_ENABLED(CLK)
/**
* clk_get_by_phandle() - Get a clock by its phandle information (of-platadata)
* @dev: Device containing the phandle
@@ -258,12 +259,26 @@ int clk_release_all(struct clk *clk, int count);
void devm_clk_put(struct udevice *dev, struct clk *clk);
#else
+
+static inline int clk_get_by_phandle(struct udevice *dev, const
+ struct phandle_1_arg *cells,
+ struct clk *clk)
+{
+ return -ENOSYS;
+}
+
static inline int clk_get_by_index(struct udevice *dev, int index,
struct clk *clk)
{
return -ENOSYS;
}
+static inline int clk_get_by_index_nodev(ofnode node, int index,
+ struct clk *clk)
+{
+ return -ENOSYS;
+}
+
static inline int clk_get_bulk(struct udevice *dev, struct clk_bulk *bulk)
{
return -ENOSYS;
@@ -275,6 +290,17 @@ static inline int clk_get_by_name(struct udevice *dev, const char *name,
return -ENOSYS;
}
+static inline struct clk *devm_clk_get(struct udevice *dev, const char *id)
+{
+ return ERR_PTR(-ENOSYS);
+}
+
+static inline struct clk *devm_clk_get_optional(struct udevice *dev,
+ const char *id)
+{
+ return ERR_PTR(-ENOSYS);
+}
+
static inline int
clk_get_by_name_nodev(ofnode node, const char *name, struct clk *clk)
{
@@ -285,6 +311,10 @@ static inline int clk_release_all(struct clk *clk, int count)
{
return -ENOSYS;
}
+
+static inline void devm_clk_put(struct udevice *dev, struct clk *clk)
+{
+}
#endif
/**
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index ff635bd716..09f5269887 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -122,7 +122,7 @@ struct mtd_oob_region {
* @ecc: function returning an ECC region in the OOB area.
* Should return -ERANGE if %section exceeds the total number of
* ECC sections.
- * @free: function returning a free region in the OOB area.
+ * @rfree: function returning a free region in the OOB area.
* Should return -ERANGE if %section exceeds the total number of
* free sections.
*/
diff --git a/include/mxs_nand.h b/include/mxs_nand.h
index 741dc8734e..bb5b84b8c2 100644
--- a/include/mxs_nand.h
+++ b/include/mxs_nand.h
@@ -12,6 +12,7 @@
#include <asm/cache.h>
#include <nand.h>
#include <asm/mach-imx/dma.h>
+#include <clk.h>
/**
* @gf_len: The length of Galois Field. (e.g., 13 or 14)
@@ -43,6 +44,7 @@ struct mxs_nand_info {
struct nand_chip chip;
struct udevice *dev;
unsigned int max_ecc_strength_supported;
+ int max_chain_delay;
bool use_minimum_ecc;
int cur_chip;
@@ -59,6 +61,7 @@ struct mxs_nand_info {
struct mxs_gpmi_regs *gpmi_regs;
struct mxs_bch_regs *bch_regs;
+ struct clk *gpmi_clk;
/* Functions with altered behaviour */
int (*hooked_read_oob)(struct mtd_info *mtd,