/freebsd-current/stand/i386/pmbr/ |
H A D | pmbr.S | 39 .set SECSIZE,0x200 # Size of a single disk sector 111 # Try alternative LBAs from the last sector for the GPT header. 114 movw $DPBUF+DPBUF_SEC,%si # %si = last sector + 1 121 jmp main.2a # Read the next sector 123 # Load a partition table sector from disk and look for a FreeBSD boot 156 addw $SECSIZE/16,%ax # sector 164 # Move to the next partition. If we walk off the end of the sector, load 165 # the next sector. We assume that partition entries are smaller than 64k 166 # and that they won't span a sector boundary. 174 cmpw $PART_ADDR+0x200,%bx # Still in sector [all...] |
/freebsd-current/lib/geom/mirror/ |
H A D | geom_mirror.c | 181 u_char sector[512]; local 188 bzero(sector, sizeof(sector)); 252 * Clear last sector first, to spoil all components if device exists. 280 mirror_metadata_encode(&md, sector); 281 error = g_metadata_store(str, sector, sizeof(sector));
|
/freebsd-current/lib/geom/part/ |
H A D | geom_part.c | 268 off_t sector, bestsector; local 274 sector = (off_t)strtoimax(s, NULL, 0); 275 if (sector < minsector) 277 if (bestpp != NULL && sector >= bestsector) 281 bestsector = sector; 626 off_t first, last, sector, end; local 670 sector = (off_t)strtoimax(s, NULL, 0); 674 length = end - sector + 1; 678 if (first < sector) { 681 (intmax_t)(sector 780 off_t sector, end; local [all...] |
/freebsd-current/sys/dev/flash/ |
H A D | mx25l.c | 65 * sector size. Trying to run FFS off of a 64k flash sector size 242 mx25l_erase_cmd(struct mx25l_softc *sc, off_t sector) argument 268 txBuf[1] = ((sector >> 24) & 0xff); 269 txBuf[2] = ((sector >> 16) & 0xff); 270 txBuf[3] = ((sector >> 8) & 0xff); 271 txBuf[4] = (sector & 0xff); 275 txBuf[1] = ((sector >> 16) & 0xff); 276 txBuf[2] = ((sector >> 8) & 0xff); 277 txBuf[3] = (sector [all...] |
/freebsd-current/usr.bin/mkimg/ |
H A D | vhd.c | 281 uint32_t sector; local 310 sector = (sizeof(footer) + sizeof(header) + batsz) / VHD_SECTOR_SIZE; 314 be32enc(&bat[entry], sector); 315 sector += (VHD_BLOCK_SIZE / VHD_SECTOR_SIZE) + 1;
|
/freebsd-current/sbin/fdisk/ |
H A D | fdisk.c | 70 #define MAX_SEC_SIZE 65536 /* maximum sector size that is supported */ 71 #define MIN_SEC_SIZE 512 /* the sector size to start sensing at */ 72 static int secsize = 0; /* the sensed sector size */ 249 static ssize_t read_disk(off_t sector, void *buf); 250 static int write_disk(off_t sector, void *buf); 332 /* (abu)use mboot.bootinst to probe for the sector size */ 334 err(1, "cannot allocate buffer to determine disk sector size"); 336 errx(1, "could not detect sector size"); 416 printf("Media sector size is %d\n", secsize); 417 printf("Warning: BIOS sector numberin 743 read_disk(off_t sector, void *buf) argument 787 write_disk(off_t sector, void *buf) argument 877 int sector, i; local [all...] |
/freebsd-current/sys/contrib/openzfs/module/os/linux/zfs/ |
H A D | vdev_disk.c | 453 /* Based on the minimum sector size set the block size */ 1283 vdev_bdev_issue_secure_erase(zfs_bdev_handle_t *bdh, sector_t sector, argument 1291 sector, nsect, GFP_NOFS); 1294 sector, nsect, GFP_NOFS, BLKDEV_DISCARD_SECURE, biop); 1297 sector, nsect, GFP_NOFS, BLKDEV_DISCARD_SECURE); 1306 vdev_bdev_issue_discard(zfs_bdev_handle_t *bdh, sector_t sector, argument 1314 sector, nsect, GFP_NOFS, 0, biop); 1317 sector, nsect, GFP_NOFS, biop); 1320 sector, nsect, GFP_NOFS, 0); 1323 sector, nsec 1343 sector_t sector = zio->io_offset >> 9; local [all...] |
/freebsd-current/sys/dev/sfxge/common/ |
H A D | efx_bootcfg.c | 41 * NOTE: This is larger than the Medford per-PF bootcfg sector. 45 /* Medford per-PF bootcfg sector */ 220 /* Checksum the entire sector, including bytes after any EFX_DHCP_END */ 750 * Copy bootcfg sector data to a target buffer which may differ in size. 757 uint8_t *sector, 775 rc = efx_dhcp_verify(sector, sector_length, 783 (sector[used_bytes - 1] != EFX_DHCP_END)) { 792 sector[0] = 0; 793 sector[1] = EFX_DHCP_END; 803 * Reinitialise the sector i 754 efx_bootcfg_copy_sector( __in efx_nic_t *enp, __inout_bcount(sector_length) uint8_t *sector, __in size_t sector_length, __out_bcount(data_size) uint8_t *data, __in size_t data_size, __in boolean_t handle_format_errors) argument [all...] |
/freebsd-current/tools/test/stress2/misc/ |
H A D | graid1_2.sh | 103 /* Write last sector on disk */
|
/freebsd-current/usr.bin/etdump/ |
H A D | etdump.c | 78 read_sector(FILE *iso, daddr_t sector, char *buffer) argument 81 if (fseek(iso, sector * ISO_DEFAULT_BLOCK_SIZE, SEEK_SET) != 0) {
|
/freebsd-current/sys/geom/raid3/ |
H A D | g_raid3_ctl.c | 402 u_char *sector; local 482 "Cannot insert provider %s, because of its sector size.", 507 sector = g_malloc(pp->sectorsize, M_WAITOK); 508 raid3_metadata_encode(&md, sector); 509 error = g_write_data(cp, pp->mediasize - pp->sectorsize, sector, 511 g_free(sector);
|
/freebsd-current/sys/fs/udf/ |
H A D | udf_vnops.c | 76 daddr_t *sector, uint32_t *max_size); 698 * logical sector in size. 1025 daddr_t sector; local 1034 error = udf_bmap_internal(node, offset, §or, &maxsize); 1041 /* bmap gives sector numbers, bio works with device blocks */ 1042 bp->b_blkno = sector << (node->udfmp->bshift - DEV_BSHIFT); 1084 /* Translate logical to physical sector number */ 1306 daddr_t sector; local 1315 error = udf_bmap_internal(node, offset, §or, &max_size); 1364 * offset, rather than beginning of calculated sector numbe 1367 udf_bmap_internal(struct udf_node *node, off_t offset, daddr_t *sector, uint32_t *max_size) argument [all...] |
/freebsd-current/usr.sbin/bsdinstall/partedit/ |
H A D | gpart_ops.c | 914 * actual stripe size, or the sector size if no stripe size was 1039 intmax_t maxsize, size, sector, firstfree, stripe; local 1065 /* Record sector and stripe sizes */ 1066 sector = pp->lg_sectorsize; 1117 humanize_number(sizestr, 7, size*sector, "B", HN_AUTOSCALE, 1199 size = MIN((intmax_t)(bytes/sector), maxsize); 1288 firstfree += bytes / sector; 1289 size -= (bytes + stripe)/sector; 1290 if (stripe > 0 && (firstfree*sector % stripe) != 0) 1291 firstfree += (stripe - ((firstfree*sector) [all...] |
/freebsd-current/stand/i386/zfsboot/ |
H A D | zfsldr.S | 67 call read # sector 93 * starting at sector 1024 (i.e. after the two vdev labels). We don't 118 add $SIZ_SEC,%ebx # next sector 176 * Read a sector from the disk. Sets up an EDD packet on the stack 193 push $0x1 # Read 1 sector
|
/freebsd-current/usr.sbin/makefs/cd9660/ |
H A D | cd9660_eltorito.h | 145 int sector; /* copied to LoadRBA */ member in struct:cd9660_boot_image
|
/freebsd-current/sys/dev/virtio/block/ |
H A D | virtio_blk.c | 968 req->vbr_hdr.sector = 0; 972 req->vbr_hdr.sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); 976 req->vbr_hdr.sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); 980 req->vbr_hdr.sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); 1113 discard->sector = vtblk_gtoh64(sc, bp->bio_offset / VTBLK_BSIZE); 1402 req->vbr_hdr.sector = 0; 1535 req->vbr_hdr.sector = vtblk_gtoh64(sc, offset / VTBLK_BSIZE); 1558 req->vbr_hdr.sector = 0;
|
/freebsd-current/sys/geom/eli/ |
H A D | g_eli.c | 402 u_char *sector; local 405 sector = NULL; 417 sector = malloc(pp->sectorsize, M_ELI, M_WAITOK | M_ZERO); 418 eli_metadata_encode(&md, sector); 419 error = g_write_data(cp, pp->mediasize - pp->sectorsize, sector, 426 explicit_bzero(sector, pp->sectorsize); 428 sector, pp->sectorsize); 436 zfree(sector, M_ELI);
|
/freebsd-current/usr.sbin/makefs/ |
H A D | cd9660.c | 189 /*Fix the sector size for now, though the spec allows for other sizes*/ 589 printf("%s: Primary path tables starts in sector %" 592 printf("%s: File data starts in sector %" 733 int sector = 16; local 743 temp->sector = sector; 748 sector++; 749 /* Set up boot support if enabled. BVD must reside in sector 17 */ 755 t->sector = 17; 759 sector [all...] |
H A D | cd9660.h | 203 int64_t sector; member in struct:_volume_descriptor 216 /* Important sector numbers here */
|
/freebsd-current/sys/geom/mirror/ |
H A D | g_mirror_ctl.c | 617 u_char *sector; local 747 sector = g_malloc(pp->sectorsize, M_WAITOK | M_ZERO); 748 mirror_metadata_encode(&md, sector); 750 pp->mediasize - pp->sectorsize, sector, pp->sectorsize); 751 g_free(sector);
|
/freebsd-current/stand/i386/boot2/ |
H A D | boot1.S | 63 bpb: .word 512 # sector size (T) 317 inc %ax # sector 327 movb $1,%al # one sector
|
/freebsd-current/stand/i386/boot0/ |
H A D | boot0.S | 38 * Note - this code uses many tricks to save space and fit in one sector. 67 * 1 3 start sector CHS 68 * 8:head, 6:sector, 2:cyl bit 9..8, 8:cyl bit 7..0 70 * 5 3 end sector CHS 71 * 8 4 LBA of first sector 211 * If the 'setdrv' flag is set in the boot sector, use the drive 212 * number from the boot sector at 'setdrv_num'. 248 * so that after 4 iterations it's beyond the end of the sector 461 movb $0x3,%ah # Write sector 478 movb $0x2,%ah # Read sector [all...] |
/freebsd-current/sys/powerpc/ps3/ |
H A D | ps3-hvcall.h | 132 int lv1_storage_read(uint64_t dev, uint64_t region, uint64_t sector, uint64_t nsectors, uint64_t flags, uint64_t buf, uint64_t *dma_tag); 133 int lv1_storage_write(uint64_t dev, uint64_t region, uint64_t sector, uint64_t nsectors, uint64_t flags, uint64_t buf, uint64_t *dma_tag);
|
/freebsd-current/usr.sbin/bhyve/ |
H A D | pci_virtio_block.c | 173 uint64_t sector; member in struct:virtio_blk_discard_write_zeroes 402 io->io_req.br_offset = discard->sector * VTBLK_BSIZE;
|
/freebsd-current/sys/geom/concat/ |
H A D | g_concat.c | 1015 u_char *sector; local 1033 sector = g_malloc(pp->sectorsize, M_WAITOK | M_ZERO); 1034 concat_metadata_encode(&md, sector); 1038 pp->mediasize - pp->sectorsize, sector, 1042 g_free(sector); 1173 /* last sector is for metadata */
|