mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-25 16:31:13 +00:00
35 lines
1.3 KiB
Diff
35 lines
1.3 KiB
Diff
|
From 52d14545d2fc276b1bf9ccf48d4612fab6edfb6a Mon Sep 17 00:00:00 2001
|
||
|
From: David Bauer <mail@david-bauer.net>
|
||
|
Date: Thu, 6 May 2021 17:49:55 +0200
|
||
|
Subject: [PATCH] mtd: spi-nor: Add support for BoHong bh25q128as
|
||
|
|
||
|
Add MTD support for the BoHong bh25q128as SPI NOR chip.
|
||
|
The chip has 16MB of total capacity, divided into a total of 256
|
||
|
sectors, each 64KB sized. The chip also supports 4KB sectors.
|
||
|
Additionally, it supports dual and quad read modes.
|
||
|
|
||
|
Functionality was verified on an Tenbay WR1800K / MTK MT7621 board.
|
||
|
|
||
|
Signed-off-by: David Bauer <mail@david-bauer.net>
|
||
|
---
|
||
|
drivers/mtd/spi-nor/Makefile | 1 +
|
||
|
drivers/mtd/spi-nor/bohong.c | 21 +++++++++++++++++++++
|
||
|
drivers/mtd/spi-nor/core.c | 1 +
|
||
|
drivers/mtd/spi-nor/core.h | 1 +
|
||
|
4 files changed, 24 insertions(+)
|
||
|
create mode 100644 drivers/mtd/spi-nor/bohong.c
|
||
|
|
||
|
--- a/drivers/mtd/spi-nor/spi-nor.c
|
||
|
+++ b/drivers/mtd/spi-nor/spi-nor.c
|
||
|
@@ -2233,6 +2233,10 @@ static const struct flash_info spi_nor_i
|
||
|
|
||
|
{ "at45db081d", INFO(0x1f2500, 0, 64 * 1024, 16, SECT_4K) },
|
||
|
|
||
|
+ /* BoHong Microelectronics */
|
||
|
+ { "bh25q128as", INFO(0x684018, 0, 64 * 1024, 256,
|
||
|
+ SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) },
|
||
|
+
|
||
|
/* EON -- en25xxx */
|
||
|
{ "en25f32", INFO(0x1c3116, 0, 64 * 1024, 64, SECT_4K) },
|
||
|
{ "en25p32", INFO(0x1c2016, 0, 64 * 1024, 64, 0) },
|