[BACK]Return to framebuf.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / lib / libpuffs

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/lib/libpuffs/framebuf.c between version 1.20 and 1.20.2.1

version 1.20, 2007/08/25 09:30:41 version 1.20.2.1, 2007/11/06 23:11:51
Line 472  puffs_framev_enqueue_directsend(struct p
Line 472  puffs_framev_enqueue_directsend(struct p
         return 0;          return 0;
 }  }
   
 /*  
  * this beauty shall remain undocumented for now  
  */  
 int  int
 puffs_framev_framebuf_ccpromote(struct puffs_framebuf *pufbuf,  puffs_framev_framebuf_ccpromote(struct puffs_framebuf *pufbuf,
         struct puffs_cc *pcc)          struct puffs_cc *pcc)
Line 588  findbuf(struct puffs_usermount *pu, stru
Line 585  findbuf(struct puffs_usermount *pu, stru
         struct puffs_fctrl_io *fio, struct puffs_framebuf *findme)          struct puffs_fctrl_io *fio, struct puffs_framebuf *findme)
 {  {
         struct puffs_framebuf *cand;          struct puffs_framebuf *cand;
           int notresp = 0;
   
         TAILQ_FOREACH(cand, &fio->res_qing, pfb_entries)          TAILQ_FOREACH(cand, &fio->res_qing, pfb_entries)
                 if (fctrl->cmpfb(pu, findme, cand) == 0)                  if (fctrl->cmpfb(pu, findme, cand, &notresp) == 0 || notresp)
                         break;                          break;
   
         if (cand == NULL)          assert(!(notresp && cand == NULL));
           if (notresp || cand == NULL)
                 return NULL;                  return NULL;
   
         TAILQ_REMOVE(&fio->res_qing, cand, pfb_entries);          TAILQ_REMOVE(&fio->res_qing, cand, pfb_entries);
Line 655  puffs_framev_input(struct puffs_usermoun
Line 654  puffs_framev_input(struct puffs_usermoun
                 if ((pufbuf->istat & ISTAT_DIRECT) == 0) {                  if ((pufbuf->istat & ISTAT_DIRECT) == 0) {
                         appbuf = findbuf(pu, fctrl, fio, pufbuf);                          appbuf = findbuf(pu, fctrl, fio, pufbuf);
   
                         /* XXX: error delivery? */                          /*
                            * No request for this frame?  If fs implements
                            * gotfb, give frame to that.  Otherwise drop it.
                            */
                         if (appbuf == NULL) {                          if (appbuf == NULL) {
                                 /* errno = ENOMSG; */                                  if (fctrl->gotfb)
                                 return;                                          fctrl->gotfb(pu, pufbuf);
   
                                   /* XXX: ugly */
                                   pufbuf->istat &= ~ISTAT_NODESTROY;
                                   fio->cur_in = NULL;
                                   puffs_framebuf_destroy(pufbuf);
                                   continue;
                         }                          }
   
                         moveinfo(pufbuf, appbuf);                          moveinfo(pufbuf, appbuf);
Line 992  puffs_framev_unmountonclose(struct puffs
Line 1000  puffs_framev_unmountonclose(struct puffs
 void  void
 puffs_framev_init(struct puffs_usermount *pu,  puffs_framev_init(struct puffs_usermount *pu,
         puffs_framev_readframe_fn rfb, puffs_framev_writeframe_fn wfb,          puffs_framev_readframe_fn rfb, puffs_framev_writeframe_fn wfb,
         puffs_framev_cmpframe_fn cmpfb, puffs_framev_fdnotify_fn fdnotfn)          puffs_framev_cmpframe_fn cmpfb, puffs_framev_gotframe_fn gotfb,
           puffs_framev_fdnotify_fn fdnotfn)
 {  {
         struct puffs_framectrl *pfctrl;          struct puffs_framectrl *pfctrl;
   
Line 1000  puffs_framev_init(struct puffs_usermount
Line 1009  puffs_framev_init(struct puffs_usermount
         pfctrl->rfb = rfb;          pfctrl->rfb = rfb;
         pfctrl->wfb = wfb;          pfctrl->wfb = wfb;
         pfctrl->cmpfb = cmpfb;          pfctrl->cmpfb = cmpfb;
           pfctrl->gotfb = gotfb;
         pfctrl->fdnotfn = fdnotfn;          pfctrl->fdnotfn = fdnotfn;
 }  }
   

Legend:
Removed from v.1.20  
changed lines
  Added in v.1.20.2.1

CVSweb <webmaster@jp.NetBSD.org>