Lines Matching refs:mtd_id_len
157 static struct mtdids* id_find_by_mtd_id(const char *mtd_id, unsigned int mtd_id_len);
846 unsigned int mtd_id_len; in device_parse() local
869 mtd_id_len = p - mtd_id + 1; in device_parse()
873 if ((id = id_find_by_mtd_id(mtd_id, mtd_id_len - 1)) == NULL) { in device_parse()
874 printf("invalid mtd device '%.*s'\n", mtd_id_len - 1, mtd_id); in device_parse()
1009 static struct mtdids* id_find_by_mtd_id(const char *mtd_id, unsigned int mtd_id_len) in id_find_by_mtd_id() argument
1015 mtd_id_len, mtd_id, mtd_id_len); in id_find_by_mtd_id()
1023 if (mtd_id_len != strlen(id->mtd_id)) in id_find_by_mtd_id()
1025 if (strncmp(id->mtd_id, mtd_id, mtd_id_len) == 0) in id_find_by_mtd_id()
1614 int mtd_id_len; local
1654 mtd_id_len = p - mtd_id + 1;
1657 mtd_id_len = strlen(mtd_id) + 1;
1659 if (mtd_id_len == 0) {
1680 if (!(id = (struct mtdids *)malloc(sizeof(struct mtdids) + mtd_id_len))) {
1684 memset(id, 0, sizeof(struct mtdids) + mtd_id_len);
1689 strncpy(id->mtd_id, mtd_id, mtd_id_len - 1);
1690 id->mtd_id[mtd_id_len - 1] = '\0';