Searched refs:bpr_size (Results 1 – 2 of 2) sorted by relevance
| /rk3399_rockchip-uboot/drivers/mtd/spi/ |
| H A D | spi_flash.c | 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() [all …]
|
| H A D | spi-nor-core.c | 998 static bool sst26_process_bpr(u32 bpr_size, u8 *cmd, u32 bit, enum lock_ctl ctl) in sst26_process_bpr() argument 1002 cmd[bpr_size - (bit / 8) - 1] |= BIT(bit % 8); in sst26_process_bpr() 1005 cmd[bpr_size - (bit / 8) - 1] &= ~BIT(bit % 8); in sst26_process_bpr() 1008 return !!(cmd[bpr_size - (bit / 8) - 1] & BIT(bit % 8)); in sst26_process_bpr() 1021 u32 i, bpr_ptr, rptr_64k, lptr_64k, bpr_size; in sst26_lock_ctl() local 1044 bpr_size = 2 + (mtd->size / SZ_64K / 8); in sst26_lock_ctl() 1046 ret = nor->read_reg(nor, SPINOR_OP_READ_BPR, bpr_buff, bpr_size); in sst26_lock_ctl() 1063 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl() 1075 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl() 1082 if (sst26_process_bpr(bpr_size, bpr_buff, bpr_ptr, ctl)) in sst26_lock_ctl() [all …]
|