Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 374723
b: refs/heads/master
c: 8e12b47
h: refs/heads/master
i:
  374721: a28f8a9
  374719: cba5ab6
v: v3
  • Loading branch information
Artem Bityutskiy authored and David Woodhouse committed Apr 5, 2013
1 parent cf2ca02 commit 4d9842a
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8dbfae1ef04311ba19d6b6c9a4d8fdddbb90ab0f
refs/heads/master: 8e12b474f9a2349bcaebda65bdc38e8398ff408e
23 changes: 17 additions & 6 deletions trunk/include/linux/mtd/nand.h
Original file line number Diff line number Diff line change
Expand Up @@ -551,9 +551,9 @@ struct nand_chip {
* defined the chip, including the geometry (chip size, eraseblock size, page
* size).
*/
#define LEGACY_ID_NAND(nm, devid, pagesz, chipsz, erasesz, opts) \
{ .name = (nm), .dev_id = (devid), .pagesize = (pagesz), \
.chipsize = (chipsz), .erasesize = (erasesz), \
#define LEGACY_ID_NAND(nm, devid, pagesz, chipsz, erasesz, opts) \
{ .name = (nm), {{ .dev_id = (devid) }}, .pagesize = (pagesz), \
.chipsize = (chipsz), .erasesize = (erasesz), \
.options = (opts) }

/*
Expand All @@ -566,14 +566,19 @@ struct nand_chip {
* buswidth), and the page size, eraseblock size, and OOB size could vary while
* using the same device ID.
*/
#define EXTENDED_ID_NAND(nm, devid, chipsz, opts) \
{ .name = (nm), .dev_id = (devid), .chipsize = (chipsz), \
#define EXTENDED_ID_NAND(nm, devid, chipsz, opts) \
{ .name = (nm), {{ .dev_id = (devid) }}, .chipsize = (chipsz), \
.options = (opts) }

/**
* struct nand_flash_dev - NAND Flash Device ID Structure
* @name: a human-readable name of the NAND chip
* @dev_id: the device ID (the second byte of the full chip ID array)
* @mfr_id: manufecturer ID part of the full chip ID array (refers the same
* memory address as @id[0])
* @dev_id: device ID part of the full chip ID array (refers the same memory
* address as @id[1])
* @id: full device ID array
* @pagesize: size of the NAND page in bytes; if 0, then the real page size (as
* well as the eraseblock size) is determined from the extended NAND
* chip ID array)
Expand All @@ -583,7 +588,13 @@ struct nand_chip {
*/
struct nand_flash_dev {
char *name;
int dev_id;
union {
struct {
uint8_t mfr_id;
uint8_t dev_id;
};
uint8_t id[8];
};
unsigned long pagesize;
unsigned long chipsize;
unsigned long erasesize;
Expand Down

0 comments on commit 4d9842a

Please sign in to comment.