History

Merge tag 'mtd/for-5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux

Pull MTD updates from Miquel Raynal: "MTD core - block2mtd: page index should use pgoff_t - maps: physmap: minimal Runtime PM support - maps: pcmciamtd: avoid possible sleep-in-atomic-context bugs - concat: Fix a comment referring to an unknown symbol Raw NAND: - Macronix: Use match_string() helper - Atmel: switch to using devm_fwnode_gpiod_get() - Denali: rework the SKIP_BYTES feature and add reset controlling - Brcmnand: set appropriate DMA mask - Cadence: add unspecified HAS_IOMEM dependency - Various cleanup. Onenand: - Rename Samsung and Omap2 drivers to avoid possible build warnings - Enable compile testing - Various build issues - Kconfig cleanup SPI-NAND: - Support for Toshiba TC58CVG2S0HRAIJ SPI-NOR: - Add support for TB selection using SR bit 6, - Add support for few flashes" * tag 'mtd/for-5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux: (41 commits) mtd: concat: Fix a comment referring to an unknown symbol mtd: rawnand: add unspecified HAS_IOMEM dependency mtd: block2mtd: page index should use pgoff_t mtd: maps: physmap: Add minimal Runtime PM support mtd: maps: pcmciamtd: fix possible sleep-in-atomic-context bugs in pcmciamtd_set_vpp() mtd: onenand: Rename omap2 driver to avoid a build warning mtd: onenand: Use a better name for samsung driver mtd: rawnand: atmel: switch to using devm_fwnode_gpiod_get() mtd: spinand: add support for Toshiba TC58CVG2S0HRAIJ mtd: rawnand: macronix: Use match_string() helper to simplify the code mtd: sharpslpart: Fix unsigned comparison to zero mtd: onenand: Enable compile testing of OMAP and Samsung drivers mtd: onenand: samsung: Fix printing format for size_t on 64-bit mtd: onenand: samsung: Fix pointer cast -Wpointer-to-int-cast warnings on 64 bit mtd: rawnand: denali: remove hard-coded DENALI_DEFAULT_OOB_SKIP_BYTES mtd: rawnand: denali_dt: add reset controlling dt-bindings: mtd: denali_dt: document reset property mtd: rawnand: denali_dt: Add support for configuring SPARE_AREA_SKIP_BYTES mtd: rawnand: denali_dt: error out if platform has no associated data mtd: rawnand: brcmnand: Set appropriate DMA mask ...

Linus Torvalds committed 6 years ago

Commit 35c222f2 parents e84bcd6 457524326 files · +286 −162Browse files

Showing the changes to include/linux (1 of 26 files). Show all

Unified · Split

include/linux/mtd/spi-nor.h+5−11
@@ -128,7 +128,8 @@ · 127 unmodified lines
128128 #define SR_BP0 BIT(2) /* Block protect 0 */
129129 #define SR_BP1 BIT(3) /* Block protect 1 */
130130 #define SR_BP2 BIT(4) /* Block protect 2 */
131−#define SR_TB BIT(5) /* Top/Bottom protect */
131+#define SR_TB_BIT5 BIT(5) /* Top/Bottom protect */
132+#define SR_TB_BIT6 BIT(6) /* Top/Bottom protect */
132133 #define SR_SRWD BIT(7) /* SR write protect */
133134 /* Spansion/Cypress specific status bits */
134135 #define SR_E_ERR BIT(5)
@@ -224,14 +225,6 @@ static inline u8 spi_nor_get_protocol_width(enum spi_nor_protocol proto) · 89 unmodified lines
224225 return spi_nor_get_protocol_data_nbits(proto);
225226 }
226227
227−enum spi_nor_ops {
228− SPI_NOR_OPS_READ = 0,
229− SPI_NOR_OPS_WRITE,
230− SPI_NOR_OPS_ERASE,
231− SPI_NOR_OPS_LOCK,
232− SPI_NOR_OPS_UNLOCK,
233−};
234−
235228 enum spi_nor_option_flags {
236229 SNOR_F_USE_FSR = BIT(0),
237230 SNOR_F_HAS_SR_TB = BIT(1),
@@ -244,6 +237,7 @@ enum spi_nor_option_flags { · 6 unmodified lines
244237 SNOR_F_HAS_LOCK = BIT(8),
245238 SNOR_F_HAS_16BIT_SR = BIT(9),
246239 SNOR_F_NO_READ_CR = BIT(10),
240+ SNOR_F_HAS_SR_TB_BIT6 = BIT(11),
247241
248242 };
249243
@@ -483,8 +477,8 @@ struct spi_nor; · 233 unmodified lines
483477 * opcode via write_reg().
484478 */
485479 struct spi_nor_controller_ops {
486− int (*prepare)(struct spi_nor *nor, enum spi_nor_ops ops);
487− void (*unprepare)(struct spi_nor *nor, enum spi_nor_ops ops);
480+ int (*prepare)(struct spi_nor *nor);
481+ void (*unprepare)(struct spi_nor *nor);
488482 int (*read_reg)(struct spi_nor *nor, u8 opcode, u8 *buf, size_t len);
489483 int (*write_reg)(struct spi_nor *nor, u8 opcode, const u8 *buf,
490484 size_t len);