SECTOR_SIZE
io_req->sectorsize = SECTOR_SIZE;
ubd_dev->openflags, SECTOR_SIZE, PAGE_SIZE,
#define ROUND_BLOCK(n) ((n + (SECTOR_SIZE - 1)) & (-SECTOR_SIZE))
lim->logical_block_size = SECTOR_SIZE;
lim->logical_block_size = SECTOR_SIZE;
if (lim->max_user_sectors < BLK_MIN_SEGMENT_SIZE / SECTOR_SIZE)
lim->physical_block_size = SECTOR_SIZE;
lim->io_min = SECTOR_SIZE;
lim->discard_granularity = SECTOR_SIZE;
lim->dma_alignment = SECTOR_SIZE - 1;
lim->dma_alignment = SECTOR_SIZE - 1;
i < SECTOR_SIZE / (int)sizeof(struct lvd); i++) {
return folio_address(folio) + offset_in_folio(folio, n * SECTOR_SIZE);
if (offset % SECTOR_SIZE)
if (!size || size % SECTOR_SIZE)
u64 offset = of_read_number(reg, a_cells) / SECTOR_SIZE;
u64 size = of_read_number(reg + a_cells, s_cells) / SECTOR_SIZE;
if (len_sect < PAGE_SIZE/SECTOR_SIZE)
len = (unsigned int)len_sect*SECTOR_SIZE;
lim.logical_block_size = SECTOR_SIZE;
lim.physical_block_size = SECTOR_SIZE;
lim.io_min = SECTOR_SIZE;
return SECTOR_SIZE;
return SECTOR_SIZE;
valid_len -= pos & (SECTOR_SIZE - 1);
unsigned int nr_sectors = DIV_ROUND_UP(len, SECTOR_SIZE);
size = (sector_t)rbd_dev->mapping.size / SECTOR_SIZE;
if (result.uint_32 < SECTOR_SIZE)
set_capacity(rbd_dev->disk, rbd_dev->mapping.size / SECTOR_SIZE);
(le16_to_cpu(rsp->logical_block_size) / SECTOR_SIZE));
.max_hw_sectors = dev->sess->max_io_size / SECTOR_SIZE,
sess->max_segments, sess->max_io_size / SECTOR_SIZE,
size = dev->size * (limit->logical_block_size / SECTOR_SIZE);
.logical_block_size = SECTOR_SIZE,
zlo->block_size = SECTOR_SIZE;
*start_off = get_start_sect(bdev) * SECTOR_SIZE;
part_size = bdev_nr_sectors(bdev) * SECTOR_SIZE;
((ISER_DEF_MAX_SECTORS * SECTOR_SIZE) >> ilog2(SZ_4K))
#define ISCSI_ISER_MAX_SG_TABLESIZE ((32768 * SECTOR_SIZE) >> ilog2(SZ_4K))
sg_tablesize = DIV_ROUND_UP(max_sectors * SECTOR_SIZE, SZ_4K);
if (ctx->sector_size < SECTOR_SIZE ||
if (ctx->sector_size != SECTOR_SIZE && !iv_large_sectors) {
ctx->sector_size = SECTOR_SIZE;
if (ctx->sector_size != SECTOR_SIZE)
if (ctx->sector_size != SECTOR_SIZE) {
index * (PAGE_SIZE / SECTOR_SIZE);
start + opt_size / SECTOR_SIZE <= boundary)
if (start + io_size / SECTOR_SIZE <= boundary)
sector_t ps = pg_index * PAGE_SIZE / SECTOR_SIZE;
sboff < (doff + mddev->dev_sectors + PAGE_SIZE / SECTOR_SIZE))
lim->discard_granularity = SECTOR_SIZE;
.blksize = SECTOR_SIZE,
le32_to_cpu(part->header.BAMOffset), SECTOR_SIZE);
u_char buf[SECTOR_SIZE];
ret = mtd_read(part->mbd.mtd, src, SECTOR_SIZE, &retlen,
ret = mtd_write(part->mbd.mtd, dest, SECTOR_SIZE, &retlen,
src += SECTOR_SIZE;
dest += SECTOR_SIZE;
if (((sector+i) * SECTOR_SIZE) >= le32_to_cpu(part->header.FormattedSize)) {
memset(buffer, 0, SECTOR_SIZE);
ret = mtd_read(part->mbd.mtd, offset, SECTOR_SIZE, &retlen,
buffer += SECTOR_SIZE;
blk = (log_addr % bsize) / SECTOR_SIZE;
virt_addr = sector * SECTOR_SIZE | BLOCK_DATA;
log_addr = part->bam_index * bsize + blk * SECTOR_SIZE;
blk * SECTOR_SIZE);
ret = mtd_write(part->mbd.mtd, offset, SECTOR_SIZE, &retlen, buffer);
buffer += SECTOR_SIZE;
virt_addr += SECTOR_SIZE;
sect = le32_to_cpu(part->header.FormattedSize)/SECTOR_SIZE;
#define NB_DATA (((SECTOR_SIZE + 1) * 8 + 6) / 10)
if ((index >= 0 && index < SECTOR_SIZE) || index == (SECTOR_SIZE + 1)) {
if (index < SECTOR_SIZE)
if ((index >= 0 && index < SECTOR_SIZE) || index == (SECTOR_SIZE + 1)) {
if (index < SECTOR_SIZE)
(i + part->header_sectors_per_block) * SECTOR_SIZE;
sectors_per_block = part->block_size / SECTOR_SIZE;
sizeof(u16) + SECTOR_SIZE - 1) / SECTOR_SIZE;
rc = mtd_read(part->mbd.mtd, addr, SECTOR_SIZE, &retlen,
if (!rc && retlen != SECTOR_SIZE)
memset(buf, 0, SECTOR_SIZE);
sector_data = kmalloc(SECTOR_SIZE, GFP_KERNEL);
(i + part->header_sectors_per_block) * SECTOR_SIZE;
rc = mtd_read(part->mbd.mtd, addr, SECTOR_SIZE, &retlen,
if (!rc && retlen != SECTOR_SIZE)
offset = (old_addr % part->block_size) / SECTOR_SIZE -
addr = (i + part->header_sectors_per_block) * SECTOR_SIZE +
rc = mtd_write(part->mbd.mtd, addr, SECTOR_SIZE, &retlen,
if (!rc && retlen != SECTOR_SIZE)
for (i=0; i<SECTOR_SIZE; i++) {
if (i == SECTOR_SIZE)
.blksize = SECTOR_SIZE,
sect_buf = kmalloc(SECTOR_SIZE, GFP_KERNEL);
ret = mtd_read(mtd, offset, SECTOR_SIZE, &retlen,
if (ret < 0 || retlen != SECTOR_SIZE) {
ret = mtd_read(mtd, offset, SECTOR_SIZE, &retlen, sect_buf);
if (ret < 0 || retlen != SECTOR_SIZE)
memset(buf, 0xff, SECTOR_SIZE);
.blksize = SECTOR_SIZE,
SECTOR_SIZE * AHA1542_MAX_SECTORS,
dma_free_coherent(shost->dma_dev, SECTOR_SIZE * AHA1542_MAX_SECTORS,
bufsize = roundup((nr_zones + 1) * 64, SECTOR_SIZE);
while (bufsize >= SECTOR_SIZE) {
bufsize = rounddown(bufsize >> 1, SECTOR_SIZE);
SECTOR_SIZE,
.max_sectors = SZ_1M / SECTOR_SIZE,
blk_config->blk_size = cpu_to_vdpasim32(vdpasim, SECTOR_SIZE);
cpu_to_vdpasim32(vdpasim, SECTOR_SIZE);
(offset & (SECTOR_SIZE - 1) || n & (SECTOR_SIZE - 1)) &&
u64 aligned_start = ALIGN(start, SECTOR_SIZE);
len = round_down(len, SECTOR_SIZE);
(DIV_ROUND_UP(ES_MAX_ENTRY_NUM << DENTRY_SIZE_BITS, SECTOR_SIZE) + 1)
bpb->fat_sector_size = SECTOR_SIZE;
sdp->sd_sb.sb_bsize = sb_min_blocksize(sb, SECTOR_SIZE);
if (sb->sb_bsize < SECTOR_SIZE || sb->sb_bsize > PAGE_SIZE ||
return bioset_init(&iomap_ioend_bioset, 4 * (PAGE_SIZE / SECTOR_SIZE),
gap = SECTOR_SIZE - (i_size & (SECTOR_SIZE - 1));
add = DIV_ROUND_UP(copied - gap, SECTOR_SIZE);
DIV_ROUND_UP(end, SECTOR_SIZE),
if (!is_aligned_req(pgio, req, SECTOR_SIZE, false)) {
if (!is_aligned_req(pgio, req, SECTOR_SIZE, false))
if (start & (SECTOR_SIZE - 1))
round_up(rl_byte_len, SECTOR_SIZE));
ni->attr_list = kvzalloc(round_up(ni->attr_list_size, SECTOR_SIZE),
if ((offset | length) & (SECTOR_SIZE - 1))
fo = (SECTOR_SIZE - ((bytes >> SECTOR_SHIFT) + 1) * sizeof(short));
if ((le16_to_cpu(r->fix_num) - 1) * SECTOR_SIZE != bytes)
fo > (SECTOR_SIZE - ((rs >> SECTOR_SHIFT) + 1) * sizeof(short)) ||
(fn - 1) * SECTOR_SIZE != rs || ao < MFTRECORD_FIXUP_OFFSET_1 ||
if (sys_page < SECTOR_SIZE || page_size < SECTOR_SIZE ||
SECTOR_SIZE - sizeof(short))
if (!IS_ALIGNED(off, 8) || ro + off > SECTOR_SIZE - sizeof(short))
if (usa_error && ra_len + ro > SECTOR_SIZE - sizeof(short))
if ((fo & 1) || fo + fn * sizeof(short) > SECTOR_SIZE || !fn-- ||
fn * SECTOR_SIZE > bytes) {
if ((fo & 1) || fo + fn * sizeof(short) > SECTOR_SIZE || !fn-- ||
fn * SECTOR_SIZE > bytes) {
ptr = Add2Ptr(bh_data, SECTOR_SIZE - sizeof(short));
ptr += SECTOR_SIZE / sizeof(short);
ptr = Add2Ptr(rhdr, SECTOR_SIZE - sizeof(short));
ptr += SECTOR_SIZE / sizeof(short);
if ((fo & 1) || fo + fn * sizeof(short) > SECTOR_SIZE || !fn-- ||
fn * SECTOR_SIZE > bytes) {
ptr = Add2Ptr(rhdr, SECTOR_SIZE - sizeof(short));
ptr += SECTOR_SIZE / sizeof(short);
if (t32 != root->index_block_clst * SECTOR_SIZE)
if (boot_sector_size < SECTOR_SIZE ||
if (record_size < SECTOR_SIZE || !is_power_of_2(record_size)) {
if (sbi->index_size < SECTOR_SIZE || !is_power_of_2(sbi->index_size)) {
check_size(kmsg_size, SECTOR_SIZE);
check_size(pmsg_size, SECTOR_SIZE);
check_size(console_size, SECTOR_SIZE);
check_size(ftrace_size, SECTOR_SIZE);
#ifndef SECTOR_SIZE
#ifndef SECTOR_SIZE
#define MSDOS_DPS (SECTOR_SIZE / sizeof(struct msdos_dir_entry))