bcm63xx: dev-enet: initialize shared_device_registered to 0
PATCH 5/10 bcm63xx: dev-enet: initialize shared_device_registered to 0
This patch initialize the shared_device_registered variable with 0, actually required for the check to be working.
Signed-off-by Maxime Bizon <[email protected]>
Signed-off-by Florian Fainelli <[email protected]>
---
arch/mips/bcm63xx/dev-enet.c +1 -1
@@ -28,7 +28,7 @@ static struct platform_device bcm63xx_enet_shared_device = { .resource = shared_res, }; -static int shared_device_registered; +static int shared_device_registered =0 ;static struct resource enet0_res[] = { {
Quoted 12 lines · Florian Fainelli
This patch initialize the
shared_device_registeredvariable with 0, actually required for the check to be working.Signed-off-by Maxime Bizon <[email protected]>Signed-off-by Florian Fainelli <[email protected]>---
arch/mips/bcm63xx/dev-enet.c +0
-0
arch/mips/bcm63xx/dev-enet.c static struct platform_device bcm63xx_enet_shared_device = { · line 31
Quoted 5 lines
arch/mips/bcm63xx/dev-enet.c +1
-1@@ -28,7 +28,7 @@ static struct platform_device bcm63xx_enet_shared_device = { .resource = shared_res, }; -static int shared_device_registered; +static int shared_device_registered =0 ;
This is bogus. The variable defaults to zero. Explicit initialization however will inflate the .data section. Dropped.
Ralf