/illumos-gate/usr/src/cmd/lp/lib/msgs/ |
H A D | mdisconnect.c | 43 int mdisconnect ( MESG * md ) in mdisconnect() argument 45 int mdisconnect (md) in mdisconnect() 46 MESG *md; in mdisconnect() 53 if (!md) 59 switch(md->type) 64 if (md->writefd >= 0) 65 (void) Close(md->writefd); 66 if (md->readfd >= 0) 67 (void) Close(md->readfd); 72 disconnect3_2(md); [all …]
|
H A D | mconnect.c | 67 MESG *md; local 119 if ((md = (MESG *)Malloc(MDSIZE)) == NULL) 125 memset(md, 0, sizeof (MESG)); 126 md->gid = getgid(); 127 md->on_discon = NULL; 128 md->readfd = fd; 129 md->state = MDS_IDLE; 130 md->type = MD_STREAM; 131 md->uid = getuid(); 132 md->writefd = fd; [all …]
|
H A D | mlisten.c | 54 mlisteninit(MESG * md) in mlisteninit() argument 56 if (md == NULL) in mlisteninit() 76 Connections[0] = md; in mlisteninit() 77 PollFdList[0].fd = md->readfd; in mlisteninit() 85 mlistenadd(MESG * md, short events) in mlistenadd() argument 123 fdp->fd = md->readfd; in mlistenadd() 131 Connections[NumCons + NumNewCons++] = md; in mlistenadd() 139 MESG * md; in mlistenreset() local 149 md = Connections[0]; in mlistenreset() 159 return(md); in mlistenreset() [all …]
|
H A D | mwrite.c | 41 static int _mwrite ( MESG * md , char * msgbuf , int ); 52 mflush(MESG *md) in mflush() argument 57 if (md == NULL || md->mque == NULL) { in mflush() 62 while ((p = md->mque) != NULL) { in mflush() 63 if (_mwrite(md, p->dat->buf, p->dat->len) != 0) in mflush() 67 md->mque = p->next; in mflush() 85 int mwrite ( MESG * md, char * msgbuf ) in mwrite() argument 92 if (md == NULL) in mwrite() 110 if (md->mque) in mwrite() 113 if (_mwrite(md, msgbuf, size) == 0) in mwrite() [all …]
|
H A D | mcreate.c | 47 MESG *md; local 60 if ((md = (MESG *)Malloc(MDSIZE)) == NULL) 63 memset(md, 0, sizeof (MESG)); 64 md->admin = 1; 65 md->file = Strdup(path); 66 md->gid = getgid(); 67 md->readfd = fds[0]; 68 md->state = MDS_IDLE; 69 md->type = MD_MASTER; 70 md->uid = getuid(); [all …]
|
H A D | mgetputm.c | 59 int mgetm ( MESG * md, int type, ... ) in mgetm() argument 61 int mgetm (md, type, va_alist) in mgetm() 62 MESG *md; in mgetm() 77 needsize = mpeek(md); 93 if (mread(md, MBG, MBGSize) < 0) 104 int mputm ( MESG * md, int type, ... ) in mputm() argument 106 int mputm (md, type, va_alist) in mputm() 107 MESG *md; in mputm() 150 return(mwrite(md, MBP)); 168 short mpeek ( MESG * md ) in mpeek() argument [all …]
|
H A D | mdestroy.c | 39 int mdestroy(MESG *md) in mdestroy() argument 44 if (!md || md->type != MD_MASTER || md->file == NULL) { in mdestroy() 49 if (fdetach(md->file) != 0) in mdestroy() 52 pfd.fd = md->readfd; in mdestroy() 55 if (ioctl(md->readfd, I_RECVFD, &recbuf) == 0) in mdestroy() 62 if (ioctl(md->writefd, I_POP, 0) != 0) in mdestroy() 65 Free(md->file); in mdestroy() 66 md->file = NULL; in mdestroy() 68 (void) mdisconnect(md); in mdestroy()
|
H A D | mread.c | 58 int mread ( MESG * md, char * msgbuf, int size ) in mread() argument 60 int mread ( md, msgbuf, size ) in mread() 61 MESG *md; in mread() 71 if (md == NULL || msgbuf == NULL) 77 switch(md->type) 96 if (Getmsg(md, &ctl, &dat, &flag) < 0) 105 (void) Close(md->readfd); 118 if (read3_2(md, msgbuf, size) < 0)
|
/illumos-gate/usr/src/cmd/lp/cmd/lpsched/ |
H A D | msgs.c | 65 MESG * md; in take_message() local 68 if ((md = mlisten()) == NULL) in take_message() 89 if ((md->event & POLLHUP) && !(md->event & POLLIN) || in take_message() 90 (md->event & (POLLERR|POLLNVAL))) { in take_message() 91 switch (md->type) { in take_message() 101 if (Exec_Table[i]->md == md) in take_message() 120 if (md->readfd == -1) { /* something happened to the readfd */ in take_message() 124 bytes = mread(md, Message, MSGMAX); in take_message() 139 if (do_msg(md)) in take_message() 151 do_msg(MESG *md) in do_msg() argument [all …]
|
H A D | disp1.c | 45 s_alloc_files(char *m, MESG *md) /* funcdef */ in s_alloc_files() argument 61 if ((file_prefix = _alloc_files(count, (char *)0, md->uid, md->gid))) { in s_alloc_files() 62 mputm(md, R_ALLOC_FILES, MOK, file_prefix); in s_alloc_files() 63 add_flt_act(md, FLT_FILES, file_prefix, count); in s_alloc_files() 65 mputm(md, R_ALLOC_FILES, MERRDEST, ""); in s_alloc_files() 67 mputm(md, R_ALLOC_FILES, MNOMEM, ""); in s_alloc_files() 78 s_print_request(char *m, MESG *md) in s_print_request() argument 130 rp->secure->uid = md->uid; in s_print_request() 131 rp->secure->gid = md->gid; in s_print_request() 132 if (md->slabel != NULL) in s_print_request() [all …]
|
H A D | disp4.c | 40 s_accept_dest(char *m, MESG *md) in s_accept_dest() argument 80 mputm (md, R_ACCEPT_DEST, status); in s_accept_dest() 89 s_reject_dest(char *m, MESG *md) in s_reject_dest() argument 134 mputm (md, R_REJECT_DEST, status); in s_reject_dest() 143 s_enable_dest(char *m, MESG *md) in s_enable_dest() argument 164 mputm (md, R_ENABLE_DEST, status); in s_enable_dest() 173 s_disable_dest(char *m, MESG *md) in s_disable_dest() argument 218 mputm (md, R_DISABLE_DEST, status, NB(req_id)); in s_disable_dest() 230 s_load_filter_table(char *m, MESG *md) in s_load_filter_table() argument 248 mputm (md, R_LOAD_FILTER_TABLE, status); in s_load_filter_table() [all …]
|
H A D | disptab.c | 304 dispatch(int type, char *m, MESG *md) in dispatch() argument 309 dispatchName(type), m, md); in dispatch() 312 mputm(md, R_BAD_MESSAGE); in dispatch() 315 mputm(md, R_BAD_MESSAGE); in dispatch() 317 else if (pd->flags & D_ADMIN && !md->admin) in dispatch() 319 (*pd->fncp) (md, type+1); in dispatch() 321 mputm(md, R_BAD_MESSAGE); in dispatch() 323 else if (pd->flags & D_SYSTEM && md->type != MD_CHILD && in dispatch() 324 md->type != MD_BOUND) in dispatch() 326 (*pd->fncp) (md, type+1); in dispatch() [all …]
|
H A D | disp2.c | 56 s_load_printer(char *m, MESG *md) in s_load_printer() argument 172 mputm (md, R_LOAD_PRINTER, status); in s_load_printer() 215 s_unload_printer(char *m, MESG *md) in s_unload_printer() argument 266 mputm (md, R_UNLOAD_PRINTER, status); in s_unload_printer() 304 local_printer_status(MESG *md, PSTATUS *pps, short status) in local_printer_status() argument 313 send(md, R_INQUIRE_PRINTER_STATUS, status, pps->printer->name, in local_printer_status() 332 s_inquire_printer_status(char *m, MESG *md) in s_inquire_printer_status() argument 347 local_printer_status(md, pps, MOKMORE); in s_inquire_printer_status() 354 local_printer_status(md, pps, MOK); in s_inquire_printer_status() 356 mputm(md, R_INQUIRE_PRINTER_STATUS, MNODEST, "", "", "", "", in s_inquire_printer_status() [all …]
|
H A D | flt.c | 53 add_flt_act(MESG * md, ...) in add_flt_act() argument 58 va_start (arg, md); in add_flt_act() 65 f->ident = md; in add_flt_act() 67 if (md->on_discon == NULL) in add_flt_act() 68 if (mon_discon(md, do_flt_acts)) in add_flt_act() 91 del_flt_act(MESG *md, ...) in del_flt_act() argument 98 va_start(arg, md); in del_flt_act() 103 if (f->next->type == type && f->next->ident == md) in del_flt_act() 115 do_flt_acts(MESG *md) in do_flt_acts() argument 127 if (f->next->ident == md) in do_flt_acts()
|
H A D | disp3.c | 235 s_max_trays(char *m, MESG *md) in s_max_trays() argument 281 mputm(md, R_MAX_TRAYS, status); in s_max_trays() 289 s_mount(char *m, MESG *md) in s_mount() argument 327 mputm(md, R_MOUNT, status); in s_mount() 335 s_mount_tray(char *m, MESG *md) in s_mount_tray() argument 380 mputm (md, R_MOUNT_TRAY, status); in s_mount_tray() 388 s_unmount(char *m, MESG *md) in s_unmount() argument 430 mputm (md, R_UNMOUNT, status); in s_unmount() 438 s_unmount_tray(char *m, MESG *md) in s_unmount_tray() argument 478 mputm (md, R_UNMOUNT_TRAY, status); in s_unmount_tray() [all …]
|
/illumos-gate/usr/src/tools/ctf/stabs/common/ |
H A D | genassym.c | 216 ga_member_cb_data_t *md = arg; in ga_member_cb() local 220 if (strcmp(name, md->gmcb_memname) != 0) in ga_member_cb() 223 md->gmcb_off += off / 8; /* off is in bits */ in ga_member_cb() 225 if (md->gmcb_submem != NULL) { in ga_member_cb() 232 smd.gmcb_memname = md->gmcb_submem; in ga_member_cb() 234 smd.gmcb_offdef = md->gmcb_offdef; in ga_member_cb() 235 smd.gmcb_off = md->gmcb_off; in ga_member_cb() 240 if (md->gmcb_offdef == NULL) { in ga_member_cb() 243 label = md->gmcb_memname; in ga_member_cb() 247 label = md->gmcb_offdef; in ga_member_cb() [all …]
|
/illumos-gate/usr/src/uts/intel/io/vmm/ |
H A D | vmm_sol_dev.c | 422 vmmdev_do_ioctl(vmm_softc_t *sc, int cmd, intptr_t arg, int md, in vmmdev_do_ioctl() argument 472 if (ddi_copyin(datap, &vcpu, sizeof (vcpu), md)) { in vmmdev_do_ioctl() 522 if (ddi_copyin(datap, &vcpu, sizeof (vcpu), md)) { in vmmdev_do_ioctl() 555 if (ddi_copyin(datap, &entry, sizeof (entry), md)) { in vmmdev_do_ioctl() 579 if (ddi_copyout(vme, outp, sizeof (*vme), md)) { in vmmdev_do_ioctl() 588 if (ddi_copyin(datap, &vmsuspend, sizeof (vmsuspend), md)) { in vmmdev_do_ioctl() 598 if (ddi_copyin(datap, &reinit, sizeof (reinit), md)) { in vmmdev_do_ioctl() 616 if (ddi_copyin(datap, &statdesc, sizeof (statdesc), md)) { in vmmdev_do_ioctl() 623 ddi_copyout(&statdesc, datap, sizeof (statdesc), md)) { in vmmdev_do_ioctl() 632 if (ddi_copyin(datap, &vmstats, sizeof (vmstats), md)) { in vmmdev_do_ioctl() [all …]
|
/illumos-gate/usr/src/uts/sun4v/os/ |
H A D | mpo.c | 179 static int valid_pages(md_t *md, mde_cookie_t cpu0); 239 get_int(md_t md, mde_cookie_t node, char *propname, uint64_t *val) in get_int() argument 241 int err = md_get_prop_val(md, node, propname, val); in get_int() 306 cpuid_to_cpunode(md_t *md, int cpuid) in cpuid_to_cpunode() argument 312 if (md == NULL) in cpuid_to_cpunode() 315 rootnode = md_root_node(md); in cpuid_to_cpunode() 319 n_cpunodes = md_alloc_scan_dag(md, rootnode, PROP_LG_CPU, in cpuid_to_cpunode() 325 if (md_get_prop_val(md, cpunodes[i], PROP_LG_CPU_ID, in cpuid_to_cpunode() 330 md_free_scan_dag(md, &cpunodes); in cpuid_to_cpunode() 336 md_free_scan_dag(md, &cpunodes); in cpuid_to_cpunode() [all …]
|
/illumos-gate/usr/src/boot/i386/libi386/ |
H A D | bootinfo32.c | 103 struct file_metadata *md; in bi_copymodules32() local 116 for (md = fp->f_metadata; md != NULL; md = md->md_next) in bi_copymodules32() 117 if (!(md->md_type & MODINFOMD_NOCOPY)) in bi_copymodules32() 118 MOD_METADATA(addr, md, c); in bi_copymodules32() 138 struct file_metadata *md; in bi_load32() local 227 md = file_findmetadata(kfp, MODINFOMD_KERNEND); in bi_load32() 228 bcopy(&kernend, md->md_data, sizeof kernend); in bi_load32() 234 md = file_findmetadata(kfp, MODINFOMD_SSYM); in bi_load32() 235 if (md != NULL) in bi_load32() 236 bcopy(&md->md_data, &ssym, sizeof (vm_offset_t)); in bi_load32() [all …]
|
H A D | bootinfo64.c | 105 struct file_metadata *md; in bi_copymodules64() local 121 for (md = fp->f_metadata; md != NULL; md = md->md_next) in bi_copymodules64() 122 if (!(md->md_type & MODINFOMD_NOCOPY)) in bi_copymodules64() 123 MOD_METADATA(addr, md, c); in bi_copymodules64() 144 struct file_metadata *md; in bi_load64() local 211 md = file_findmetadata(kfp, MODINFOMD_KERNEND); in bi_load64() 212 bcopy(&kernend, md->md_data, sizeof kernend); in bi_load64() 215 md = file_findmetadata(kfp, MODINFOMD_ENVP); in bi_load64() 216 bcopy(&envp, md->md_data, sizeof envp); in bi_load64()
|
/illumos-gate/usr/src/boot/efi/loader/arch/i386/ |
H A D | bootinfo.c | 182 struct file_metadata *md; in bi_copymodules() local 193 for (md = fp->f_metadata; md != NULL; md = md->md_next) { in bi_copymodules() 194 if (!(md->md_type & MODINFOMD_NOCOPY)) in bi_copymodules() 195 MOD_METADATA(addr, md); in bi_copymodules() 213 struct file_metadata *md; in bi_load() local 235 md = file_findmetadata(fp, MODINFOMD_SSYM); in bi_load() 236 ssym = (md != NULL) ? *((vm_offset_t *)&(md->md_data)) : 0; in bi_load() 237 md = file_findmetadata(fp, MODINFOMD_ESYM); in bi_load() 238 esym = (md != NULL) ? *((vm_offset_t *)&(md->md_data)) : 0; in bi_load()
|
/illumos-gate/usr/src/cmd/smbios/ |
H A D | smbios.c | 1039 smbios_memdevice_t md; in print_memdevice() local 1041 if (smbios_info_memdevice(shp, id, &md) != 0) { in print_memdevice() 1046 id_printf(fp, " Physical Memory Array: ", md.smbmd_array); in print_memdevice() 1047 id_printf(fp, " Memory Error Data: ", md.smbmd_error); in print_memdevice() 1049 if (md.smbmd_twidth != -1u) in print_memdevice() 1050 oprintf(fp, " Total Width: %u bits\n", md.smbmd_twidth); in print_memdevice() 1054 if (md.smbmd_dwidth != -1u) in print_memdevice() 1055 oprintf(fp, " Data Width: %u bits\n", md.smbmd_dwidth); in print_memdevice() 1059 switch (md.smbmd_size) { in print_memdevice() 1068 (u_longlong_t)md.smbmd_size); in print_memdevice() [all …]
|
/illumos-gate/usr/src/boot/common/ |
H A D | module.c | 229 struct file_metadata *md; in command_lsmod() local 306 for (md = fp->f_metadata; md != NULL; in command_lsmod() 307 md = md->md_next) { in command_lsmod() 310 md->md_type, (long)md->md_size); in command_lsmod() 370 struct file_metadata *md; in file_load_dependencies() local 377 md = file_findmetadata(base_file, MODINFOMD_DEPLIST); in file_load_dependencies() 378 if (md == NULL) in file_load_dependencies() 382 verinfo = (struct mod_depend *)md->md_data; in file_load_dependencies() 404 md = metadata_next(md, MODINFOMD_DEPLIST); in file_load_dependencies() 405 } while (md); in file_load_dependencies() [all …]
|
/illumos-gate/usr/src/lib/krb5/plugins/preauth/pkinit/ |
H A D | pkinit_matching.c | 485 pkinit_cert_matching_data *md) in component_match() argument 496 match = regexp_match(context, rc, md->subject_dn); in component_match() 499 match = regexp_match(context, rc, md->issuer_dn); in component_match() 502 if (md->sans == NULL) in component_match() 504 for (i = 0, p = md->sans[i]; p != NULL; p = md->sans[++i]) { in component_match() 524 rc->eku_bits, md->eku_bits); in component_match() 525 if ((rc->eku_bits & md->eku_bits) == rc->eku_bits) in component_match() 531 rc->ku_bits, md->ku_bits); in component_match() 532 if ((rc->ku_bits & md->ku_bits) == rc->ku_bits) in component_match() 567 pkinit_cert_matching_data *md; in check_all_certs() local [all …]
|
/illumos-gate/usr/src/uts/intel/io/viona/ |
H A D | viona_main.c | 559 viona_ioctl(dev_t dev, int cmd, intptr_t data, int md, cred_t *cr, int *rv) in viona_ioctl() argument 573 return (viona_ioc_create(ss, dptr, md, cr)); in viona_ioctl() 585 return (viona_ioc_get_params(NULL, dptr, md)); in viona_ioctl() 600 if (ddi_copyout(&val, dptr, sizeof (val), md) != 0) { in viona_ioctl() 605 if (ddi_copyin(dptr, &val, sizeof (val), md) != 0) { in viona_ioctl() 620 err = viona_ioc_ring_init(link, dptr, md); in viona_ioctl() 629 err = viona_ioc_ring_set_msi(link, dptr, md); in viona_ioctl() 635 err = viona_ioc_ring_set_state(link, dptr, md); in viona_ioctl() 638 err = viona_ioc_ring_get_state(link, dptr, md); in viona_ioctl() 645 err = viona_ioc_intr_poll(link, dptr, md, rv); in viona_ioctl() [all …]
|