From: Devin Heitmueller Date: Fri, 19 Jun 2009 03:20:28 +0000 (-0300) Subject: V4L/DVB (12100): em28xx: make sure the analog GPIOs are set if we used a card hint X-Git-Tag: 2.1b_release~12124^2~33 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cdf7bfa8926fb26d5900103ae09eb5f3eddb95cc;p=platform%2Fkernel%2Fkernel-mfld-blackbay.git V4L/DVB (12100): em28xx: make sure the analog GPIOs are set if we used a card hint In cases where the board had a default USB ID, we would not indentify the board until after the call to em28xx_set_mode(). As a result, for those boards the analog GPIOs were not being set before probing the i2c bus for devices (the probe would occur with the GPIOs being all high). Make a call to em28xx_set_mode() so that the GPIOs are set properly before probing the i2c bus for devices. This problem was detected with the EVGA inDtube, where the tvp5150 is not powered on unless GPIO1 is pulled low. Signed-off-by: Devin Heitmueller Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c index 00cc791..0b6e5c7 100644 --- a/drivers/media/video/em28xx/em28xx-cards.c +++ b/drivers/media/video/em28xx/em28xx-cards.c @@ -2101,6 +2101,12 @@ void em28xx_card_setup(struct em28xx *dev) case EM2880_BOARD_MSI_DIGIVOX_AD: if (!em28xx_hint_board(dev)) em28xx_set_model(dev); + + /* In cases where we had to use a board hint, the call to + em28xx_set_mode() in em28xx_pre_card_setup() was a no-op, + so make the call now so the analog GPIOs are set properly + before probing the i2c bus. */ + em28xx_set_mode(dev, EM28XX_ANALOG_MODE); break; }