Lines Matching refs:buf
35 uint32_t *buf = (uint32_t *)params[1].memref.buffer; in bsec_read_mem() local
45 if (pt != exp_pt || !buf || !size || in bsec_read_mem()
58 otp_id++, buf++) { in bsec_read_mem()
64 *buf = 0x0; in bsec_read_mem()
68 res = stm32_bsec_read_otp(buf, otp_id); in bsec_read_mem()
70 *buf); in bsec_read_mem()
77 res = stm32_bsec_shadow_read_otp(buf, otp_id); in bsec_read_mem()
78 FMSG("Read fuse %"PRIu32" val: %#"PRIx32, otp_id, *buf); in bsec_read_mem()
83 *buf = PTA_BSEC_LOCK_ERROR; in bsec_read_mem()
86 *buf = 0; in bsec_read_mem()
93 *buf |= PTA_BSEC_LOCK_PERM; in bsec_read_mem()
100 *buf |= PTA_BSEC_LOCK_SHADOW_R; in bsec_read_mem()
107 *buf |= PTA_BSEC_LOCK_SHADOW_W; in bsec_read_mem()
114 *buf |= PTA_BSEC_LOCK_SHADOW_P; in bsec_read_mem()
116 FMSG("Read lock %"PRIu32" val: %#"PRIx32, otp_id, *buf); in bsec_read_mem()
128 FMSG("Buffer orig %p, size %zu", buf, size); in bsec_read_mem()
142 uint32_t *buf = (uint32_t *)params[1].memref.buffer; in bsec_write_mem() local
151 if (pt != exp_pt || !buf || !size || in bsec_write_mem()
171 otp_id++, buf++) { in bsec_write_mem()
176 otp_id, *buf); in bsec_write_mem()
177 res = stm32_bsec_write_otp(*buf, otp_id); in bsec_write_mem()
183 otp_id, *buf); in bsec_write_mem()
184 res = stm32_bsec_program_otp(*buf, otp_id); in bsec_write_mem()
188 if (*buf & PTA_BSEC_LOCK_PERM) { in bsec_write_mem()
195 if (*buf & PTA_BSEC_LOCK_SHADOW_R) { in bsec_write_mem()
202 if (*buf & PTA_BSEC_LOCK_SHADOW_W) { in bsec_write_mem()
209 if (*buf & PTA_BSEC_LOCK_SHADOW_P) { in bsec_write_mem()