Skip to content

Commit 02e1374

Browse files
notropopcornmix
authored andcommitted
bcm2708: don't register i2c controllers when using DT
The devices for the i2c controllers are in the Device Tree. Only register devices when not using DT. Signed-off-by: Noralf Tronnes <notro@tronnes.org>
1 parent 99fe589 commit 02e1374

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎arch/arm/mach-bcm2708/bcm2708.c‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -560,6 +560,7 @@ static struct spi_board_info bcm2708_spi_devices[] = {
560560
};
561561
#endif
562562

563+
#ifndef CONFIG_OF
563564
static struct resource bcm2708_bsc0_resources[] = {
564565
{
565566
.start = BSC0_BASE,
@@ -598,6 +599,7 @@ static struct platform_device bcm2708_bsc1_device = {
598599
.num_resources = ARRAY_SIZE(bcm2708_bsc1_resources),
599600
.resource = bcm2708_bsc1_resources,
600601
};
602+
#endif
601603

602604
static struct platform_device bcm2835_hwmon_device = {
603605
.name = "bcm2835_hwmon",
@@ -828,8 +830,8 @@ void __init bcm2708_init(void)
828830
bcm_register_device(&bcm2708_alsa_devices[i]);
829831

830832
bcm_register_device_dt(&bcm2708_spi_device);
831-
bcm_register_device(&bcm2708_bsc0_device);
832-
bcm_register_device(&bcm2708_bsc1_device);
833+
bcm_register_device_dt(&bcm2708_bsc0_device);
834+
bcm_register_device_dt(&bcm2708_bsc1_device);
833835

834836
bcm_register_device(&bcm2835_hwmon_device);
835837
bcm_register_device(&bcm2835_thermal_device);

0 commit comments

Comments
 (0)