nor: move in driver.h the flash_driver's declaration

The static analyser 'sparse' complains, while compiling a nor
driver, that the struct flash_driver is declared in the file as
non static, but it is not exposed through an include file.
The message is:
	warning: symbol 'XXX' was not declared. Should it be static?

Move the list of flash_driver's declaration in driver.h
Fix some incorrect non-const declaration and remove redundant
forward declarations.

Change-Id: I5e41d094307aac4a57dfa9a70496ff3cf180bd92
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7662
Tested-by: jenkins
This commit is contained in:
Antonio Borneo
2023-05-01 00:17:23 +02:00
parent 5d77897526
commit 20005eb81a
8 changed files with 74 additions and 80 deletions

View File

@@ -53,8 +53,6 @@
#define SAMV_PAGE_SIZE 512
#define SAMV_FLASH_BASE 0x00400000
extern const struct flash_driver atsamv_flash;
struct samv_flash_bank {
bool probed;
unsigned size_bytes;