Lines Matching refs:PhyBlock

228 …conv_to_logical(pdx, PhyBlock) (((PhyBlock) >= (pdx)->MS_Lib.NumberOfPhyBlock) ? MS_STATUS_ERROR :…  argument
850 static int ms_count_freeblock(struct us_data *us, u16 PhyBlock) in ms_count_freeblock() argument
855 Ende = PhyBlock + MS_PHYSICAL_BLOCKS_PER_SEGMENT; in ms_count_freeblock()
856 for (Count = 0; PhyBlock < Ende; PhyBlock++) { in ms_count_freeblock()
857 switch (info->MS_Lib.Phy2LogMap[PhyBlock]) { in ms_count_freeblock()
932 static int ms_lib_process_bootblock(struct us_data *us, u16 PhyBlock, u8 *PageData) in ms_lib_process_bootblock() argument
983 ms_lib_set_bootblockmark(us, PhyBlock); in ms_lib_process_bootblock()
1013 switch (ms_read_readpage(us, PhyBlock, PageNumber, (u32 *)PageBuffer, &ExtraData)) { in ms_lib_process_bootblock()
1039 …switch (ms_read_readpage(us, PhyBlock, (u8)(EntryOffset / MS_BYTES_PER_PAGE + 1), (u32 *)PageBuffe… in ms_lib_process_bootblock()
1213 static int ms_lib_check_disableblock(struct us_data *us, u16 PhyBlock) in ms_lib_check_disableblock() argument
1227 ms_read_readpage(us, PhyBlock, 1, (u32 *)PageBuf, &extdat); in ms_lib_check_disableblock()
1347 static int ms_lib_read_extra(struct us_data *us, u32 PhyBlock, in ms_lib_read_extra() argument
1362 bcb->CDB[4] = (unsigned char)(PhyBlock); in ms_lib_read_extra()
1363 bcb->CDB[3] = (unsigned char)(PhyBlock>>8); in ms_lib_read_extra()
1364 bcb->CDB[2] = (unsigned char)(PhyBlock>>16); in ms_lib_read_extra()
1519 static void ms_lib_phy_to_log_range(u16 PhyBlock, u16 *LogStart, u16 *LogEnde) in ms_lib_phy_to_log_range() argument
1521 PhyBlock /= MS_PHYSICAL_BLOCKS_PER_SEGMENT; in ms_lib_phy_to_log_range()
1523 if (PhyBlock) { in ms_lib_phy_to_log_range()
1524 …*LogStart = MS_LOGICAL_BLOCKS_IN_1ST_SEGMENT + (PhyBlock - 1) * MS_LOGICAL_BLOCKS_PER_SEGMENT;/*49… in ms_lib_phy_to_log_range()
1532 static int ms_lib_read_extrablock(struct us_data *us, u32 PhyBlock, in ms_lib_read_extrablock() argument
1546 bcb->CDB[4] = (unsigned char)(PhyBlock); in ms_lib_read_extrablock()
1547 bcb->CDB[3] = (unsigned char)(PhyBlock>>8); in ms_lib_read_extrablock()
1548 bcb->CDB[2] = (unsigned char)(PhyBlock>>16); in ms_lib_read_extrablock()
1560 u16 PhyBlock, newblk, i; in ms_lib_scan_logicalblocknumber() local
1567 for (PhyBlock = 0; PhyBlock < info->MS_Lib.NumberOfPhyBlock;) { in ms_lib_scan_logicalblocknumber()
1568 ms_lib_phy_to_log_range(PhyBlock, &LogStart, &LogEnde); in ms_lib_scan_logicalblocknumber()
1570 for (i = 0; i < MS_PHYSICAL_BLOCKS_PER_SEGMENT; i++, PhyBlock++) { in ms_lib_scan_logicalblocknumber()
1571 switch (ms_libconv_to_logical(info, PhyBlock)) { in ms_lib_scan_logicalblocknumber()
1578 if (count == PhyBlock) { in ms_lib_scan_logicalblocknumber()
1579 ms_lib_read_extrablock(us, PhyBlock, 0, 0x80, in ms_lib_scan_logicalblocknumber()
1583 index = (PhyBlock % 0x80) * 4; in ms_lib_scan_logicalblocknumber()
1591 ms_lib_setacquired_errorblock(us, PhyBlock); in ms_lib_scan_logicalblocknumber()
1596 ms_lib_erase_phyblock(us, PhyBlock); in ms_lib_scan_logicalblocknumber()
1602 ms_lib_erase_phyblock(us, PhyBlock); in ms_lib_scan_logicalblocknumber()
1610 ms_lib_set_logicalpair(us, extdat.logadr, PhyBlock); in ms_lib_scan_logicalblocknumber()
1619 ms_lib_erase_phyblock(us, PhyBlock); in ms_lib_scan_logicalblocknumber()
1626 ms_lib_set_logicalpair(us, extdat.logadr, PhyBlock); in ms_lib_scan_logicalblocknumber()