Add support for Cadence network controller found in HiFive Unleashed board.
Reviewed by: markj Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D19798
This commit is contained in:
parent
7bad03a8b5
commit
ef5a75b193
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=346634
@ -98,6 +98,12 @@ __FBSDID("$FreeBSD$");
|
||||
#define CGEM_CKSUM_ASSIST (CSUM_IP | CSUM_TCP | CSUM_UDP | \
|
||||
CSUM_TCP_IPV6 | CSUM_UDP_IPV6)
|
||||
|
||||
static struct ofw_compat_data compat_data[] = {
|
||||
{ "cadence,gem", 1 },
|
||||
{ "cdns,macb", 1 },
|
||||
{ NULL, 0 },
|
||||
};
|
||||
|
||||
struct cgem_softc {
|
||||
if_t ifp;
|
||||
struct mtx sc_mtx;
|
||||
@ -1635,7 +1641,7 @@ cgem_probe(device_t dev)
|
||||
if (!ofw_bus_status_okay(dev))
|
||||
return (ENXIO);
|
||||
|
||||
if (!ofw_bus_is_compatible(dev, "cadence,gem"))
|
||||
if (ofw_bus_search_compatible(dev, compat_data)->ocd_data == 0)
|
||||
return (ENXIO);
|
||||
|
||||
device_set_desc(dev, "Cadence CGEM Gigabit Ethernet Interface");
|
||||
|
Loading…
Reference in New Issue
Block a user