# HG changeset patch # User Trent Piepho # Date 1244834958 25200 # Node ID 23bd6516eafcc06ffb590073e744c7e17382aef9 # Parent 01fd4e3bd1c0fb52cb15acbd22ca7f4857170e6e v4l2: Move bounding code outside I2C ifdef block From: Trent Piepho Move v4l_bound_align_image() and clamp_align() outside of an ifdef block for I2C related code. Can cause an undefined reference to `v4l_bound_align_image' if I2C isn't enabled. Priority: high Signed-off-by: Trent Piepho Reported-by: Randy Dunlap diff -r 01fd4e3bd1c0 -r 23bd6516eafc linux/drivers/media/video/v4l2-common.c --- a/linux/drivers/media/video/v4l2-common.c Thu Jun 11 15:31:22 2009 -0700 +++ b/linux/drivers/media/video/v4l2-common.c Fri Jun 12 12:29:18 2009 -0700 @@ -997,6 +997,8 @@ const unsigned short *v4l2_i2c_tuner_add } EXPORT_SYMBOL_GPL(v4l2_i2c_tuner_addrs); +#endif /* defined(CONFIG_I2C) */ + /* Clamp x to be between min and max, aligned to a multiple of 2^align. min * and max don't have to be aligned, but there must be at least one valid * value. E.g., min=17,max=31,align=4 is not allowed as there are no multiples @@ -1067,5 +1069,3 @@ void v4l_bound_align_image(u32 *w, unsig } } EXPORT_SYMBOL_GPL(v4l_bound_align_image); - -#endif