Lines Matching full:nor

265  * struct spi_nor - Structure for defining a the SPI NOR layer
268 * @dev: point to a spi device, or a spi nor controller device.
269 * @info: spi-nor part JDEC MFR id and other info
270 * @page_size: the page size of the SPI NOR
280 * @flags: flag options for the current SPI-NOR (SNOR_F_*)
291 * @read: [DRIVER-SPECIFIC] read data from the SPI NOR
292 * @write: [DRIVER-SPECIFIC] write data to the SPI NOR
293 * @erase: [DRIVER-SPECIFIC] erase a sector of the SPI NOR
295 * spi-nor will send the erase opcode via write_reg()
296 * @flash_lock: [FLASH-SPECIFIC] lock a region of the SPI NOR
297 * @flash_unlock: [FLASH-SPECIFIC] unlock a region of the SPI NOR
298 * @flash_is_locked: [FLASH-SPECIFIC] check if a region of the SPI NOR is
299 * @quad_enable: [FLASH-SPECIFIC] enables SPI NOR quad mode
326 int (*prepare)(struct spi_nor *nor, enum spi_nor_ops ops);
327 void (*unprepare)(struct spi_nor *nor, enum spi_nor_ops ops);
328 int (*read_reg)(struct spi_nor *nor, u8 opcode, u8 *buf, int len);
329 int (*write_reg)(struct spi_nor *nor, u8 opcode, u8 *buf, int len);
331 ssize_t (*read)(struct spi_nor *nor, loff_t from,
333 ssize_t (*write)(struct spi_nor *nor, loff_t to,
335 int (*erase)(struct spi_nor *nor, loff_t offs);
337 int (*flash_lock)(struct spi_nor *nor, loff_t ofs, uint64_t len);
338 int (*flash_unlock)(struct spi_nor *nor, loff_t ofs, uint64_t len);
339 int (*flash_is_locked)(struct spi_nor *nor, loff_t ofs, uint64_t len);
340 int (*quad_enable)(struct spi_nor *nor);
350 static inline void spi_nor_set_flash_node(struct spi_nor *nor, in spi_nor_set_flash_node() argument
353 mtd_set_of_node(&nor->mtd, np); in spi_nor_set_flash_node()
357 device_node *spi_nor_get_flash_node(struct spi_nor *nor) in spi_nor_get_flash_node() argument
359 return mtd_get_of_node(&nor->mtd); in spi_nor_get_flash_node()
424 * spi_nor_scan() - scan the SPI NOR
425 * @nor: the spi_nor structure
427 * The drivers can use this function to scan the SPI NOR.
433 int spi_nor_scan(struct spi_nor *nor);