Am 05.03.2013 11:55, schrieb Mauro Carvalho Chehab: > Prepare to register a separate bus for the second bus. > > For now, just add a new field. A latter patch will add the > bits to make it work. > > This patch was generated by this script: > > perl -e 'while (<>) { if (s/EM2874_I2C_SECONDARY_BUS_SELECT.*\n//) { > printf "\t\t.def_i2c_bus = 1,\n"; $found = 1; print $_ } else { if > ($found) { s/^\s+// }; $found = 0; print $_; } }' \ > drivers/media/usb/em28xx/em28xx-cards.c >a && mv a > drivers/media/usb/em28xx/em28xx-cards.c > > Signed-off-by: Mauro Carvalho Chehab <mche...@redhat.com> > --- > drivers/media/usb/em28xx/em28xx-cards.c | 43 > ++++++++++++++++++--------------- > drivers/media/usb/em28xx/em28xx.h | 1 + > 2 files changed, 24 insertions(+), 20 deletions(-) > > diff --git a/drivers/media/usb/em28xx/em28xx-cards.c > b/drivers/media/usb/em28xx/em28xx-cards.c > index d81f7ee..16ab4d7 100644 > --- a/drivers/media/usb/em28xx/em28xx-cards.c > +++ b/drivers/media/usb/em28xx/em28xx-cards.c > @@ -958,8 +958,8 @@ struct em28xx_board em28xx_boards[] = { > #else > .tuner_type = TUNER_ABSENT, > #endif > - .i2c_speed = EM2874_I2C_SECONDARY_BUS_SELECT | > - EM28XX_I2C_CLK_WAIT_ENABLE | > + .def_i2c_bus = 1, > + .i2c_speed = EM28XX_I2C_CLK_WAIT_ENABLE | > EM28XX_I2C_FREQ_400_KHZ, ...
Looks good, we need a separate field like this for em2765 and Co., too (which don't use reg 0x06 for bus switching). Regards, Frank -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html