![]() |
|
|||
0001 /***********************license start*************** 0002 * Author: Cavium Networks 0003 * 0004 * Contact: support@caviumnetworks.com 0005 * This file is part of the OCTEON SDK 0006 * 0007 * Copyright (c) 2003-2008 Cavium Networks 0008 * 0009 * This file is free software; you can redistribute it and/or modify 0010 * it under the terms of the GNU General Public License, Version 2, as 0011 * published by the Free Software Foundation. 0012 * 0013 * This file is distributed in the hope that it will be useful, but 0014 * AS-IS and WITHOUT ANY WARRANTY; without even the implied warranty 0015 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE, TITLE, or 0016 * NONINFRINGEMENT. See the GNU General Public License for more 0017 * details. 0018 * 0019 * You should have received a copy of the GNU General Public License 0020 * along with this file; if not, write to the Free Software 0021 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 0022 * or visit http://www.gnu.org/licenses/. 0023 * 0024 * This file may also be available under a different license from Cavium. 0025 * Contact Cavium Networks for more information 0026 ***********************license end**************************************/ 0027 0028 /* 0029 * Packet buffer defines. 0030 */ 0031 0032 #ifndef __CVMX_PACKET_H__ 0033 #define __CVMX_PACKET_H__ 0034 0035 /** 0036 * This structure defines a buffer pointer on Octeon 0037 */ 0038 union cvmx_buf_ptr { 0039 void *ptr; 0040 uint64_t u64; 0041 struct { 0042 #ifdef __BIG_ENDIAN_BITFIELD 0043 /* if set, invert the "free" pick of the overall 0044 * packet. HW always sets this bit to 0 on inbound 0045 * packet */ 0046 uint64_t i:1; 0047 0048 /* Indicates the amount to back up to get to the 0049 * buffer start in cache lines. In most cases this is 0050 * less than one complete cache line, so the value is 0051 * zero */ 0052 uint64_t back:4; 0053 /* The pool that the buffer came from / goes to */ 0054 uint64_t pool:3; 0055 /* The size of the segment pointed to by addr (in bytes) */ 0056 uint64_t size:16; 0057 /* Pointer to the first byte of the data, NOT buffer */ 0058 uint64_t addr:40; 0059 #else 0060 uint64_t addr:40; 0061 uint64_t size:16; 0062 uint64_t pool:3; 0063 uint64_t back:4; 0064 uint64_t i:1; 0065 #endif 0066 } s; 0067 }; 0068 0069 #endif /* __CVMX_PACKET_H__ */
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.1.0 LXR engine. The LXR team |
![]() ![]() |