Lines Matching refs:idx

98 static void saveFingerprint(worker_thread_t* listener, int idx) {  in saveFingerprint()  argument
99 ALOGD("----------------> %s -----------------> idx %d", __FUNCTION__, idx); in saveFingerprint()
111 ALOGD("Write fingerprint[%d] (0x%" PRIx64 ",0x%" PRIx64 ")", idx, in saveFingerprint()
112 listener->secureid[idx], listener->fingerid[idx]); in saveFingerprint()
114 if (fseek(fp, (idx) * sizeof(uint64_t), SEEK_SET) < 0) { in saveFingerprint()
116 idx); in saveFingerprint()
120 int ns = fwrite(&listener->secureid[idx], sizeof(uint64_t), 1, fp); in saveFingerprint()
122 if (fseek(fp, (MAX_NUM_FINGERS + idx) * sizeof(uint64_t), SEEK_SET) < 0) { in saveFingerprint()
124 idx); in saveFingerprint()
128 int nf = fwrite(&listener->fingerid[idx], sizeof(uint64_t), 1, fp); in saveFingerprint()
454 int idx = 0; in fingerprint_remove() local
474 for (idx = 0; idx < MAX_NUM_FINGERS; idx++) { in fingerprint_remove()
475 uint32_t theFid = qdev->listener.fingerid[idx]; in fingerprint_remove()
478 qdev->listener.secureid[idx] = 0; in fingerprint_remove()
479 qdev->listener.fingerid[idx] = 0; in fingerprint_remove()
480 saveFingerprint(&qdev->listener, idx); in fingerprint_remove()
507 for (idx = 0; idx < MAX_NUM_FINGERS; idx++) { in fingerprint_remove()
508 if (qdev->listener.fingerid[idx] == fid && in fingerprint_remove()
509 qdev->listener.secureid[idx] != 0) { in fingerprint_remove()
514 if (idx >= MAX_NUM_FINGERS) { in fingerprint_remove()
529 qdev->listener.secureid[idx] = 0; in fingerprint_remove()
530 qdev->listener.fingerid[idx] = 0; in fingerprint_remove()
531 saveFingerprint(&qdev->listener, idx); in fingerprint_remove()
564 int idx = 0; in is_valid_fid() local
566 for (idx = 0; idx < MAX_NUM_FINGERS; idx++) { in is_valid_fid()
567 if (qdev->listener.fingerid[idx] == fid) { in is_valid_fid()
620 int idx = 0; in send_enroll_notice() local
621 for (idx = 0; idx < MAX_NUM_FINGERS; idx++) { in send_enroll_notice()
622 if (qdev->listener.secureid[idx] == 0 || in send_enroll_notice()
623 qdev->listener.fingerid[idx] == 0) { in send_enroll_notice()
628 if (idx >= MAX_NUM_FINGERS) { in send_enroll_notice()
637 qdev->listener.secureid[idx] = qdev->secure_user_id; in send_enroll_notice()
638 qdev->listener.fingerid[idx] = fid; in send_enroll_notice()
639 saveFingerprint(&qdev->listener, idx); in send_enroll_notice()