Skip to content

Commit

Permalink
Fix external flash on AVR (#16851)
Browse files Browse the repository at this point in the history
  • Loading branch information
leah-splitkb authored Apr 14, 2022
1 parent 46c0db4 commit 18e5690
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion drivers/flash/flash_spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.

/* Mode setting comands */
#define FLASH_CMD_DP 0xB9 /* DP (Deep Power Down) */
#define FLASH_CMD_RDP 0xAB /* RDP (Release form Deep Power Down) */
#define FLASH_CMD_RDP 0xAB /* RDP (Release from Deep Power Down) */

/* Status register */
#define FLASH_FLAG_WIP 0x01 /* Write in progress bit */
Expand Down
6 changes: 3 additions & 3 deletions drivers/flash/flash_spi.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,21 +74,21 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
The sector size of the FLASH in bytes, as specified in the datasheet.
*/
#ifndef EXTERNAL_FLASH_SECTOR_SIZE
# define EXTERNAL_FLASH_SECTOR_SIZE (4 * 1024)
# define EXTERNAL_FLASH_SECTOR_SIZE (4 * 1024L)
#endif

/*
The block size of the FLASH in bytes, as specified in the datasheet.
*/
#ifndef EXTERNAL_FLASH_BLOCK_SIZE
# define EXTERNAL_FLASH_BLOCK_SIZE (64 * 1024)
# define EXTERNAL_FLASH_BLOCK_SIZE (64 * 1024L)
#endif

/*
The total size of the FLASH in bytes, as specified in the datasheet.
*/
#ifndef EXTERNAL_FLASH_SIZE
# define EXTERNAL_FLASH_SIZE (512 * 1024)
# define EXTERNAL_FLASH_SIZE (512 * 1024L)
#endif

/*
Expand Down

0 comments on commit 18e5690

Please sign in to comment.