Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-or-later */
0002 /*
0003  * Copyright (C) 2001 Mike Corrigan & Dave Engebretsen, IBM Corporation
0004  * Rewrite, cleanup:
0005  * Copyright (C) 2004 Olof Johansson <olof@lixom.net>, IBM Corporation
0006  */
0007 
0008 #ifndef _ASM_POWERPC_TCE_H
0009 #define _ASM_POWERPC_TCE_H
0010 #ifdef __KERNEL__
0011 
0012 #include <asm/iommu.h>
0013 
0014 /*
0015  * Tces come in two formats, one for the virtual bus and a different
0016  * format for PCI.  PCI TCEs can have hardware or software maintianed
0017  * coherency.
0018  */
0019 #define TCE_VB          0
0020 #define TCE_PCI         1
0021 
0022 #define TCE_ENTRY_SIZE      8       /* each TCE is 64 bits */
0023 #define TCE_VALID       0x800       /* TCE valid */
0024 #define TCE_ALLIO       0x400       /* TCE valid for all lpars */
0025 #define TCE_PCI_WRITE       0x2     /* write from PCI allowed */
0026 #define TCE_PCI_READ        0x1     /* read from PCI allowed */
0027 #define TCE_VB_WRITE        0x1     /* write from VB allowed */
0028 
0029 #endif /* __KERNEL__ */
0030 #endif /* _ASM_POWERPC_TCE_H */