1/* 2 * Generic Broadcom Home Networking Division (HND) PIO engine HW interface 3 * This supports the following chips: BCM42xx, 44xx, 47xx . 4 * 5 * Copyright (C) 2015, Broadcom Corporation. All Rights Reserved. 6 * 7 * Permission to use, copy, modify, and/or distribute this software for any 8 * purpose with or without fee is hereby granted, provided that the above 9 * copyright notice and this permission notice appear in all copies. 10 * 11 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 12 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 13 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY 14 * SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 15 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION 16 * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 17 * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 18 * $Id: sbhndpio.h 419467 2013-08-21 09:19:48Z $ 19 */ 20 21#ifndef _sbhndpio_h_ 22#define _sbhndpio_h_ 23 24/* PIO structure, 25 * support two PIO format: 2 bytes access and 4 bytes access 26 * basic FIFO register set is per channel(transmit or receive) 27 * a pair of channels is defined for convenience 28 */ 29 30/* 2byte-wide pio register set per channel(xmt or rcv) */ 31typedef volatile struct { 32 uint16 fifocontrol; 33 uint16 fifodata; 34 uint16 fifofree; /* only valid in xmt channel, not in rcv channel */ 35 uint16 PAD; 36} pio2regs_t; 37 38/* a pair of pio channels(tx and rx) */ 39typedef volatile struct { 40 pio2regs_t tx; 41 pio2regs_t rx; 42} pio2regp_t; 43 44/* 4byte-wide pio register set per channel(xmt or rcv) */ 45typedef volatile struct { 46 uint32 fifocontrol; 47 uint32 fifodata; 48} pio4regs_t; 49 50/* a pair of pio channels(tx and rx) */ 51typedef volatile struct { 52 pio4regs_t tx; 53 pio4regs_t rx; 54} pio4regp_t; 55 56#endif /* _sbhndpio_h_ */ 57