Lines Matching defs:gref

87 	gref_t *gref;
96 if ((sp == 0) || (sp->gref==0) || (sp->state==sClosed))
125 adsp_rput(sp->gref, mp);
136 gref = (gref_t *)((ioc_t *)gbuf_rptr(mp))->ioc_private;
150 adsp_rput(gref, mp);
156 int adsp_readable(gref)
157 gref_t *gref;
162 if (gref->info == 0)
169 * this if it can't retrieve the 'gref' structure from the
174 sp = (CCBPtr)gbuf_rptr(((gbuf_t *)gref->info));
181 int adsp_writeable(gref)
182 gref_t *gref;
187 if (gref->info == 0)
194 * this if it can't retrieve the 'gref' structure from the
199 sp = (CCBPtr)gbuf_rptr(((gbuf_t *)gref->info));
224 int adsp_open(gref)
225 gref_t *gref;
232 if (!adspAllocateCCB(gref))
235 sp = (CCBPtr)gbuf_rptr(((gbuf_t *)gref->info));
236 gref->readable = adsp_readable;
237 gref->writeable = adsp_writeable;
244 int adsp_close(gref)
245 gref_t *gref;
250 if (gref->info) {
251 CCBPtr sp = (CCBPtr)gbuf_rptr(((gbuf_t *)gref->info));
254 adspRelease(gref);
258 gbuf_freeb((gbuf_t *)gref->info);
273 void adsp_rput(gref, mp)
274 gref_t *gref; /* READ queue */
281 switch (adspReadHandler(gref, mp)) {
283 atalk_putnext(gref, mp);
295 CheckReadQueue((CCBPtr)gbuf_rptr(((gbuf_t *)gref->info)));
296 CheckSend((CCBPtr)gbuf_rptr(((gbuf_t *)gref->info)));
302 if (adspReadHandler(gref, mp) == STR_PUTNEXT)
303 atalk_putnext(gref, mp);
306 atalk_putnext(gref, mp);
321 int adsp_wput(gref, mp)
322 gref_t *gref; /* WRITE queue */
330 if (gref->info)
331 sp = (CCBPtr)gbuf_rptr(((gbuf_t *)gref->info));
344 adsp_iocnak(gref, mp, EINVAL);
351 adsp_iocnak(gref, mp, EINVAL);
355 if ((v = adspAssignSocket(gref, 0)) == 0) {
357 adsp_iocnak(gref, mp, EINVAL);
369 adsp_iocack(gref, mp);
382 adsp_iocnak(gref, mp, ENOBUFS);
403 adsp_iocack(gref, mp);
411 adsp_iocnak(gref, mp, ENOBUFS);
427 adsp_iocack(gref, mp);
432 if (!gref->info)
435 rc = adspWriteHandler(gref, mp);
441 iocbp->ioc_private = (void *)gref;
457 void adspioc_ack(errno, m, gref)
460 gref_t *gref;
474 SndMsgUp(gref, m);
477 static void adsp_iocack(gref, m)
478 gref_t *gref;
489 SndMsgUp(gref, m);
493 static void adsp_iocnak(gref, m, err)
494 gref_t *gref;
510 SndMsgUp(gref, m);
514 adspAssignSocket(gref, flag)
515 gref_t *gref;
542 sp = (CCBPtr)gbuf_rptr(((gbuf_t *)gref->info));
614 void SndMsgUp(gref, mp)
615 gref_t *gref; /* WRITE queue */
620 ("SndMsgUp: gref=0x%x, mbuf=0x%x\n", (unsigned)gref, (unsigned)mp));
623 atalk_putnext(gref, mp);