From edf210ec3fe0377c106dc7f00803877ed17d298e Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Thu, 7 Jun 2007 08:01:48 -0300 Subject: Allow removing CONFIG_BIGPHYS_AREA from mainstream kernel From: Mauro Carvalho Chehab CONFIG_BIGPHYS_AREA is an out-of-tree patch. While it may be interesting to have this configuration flag when compiling v4l-dvb out-of-tree, for development purposes, there's no sense on keeping those unused code inside kernel. This patch do some cosmetic changes on zoran_driver.c, preserving both supports there, and adds the defaults to be used by gentree.pl. This way, gentree.pl will handle the removal of the dead code when submitting code to mainstream, while keeping the complete code at v4l-dvb tree. Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/zoran_driver.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'linux/drivers/media/video/zoran_driver.c') diff --git a/linux/drivers/media/video/zoran_driver.c b/linux/drivers/media/video/zoran_driver.c index de85abc45..d7b6d7c96 100644 --- a/linux/drivers/media/video/zoran_driver.c +++ b/linux/drivers/media/video/zoran_driver.c @@ -186,7 +186,7 @@ static const int zoran_num_formats = (sizeof(zoran_formats) / sizeof(struct zoran_format)); // RJ: Test only - want to test BUZ_USE_HIMEM even when CONFIG_BIGPHYS_AREA is defined -#if !defined(CONFIG_BIGPHYS_AREA) +#if !defined(CONFIG_BIGPHYS_AREA) && !defined(BUZ_USE_HIMEM) //#undef CONFIG_BIGPHYS_AREA #define BUZ_USE_HIMEM #endif @@ -404,7 +404,8 @@ v4l_fbuffer_alloc (struct file *file) /* Zero out the allocated memory */ memset(fh->v4l_buffers.buffer[i].fbuffer, 0, fh->v4l_buffers.buffer_size); -#elif defined(BUZ_USE_HIMEM) +#else +#if defined(BUZ_USE_HIMEM) /* Use high memory which has been left at boot time */ @@ -457,6 +458,7 @@ v4l_fbuffer_alloc (struct file *file) ZR_DEVNAME(zr), fh->v4l_buffers.num_buffers, fh->v4l_buffers.buffer_size >> 10); return -ENOBUFS; +#endif #endif } } -- cgit v1.2.3