Skip to content

Commit bd61224

Browse files
Sergei Shtylyovdavem330
authored andcommitted
SolutionEngine7724: fix Ether support
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>
1 parent 06a64f9 commit bd61224

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎arch/sh/boards/mach-se/7724/setup.c‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ static struct platform_device keysc_device = {
365365
static struct resource sh_eth_resources[] = {
366366
[0] = {
367367
.start = SH_ETH_ADDR,
368-
.end = SH_ETH_ADDR + 0x1FC,
368+
.end = SH_ETH_ADDR + 0x1FC - 1,
369369
.flags = IORESOURCE_MEM,
370370
},
371371
[1] = {
@@ -377,6 +377,8 @@ static struct resource sh_eth_resources[] = {
377377
static struct sh_eth_plat_data sh_eth_plat = {
378378
.phy = 0x1f, /* SMSC LAN8187 */
379379
.edmac_endian = EDMAC_LITTLE_ENDIAN,
380+
.register_type = SH_ETH_REG_FAST_SH4,
381+
.phy_interace = PHY_INTERFACE_MODE_MII,
380382
};
381383

382384
static struct platform_device sh_eth_device = {

0 commit comments

Comments
 (0)