Lines Matching defs:fd
152 int fd, rc;
168 if ((fd = open(rdskname, O_RDONLY)) == -1) {
170 } else if ((rc = read_vtoc(fd, &vtoc)) >= 0) {
177 (void) close(fd);
180 (efi_alloc_and_read(fd, &gpt)) >= 0) {
183 (void) close(fd);
428 int fd, createdir = 0;
518 (fd = open(cpr_conf, O_RDONLY)) != -1) {
519 nread = read(fd, &cc, sizeof (cc));
527 (void) close(fd);
548 if ((fd = open(cpr_conf, O_CREAT | O_TRUNC | O_WRONLY, 0644)) == -1) {
555 if (write(fd, &cc, sizeof (cc)) != sizeof (cc)) {
559 (void) close(fd);
563 (void) close(fd);
629 int fd, upval;
631 if ((fd = open(promdev, O_RDONLY)) == -1) {
641 upval = ioctl(fd, OPROMDEV2PROMNAME, opp);
642 (void) close(fd);