/* Find an MSN entry in the list. If ia5 != 0, return IA5-encoded EAZ, else return a bitmask with corresponding bit set.  */
static __u16 act2000_find_msn(act2000_card *card, char *msn, int ia5)
/* Find an MSN entry in the list. If ia5 != 0, return IA5-encoded EAZ, else return a bitmask with corresponding bit set.  */
static __u16 act2000_find_msn(act2000_card *card, char *msn, int ia5)
{
        struct msn_entry *p = card->msn_list;
	__u8 eaz = '0';
	while (p) {
		if (!strcmp(p->msn, msn)) {
			eaz = p->eaz;
			break;
		}
		p = p->next;
	}
	if (!ia5)
		return (1 << (eaz - '0'));
	else
		return eaz;
}