/[hurd]/hurd/trans/fakeroot.c
ViewVC logotype

Diff of /hurd/trans/fakeroot.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.9 by roland, Sun May 12 19:55:41 2002 UTC revision 1.10 by marcus, Mon May 13 02:16:25 2002 UTC
# Line 589  netfs_S_io_map (struct protid *user, Line 589  netfs_S_io_map (struct protid *user,
589    return err;    return err;
590  }  }
591    
592    error_t
593    netfs_S_io_map_cntl (struct protid *user,
594                         mach_port_t *obj,
595                         mach_msg_type_name_t *objtype)
596    {
597      error_t err;
598    
599      if (!user)
600        return EOPNOTSUPP;
601      *objtype = MACH_MSG_TYPE_MOVE_SEND;
602    
603      mutex_lock (&user->po->np->lock);
604      err = io_map_cntl (user->po->np->nn->file, obj);
605      mutex_unlock (&user->po->np->lock);
606      return err;
607    }
608    
609    #define NETFS_S_SIMPLE(name)                    \
610    error_t                                         \
611    netfs_S_##name (struct protid *user)            \
612    {                                               \
613      error_t err;                                  \
614                                                    \
615      if (!user)                                    \
616        return EOPNOTSUPP;                          \
617                                                    \
618      mutex_lock (&user->po->np->lock);             \
619      err = name (user->po->np->nn->file);          \
620      mutex_unlock (&user->po->np->lock);           \
621      return err;                                   \
622    }
623    
624    NETFS_S_SIMPLE (io_get_conch)
625    NETFS_S_SIMPLE (io_release_conch)
626    NETFS_S_SIMPLE (io_eofnotify)
627    NETFS_S_SIMPLE (io_readnotify)
628    NETFS_S_SIMPLE (io_readsleep)
629    NETFS_S_SIMPLE (io_sigio)
630    
631    error_t
632    netfs_S_io_prenotify (struct protid *user,
633                          vm_offset_t start, vm_offset_t stop)
634    {
635      error_t err;
636    
637      if (!user)
638        return EOPNOTSUPP;
639    
640      mutex_lock (&user->po->np->lock);
641      err = io_get_prenotify (user->po->np->nn->file, start, stop);
642      mutex_unlock (&user->po->np->lock);
643      return err;
644    }
645    
646    error_t
647    netfs_S_io_postnotify (struct protid *user,
648                           vm_offset_t start, vm_offset_t stop)
649    {
650      error_t err;
651    
652      if (!user)
653        return EOPNOTSUPP;
654    
655      mutex_lock (&user->po->np->lock);
656      err = io_get_postnotify (user->po->np->nn->file, start, stop);
657      mutex_unlock (&user->po->np->lock);
658      return err;
659    }
660    
661  /* This overrides the library's definition.  */  /* This overrides the library's definition.  */
662  int  int
663  netfs_demuxer (mach_msg_header_t *inp,  netfs_demuxer (mach_msg_header_t *inp,

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26