A few fixes for clean apps/examples/mtdrwb build
This commit is contained in:
parent
d8f8151a4f
commit
74972dfa59
@ -130,6 +130,10 @@ ifeq ($(CONFIG_EXAMPLES_MTDPART),y)
|
||||
CONFIGURED_APPS += examples/mtdpart
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_EXAMPLES_MTDRWB),y)
|
||||
CONFIGURED_APPS += examples/mtdrwb
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_EXAMPLES_NETPKT),y)
|
||||
CONFIGURED_APPS += examples/netpkt
|
||||
endif
|
||||
|
@ -240,6 +240,12 @@ int mtdrwb_main(int argc, char *argv[])
|
||||
message(" erasesize: %lu\n", (unsigned long)geo.erasesize);
|
||||
message(" neraseblocks: %lu\n", (unsigned long)geo.neraseblocks);
|
||||
|
||||
blkpererase = geo.erasesize / geo.blocksize;
|
||||
message(" blkpererase: %u\n", blkpererase);
|
||||
|
||||
nblocks = geo.neraseblocks * blkpererase;
|
||||
message(" nblocks: %lu\n", (unsigned long)nblocks);
|
||||
|
||||
/* Allocate a buffer */
|
||||
|
||||
buffer = (FAR uint32_t *)malloc(geo.blocksize);
|
||||
|
Loading…
x
Reference in New Issue
Block a user