drivers: ethernet: Add DTS support for Stellaris Ethernet controller.

* Add DTS support for Stellaris ethernet controller.
  * Add base DTS binding definition for Ethernet.
  * Add DTS binding definition for Stellaris ethernet controller.

Signed-off-by: Fadhel Habeeb <fadhel@zilogic.com>
Signed-off-by: Nirav Parmar <niravparmar@zilogic.com>
Signed-off-by: Vijay Kumar B <vijaykumar@zilogic.com>
This commit is contained in:
Vijay Kumar B 2018-09-19 15:23:59 +05:30 committed by Kumar Gala
commit 392be3a8b3
4 changed files with 54 additions and 0 deletions

View file

@ -36,3 +36,7 @@
status = "ok";
current-speed = <115200>;
};
&eth {
status = "ok";
};

View file

@ -47,6 +47,15 @@
status = "disabled";
label = "UART_2";
};
eth: ethernet@40048000 {
compatible = "ti,stellaris-ethernet";
reg = <0x40048000 0x3c>;
interrupts = <42 0>;
status = "disabled";
local-mac-address = [00 00 94 00 83 00];
label = "ETH";
};
};
};

View file

@ -0,0 +1,31 @@
#
# Copyright (c) 2018 Zilogic Systems
# SPDX-License-Identifier: Apache-2.0
#
---
title: TI Stellaris Ethernet
version: 0.1
description: >
This binding gives a base representation of the TI Stellaris Ethernet
inherits:
!include ethernet.yaml
properties:
compatible:
type: string
category: required
description: compatible strings
constraint: "ti,stellaris-ethernet"
reg:
type: array
description: mmio register space
generation: define
category: required
interrupts:
type: array
category: required
description: required interrupts
generation: define
...

View file

@ -1,5 +1,15 @@
/* SoC level DTS fixup file */
#define DT_NUM_IRQ_PRIO_BITS DT_ARM_V7M_NVIC_E000E100_ARM_NUM_IRQ_PRIORITY_BITS
#define DT_ETH_BASE_ADDR DT_TI_STELLARIS_ETHERNET_40048000_BASE_ADDRESS
#define DT_ETH_DRV_NAME DT_TI_STELLARIS_ETHERNET_40048000_LABEL
#define DT_ETH_IRQ DT_TI_STELLARIS_ETHERNET_40048000_IRQ_0
#define DT_ETH_IRQ_PRIO DT_TI_STELLARIS_ETHERNET_40048000_IRQ_0_PRIORITY
#define DT_ETH_MAC_ADDR_0 DT_TI_STELLARIS_ETHERNET_40048000_LOCAL_MAC_ADDRESS_0
#define DT_ETH_MAC_ADDR_1 DT_TI_STELLARIS_ETHERNET_40048000_LOCAL_MAC_ADDRESS_1
#define DT_ETH_MAC_ADDR_2 DT_TI_STELLARIS_ETHERNET_40048000_LOCAL_MAC_ADDRESS_2
#define DT_ETH_MAC_ADDR_3 DT_TI_STELLARIS_ETHERNET_40048000_LOCAL_MAC_ADDRESS_3
#define DT_ETH_MAC_ADDR_4 DT_TI_STELLARIS_ETHERNET_40048000_LOCAL_MAC_ADDRESS_4
#define DT_ETH_MAC_ADDR_5 DT_TI_STELLARIS_ETHERNET_40048000_LOCAL_MAC_ADDRESS_5
/* End of SoC Level DTS fixup file */