stmhal: Move fatfs volume/partition lookup table to ROM.
This commit is contained in:
parent
60427864b1
commit
b96c7c03ca
@ -15,7 +15,7 @@
|
||||
#include "storage.h"
|
||||
#include "sdcard.h"
|
||||
|
||||
PARTITION VolToPart[] = {
|
||||
const PARTITION VolToPart[] = {
|
||||
{0, 1}, // Logical drive 0 ==> Physical drive 0, 1st partition
|
||||
{1, 0}, // Logical drive 1 ==> Physical drive 1 (auto detection)
|
||||
/*
|
||||
|
@ -37,7 +37,7 @@ typedef struct {
|
||||
BYTE pd; /* Physical drive number */
|
||||
BYTE pt; /* Partition: 0:Auto detect, 1-4:Forced partition) */
|
||||
} PARTITION;
|
||||
extern PARTITION VolToPart[]; /* Volume - Partition resolution table */
|
||||
extern const PARTITION VolToPart[]; /* Volume - Partition resolution table */
|
||||
#define LD2PD(vol) (VolToPart[vol].pd) /* Get physical drive number */
|
||||
#define LD2PT(vol) (VolToPart[vol].pt) /* Get partition index */
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user