blob: f765cd7c4ca1ba4c0bbc9bbb694017b229fab669 [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Neil Armstrongef441cb2017-11-27 10:16:16 +01002/*
3 * Copyright (C) 2016 BayLibre, SAS
4 * Author: Neil Armstrong <narmstrong@baylibre.com>
Neil Armstrongef441cb2017-11-27 10:16:16 +01005 */
6
7#ifndef __MESON_ETH_H__
8#define __MESON_ETH_H__
9
10#include <phy.h>
11
12enum {
Jerome Brunetf897c4b2018-10-05 17:00:37 +020013 /* Use Internal RMII PHY */
14 MESON_USE_INTERNAL_RMII_PHY = 1,
Neil Armstrongef441cb2017-11-27 10:16:16 +010015};
16
17/* Configure the Ethernet MAC with the requested interface mode
18 * with some optional flags.
19 */
Jerome Brunetf897c4b2018-10-05 17:00:37 +020020void meson_eth_init(phy_interface_t mode, unsigned int flags);
Neil Armstrongef441cb2017-11-27 10:16:16 +010021
Neil Armstrongb4acf5a2019-06-12 11:49:07 +020022/* Generate an unique MAC address based on the HW serial */
23int meson_generate_serial_ethaddr(void);
24
Neil Armstrongef441cb2017-11-27 10:16:16 +010025#endif /* __MESON_ETH_H__ */