diff --git a/drivers/media/i2c/ov13850.c b/drivers/media/i2c/ov13850.c index 7df5ac335eea..45718446e8ec 100644 --- a/drivers/media/i2c/ov13850.c +++ b/drivers/media/i2c/ov13850.c @@ -24,8 +24,9 @@ #define V4L2_CID_DIGITAL_GAIN V4L2_CID_GAIN #endif -/* 45Mhz * 4 Binning */ -#define OV13850_PIXEL_RATE (45 * 1000 * 1000 * 4) +#define OV13850_LINK_FREQ_300MHZ 300000000 +/* pixel rate = link frequency * 2 * lanes / BITS_PER_SAMPLE */ +#define OV13850_PIXEL_RATE (OV13850_LINK_FREQ_300MHZ * 2 * 2 / 10) #define OV13850_XVCLK_FREQ 24000000 #define CHIP_ID 0x00d850 @@ -589,7 +590,6 @@ static const struct ov13850_mode supported_modes[] = { }, }; -#define OV13850_LINK_FREQ_300MHZ 300000000 static const s64 link_freq_menu_items[] = { OV13850_LINK_FREQ_300MHZ }; diff --git a/drivers/media/i2c/ov4689.c b/drivers/media/i2c/ov4689.c index 819b856e9872..2f90ef707b84 100644 --- a/drivers/media/i2c/ov4689.c +++ b/drivers/media/i2c/ov4689.c @@ -24,8 +24,9 @@ #define V4L2_CID_DIGITAL_GAIN V4L2_CID_GAIN #endif -/* 45Mhz * 4 Binning */ -#define OV4689_PIXEL_RATE (45 * 1000 * 1000 * 4) +#define OV4689_LINK_FREQ_500MHZ 500000000 +/* pixel rate = link frequency * 2 * lanes / BITS_PER_SAMPLE */ +#define OV4689_PIXEL_RATE (OV4689_LINK_FREQ_500MHZ * 2 * 2 / 10) #define OV4689_XVCLK_FREQ 24000000 #define CHIP_ID 0x004688 @@ -398,7 +399,6 @@ static const struct ov4689_mode supported_modes[] = { }, }; -#define OV4689_LINK_FREQ_500MHZ 500000000 static const s64 link_freq_menu_items[] = { OV4689_LINK_FREQ_500MHZ };