alistair23-linux/include/linux/sh_eth.h
Sergei Shtylyov 5133550296 sh_eth: fix SH7757 GEther initialization
Renesas  SH7757 has 2 Fast and 2 Gigabit Ether controllers, while the
'sh_eth' driver can only reset and initialize TSU of the first controller
pair. Shimoda-san tried to solve that adding the 'needs_init' member to the
'struct sh_eth_plat_data', however the platform code still never sets this
flag. I think  that we can infer this information from the 'devno' variable
(set  to 'platform_device::id') and reset/init the Ether controller pair
only for an even 'devno'; therefore 'sh_eth_plat_data::needs_init' can be
removed...

Fixes: 150647fb2c ("net: sh_eth: change the condition of initialization")
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-01-05 13:59:18 -05:00

23 lines
417 B
C

/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __ASM_SH_ETH_H__
#define __ASM_SH_ETH_H__
#include <linux/phy.h>
#include <linux/if_ether.h>
enum {EDMAC_LITTLE_ENDIAN};
struct sh_eth_plat_data {
int phy;
int phy_irq;
int edmac_endian;
phy_interface_t phy_interface;
void (*set_mdio_gate)(void *addr);
unsigned char mac_addr[ETH_ALEN];
unsigned no_ether_link:1;
unsigned ether_link_active_low:1;
};
#endif