Lines Matching refs:bpr_size
553 static bool sst26_process_bpr(u32 bpr_size, u8 *cmd, u32 bit, enum lock_ctl ctl) in sst26_process_bpr() argument
557 cmd[bpr_size - (bit / 8) - 1] |= BIT(bit % 8); in sst26_process_bpr()
560 cmd[bpr_size - (bit / 8) - 1] &= ~BIT(bit % 8); in sst26_process_bpr()
563 return !!(cmd[bpr_size - (bit / 8) - 1] & BIT(bit % 8)); in sst26_process_bpr()
587 u32 i, bpr_ptr, rptr_64k, lptr_64k, bpr_size; in sst26_lock_ctl() local
605 bpr_size = 2 + (flash->size / SZ_64K / 8); in sst26_lock_ctl()
608 ret = spi_flash_read_common(flash, &cmd, 1, bpr_buff, bpr_size); in sst26_lock_ctl()
625 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl()
637 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl()
644 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl()
652 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl()
662 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl()
674 ret = spi_flash_write_common(flash, &cmd, 1, bpr_buff, bpr_size); in sst26_lock_ctl()