Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Neil Armstrong | ef441cb | 2017-11-27 10:16:16 +0100 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (C) 2016 BayLibre, SAS |
| 4 | * Author: Neil Armstrong <narmstrong@baylibre.com> |
Neil Armstrong | ef441cb | 2017-11-27 10:16:16 +0100 | [diff] [blame] | 5 | */ |
| 6 | |
| 7 | #ifndef __MESON_ETH_H__ |
| 8 | #define __MESON_ETH_H__ |
| 9 | |
| 10 | #include <phy.h> |
| 11 | |
| 12 | enum { |
Jerome Brunet | f897c4b | 2018-10-05 17:00:37 +0200 | [diff] [blame] | 13 | /* Use Internal RMII PHY */ |
| 14 | MESON_USE_INTERNAL_RMII_PHY = 1, |
Neil Armstrong | ef441cb | 2017-11-27 10:16:16 +0100 | [diff] [blame] | 15 | }; |
| 16 | |
| 17 | /* Configure the Ethernet MAC with the requested interface mode |
| 18 | * with some optional flags. |
| 19 | */ |
Jerome Brunet | f897c4b | 2018-10-05 17:00:37 +0200 | [diff] [blame] | 20 | void meson_eth_init(phy_interface_t mode, unsigned int flags); |
Neil Armstrong | ef441cb | 2017-11-27 10:16:16 +0100 | [diff] [blame] | 21 | |
Neil Armstrong | b4acf5a | 2019-06-12 11:49:07 +0200 | [diff] [blame] | 22 | /* Generate an unique MAC address based on the HW serial */ |
| 23 | int meson_generate_serial_ethaddr(void); |
| 24 | |
Neil Armstrong | ef441cb | 2017-11-27 10:16:16 +0100 | [diff] [blame] | 25 | #endif /* __MESON_ETH_H__ */ |