changeset 20523:d16b13fcc286

treewide: lseek64() -> lseek()
author Lauri Tirkkonen <lotheac@iki.fi>
date Tue, 16 Apr 2019 22:49:11 +0300
parents c10790e8f12c
children 318619db5bd1
files usr/src/cmd/backup/dump/dumptape.c usr/src/cmd/backup/restore/tape.c usr/src/cmd/fm/fmd/common/fmd_log.c usr/src/cmd/fm/fmd/common/fmd_sysevent.c usr/src/cmd/fs.d/pcfs/fsck/bpb.c usr/src/cmd/fs.d/pcfs/fsck/clusters.c usr/src/cmd/fs.d/pcfs/fsck/dir.c usr/src/cmd/fs.d/pcfs/fsck/fat.c usr/src/cmd/fs.d/pcfs/fsck/pcfs_common.c usr/src/cmd/fs.d/pcfs/mkfs/mkfs.c usr/src/cmd/mdb/common/mdb/mdb_fdio.c usr/src/cmd/ypcmd/ypxfrd_client.c usr/src/lib/fm/libfmd_log/common/fmd_log.c usr/src/lib/libc/port/gen/getlogin.c usr/src/lib/libc/port/gen/ndbm.c usr/src/lib/libc/port/stdio/_endopen.c usr/src/lib/libc/port/stdio/fdopen.c usr/src/lib/libc/port/stdio/flush.c usr/src/lib/libc/port/stdio/fopen.c usr/src/lib/libc/port/stdio/ftell.c usr/src/lib/libc/port/stdio/rewind.c usr/src/lib/libdtrace/common/dt_cc.c usr/src/lib/libdtrace/common/dt_link.c usr/src/lib/libproc/common/Pcore.c usr/src/lib/libsmbios/common/smbios_lib.c usr/src/test/smbclient-tests/cmd/file_trunc/file_trunc.c usr/src/test/zfs-tests/cmd/file_trunc/file_trunc.c
diffstat 27 files changed, 69 insertions(+), 69 deletions(-) [+]
line wrap: on
line diff
--- a/usr/src/cmd/backup/dump/dumptape.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/backup/dump/dumptape.c	Tue Apr 16 22:49:11 2019 +0300
@@ -427,7 +427,7 @@
 
 		archive_opened = 1;
 
