From bddb03181fef4172d529717ff1c613a1770d737c Mon Sep 17 00:00:00 2001 From: Koen Kooi Date: Fri, 18 May 2012 12:39:25 +0200 Subject: [PATCH 45/56] beaglebone: allow capes to disable w1-gpio Signed-off-by: Koen Kooi --- arch/arm/mach-omap2/board-am335xevm.c | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-omap2/board-am335xevm.c b/arch/arm/mach-omap2/board-am335xevm.c index 5bb71b1..5c89494 100644 --- a/arch/arm/mach-omap2/board-am335xevm.c +++ b/arch/arm/mach-omap2/board-am335xevm.c @@ -498,7 +498,7 @@ static int capecount = 0; static bool beaglebone_tsadcpins_free = 1; static bool beaglebone_leds_free = 1; static bool beaglebone_spi1_free = 1; - +static bool beaglebone_w1gpio_free = 1; #define GP_EVM_REV_IS_1_0 0x1 #define GP_EVM_REV_IS_1_0A 0x1 @@ -1727,6 +1727,7 @@ static void lcd7leds_init(int evm_id, int profile ) static void bonew1_gpio_init(int evm_id, int profile ) { + beaglebone_w1gpio_free = 0; int err; setup_pin_mux(w1_gpio_pin_mux); err = platform_device_register(&bone_w1_device); @@ -2258,6 +2259,9 @@ static void beaglebone_cape_setup(struct memory_accessor *mem_acc, void *context setup_pin_mux(spi1_pin_mux); spi_register_board_info(bone_spidev2_info, ARRAY_SIZE(bone_spidev2_info)); } + if(beaglebone_w1gpio_free == 1) { + bonew1_gpio_init(0,0); + } } return; } @@ -2831,7 +2835,6 @@ static struct evm_dev_cfg beaglebone_dev_cfg[] = { {usb1_init, DEV_ON_BASEBOARD, PROFILE_NONE}, {i2c2_init, DEV_ON_BASEBOARD, PROFILE_NONE}, {mmc0_init, DEV_ON_BASEBOARD, PROFILE_NONE}, - {bonew1_gpio_init, DEV_ON_BASEBOARD, PROFILE_ALL}, {NULL, 0, 0}, }; -- 1.7.7.6