From a2f35a3ccf9953ece897da27cd27701c60bc296d Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Fri, 2 May 2008 00:57:47 -0300 Subject: backport commit bdf4bbaaee3d4b8f555658333cbce1affe9070fb From: Mauro Carvalho Chehab kernel-sync: Author: Harvey Harrison Date: Wed Apr 30 00:54:55 2008 -0700 Add macros similar to min/max/min_t/max_t Also, change the variable names used in the min/max macros to avoid shadowed variable warnings when min/max min_t/max_t are nested. Small formatting changes to make all the macros have a similar form. [akpm@linux-foundation.org: coding-style fixes] [akpm@linux-foundation.org: fix v4l build] Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/bt8xx/bttvp.h | 2 -- linux/drivers/media/video/usbvideo/vicam.c | 6 ------ 2 files changed, 8 deletions(-) (limited to 'linux') diff --git a/linux/drivers/media/video/bt8xx/bttvp.h b/linux/drivers/media/video/bt8xx/bttvp.h index e9219458e..b8ab81fb8 100644 --- a/linux/drivers/media/video/bt8xx/bttvp.h +++ b/linux/drivers/media/video/bt8xx/bttvp.h @@ -90,8 +90,6 @@ /* Limits scaled width, which must be a multiple of 4. */ #define MAX_HACTIVE (0x3FF & -4) -#define clamp(x, low, high) min (max (low, x), high) - #define BTTV_NORMS (\ V4L2_STD_PAL | V4L2_STD_PAL_N | \ V4L2_STD_PAL_Nc | V4L2_STD_SECAM | \ diff --git a/linux/drivers/media/video/usbvideo/vicam.c b/linux/drivers/media/video/usbvideo/vicam.c index 5853563fa..049f588ae 100644 --- a/linux/drivers/media/video/usbvideo/vicam.c +++ b/linux/drivers/media/video/usbvideo/vicam.c @@ -72,12 +72,6 @@ #define VICAM_HEADER_SIZE 64 -#define clamp( x, l, h ) max_t( __typeof__( x ), \ - ( l ), \ - min_t( __typeof__( x ), \ - ( h ), \ - ( x ) ) ) - /* Not sure what all the bytes in these char * arrays do, but they're necessary to make * the camera work. -- cgit v1.2.3