Lines Matching refs:cid
95 struct mmc_cid cid; /* cid decoded */ member
177 static void mmc_decode_cid_mmc(uint32_t *raw_cid, struct mmc_cid *cid,
179 static void mmc_decode_cid_sd(uint32_t *raw_cid, struct mmc_cid *cid);
1092 mmc_decode_cid_sd(uint32_t *raw_cid, struct mmc_cid *cid) in mmc_decode_cid_sd() argument
1097 memset(cid, 0, sizeof(*cid)); in mmc_decode_cid_sd()
1098 cid->mid = mmc_get_bits(raw_cid, 128, 120, 8); in mmc_decode_cid_sd()
1099 cid->oid = mmc_get_bits(raw_cid, 128, 104, 16); in mmc_decode_cid_sd()
1101 cid->pnm[i] = mmc_get_bits(raw_cid, 128, 96 - i * 8, 8); in mmc_decode_cid_sd()
1102 cid->pnm[5] = 0; in mmc_decode_cid_sd()
1103 cid->prv = mmc_get_bits(raw_cid, 128, 56, 8); in mmc_decode_cid_sd()
1104 cid->psn = mmc_get_bits(raw_cid, 128, 24, 32); in mmc_decode_cid_sd()
1105 cid->mdt_year = mmc_get_bits(raw_cid, 128, 12, 8) + 2000; in mmc_decode_cid_sd()
1106 cid->mdt_month = mmc_get_bits(raw_cid, 128, 8, 4); in mmc_decode_cid_sd()
1110 mmc_decode_cid_mmc(uint32_t *raw_cid, struct mmc_cid *cid, bool is_4_41p) in mmc_decode_cid_mmc() argument
1115 memset(cid, 0, sizeof(*cid)); in mmc_decode_cid_mmc()
1116 cid->mid = mmc_get_bits(raw_cid, 128, 120, 8); in mmc_decode_cid_mmc()
1117 cid->oid = mmc_get_bits(raw_cid, 128, 104, 8); in mmc_decode_cid_mmc()
1119 cid->pnm[i] = mmc_get_bits(raw_cid, 128, 96 - i * 8, 8); in mmc_decode_cid_mmc()
1120 cid->pnm[6] = 0; in mmc_decode_cid_mmc()
1121 cid->prv = mmc_get_bits(raw_cid, 128, 48, 8); in mmc_decode_cid_mmc()
1122 cid->psn = mmc_get_bits(raw_cid, 128, 16, 32); in mmc_decode_cid_mmc()
1123 cid->mdt_month = mmc_get_bits(raw_cid, 128, 12, 4); in mmc_decode_cid_mmc()
1124 cid->mdt_year = mmc_get_bits(raw_cid, 128, 8, 4); in mmc_decode_cid_mmc()
1126 cid->mdt_year += 2013; in mmc_decode_cid_mmc()
1128 cid->mdt_year += 1997; in mmc_decode_cid_mmc()
1154 c1 = (ivar->cid.oid >> 8) & 0x0ff; in mmc_format_card_id_string()
1155 c2 = ivar->cid.oid & 0x0ff; in mmc_format_card_id_string()
1159 snprintf(oidstr, sizeof(oidstr), "0x%04x", ivar->cid.oid); in mmc_format_card_id_string()
1161 "%08X", ivar->cid.psn); in mmc_format_card_id_string()
1165 ivar->cid.pnm, ivar->cid.prv >> 4, ivar->cid.prv & 0x0f, in mmc_format_card_id_string()
1166 ivar->cid.psn, ivar->cid.mdt_month, ivar->cid.mdt_year, in mmc_format_card_id_string()
1167 ivar->cid.mid, oidstr); in mmc_format_card_id_string()
1644 mmc_decode_cid_sd(ivar->raw_cid, &ivar->cid); in mmc_discover_cards()
1893 mmc_decode_cid_mmc(ivar->raw_cid, &ivar->cid, rev >= 5); in mmc_discover_cards()
1898 quirk->mid == ivar->cid.mid) && in mmc_discover_cards()
1900 quirk->oid == ivar->cid.oid) && in mmc_discover_cards()
1901 strncmp(quirk->pnm, ivar->cid.pnm, in mmc_discover_cards()
1902 sizeof(ivar->cid.pnm)) == 0) { in mmc_discover_cards()