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/dev/sound/sbus/apcdmareg.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 /*      $FreeBSD$       */
    2 /*      $OpenBSD: apcdmareg.h,v 1.2 2003/06/02 18:53:18 jason Exp $     */
    3 
    4 /*-
    5  * Copyright (c) 2001 Jason L. Wright (jason@thought.net)
    6  * All rights reserved.
    7  *
    8  * Redistribution and use in source and binary forms, with or without
    9  * modification, are permitted provided that the following conditions
   10  * are met:
   11  * 1. Redistributions of source code must retain the above copyright
   12  *    notice, this list of conditions and the following disclaimer.
   13  * 2. Redistributions in binary form must reproduce the above copyright
   14  *    notice, this list of conditions and the following disclaimer in the
   15  *    documentation and/or other materials provided with the distribution.
   16  *
   17  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
   18  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
   19  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   20  * DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
   21  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
   22  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
   23  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
   24  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
   25  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
   26  * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
   27  * POSSIBILITY OF SUCH DAMAGE.
   28  */
   29 
   30 /*
   31  * Definitions for Sun APC DMA controller.
   32  */
   33 
   34 /* APC DMA registers */
   35 #define APC_CSR         0x0010          /* control/status */
   36 #define APC_CVA         0x0020          /* capture virtual address */
   37 #define APC_CC          0x0024          /* capture count */
   38 #define APC_CNVA        0x0028          /* capture next virtual address */
   39 #define APC_CNC         0x002c          /* capture next count */
   40 #define APC_PVA         0x0030          /* playback virtual address */
   41 #define APC_PC          0x0034          /* playback count */
   42 #define APC_PNVA        0x0038          /* playback next virtual address */
   43 #define APC_PNC         0x003c          /* playback next count */
   44 
   45 /*
   46  * APC DMA Register definitions
   47  */
   48 #define APC_CSR_RESET           0x00000001      /* reset */
   49 #define APC_CSR_CDMA_GO         0x00000004      /* capture dma go */
   50 #define APC_CSR_PDMA_GO         0x00000008      /* playback dma go */
   51 #define APC_CSR_CODEC_RESET     0x00000020      /* codec reset */
   52 #define APC_CSR_CPAUSE          0x00000040      /* capture dma pause */
   53 #define APC_CSR_PPAUSE          0x00000080      /* playback dma pause */
   54 #define APC_CSR_CMIE            0x00000100      /* capture pipe empty enb */
   55 #define APC_CSR_CMI             0x00000200      /* capture pipe empty intr */
   56 #define APC_CSR_CD              0x00000400      /* capture nva dirty */
   57 #define APC_CSR_CM              0x00000800      /* capture data lost */
   58 #define APC_CSR_PMIE            0x00001000      /* pb pipe empty intr enable */
   59 #define APC_CSR_PD              0x00002000      /* pb nva dirty */
   60 #define APC_CSR_PM              0x00004000      /* pb pipe empty */
   61 #define APC_CSR_PMI             0x00008000      /* pb pipe empty interrupt */
   62 #define APC_CSR_EIE             0x00010000      /* error interrupt enable */
   63 #define APC_CSR_CIE             0x00020000      /* capture intr enable */
   64 #define APC_CSR_PIE             0x00040000      /* playback intr enable */
   65 #define APC_CSR_GIE             0x00080000      /* general intr enable */
   66 #define APC_CSR_EI              0x00100000      /* error interrupt */
   67 #define APC_CSR_CI              0x00200000      /* capture interrupt */
   68 #define APC_CSR_PI              0x00400000      /* playback interrupt */
   69 #define APC_CSR_GI              0x00800000      /* general interrupt */
   70 
   71 #define APC_CSR_PLAY                    ( \
   72                 APC_CSR_EI              | \
   73                 APC_CSR_GIE             | \
   74                 APC_CSR_PIE             | \
   75                 APC_CSR_EIE             | \
   76                 APC_CSR_PDMA_GO         | \
   77                 APC_CSR_PMIE            )
   78 
   79 #define APC_CSR_CAPTURE                 ( \
   80                 APC_CSR_EI              | \
   81                 APC_CSR_GIE             | \
   82                 APC_CSR_CIE             | \
   83                 APC_CSR_EIE             | \
   84                 APC_CSR_CDMA_GO )
   85 
   86 #define APC_CSR_PLAY_PAUSE              (~( \
   87                 APC_CSR_PPAUSE          | \
   88                 APC_CSR_GI              | \
   89                 APC_CSR_PI              | \
   90                 APC_CSR_CI              | \
   91                 APC_CSR_EI              | \
   92                 APC_CSR_PMI             | \
   93                 APC_CSR_PMIE            | \
   94                 APC_CSR_CMI             | \
   95                 APC_CSR_CMIE            ) )
   96 
   97 #define APC_CSR_CAPTURE_PAUSE           (~( \
   98                 APC_CSR_PPAUSE          | \
   99                 APC_CSR_GI              | \
  100                 APC_CSR_PI              | \
  101                 APC_CSR_CI              | \
  102                 APC_CSR_EI              | \
  103                 APC_CSR_PMI             | \
  104                 APC_CSR_PMIE            | \
  105                 APC_CSR_CMI             | \
  106                 APC_CSR_CMIE            ) )
  107 
  108 #define APC_CSR_INTR_MASK               ( \
  109                 APC_CSR_GI              | \
  110                 APC_CSR_PI              | \
  111                 APC_CSR_CI              | \
  112                 APC_CSR_EI              | \
  113                 APC_CSR_PMI             | \
  114                 APC_CSR_CMI             )

Cache object: bdba33dd689e92a370acc19b938b6676


[ 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.