![]() |
|
|||
0001 /* SPDX-License-Identifier: GPL-2.0-or-later */ 0002 /*************************************************************************** 0003 * 0004 * Copyright (C) 2004-2008 SMSC 0005 * Copyright (C) 2005-2008 ARM 0006 * 0007 ***************************************************************************/ 0008 #ifndef __LINUX_SMSC911X_H__ 0009 #define __LINUX_SMSC911X_H__ 0010 0011 #include <linux/phy.h> 0012 #include <linux/if_ether.h> 0013 0014 /* platform_device configuration data, should be assigned to 0015 * the platform_device's dev.platform_data */ 0016 struct smsc911x_platform_config { 0017 unsigned int irq_polarity; 0018 unsigned int irq_type; 0019 unsigned int flags; 0020 unsigned int shift; 0021 phy_interface_t phy_interface; 0022 unsigned char mac[ETH_ALEN]; 0023 }; 0024 0025 /* Constants for platform_device irq polarity configuration */ 0026 #define SMSC911X_IRQ_POLARITY_ACTIVE_LOW 0 0027 #define SMSC911X_IRQ_POLARITY_ACTIVE_HIGH 1 0028 0029 /* Constants for platform_device irq type configuration */ 0030 #define SMSC911X_IRQ_TYPE_OPEN_DRAIN 0 0031 #define SMSC911X_IRQ_TYPE_PUSH_PULL 1 0032 0033 /* Constants for flags */ 0034 #define SMSC911X_USE_16BIT (BIT(0)) 0035 #define SMSC911X_USE_32BIT (BIT(1)) 0036 #define SMSC911X_FORCE_INTERNAL_PHY (BIT(2)) 0037 #define SMSC911X_FORCE_EXTERNAL_PHY (BIT(3)) 0038 #define SMSC911X_SAVE_MAC_ADDRESS (BIT(4)) 0039 0040 /* 0041 * SMSC911X_SWAP_FIFO: 0042 * Enables software byte swap for fifo data. Should only be used as a 0043 * "last resort" in the case of big endian mode on boards with incorrectly 0044 * routed data bus to older devices such as LAN9118. Newer devices such as 0045 * LAN9221 can handle this in hardware, there are registers to control 0046 * this swapping but the driver doesn't currently use them. 0047 */ 0048 #define SMSC911X_SWAP_FIFO (BIT(5)) 0049 0050 #endif /* __LINUX_SMSC911X_H__ */
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.1.0 LXR engine. The LXR team |
![]() ![]() |