Skip to content

Commit

Permalink
SolutionEngine7724: fix Ether support
Browse files Browse the repository at this point in the history
The Ether platform data is behind the declaration of 'struct sh_eth_plat_data'
as it's lacking the initializers for the 'register_type' and 'phy_interface'
fields -- it means they'll be implicitly and wrongly set to SH_ETH_REG_GIGABIT
and PHY_INTERFACE_MODE_NA. Initialize the fields explicitly and fix off-by-one
error in the Ether memory resource end, while at it...

Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Sergei Shtylyov authored and David S. Miller committed Aug 21, 2013
1 parent 06a64f9 commit bd61224
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion arch/sh/boards/mach-se/7724/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ static struct platform_device keysc_device = {
static struct resource sh_eth_resources[] = {
[0] = {
.start = SH_ETH_ADDR,
.end = SH_ETH_ADDR + 0x1FC,
.end = SH_ETH_ADDR + 0x1FC - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
Expand All @@ -377,6 +377,8 @@ static struct resource sh_eth_resources[] = {
static struct sh_eth_plat_data sh_eth_plat = {
.phy = 0x1f, /* SMSC LAN8187 */
.edmac_endian = EDMAC_LITTLE_ENDIAN,
.register_type = SH_ETH_REG_FAST_SH4,
.phy_interace = PHY_INTERFACE_MODE_MII,
};

static struct platform_device sh_eth_device = {
Expand Down

0 comments on commit bd61224

Please sign in to comment.