The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/device/buf.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /* 
    2  * Mach Operating System
    3  * Copyright (c) 1991,1990,1989 Carnegie Mellon University
    4  * All Rights Reserved.
    5  * 
    6  * Permission to use, copy, modify and distribute this software and its
    7  * documentation is hereby granted, provided that both the copyright
    8  * notice and this permission notice appear in all copies of the
    9  * software, derivative works or modified versions, and any portions
   10  * thereof, and that both notices appear in supporting documentation.
   11  * 
   12  * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
   13  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
   14  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
   15  * 
   16  * Carnegie Mellon requests users of this software to return to
   17  * 
   18  *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
   19  *  School of Computer Science
   20  *  Carnegie Mellon University
   21  *  Pittsburgh PA 15213-3890
   22  * 
   23  * any improvements or extensions that they make and grant Carnegie Mellon
   24  * the rights to redistribute these changes.
   25  */
   26 /*
   27  * HISTORY
   28  * $Log:        buf.h,v $
   29  * Revision 2.4  91/05/14  15:38:51  mrt
   30  *      Correcting copyright
   31  * 
   32  * Revision 2.3  91/02/05  17:07:51  mrt
   33  *      Changed to new Mach copyright
   34  *      [91/01/31  17:26:11  mrt]
   35  * 
   36  * Revision 2.2  90/05/03  15:19:05  dbg
   37  *      Add B_MD1.
   38  *      [90/03/14            dbg]
   39  * 
   40  */
   41 /*
   42  *      Author: David B. Golub, Carnegie Mellon University
   43  *      Date:   3/90
   44  *
   45  *      Definitions to make new IO structures look like old ones
   46  */
   47 
   48 /*
   49  * io_req and fields
   50  */
   51 #include <device/io_req.h>
   52 
   53 #define buf     io_req
   54 
   55 /*
   56  * Redefine fields for drivers using old names
   57  */
   58 #define b_flags         io_op
   59 #define b_bcount        io_count
   60 #define b_error         io_error
   61 #define b_dev           io_unit
   62 #define b_blkno         io_recnum
   63 #define b_resid         io_residual
   64 #define b_un            io_un
   65 #define b_addr          data
   66 #define av_forw         io_next
   67 #define av_back         io_prev
   68 
   69 /*
   70  * Redefine fields for driver request list heads, using old names.
   71  */
   72 #define b_actf          io_next
   73 #define b_actl          io_prev
   74 #define b_forw          io_link
   75 #define b_back          io_rlink
   76 #define b_active        io_count
   77 #define b_errcnt        io_residual
   78 #define b_bufsize       io_alloc_size
   79 
   80 /*
   81  * Redefine flags
   82  */
   83 #define B_WRITE         IO_WRITE
   84 #define B_READ          IO_READ
   85 #define B_OPEN          IO_OPEN
   86 #define B_DONE          IO_DONE
   87 #define B_ERROR         IO_ERROR
   88 #define B_BUSY          IO_BUSY
   89 #define B_WANTED        IO_WANTED
   90 #define B_BAD           IO_BAD
   91 #define B_CALL          IO_CALL
   92 
   93 #define B_MD1           IO_SPARE_START
   94 
   95 /*
   96  * Redefine uio structure
   97  */
   98 #define uio     io_req
   99 
  100 /*
  101  * Redefine physio routine
  102  */
  103 #define physio(strat, xbuf, dev, ops, minphys, ior) \
  104                 block_io(strat, minphys, ior)
  105 
  106 /*
  107  * Export standard minphys routine.
  108  */
  109 extern  minphys();
  110 
  111 /*
  112  * Alternate name for iodone
  113  */
  114 #define biodone iodone
  115 #define biowait iowait

Cache object: 95067bebd546a06711118b480c07f804


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.