Home
last modified time | relevance | path

Searched refs:SECTOR_SIZE (Results 1 – 25 of 25) sorted by relevance

/illumos-gate/usr/src/cmd/boot/installgrub/
H A Dinstallgrub.h36 #define SECTOR_SIZE (512) macro
47 char boot_sector[SECTOR_SIZE];
64 char stage1_buf[SECTOR_SIZE];
88 #define STAGE2_BLOCKLIST (SECTOR_SIZE - 0x8)
89 #define STAGE2_INSTALLPART (SECTOR_SIZE + 0x8)
90 #define STAGE2_FORCE_LBA (SECTOR_SIZE + 0x11)
H A Dinstallgrub.c602 buf_size = src_stage2->file_size + SECTOR_SIZE; in propagate_bootblock()
666 != SECTOR_SIZE) { in init_device()
998 SECTOR_SIZE, stage2->pcfs_first_sectors[1] * SECTOR_SIZE) in write_stage2()
1092 read(fd, dest->stage1_buf, SECTOR_SIZE) != SECTOR_SIZE) { in read_stage1_from_file()
1126 buf_size = stage2->file_size + SECTOR_SIZE; in read_stage2_from_file()
1135 stage2->buf_size / SECTOR_SIZE); in read_stage2_from_file()
1183 char bpb_sect[SECTOR_SIZE]; in prepare_stage1()
1186 != SECTOR_SIZE) { in prepare_stage1()
1196 SECTOR_SIZE - BOOTSZ); in prepare_stage1()
1263 buf_size = P2ROUNDUP(size + SECTOR_SIZE, SECTOR_SIZE); in read_stage2_from_disk()
[all …]
/illumos-gate/usr/src/grub/grub-0.97/stage2/
H A Dbuiltins.c463 if (grub_read ((char *) BOOTSEC_LOCATION, SECTOR_SIZE) != SECTOR_SIZE) in chainloader_func()
1419 size = (len + SECTOR_SIZE - 1) / SECTOR_SIZE; in embed_func()
2355 || ! grub_read (stage1_buffer, SECTOR_SIZE) == SECTOR_SIZE) in install_func()
2437 if (grub_read (stage2_first_buffer, SECTOR_SIZE) != SECTOR_SIZE) in install_func()
2447 if (grub_read (stage2_second_buffer, SECTOR_SIZE) != SECTOR_SIZE) in install_func()
2504 grub_seek (SECTOR_SIZE); in install_func()
2590 if (grub_read (stage2_buffer, SECTOR_SIZE) != SECTOR_SIZE) in install_func()
2647 != SECTOR_SIZE) in install_func()
2681 if (fwrite (stage2_first_buffer, 1, SECTOR_SIZE, fp) != SECTOR_SIZE) in install_func()
2688 if (fwrite (stage2_second_buffer, 1, SECTOR_SIZE, fp) != SECTOR_SIZE) in install_func()
[all …]
H A Ddisk_io.c327 byte_offset &= SECTOR_SIZE - 1; in devread()
366 memmove ((char *) SCRATCHADDR, buf, SECTOR_SIZE); in rawwrite()
631 0, SECTOR_SIZE, buf)) in next_partition()
752 if (! rawread (drive, 1, 0, SECTOR_SIZE, buf)) in next_partition()
921 char buf[SECTOR_SIZE]; in real_open_partition()
1300 0, SECTOR_SIZE, (char *) SCRATCHADDR)) in set_bootdev()
1765 filemax += (tmp * SECTOR_SIZE); in grub_open()
1857 >= SECTOR_SIZE) in grub_read()
1859 BLK_CUR_FILEPOS += SECTOR_SIZE; in grub_read()
1872 off = filepos & (SECTOR_SIZE - 1); in grub_read()
[all …]
H A Dstage1_5.c47 grub_read ((char *) 0x8000, SECTOR_SIZE * 2); in cmain()
57 ret = grub_read ((char *) 0x8000 + SECTOR_SIZE * 2, -1); in cmain()
H A Dgpt.h64 ((((entry) * (size) + 1) & ~(SECTOR_SIZE - 1)) >> SECTOR_BITS)
66 ((((entry) * (size) + 1) & (SECTOR_SIZE - 1)) - 1)
H A Dfsys_fat.c157 || FAT_CVT_U16(bpb.bytes_per_sect) != SECTOR_SIZE in fat_mount()
161 || (FAT_SUPER->fat_size * FAT_SUPER->num_clust / (2 * SECTOR_SIZE) in fat_mount()
240 FAT_SUPER->cached_fat = (fat_entry & ~(2*SECTOR_SIZE - 1)); in fat_read()
243 + FAT_SUPER->cached_fat / (2*SECTOR_SIZE); in fat_read()
H A Dstart_eltorito.S118 ljmp $0, $(STAGE_ADDR+SECTOR_SIZE) /* jump to main() in asm.S */
309 . = _start + SECTOR_SIZE - BOOTSEC_LISTSIZE
324 .word (STAGE_ADDR + SECTOR_SIZE) >> 4
H A Dbios.c179 geometry->sector_size = SECTOR_SIZE; in get_cdinfo()
346 geometry->sector_size = SECTOR_SIZE; in get_diskinfo()
373 geometry->sector_size = SECTOR_SIZE; in get_diskinfo()
H A Dboot.c268 text_len = filemax - data_len - SECTOR_SIZE; in load_image()
378 if (data_len + SECTOR_SIZE <= MULTIBOOT_SEARCH) in load_image()
380 data_len + SECTOR_SIZE); in load_image()
385 data_len + SECTOR_SIZE - MULTIBOOT_SEARCH); in load_image()
444 grub_seek (data_len + SECTOR_SIZE); in load_image()
H A Dfsys_reiserfs.c295 #define FSYSREISER_MIN_BLOCKSIZE SECTOR_SIZE
628 || (SECTOR_SIZE << INFO->blocksize_shift) != super.s_blocksize) in reiserfs_mount()
H A Dshared.h190 #define SECTOR_SIZE 0x200 macro
/illumos-gate/usr/src/grub/grub-0.97/grub/
H A Dasmstub.c954 offset = (loff_t) sector * (loff_t) SECTOR_SIZE; in biosdisk()
960 off_t offset = (off_t) sector * (off_t) SECTOR_SIZE; in biosdisk()
979 if (nread (fd, buf, SECTOR_SIZE) != SECTOR_SIZE) in biosdisk()
981 buf += SECTOR_SIZE; in biosdisk()
985 if (nread (fd, buf, nsec * SECTOR_SIZE) != nsec * SECTOR_SIZE) in biosdisk()
995 hex_dump (buf, nsec * SECTOR_SIZE); in biosdisk()
998 if (nwrite (fd, buf, nsec * SECTOR_SIZE) != nsec * SECTOR_SIZE) in biosdisk()
/illumos-gate/usr/src/cmd/boot/installboot/sparc/
H A Dinstallboot.c118 buf_size = P2ROUNDUP(bblock->file_size, SECTOR_SIZE); in read_bootblock_from_file()
124 buf_size = P2ROUNDUP(bblock->file_size + SECTOR_SIZE, in read_bootblock_from_file()
125 SECTOR_SIZE); in read_bootblock_from_file()
217 buf_size = P2ROUNDUP(size + SECTOR_SIZE, SECTOR_SIZE); in read_bootblock_from_disk()
232 if (read_in(dev_fd, dest, size, SECTOR_SIZE) != BC_SUCCESS) { in read_bootblock_from_disk()
404 if (write_out(device->fd, bufptr, size, SECTOR_SIZE) != BC_SUCCESS) { in write_zfs_bootblock()
438 SECTOR_SIZE) != BC_SUCCESS) { in write_bootblock()
539 buf_size = src_bblock->file_size + SECTOR_SIZE; in propagate_bootblock()
541 dest_bblock->buf_size = P2ROUNDUP(buf_size, SECTOR_SIZE); in propagate_bootblock()
H A Dinstallboot.h66 #define BBLK_DATA_RSVD_SIZE (15 * SECTOR_SIZE)
67 #define BBLK_ZFS_EXTRA_OFF (SECTOR_SIZE * 1024)
/illumos-gate/usr/src/cmd/boot/common/
H A Dboot_utils.c62 if (size % SECTOR_SIZE != 0) in write_out()
95 if (size % SECTOR_SIZE != 0) in read_in()
H A Dboot_utils.h43 #define SECTOR_SIZE (512) macro
/illumos-gate/usr/src/boot/i386/loader/
H A Dchain.c39 #define SECTOR_SIZE (512) macro
46 int fd, len, size = SECTOR_SIZE; in command_chain()
/illumos-gate/usr/src/tools/btxld/
H A Dversion.c73 buf_size = P2ROUNDUP(sb.st_size + SECTOR_SIZE, SECTOR_SIZE); in add_version()
/illumos-gate/usr/src/grub/grub-0.97/lib/
H A Ddevice.c153 geom->sector_size = SECTOR_SIZE; in get_drive_geometry()
912 offset = (loff_t) sector * (loff_t) SECTOR_SIZE; in write_to_partition()
921 off_t offset = (off_t) sector * (off_t) SECTOR_SIZE; in write_to_partition()
931 if (write (fd, buf, size * SECTOR_SIZE) != (size * SECTOR_SIZE)) in write_to_partition()
/illumos-gate/usr/src/cmd/boot/installboot/i386/
H A Dinstallboot.c117 static size_t sector_size = SECTOR_SIZE;
255 offset = plist->pl_device->stage.offset * SECTOR_SIZE; in install_stage2_cb()
265 (bblock->buf_size / SECTOR_SIZE) + 1, offset / SECTOR_SIZE, abs); in install_stage2_cb()
583 data = malloc(SECTOR_SIZE); in read_stage1_bbl_cb()
590 read(fd, data, SECTOR_SIZE) != SECTOR_SIZE) { in read_stage1_bbl_cb()
627 offset = device->stage.offset * SECTOR_SIZE; in read_stage2_cb()
663 buf_size = P2ROUNDUP(size + SECTOR_SIZE, SECTOR_SIZE); in read_stage2_cb()
958 return (SECTOR_SIZE); in get_media_info()
1910 SECTOR_SIZE - STAGE1_SIG); in prepare_stage1()
1917 size = bblk->buf_size / SECTOR_SIZE; in prepare_stage1()
[all …]
H A Dinstallboot.h39 #define SECTOR_SIZE (512) macro
/illumos-gate/usr/src/cmd/mdb/common/modules/disk_label/
H A Ddisk_label.c94 size_t sector_size = SECTOR_SIZE;
254 CTASSERT(sizeof (*mbr) == SECTOR_SIZE); in cmd_mbr()
456 if (header->efi_gpt_HeaderSize > SECTOR_SIZE) { in cmd_gpt()
778 uint64_t size = SECTOR_SIZE; in cmd_sect()
/illumos-gate/usr/src/cmd/boot/bootadm/
H A Dbootadm.c5556 #define SECTOR_SIZE 512 macro
5563 char boot_sect[SECTOR_SIZE];
5583 if (fd == -1 || read(fd, boot_sect, SECTOR_SIZE) != SECTOR_SIZE) {
/illumos-gate/usr/src/grub/grub-0.97/
H A DChangeLog605 (rawread): Use BUF_GEOM.SECTOR_SIZE instead of SECTOR_SIZE.
625 Set the sector size to SECTOR_SIZE if it is not a CD-ROM.
655 * lib/device.c (get_drive_geometry): Set GEOM->SECTOR_SIZE to
656 SECTOR_SIZE by default.
929 * stage2/boot.c (load_image): Check if DATA_LEN plus SECTOR_SIZE
4788 SECTOR_SIZE to compute BLOCKSIZE.
5092 (1 << SECTOR_SHIFT) == SECTOR_SIZE.
6074 function biosdisk is changed from SECTOR + I * SECTOR_SIZE to
7806 (fat_create_blocklist): Use the macro SECTOR_SIZE instead of a