-		if (lseek64(archivefd, lf_archoffset, 0) < 0) {
+		if (lseek(archivefd, lf_archoffset, 0) < 0) {
 			saverr = errno;
 			msg(gettext(
 				    "Cannot position archive file `%s' : %s\n"),
@@ -969,7 +969,7 @@
 	 * Checkpoint archive file
 	 */
 	if (!doingverify && archive) {
-		lf_archoffset = lseek64(archivefd, (off64_t)0, 2);
+		lf_archoffset = lseek(archivefd, (off64_t)0, 2);
 		if (lf_archoffset < 0) {
 			int saverr = errno;
 			msg(gettext("Cannot position archive file `%s': %s\n"),
--- a/usr/src/cmd/backup/restore/tape.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/backup/restore/tape.c	Tue Apr 16 22:49:11 2019 +0300
@@ -1127,7 +1127,7 @@
 static void
 xtrskip(char *buf, size_t size)
 {
-	if (lseek64(ofile, (offset_t)size, 1) == -1) {
+	if (lseek(ofile, (offset_t)size, 1) == -1) {
 		int saverr = errno;
 		(void) fprintf(stderr,
 		    gettext("seek error extracting inode %d, name %s\n"),
@@ -1544,7 +1544,7 @@
 		/* LINTED: unsigned->signed conversion ok */
 		i = (int)(ntrec*tp_bsize);
 		bzero(tbf, (size_t)i);
-		if (lseek64(mt, (offset_t)i, 1) == (off64_t)-1) {
+		if (lseek(mt, (offset_t)i, 1) == (off64_t)-1) {
 			perror(gettext("continuation failed"));
 			done(1);
 		}
--- a/usr/src/cmd/fm/fmd/common/fmd_log.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fm/fmd/common/fmd_log.c	Tue Apr 16 22:49:11 2019 +0300
@@ -176,7 +176,7 @@
 		(void) ea_pack_object(&hdr, buf, hdr_size);
 		(void) ea_pack_object(&toc, (char *)buf + hdr_size, toc_size);
 
-		if ((lp->log_off = lseek64(lp->log_fd, 0, SEEK_END)) == -1L)
+		if ((lp->log_off = lseek(lp->log_fd, 0, SEEK_END)) == -1L)
 			fmd_panic("failed to seek log %s", lp->log_name);
 
 		if (fmd_log_write(lp, buf, size) != size)
@@ -188,7 +188,7 @@
 		lp->log_beg = lp->log_off + hdr_size + toc_size;
 		lp->log_off = lp->log_off + hdr_size + toc_size;
 
-		if (lp->log_off != lseek64(lp->log_fd, 0, SEEK_END))
+		if (lp->log_off != lseek(lp->log_fd, 0, SEEK_END))
 			fmd_panic("eof off != log_off 0x%llx\n", lp->log_off);
 	} else
 		err = EFMD_LOG_EXACCT;
@@ -229,7 +229,7 @@
 
 	ea_clear(&lp->log_ea); /* resync exacct file */
 
-	if ((hdr_off = lseek64(lp->log_fd, 0, SEEK_CUR)) == -1L)
+	if ((hdr_off = lseek(lp->log_fd, 0, SEEK_CUR)) == -1L)
 		fmd_panic("failed to seek log %s", lp->log_name);
 
 	/*
@@ -316,7 +316,7 @@
 
 	lp->log_toc = hdr_off + hdr_size;
 	lp->log_beg = hdr_off + hdr_size + ea_pack_object(grp, NULL, 0);
-	lp->log_off = lseek64(lp->log_fd, 0, SEEK_END);
+	lp->log_off = lseek(lp->log_fd, 0, SEEK_END);
 	lp->log_skip = grp->eo_group.eg_objs->eo_item.ei_uint64;
 
 	if (lp->log_skip > lp->log_off) {
@@ -657,7 +657,7 @@
 		 * the original location and truncate it there in order to make
 		 * sure the file is always in a sane state w.r.t. libexacct.
 		 */
-		(void) lseek64(lp->log_fd, lp->log_off, SEEK_SET);
+		(void) lseek(lp->log_fd, lp->log_off, SEEK_SET);
 		(void) ftruncate(lp->log_fd, lp->log_off);
 	}
 
@@ -889,7 +889,7 @@
 		c = CAT_FMA_GROUP;
 	}
 
-	if (lseek64(lp->log_fd, off, SEEK_SET) != off) {
+	if (lseek(lp->log_fd, off, SEEK_SET) != off) {
 		fmd_panic("failed to seek %s to 0x%llx\n",
 		    lp->log_name, (u_longlong_t)off);
 	}
@@ -946,7 +946,7 @@
 		skp = off; /* if no replays, move skip to where we ended up */
 
 out:
-	if (lseek64(lp->log_fd, lp->log_off, SEEK_SET) != lp->log_off) {
+	if (lseek(lp->log_fd, lp->log_off, SEEK_SET) != lp->log_off) {
 		fmd_panic("failed to seek %s to 0x%llx\n",
 		    lp->log_name, (u_longlong_t)lp->log_off);
 	}
--- a/usr/src/cmd/fm/fmd/common/fmd_sysevent.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fm/fmd/common/fmd_sysevent.c	Tue Apr 16 22:49:11 2019 +0300
@@ -261,7 +261,7 @@
 	}
 
 	off = DUMP_OFFSET + DUMP_LOGSIZE + DUMP_ERPTSIZE;
-	off = off0 = lseek64(fd, -off, SEEK_END) & -DUMP_OFFSET;
+	off = off0 = lseek(fd, -off, SEEK_END) & -DUMP_OFFSET;
 
 	if (off == (off64_t)-1LL) {
 		fmd_hdl_error(hdl, "failed to seek dump transport %s "
--- a/usr/src/cmd/fs.d/pcfs/fsck/bpb.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fs.d/pcfs/fsck/bpb.c	Tue Apr 16 22:49:11 2019 +0300
@@ -174,7 +174,7 @@
 	/*
 	 *  The BPB is the first sector of the file system
 	 */
-	if (lseek64(fd, PartitionOffset, SEEK_SET) < 0) {
+	if (lseek(fd, PartitionOffset, SEEK_SET) < 0) {
 		mountSanityCheckFails();
 		perror(gettext("Cannot seek to start of disk partition"));
 		(void) close(fd);
--- a/usr/src/cmd/fs.d/pcfs/fsck/clusters.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fs.d/pcfs/fsck/clusters.c	Tue Apr 16 22:49:11 2019 +0300
@@ -291,7 +291,7 @@
 
 	seekto = FirstClusterOffset +
 	    ((off64_t)clusterNum - FIRST_CLUSTER) * BytesPerCluster;
-	if (lseek64(fd, seekto, SEEK_SET) != seekto) {
+	if (lseek(fd, seekto, SEEK_SET) != seekto) {
 		saveError = errno;
 		(void) fprintf(stderr,
 		    gettext("Seek to Allocation unit #%d failed: "),
--- a/usr/src/cmd/fs.d/pcfs/fsck/dir.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fs.d/pcfs/fsck/dir.c	Tue Apr 16 22:49:11 2019 +0300
@@ -924,7 +924,7 @@
 	if (Verbose)
 		(void) fprintf(stderr,
 		    gettext("Seeking root directory @%lld.\n"), seekto);
-	return (lseek64(fd, seekto, SEEK_SET));
+	return (lseek(fd, seekto, SEEK_SET));
 }
 
 void
--- a/usr/src/cmd/fs.d/pcfs/fsck/fat.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fs.d/pcfs/fsck/fat.c	Tue Apr 16 22:49:11 2019 +0300
@@ -65,7 +65,7 @@
 	 */
 	seekto = TheBIOSParameterBlock.bpb.resv_sectors *
 		TheBIOSParameterBlock.bpb.bytes_per_sector + PartitionOffset;
-	return (lseek64(fd, seekto, SEEK_SET));
+	return (lseek(fd, seekto, SEEK_SET));
 }
 
 void
--- a/usr/src/cmd/fs.d/pcfs/fsck/pcfs_common.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fs.d/pcfs/fsck/pcfs_common.c	Tue Apr 16 22:49:11 2019 +0300
@@ -586,7 +586,7 @@
 			 *  Seek the next extended partition, and find
 			 *  logical drives within it.
 			 */
-			if (lseek64(fd, nextseek * BPSEC, SEEK_SET) < 0 ||
+			if (lseek(fd, nextseek * BPSEC, SEEK_SET) < 0 ||
 			    read(fd, &extmboot, sizeof (extmboot)) !=
 			    sizeof (extmboot)) {
 				perror(gettext("Unable to read extended "
--- a/usr/src/cmd/fs.d/pcfs/mkfs/mkfs.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/fs.d/pcfs/mkfs/mkfs.c	Tue Apr 16 22:49:11 2019 +0300
@@ -723,7 +723,7 @@
 		if (Verbose)
 			(void) printf(gettext("Boot partition's offset: "
 			    "Sector %x.\n"), *seekto/BPSEC);
-		if (lseek64(fd, *seekto, SEEK_SET) < 0) {
+		if (lseek(fd, *seekto, SEEK_SET) < 0) {
 			(void) fprintf(stderr, gettext("Partition %s: "), pn);
 			perror("");
 			return (PART_NOT_FOUND);
@@ -745,7 +745,7 @@
 		if (Verbose)
 			(void) printf(gettext("Partition's offset: "
 			    "Sector %x.\n"), *seekto/BPSEC);
-		if (lseek64(fd, *seekto, SEEK_SET) < 0) {
+		if (lseek(fd, *seekto, SEEK_SET) < 0) {
 			(void) fprintf(stderr, gettext("Partition %s: "), pn);
 			perror("");
 			return (PART_NOT_FOUND);
@@ -781,7 +781,7 @@
 			 *  Seek the next extended partition, and find
 			 *  logical drives within it.
 			 */
-			if (lseek64(fd, nextseek * BPSEC, SEEK_SET) < 0 ||
+			if (lseek(fd, nextseek * BPSEC, SEEK_SET) < 0 ||
 			    read(fd, &extmboot, sizeof (extmboot)) !=
 			    sizeof (extmboot)) {
 				perror(gettext("Unable to read extended "
@@ -864,7 +864,7 @@
 			if (Verbose)
 				(void) printf(gettext("Partition's offset: "
 				    "Sector 0x%x.\n"), *seekto/BPSEC);
-			if (lseek64(fd, *seekto, SEEK_SET) < 0) {
+			if (lseek(fd, *seekto, SEEK_SET) < 0) {
 				(void) fprintf(stderr,
 				    gettext("Partition %s: "), pn);
 				perror("");
@@ -904,7 +904,7 @@
 		if (Verbose)
 			(void) printf(gettext("Partition's offset: "
 			    "Sector %x.\n"), *seekto/BPSEC);
-		if (lseek64(fd, *seekto, SEEK_SET) < 0) {
+		if (lseek(fd, *seekto, SEEK_SET) < 0) {
 			(void) fprintf(stderr,
 			    gettext("Partition %s: "), pn);
 			perror("");
@@ -942,7 +942,7 @@
 		(void) printf(gettext("Requested offset: Sector %x.\n"),
 		    *seekto/BPSEC);
 
-	if (lseek64(fd, *seekto, SEEK_SET) < 0) {
+	if (lseek(fd, *seekto, SEEK_SET) < 0) {
 		(void) fprintf(stderr,
 		    gettext("User specified start sector %d"), RelOffset);
 		perror("");
@@ -3102,7 +3102,7 @@
 			perror(gettext("FS info sector write"));
 			exit(4);
 		}
-		if (lseek64(fd,	seekto + BKUP_BOOTSECT_OFFSET, SEEK_SET) < 0) {
+		if (lseek(fd,	seekto + BKUP_BOOTSECT_OFFSET, SEEK_SET) < 0) {
 			(void) close(fd);
 			perror(gettext("Boot sector backup seek"));
 			exit(4);
@@ -3212,7 +3212,7 @@
 
 	write_bootsects(fd, &bootsect, wbpb, &fsinfo, seekto);
 
-	if (lseek64(fd,
+	if (lseek(fd,
 	    seekto + (BPSEC * wbpb->bpb.resv_sectors), SEEK_SET) < 0) {
 		(void) close(fd);
 		perror(gettext("Seek to end of reserved sectors"));
--- a/usr/src/cmd/mdb/common/mdb/mdb_fdio.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/mdb/common/mdb/mdb_fdio.c	Tue Apr 16 22:49:11 2019 +0300
@@ -81,7 +81,7 @@
 	fd_data_t *fdp = io->io_data;
 
 	if (io->io_next == NULL)
-		return (lseek64(fdp->fd_fd, offset, whence));
+		return (lseek(fdp->fd_fd, offset, whence));
 
 	return (IOP_SEEK(io->io_next, offset, whence));
 }
@@ -185,7 +185,7 @@
 	if (io->io_next != NULL)
 		return (IOP_READ(io->io_next, buf, nbytes));
 
-	if ((off = lseek64(fdp->fd_fd, 0, SEEK_CUR)) == -1)
+	if ((off = lseek(fdp->fd_fd, 0, SEEK_CUR)) == -1)
 		return (-1); /* errno is set for us */
 
 	while (resid != 0) {
@@ -205,7 +205,7 @@
 	if (resid == nbytes && nbytes != 0)
 		return (set_errno(EMDB_EOF));
 
-	(void) lseek64(fdp->fd_fd, off, SEEK_SET);
+	(void) lseek(fdp->fd_fd, off, SEEK_SET);
 	return (nbytes - resid);
 }
 
@@ -226,7 +226,7 @@
 	if (io->io_next != NULL)
 		return (IOP_WRITE(io->io_next, buf, nbytes));
 
-	if ((off = lseek64(fdp->fd_fd, 0, SEEK_CUR)) == -1)
+	if ((off = lseek(fdp->fd_fd, 0, SEEK_CUR)) == -1)
 		return (-1); /* errno is set for us */
 
 	while (resid != 0) {
@@ -250,7 +250,7 @@
 	if (resid == nbytes && nbytes != 0)
 		return (set_errno(EMDB_EOF));
 
-	(void) lseek64(fdp->fd_fd, off, SEEK_SET);
+	(void) lseek(fdp->fd_fd, off, SEEK_SET);
 	return (nbytes - resid);
 }
 
--- a/usr/src/cmd/ypcmd/ypxfrd_client.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/cmd/ypcmd/ypxfrd_client.c	Tue Apr 16 22:49:11 2019 +0300
@@ -105,7 +105,7 @@
 #endif
 			errno = 0;
 			where = (((off64_t)PAG->pag_u.ok.blkno) * PBLKSIZ);
-			(void) lseek64(db->dbm_pagf, where, L_SET);
+			(void) lseek(db->dbm_pagf, where, L_SET);
 			if (errno != 0) {
 				perror("seek");
 				exit(-1);
@@ -150,7 +150,7 @@
 		if (DIR->status == OK) {
 			errno = 0;
 			where = (((off64_t)DIR->dir_u.ok.blkno) * DBLKSIZ);
-			(void) lseek64(db->dbm_dirf, where, L_SET);
+			(void) lseek(db->dbm_dirf, where, L_SET);
 			if (errno != 0) {
 				perror("seek");
 				exit(-1);
--- a/usr/src/lib/fm/libfmd_log/common/fmd_log.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/fm/libfmd_log/common/fmd_log.c	Tue Apr 16 22:49:11 2019 +0300
@@ -110,7 +110,7 @@
 
 	if (iflags & FMD_LOG_XITER_OFFS) {
 		ea_clear(&lp->log_ea);
-		off = lseek64(lp->log_fd, 0, SEEK_CUR);
+		off = lseek(lp->log_fd, 0, SEEK_CUR);
 	}
 
 	if ((grp = ea_get_object_tree(&lp->log_ea, 1)) == NULL)
@@ -262,7 +262,7 @@
 
 	xlp->log_flags &= ~FMD_LF_START;
 	ea_clear(&xlp->log_ea);
-	(void) lseek64(xlp->log_fd, off, SEEK_SET);
+	(void) lseek(xlp->log_fd, off, SEEK_SET);
 
 	return (fmd_log_load_record(xlp,
 	    iflags, &rp->rec_xrefs[rp->rec_nrefs++]));
@@ -701,7 +701,7 @@
 	lp->log_flags &= ~FMD_LF_START;
 	ea_clear(&lp->log_ea);
 
-	if (lseek64(lp->log_fd, off, SEEK_SET) != off)
+	if (lseek(lp->log_fd, off, SEEK_SET) != off)
 		return (fmd_log_set_errno(lp, errno));
 
 	return (0);
--- a/usr/src/lib/libc/port/gen/getlogin.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/gen/getlogin.c	Tue Apr 16 22:49:11 2019 +0300
@@ -65,7 +65,7 @@
 		return (NULL);
 	if ((uf = open(UTMPX_FILE, 0)) < 0)
 		return (NULL);
-	(void) lseek64(uf, me * sizeof (ubuf), SEEK_SET);
+	(void) lseek(uf, me * sizeof (ubuf), SEEK_SET);
 	if (read(uf, &ubuf, sizeof (ubuf)) != sizeof (ubuf)) {
 		(void) close(uf);
 		return (NULL);
--- a/usr/src/lib/libc/port/gen/ndbm.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/gen/ndbm.c	Tue Apr 16 22:49:11 2019 +0300
@@ -127,7 +127,7 @@
 
 	if (dbm_dirty(db)) { /* must page out the page */
 		where = (((off64_t)db->dbm_pagbno) * PBLKSIZ);
-		if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 		    (write(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) != PBLKSIZ)) {
 			db->dbm_flags |= _DBM_IOERR;
 			ok = -1;
@@ -144,7 +144,7 @@
 	off64_t where;
 	if (dbm_dirdirty(db)) { /* must page out the dir */
 		where = (((off64_t)db->dbm_dirbno) * DBLKSIZ);
-		if ((lseek64(db->dbm_dirf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_dirf, where, L_SET) != where) ||
 		    (write(db->dbm_dirf, db->dbm_dirbuf, DBLKSIZ) != DBLKSIZ)) {
 			ok = -1;
 		}
@@ -290,7 +290,7 @@
 		dbm_setdirty(db);
 	} else {
 		where = (((off64_t)db->dbm_blkno) * PBLKSIZ);
-		if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 		    (write(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) != PBLKSIZ)) {
 			err:
 				db->dbm_flags |= _DBM_IOERR;
@@ -333,7 +333,7 @@
 		dbm_setdirty(db);
 	} else {
 		where = (((off64_t)db->dbm_blkno) * PBLKSIZ);
-		if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 		    (write(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) != PBLKSIZ)) {
 			db->dbm_flags |= _DBM_IOERR;
 			return (-1);
@@ -376,14 +376,14 @@
 	}
 	db->dbm_pagbno = db->dbm_blkno;
 	where = (((off64_t)db->dbm_blkno) * PBLKSIZ);
-	if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+	if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 	    (write(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) != PBLKSIZ)) {
 		db->dbm_flags |= _DBM_IOERR;
 		return (-1);
 	}
 	dbm_clrdirty(db); /* clear dirty */
 	where = (((off64_t)db->dbm_blkno + db->dbm_hmask + 1) * PBLKSIZ);
-	if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+	if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 	    (write(db->dbm_pagf, ovfbuf, PBLKSIZ) != PBLKSIZ)) {
 		db->dbm_flags |= _DBM_IOERR;
 		return (-1);
@@ -508,7 +508,7 @@
 
 			db->dbm_pagbno = db->dbm_blkptr;
 			where = (((off64_t)db->dbm_blkptr) * PBLKSIZ);
-			if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+			if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 			    (read(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) !=
 			    PBLKSIZ))
 				(void) memset(db->dbm_pagbuf, 0, PBLKSIZ);
@@ -581,7 +581,7 @@
 			if (dbm_dirty(db)) (void) dbm_flushpag(db);
 			db->dbm_pagbno = db->dbm_blkptr;
 			where = (((off64_t)db->dbm_blkptr) * PBLKSIZ);
-			if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+			if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 			    (read(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) !=
 			    PBLKSIZ))
 				(void) memset(db->dbm_pagbuf, 0, PBLKSIZ);
@@ -739,7 +739,7 @@
 				(void) dbm_flushdir(db); /* must flush */
 			db->dbm_dirbno = b;
 			where = (((off64_t)b) * DBLKSIZ);
-			if ((lseek64(db->dbm_dirf, where, L_SET) != where) ||
+			if ((lseek(db->dbm_dirf, where, L_SET) != where) ||
 			    (read(db->dbm_dirf, db->dbm_dirbuf, DBLKSIZ) !=
 			    DBLKSIZ))
 				(void) memset(db->dbm_dirbuf, 0, DBLKSIZ);
@@ -759,7 +759,7 @@
 	if (my_blkno != db->dbm_pagbno) {
 		if (dbm_dirty(db)) { /* must page out the page */
 			where = (((off64_t)db->dbm_pagbno) * PBLKSIZ);
-			if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+			if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 			    (write(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) !=
 			    PBLKSIZ)) {
 				db->dbm_flags |= _DBM_IOERR;
@@ -769,7 +769,7 @@
 
 		db->dbm_pagbno = my_blkno;
 		where = (((off64_t)my_blkno) * PBLKSIZ);
-		if ((lseek64(db->dbm_pagf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_pagf, where, L_SET) != where) ||
 		    (read(db->dbm_pagf, db->dbm_pagbuf, PBLKSIZ) != PBLKSIZ))
 			(void) memset(db->dbm_pagbuf, 0, PBLKSIZ);
 #ifdef DEBUG
@@ -797,7 +797,7 @@
 			(void) dbm_flushdir(db); /* must flush */
 		db->dbm_dirbno = b;
 		where = (((off64_t)b) * DBLKSIZ);
-		if ((lseek64(db->dbm_dirf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_dirf, where, L_SET) != where) ||
 		    (read(db->dbm_dirf, db->dbm_dirbuf, DBLKSIZ) != DBLKSIZ))
 			(void) memset(db->dbm_dirbuf, 0, DBLKSIZ);
 	}
@@ -822,7 +822,7 @@
 			(void) dbm_flushdir(db);
 		db->dbm_dirbno = b;
 		where = (((off64_t)b) * DBLKSIZ);
-		if ((lseek64(db->dbm_dirf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_dirf, where, L_SET) != where) ||
 		    (read(db->dbm_dirf, db->dbm_dirbuf, DBLKSIZ) != DBLKSIZ))
 			(void) memset(db->dbm_dirbuf, 0, DBLKSIZ);
 	}
@@ -832,7 +832,7 @@
 		dbm_setdirdirty(db);
 	} else {
 		where = (((off64_t)b) * DBLKSIZ);
-		if ((lseek64(db->dbm_dirf, where, L_SET) != where) ||
+		if ((lseek(db->dbm_dirf, where, L_SET) != where) ||
 		    (write(db->dbm_dirf, db->dbm_dirbuf, DBLKSIZ) != DBLKSIZ)) {
 			return (-1);
 		}
--- a/usr/src/lib/libc/port/stdio/_endopen.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/stdio/_endopen.c	Tue Apr 16 22:49:11 2019 +0300
@@ -129,7 +129,7 @@
 #endif	/*	_LP64	*/
 
 	if (oflag == (O_WRONLY | O_APPEND | O_CREAT)) {	/* type == "a" */
-		if (lseek64(fd, (off64_t)0, SEEK_END) < (off64_t)0) {
+		if (lseek(fd, (off64_t)0, SEEK_END) < (off64_t)0) {
 			(void) close(fd);
 			return (NULL);
 		}
--- a/usr/src/lib/libc/port/stdio/fdopen.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/stdio/fdopen.c	Tue Apr 16 22:49:11 2019 +0300
@@ -78,7 +78,7 @@
 		flag = _IOREAD;
 		break;
 	case 'a':
-		(void) lseek64(fd, (off64_t)0, SEEK_END);
+		(void) lseek(fd, (off64_t)0, SEEK_END);
 		/*FALLTHROUGH*/
 	case 'w':
 		flag = _IOWRT;
--- a/usr/src/lib/libc/port/stdio/flush.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/stdio/flush.c	Tue Apr 16 22:49:11 2019 +0300
@@ -662,7 +662,7 @@
 
 	/* this portion is always assumed locked */
 	if (!(iop->_flag & _IOWRT)) {
-		(void) lseek64(GET_FD(iop), -iop->_cnt, SEEK_CUR);
+		(void) lseek(GET_FD(iop), -iop->_cnt, SEEK_CUR);
 		iop->_cnt = 0;
 		/* needed for ungetc & multibyte pushbacks */
 		iop->_ptr = iop->_base;
--- a/usr/src/lib/libc/port/stdio/fopen.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/stdio/fopen.c	Tue Apr 16 22:49:11 2019 +0300
@@ -180,7 +180,7 @@
 		goto errret;
 
 	/* ignore seek failures, eg. with pipes */
-	(void) lseek64(fd, (off64_t)0, SEEK_SET);
+	(void) lseek(fd, (off64_t)0, SEEK_SET);
 
 	return (iop);
 
--- a/usr/src/lib/libc/port/stdio/ftell.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/stdio/ftell.c	Tue Apr 16 22:49:11 2019 +0300
@@ -74,7 +74,7 @@
 		return (EOF);
 	}
 
-	tres = lseek64(FILENO(iop), 0, SEEK_CUR);
+	tres = lseek(FILENO(iop), 0, SEEK_CUR);
 	if (tres >= 0)
 		tres += adjust;
 
--- a/usr/src/lib/libc/port/stdio/rewind.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libc/port/stdio/rewind.c	Tue Apr 16 22:49:11 2019 +0300
@@ -55,7 +55,7 @@
 _rewind_unlocked(FILE *iop)
 {
 	(void) _fflush_u(iop);
-	(void) lseek64(FILENO(iop), 0, SEEK_SET);
+	(void) lseek(FILENO(iop), 0, SEEK_SET);
 	iop->_cnt = 0;
 	iop->_ptr = iop->_base;
 	iop->_flag &= ~(_IOERR | _IOEOF);
--- a/usr/src/lib/libdtrace/common/dt_cc.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libdtrace/common/dt_cc.c	Tue Apr 16 22:49:11 2019 +0300
@@ -2495,12 +2495,12 @@
 		dt_node_printr(yypcb->pcb_root, stderr, 0);
 
 	if (dtp->dt_cdefs_fd != -1 && (ftruncate(dtp->dt_cdefs_fd, 0) == -1 ||
-	    lseek64(dtp->dt_cdefs_fd, 0, SEEK_SET) == -1 ||
+	    lseek(dtp->dt_cdefs_fd, 0, SEEK_SET) == -1 ||
 	    ctf_write(dtp->dt_cdefs->dm_ctfp, dtp->dt_cdefs_fd) == CTF_ERR))
 		dt_dprintf("failed to update CTF cache: %s\n", strerror(errno));
 
 	if (dtp->dt_ddefs_fd != -1 && (ftruncate(dtp->dt_ddefs_fd, 0) == -1 ||
-	    lseek64(dtp->dt_ddefs_fd, 0, SEEK_SET) == -1 ||
+	    lseek(dtp->dt_ddefs_fd, 0, SEEK_SET) == -1 ||
 	    ctf_write(dtp->dt_ddefs->dm_ctfp, dtp->dt_ddefs_fd) == CTF_ERR))
 		dt_dprintf("failed to update CTF cache: %s\n", strerror(errno));
 
--- a/usr/src/lib/libdtrace/common/dt_link.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libdtrace/common/dt_link.c	Tue Apr 16 22:49:11 2019 +0300
@@ -58,7 +58,7 @@
 #define	ESHDR_NUM	6
 
 #define	PWRITE_SCN(index, data) \
-	(lseek64(fd, (off64_t)elf_file.shdr[(index)].sh_offset, SEEK_SET) != \
+	(lseek(fd, (off64_t)elf_file.shdr[(index)].sh_offset, SEEK_SET) != \
 	(off64_t)elf_file.shdr[(index)].sh_offset || \
 	dt_write(dtp, fd, (data), elf_file.shdr[(index)].sh_size) != \
 	elf_file.shdr[(index)].sh_size)
--- a/usr/src/lib/libproc/common/Pcore.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libproc/common/Pcore.c	Tue Apr 16 22:49:11 2019 +0300
@@ -2333,7 +2333,7 @@
 	/*
 	 * Advance the seek pointer to the start of the PT_NOTE data
 	 */
-	if (lseek64(P->asfd, note_phdr.p_offset, SEEK_SET) == (off_t)-1) {
+	if (lseek(P->asfd, note_phdr.p_offset, SEEK_SET) == (off_t)-1) {
 		dprintf("Pgrab_core: failed to lseek to PT_NOTE data\n");
 		*perr = G_STRANGE;
 		goto err;
@@ -2379,7 +2379,7 @@
 		 */
 		namesz = P2ROUNDUP((off_t)nhdr.n_namesz, (off_t)4);
 
-		if (lseek64(P->asfd, namesz, SEEK_CUR) == (off_t)-1) {
+		if (lseek(P->asfd, namesz, SEEK_CUR) == (off_t)-1) {
 			dprintf("failed to seek past name and padding\n");
 			*perr = G_STRANGE;
 			goto err;
@@ -2388,7 +2388,7 @@
 		dprintf("Note hdr n_type=%u n_namesz=%u n_descsz=%u\n",
 		    nhdr.n_type, nhdr.n_namesz, nhdr.n_descsz);
 
-		off = lseek64(P->asfd, (off_t)0L, SEEK_CUR);
+		off = lseek(P->asfd, (off_t)0L, SEEK_CUR);
 
 		/*
 		 * Invoke the note handler function from our table
@@ -2417,7 +2417,7 @@
 		 * Seek past the current note data to the next Elf_Nhdr
 		 */
 		descsz = P2ROUNDUP((off_t)nhdr.n_descsz, (off_t)4);
-		if (lseek64(P->asfd, off + descsz, SEEK_SET) == (off_t)-1) {
+		if (lseek(P->asfd, off + descsz, SEEK_SET) == (off_t)-1) {
 			dprintf("Pgrab_core: failed to seek to next nhdr\n");
 			*perr = G_STRANGE;
 			goto err;
--- a/usr/src/lib/libsmbios/common/smbios_lib.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/lib/libsmbios/common/smbios_lib.c	Tue Apr 16 22:49:11 2019 +0300
@@ -248,7 +248,7 @@
 smbios_write(smbios_hdl_t *shp, int fd)
 {
 	smbios_entry_t ep;
-	off64_t off = lseek64(fd, 0, SEEK_CUR) + P2ROUNDUP(sizeof (ep), 16);
+	off64_t off = lseek(fd, 0, SEEK_CUR) + P2ROUNDUP(sizeof (ep), 16);
 
 	if (off > UINT32_MAX)
 		return (smb_set_errno(shp, EOVERFLOW));
@@ -264,7 +264,7 @@
 	smbios_checksum(shp, &ep);
 
 	if (smbios_xwrite(shp, fd, &ep, sizeof (ep)) == -1 ||
-	    lseek64(fd, off, SEEK_SET) != off ||
+	    lseek(fd, off, SEEK_SET) != off ||
 	    smbios_xwrite(shp, fd, shp->sh_buf, shp->sh_buflen) == -1)
 		return (-1);
 
--- a/usr/src/test/smbclient-tests/cmd/file_trunc/file_trunc.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/test/smbclient-tests/cmd/file_trunc/file_trunc.c	Tue Apr 16 22:49:11 2019 +0300
@@ -178,7 +178,7 @@
 	}
 
 	roffset = random() % fsize;
-	if (lseek64(fd, (offset + roffset), SEEK_SET) < 0) {
+	if (lseek(fd, (offset + roffset), SEEK_SET) < 0) {
 		perror("lseek");
 		exit(5);
 	}
@@ -190,7 +190,7 @@
 	}
 
 	if (rflag) {
-		if (lseek64(fd, (offset + roffset), SEEK_SET) < 0) {
+		if (lseek(fd, (offset + roffset), SEEK_SET) < 0) {
 			perror("lseek");
 			exit(7);
 		}
--- a/usr/src/test/zfs-tests/cmd/file_trunc/file_trunc.c	Tue Apr 16 22:49:10 2019 +0300
+++ b/usr/src/test/zfs-tests/cmd/file_trunc/file_trunc.c	Tue Apr 16 22:49:11 2019 +0300
@@ -181,7 +181,7 @@
 	}
 
 	roffset = random() % fsize;
-	if (lseek64(fd, (offset + roffset), SEEK_SET) < 0) {
+	if (lseek(fd, (offset + roffset), SEEK_SET) < 0) {
 		perror("lseek");
 		exit(5);
 	}
@@ -193,7 +193,7 @@
 	}
 
 	if (rflag) {
-		if (lseek64(fd, (offset + roffset), SEEK_SET) < 0) {
+		if (lseek(fd, (offset + roffset), SEEK_SET) < 0) {
 			perror("lseek");
 			exit(7);
 		}