Skip to contentSkip to conversation

dvb: build failure fix

PATCH In review Ingo Molnar 4 participants 20 messages Apr 28, 2008 – Apr 30, 2008 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 dvb: build failure fix

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

build failure is due to this nasty dependency:

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

the solution is to follow the DVB_CORE constraint in the Kconfig. It's not pretty but works.

Kconfig should be enhanced instead with a new keyword: "depends on instructure ..." that makes it clear that the dependent module can only be of equal or lesser link mode - but not =y while the infrastructure module is =m. But i digress.

---
 drivers/media/Kconfig |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
drivers/media/Kconfig +7 -7
Index: linux/drivers/media/Kconfig
===================================================================
@@ -106,21 +106,21 @@ if VIDEO_TUNER_CUSTOMIZE
 
 config TUNER_XC2028
 	tristate "XCeive xc2028/xc3028 tuners"
-	depends on I2C && FW_LOADER
+	depends on I2C && FW_LOADER && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the xc2028/xc3028 tuners.
 
 config TUNER_MT20XX
 	tristate "Microtune 2032 / 2050 tuners"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the MT2032 / MT2050 tuner.
 
 config TUNER_TDA8290
 	tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select DVB_TDA827X
 	select DVB_TDA18271
 	default m if VIDEO_TUNER_CUSTOMIZE
@@ -129,21 +129,21 @@ config TUNER_TDA8290
 
 config TUNER_TEA5761
 	tristate "TEA 5761 radio tuner (EXPERIMENTAL)"
-	depends on I2C && EXPERIMENTAL
+	depends on I2C && EXPERIMENTAL && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the Philips TEA5761 radio tuner.
 
 config TUNER_TEA5767
 	tristate "TEA 5767 radio tuner"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the Philips TEA5767 radio tuner.
 
 config TUNER_SIMPLE
 	tristate "Simple tuner support"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select TUNER_TDA9887
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
@@ -151,7 +151,7 @@ config TUNER_SIMPLE
 
 config TUNER_TDA9887
 	tristate "TDA 9885/6/7 analog IF demodulator"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for Philips TDA9885/6/7
#1 lore raw
Quoted 8 lines · Ingo Molnar

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

Quoted 6 lines

build failure is due to this nasty dependency:

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

the solution is to follow the DVB_CORE constraint in the Kconfig. It's not pretty but works.

It might work around the problem in your specific configuration, but it's not the correct solution.

Please send your .config .

Quoted 4 lines

Kconfig should be enhanced instead with a new keyword: "depends on instructure ..." that makes it clear that the dependent module can only be of equal or lesser link mode - but not =y while the infrastructure module is =m. But i digress.

What are you smoking?

That's exactly what "depends on" always did and still does.

Quoted 10 lines
---
 drivers/media/Kconfig |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

Index: linux/drivers/media/Kconfig
===================================================================

drivers/media/Kconfig if VIDEO_TUNER_CUSTOMIZE · line 109

Quoted 6 lines
drivers/media/Kconfig +1 -1
@@ -106,21 +106,21 @@ if VIDEO_TUNER_CUSTOMIZE
 
 config TUNER_XC2028
 	tristate "XCeive xc2028/xc3028 tuners"
-	depends on I2C && FW_LOADER
+	depends on I2C && FW_LOADER && ((DVB_CORE = m && m) || (DVB_CORE = y))
...

Your funny additions are equivalent to "&& DVB_CORE".

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#2 lore raw
Quoted 9 lines · Adrian Bunk
Quoted 8 lines · Ingo Molnar

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

Quoted 8 lines
Quoted 3 lines

build failure is due to this nasty dependency:

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

It might work around the problem in your specific configuration, but it's not the correct solution.

Please send your .config .

i dont have it anymore, but the key was what i wrote in the changelog above:

CONFIG_DVB_CORE=m
CONFIG_TUNER_TDA8290=y

if you look at the symbols above, their definition sites, and the dependencies between them you'll see why that breaks the build. (There might be more to it, this area has been a frequent source of problems.)

Quoted 5 lines

Review

Quoted 3 lines
(quoted diff) +1 -1
-	depends on I2C && FW_LOADER
+	depends on I2C && FW_LOADER && ((DVB_CORE = m && m) || (DVB_CORE = y))
...

Your funny additions are equivalent to "&& DVB_CORE".

right you are, thanks - the above change was the best hack 4 hours of sleep can buy ;-) Simplified patch below.

Ingo

---------------------->
Subject: dvb: build failure fix
From: Ingo Molnar <[email protected]>
Date: Mon Apr 28 18:17:58 CEST 2008

fix build failure:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

due to:

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

---
 drivers/media/Kconfig |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
drivers/media/Kconfig +7 -7
Index: linux/drivers/media/Kconfig
===================================================================
@@ -106,21 +106,21 @@ if VIDEO_TUNER_CUSTOMIZE
 
 config TUNER_XC2028
 	tristate "XCeive xc2028/xc3028 tuners"
-	depends on I2C && FW_LOADER
+	depends on I2C && FW_LOADER && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the xc2028/xc3028 tuners.
 
 config TUNER_MT20XX
 	tristate "Microtune 2032 / 2050 tuners"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the MT2032 / MT2050 tuner.
 
 config TUNER_TDA8290
 	tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select DVB_TDA827X
 	select DVB_TDA18271
 	default m if VIDEO_TUNER_CUSTOMIZE
@@ -129,21 +129,21 @@ config TUNER_TDA8290
 
 config TUNER_TEA5761
 	tristate "TEA 5761 radio tuner (EXPERIMENTAL)"
-	depends on I2C && EXPERIMENTAL
+	depends on I2C && EXPERIMENTAL && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the Philips TEA5761 radio tuner.
 
 config TUNER_TEA5767
 	tristate "TEA 5767 radio tuner"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the Philips TEA5767 radio tuner.
 
 config TUNER_SIMPLE
 	tristate "Simple tuner support"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select TUNER_TDA9887
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
@@ -151,7 +151,7 @@ config TUNER_SIMPLE
 
 config TUNER_TDA9887
 	tristate "TDA 9885/6/7 analog IF demodulator"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for Philips TDA9885/6/7
#3 lore raw
Quoted 14 lines · Ingo Molnar
Quoted 11 lines · Adrian Bunk
Quoted 10 lines · Ingo Molnar

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

build failure is due to this nasty dependency:

Quoted 8 lines
Quoted 6 lines
Quoted 1 line

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

It might work around the problem in your specific configuration, but it's not the correct solution.

Please send your .config .

i dont have it anymore,

That's bad since it makes it harder for other people to reproduce the problem.

Quoted 9 lines

but the key was what i wrote in the changelog
above:

CONFIG_DVB_CORE=m
CONFIG_TUNER_TDA8290=y

if you look at the symbols above, their definition sites, and the dependencies between them you'll see why that breaks the build. (There might be more to it, this area has been a frequent source of problems.)

TUNER_TDA8290 is the only affected driver, your patch also adds wrong dependences to other driver.

And the underlying problem is that it has both an analog an a DVB tuner, and although forcing a dependency on DVB_CORE might make the randconfig crowd happy it's not the correct solution.

Mauro, where were we regarding this issue?

What about:

config TUNER_TDA8290
tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo" depends on I2C
depends on DVB_CORE || DVB_CORE=n
select DVB_TDA827X if DVB_CORE
select DVB_TDA18271 if DVB_CORE
default m if VIDEO_TUNER_CUSTOMIZE
help
Say Y here to include support for Philips TDA8290+8275(a) tuner.

Or is there some twist I'm missing?

Quoted 8 lines
Quoted 5 lines

drivers/media/Kconfig if VIDEO_TUNER_CUSTOMIZE · line 109

Quoted 3 lines
drivers/media/Kconfig +1 -1
-	depends on I2C && FW_LOADER
+	depends on I2C && FW_LOADER && ((DVB_CORE = m && m) || (DVB_CORE = y))
...

Your funny additions are equivalent to "&& DVB_CORE".

right you are, thanks - the above change was the best hack 4 hours of sleep can buy ;-) Simplified patch below.

Still the old one...

But as described above, even the fixed one would be wrong.

Quoted 78 lines

Ingo

---------------------->
Subject: dvb: build failure fix
From: Ingo Molnar <[email protected]>
Date: Mon Apr 28 18:17:58 CEST 2008

fix build failure:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

due to:

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

---
 drivers/media/Kconfig |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

Index: linux/drivers/media/Kconfig
===================================================================

drivers/media/Kconfig +6 -6
@@ -106,21 +106,21 @@ if VIDEO_TUNER_CUSTOMIZE
 
 config TUNER_XC2028
 	tristate "XCeive xc2028/xc3028 tuners"
-	depends on I2C && FW_LOADER
+	depends on I2C && FW_LOADER && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the xc2028/xc3028 tuners.
 
 config TUNER_MT20XX
 	tristate "Microtune 2032 / 2050 tuners"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the MT2032 / MT2050 tuner.
 
 config TUNER_TDA8290
 	tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select DVB_TDA827X
 	select DVB_TDA18271
 	default m if VIDEO_TUNER_CUSTOMIZE
@@ -129,21 +129,21 @@ config TUNER_TDA8290
 
 config TUNER_TEA5761
 	tristate "TEA 5761 radio tuner (EXPERIMENTAL)"
-	depends on I2C && EXPERIMENTAL
+	depends on I2C && EXPERIMENTAL && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the Philips TEA5761 radio tuner.
 
 config TUNER_TEA5767
 	tristate "TEA 5767 radio tuner"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for the Philips TEA5767 radio tuner.
 
 config TUNER_SIMPLE
 	tristate "Simple tuner support"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select TUNER_TDA9887
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help

drivers/media/Kconfig config TUNER_SIMPLE · line 157

Quoted 8 lines
drivers/media/Kconfig +1 -1
@@ -151,7 +151,7 @@ config TUNER_SIMPLE
 
 config TUNER_TDA9887
 	tristate "TDA 9885/6/7 analog IF demodulator"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	default m if VIDEO_TUNER_CUSTOMIZE
 	help
 	  Say Y here to include support for Philips TDA9885/6/7

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#4 lore raw
Quoted 58 lines · On Tue, 29 Apr 2008 00:01:22 +0300 Adrian Bunk <[email protected]> wrote:
Quoted 14 lines · Ingo Molnar
Quoted 11 lines · Adrian Bunk
Quoted 10 lines · Ingo Molnar

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

build failure is due to this nasty dependency:

Quoted 8 lines
Quoted 6 lines
Quoted 1 line

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

It might work around the problem in your specific configuration, but it's not the correct solution.

Please send your .config .

i dont have it anymore,

That's bad since it makes it harder for other people to reproduce the problem.

Quoted 9 lines

but the key was what i wrote in the changelog
above:

CONFIG_DVB_CORE=m
CONFIG_TUNER_TDA8290=y

if you look at the symbols above, their definition sites, and the dependencies between them you'll see why that breaks the build. (There might be more to it, this area has been a frequent source of problems.)

TUNER_TDA8290 is the only affected driver, your patch also adds wrong dependences to other driver.

And the underlying problem is that it has both an analog an a DVB tuner, and although forcing a dependency on DVB_CORE might make the randconfig crowd happy it's not the correct solution.

Mauro, where were we regarding this issue?

What about:

config TUNER_TDA8290
tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo" depends on I2C
depends on DVB_CORE || DVB_CORE=n
select DVB_TDA827X if DVB_CORE
select DVB_TDA18271 if DVB_CORE
default m if VIDEO_TUNER_CUSTOMIZE
help
Say Y here to include support for Philips TDA8290+8275(a) tuner.

Quoted 1 line

Or is there some twist I'm missing?

This will fix compilation, but some drivers will be broken, since tda8275 is needed even for some analog-only drivers.

It would be better to do a "select DVB_CORE", although this is also ugly.

I'm pinging Mkrufky. He is the one that touched a lot on those drivers. Maybe he can come up with a better solution.

Cheers,
Mauro

#5 lore raw
Quoted 54 lines · Mauro Carvalho Chehab
Quoted 50 lines · On Tue, 29 Apr 2008 00:01:22 +0300 Adrian Bunk <[email protected]> wrote:
Quoted 14 lines · Ingo Molnar
Quoted 11 lines · Adrian Bunk
Quoted 9 lines · Ingo Molnar

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

build failure is due to this nasty dependency:

Quoted 9 lines
Quoted 7 lines
Quoted 2 lines

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

It might work around the problem in your specific configuration, but it's not the correct solution.

Please send your .config .

i dont have it anymore,

That's bad since it makes it harder for other people to reproduce the problem.

Quoted 10 lines

but the key was what i wrote in the changelog
above:

CONFIG_DVB_CORE=m
CONFIG_TUNER_TDA8290=y

if you look at the symbols above, their definition sites, and the dependencies between them you'll see why that breaks the build. (There might be more to it, this area has been a frequent source of problems.)

TUNER_TDA8290 is the only affected driver, your patch also adds wrong dependences to other driver.

And the underlying problem is that it has both an analog an a DVB tuner, and although forcing a dependency on DVB_CORE might make the randconfig crowd happy it's not the correct solution.

Mauro, where were we regarding this issue?

What about:

Quoted 9 lines
Quoted 9 lines

config TUNER_TDA8290
tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo" depends on I2C
depends on DVB_CORE || DVB_CORE=n
select DVB_TDA827X if DVB_CORE
select DVB_TDA18271 if DVB_CORE
default m if VIDEO_TUNER_CUSTOMIZE
help
Say Y here to include support for Philips TDA8290+8275(a)

tuner.

Quoted 6 lines
Quoted 3 lines

Or is there some twist I'm missing?

This will fix compilation, but some drivers will be broken, since tda8275

is

Quoted 5 lines

needed even for some analog-only drivers.

It would be better to do a "select DVB_CORE", although this is also ugly.

I'm pinging Mkrufky. He is the one that touched a lot on those drivers.

Maybe

Quoted 1 line

he can come up with a better solution.

The fix for this issue will come "for free" after the tuner location reorganization to the media/common/ folder.

If you try the devel branch of mauro's v4l-dvb tree, is the issue resolved for you?

Regards,

Mike

#6 lore raw
Quoted 2 lines · * [email protected] <[email protected]> wrote:

The fix for this issue will come "for free" after the tuner location reorganization to the media/common/ folder.

btw., will that go into v2.6.26? If not automatically then please push it into ahead separately if possible.

Ingo

#7 lore raw
In reply to [email protected]
Quoted 74 lines · On Mon, 28 Apr 2008 17:29:49 -0400 [email protected] wrote:
Quoted 54 lines · Mauro Carvalho Chehab
Quoted 50 lines · On Tue, 29 Apr 2008 00:01:22 +0300 Adrian Bunk <[email protected]> wrote:
Quoted 14 lines · Ingo Molnar
Quoted 11 lines · Adrian Bunk
Quoted 9 lines · Ingo Molnar

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

build failure is due to this nasty dependency:

Quoted 9 lines
Quoted 7 lines
Quoted 2 lines

CONFIG_DVB_CORE=m but CONFIG_TUNER_TDA8290=y.

It might work around the problem in your specific configuration, but it's not the correct solution.

Please send your .config .

i dont have it anymore,

That's bad since it makes it harder for other people to reproduce the problem.

Quoted 10 lines

but the key was what i wrote in the changelog
above:

CONFIG_DVB_CORE=m
CONFIG_TUNER_TDA8290=y

if you look at the symbols above, their definition sites, and the dependencies between them you'll see why that breaks the build. (There might be more to it, this area has been a frequent source of problems.)

TUNER_TDA8290 is the only affected driver, your patch also adds wrong dependences to other driver.

And the underlying problem is that it has both an analog an a DVB tuner, and although forcing a dependency on DVB_CORE might make the randconfig crowd happy it's not the correct solution.

Mauro, where were we regarding this issue?

What about:

Quoted 9 lines
Quoted 9 lines

config TUNER_TDA8290
tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo" depends on I2C
depends on DVB_CORE || DVB_CORE=n
select DVB_TDA827X if DVB_CORE
select DVB_TDA18271 if DVB_CORE
default m if VIDEO_TUNER_CUSTOMIZE
help
Say Y here to include support for Philips TDA8290+8275(a)

tuner.

Quoted 6 lines
Quoted 3 lines

Or is there some twist I'm missing?

This will fix compilation, but some drivers will be broken, since tda8275

is

Quoted 2 lines

needed even for some analog-only drivers.

Quoted 8 lines
Quoted 3 lines

It would be better to do a "select DVB_CORE", although this is also ugly.

I'm pinging Mkrufky. He is the one that touched a lot on those drivers.

Maybe

Quoted 1 line

he can come up with a better solution.

The fix for this issue will come "for free" after the tuner location reorganization to the media/common/ folder.

Yes, but I think we should try do do something for 2.6.25 and 2.6.24. Maybe, we may just do:
obj-y += /dvb

At media/Kconfig.

Cheers,
Mauro

#8 lore raw
Quoted 32 lines · Mauro Carvalho Chehab
Quoted 3 lines · On Mon, 28 Apr 2008 17:29:49 -0400 [email protected] wrote:
Quoted 2 lines · Mauro Carvalho Chehab

On Tue, 29 Apr 2008 00:01:22 +0300
Adrian Bunk <[email protected]> wrote:

...

Quoted 25 lines
Quoted 4 lines
Quoted 4 lines

Mauro, where were we regarding this issue?

What about:

Quoted 9 lines
Quoted 9 lines

config TUNER_TDA8290
tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo" depends on I2C
depends on DVB_CORE || DVB_CORE=n
select DVB_TDA827X if DVB_CORE
select DVB_TDA18271 if DVB_CORE
default m if VIDEO_TUNER_CUSTOMIZE
help
Say Y here to include support for Philips TDA8290+8275(a)

tuner.

Quoted 6 lines
Quoted 3 lines

Or is there some twist I'm missing?

This will fix compilation, but some drivers will be broken, since tda8275

is

Quoted 4 lines

needed even for some analog-only drivers.

It would be better to do a "select DVB_CORE", although this is also ugly.

Quoted 8 lines
Quoted 6 lines
Quoted 1 line

I'm pinging Mkrufky. He is the one that touched a lot on those drivers.

Maybe

Quoted 1 line

he can come up with a better solution.

The fix for this issue will come "for free" after the tuner location reorganization to the media/common/ folder.

Yes, but I think we should try do do something for 2.6.25 and 2.6.24.

Toralf and Ingo only discovered it during randconfig testing.

Are there actually reports from users running into this problem?

Quoted 4 lines

Maybe, we
may just do:
obj-y += /dvb
...

Do DVB_TDA827X/DVB_TDA18271 need anything from DVB_CORE?

If yes you'd only transform one build error into another.

Quoted 2 lines

Cheers,
Mauro

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#9 lore raw
Quoted 27 lines · Adrian Bunk
Quoted 25 lines · Mauro Carvalho Chehab
Quoted 5 lines · On Mon, 28 Apr 2008 17:29:49 -0400 [email protected] wrote:
Quoted 3 lines · Mauro Carvalho Chehab

On Tue, 29 Apr 2008 00:01:22 +0300
Adrian Bunk <[email protected]> wrote:

...

Quoted 14 lines
Quoted 14 lines
Quoted 14 lines

Mauro, where were we regarding this issue?

What about:

config TUNER_TDA8290
tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo" depends on I2C
depends on DVB_CORE || DVB_CORE=n
select DVB_TDA827X if DVB_CORE
select DVB_TDA18271 if DVB_CORE
default m if VIDEO_TUNER_CUSTOMIZE
help
Say Y here to include support for Philips TDA8290+8275(a)

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

tuner.

Quoted 4 lines
Quoted 3 lines

Or is there some twist I'm missing?

This will fix compilation, but some drivers will be broken, since

tda8275

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 1 line

is

Quoted 3 lines

needed even for some analog-only drivers.

It would be better to do a "select DVB_CORE", although this is also

ugly.

Quoted 24 lines
Quoted 12 lines
Quoted 10 lines
Quoted 3 lines

I'm pinging Mkrufky. He is the one that touched a lot on those drivers.

Maybe

Quoted 2 lines

he can come up with a better solution.

The fix for this issue will come "for free" after the tuner location reorganization to the media/common/ folder.

Yes, but I think we should try do do something for 2.6.25 and 2.6.24.

Toralf and Ingo only discovered it during randconfig testing.

Are there actually reports from users running into this problem?

Quoted 5 lines

Maybe, we
may just do:
obj-y += /dvb
...

Quoted 3 lines

Do DVB_TDA827X/DVB_TDA18271 need anything from DVB_CORE?

If yes you'd only transform one build error into another.

DVB_TDA827X and DVB_TDA18271 do not need anything from DVB_CORE -- their only dependency is I2C_CORE.

I think Mauro renamed those Kconfig symbols to MEDIA_TUNER_TDAfoo now, btw.

-Mike

#10 lore raw
Quoted 1 line · On Wed, 30 Apr 2008 15:31:42 -0400 [email protected] wrote:
Quoted 1 line

Are there actually reports from users running into this problem?

No.

Yet, the configuration may be valid. If you have a board with tda8290, it _will_ need another chip, like tda827x.

In the past, both tda8290 and tda827x were handled by the same driver, and worked for analog only.

So, IMO, this is a regression.

Quoted 6 lines
Quoted 6 lines
Quoted 5 lines

Maybe, we
may just do:
obj-y += /dvb
...

Quoted 8 lines
Quoted 3 lines

Do DVB_TDA827X/DVB_TDA18271 need anything from DVB_CORE?

If yes you'd only transform one build error into another.

DVB_TDA827X and DVB_TDA18271 do not need anything from DVB_CORE -- their only dependency is I2C_CORE.

I think Mauro renamed those Kconfig symbols to MEDIA_TUNER_TDAfoo now, btw.

I can't foresee any issues with those drivers. The risk I can see is to compile some dvb core things that aren't needed, or whose Kconfig dependencies may be incomplete.

I didn't make yet a deeper analysis to be sure that this won't cause any issues, but I suspect that this would be safe.

I agree that we need to check the resulting dependencies.

Cheers,
Mauro

#11 lore raw
Quoted 7 lines · Mauro Carvalho Chehab
Quoted 1 line · On Wed, 30 Apr 2008 15:31:42 -0400 [email protected] wrote:
Quoted 1 line

Are there actually reports from users running into this problem?

No.

Quoted 8 lines

Yet, the configuration may be valid. If you have a board with tda8290, it _will_ need another chip, like tda827x.

In the past, both tda8290 and tda827x were handled by the same driver, and worked for analog only.

So, IMO, this is a regression.
...

drivers/media/ is the part of the kernel with the most fragile kconfig constructs.

And we are talking about bringing a solution into -stable that has never and will never be in mainline.

A compile error in a configuration without practical relevance isn't a huge problem, and I'd vote for leaving -stable unchanged.

Quoted 2 lines

Cheers,
Mauro

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#12 lore raw
Quoted 6 lines · Adrian Bunk
Quoted 4 lines · Mauro Carvalho Chehab

On Wed, 30 Apr 2008 15:31:42 -0400
[email protected] wrote:

Quoted 8 lines
Quoted 8 lines
Quoted 2 lines
Quoted 2 lines

Are there actually reports from users running into this problem?

No.

Yet, the configuration may be valid. If you have a board with tda8290, it _will_ need another chip, like tda827x.

In the past, both tda8290 and tda827x were handled by the same driver,

and

Quoted 6 lines
Quoted 5 lines

worked for analog only.

So, IMO, this is a regression.
...

Quoted 8 lines

drivers/media/ is the part of the kernel with the most fragile kconfig constructs.

And we are talking about bringing a solution into -stable that has never and will never be in mainline.

A compile error in a configuration without practical relevance isn't a huge problem, and I'd vote for leaving -stable unchanged.

I agree wholeheartedly -- we should not change the build procedure for the -stable series.

I hope nobody was seriously considering throwing in this sort of monkey wrench to a stable kernel.

-Mike

#13 lore raw
In reply to Ingo Molnar
Quoted 8 lines · On Mon, 28 Apr 2008 18:24:21 +0200 Ingo Molnar <[email protected]> wrote:

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

Quoted 6 lines

config TUNER_XC2028
config TUNER_MT20XX
config TUNER_TEA5761
config TUNER_TEA5767
config TUNER_SIMPLE
config TUNER_TDA9887

Hmm... if the issues are with tda827x and tda18271, why have you touched on the above drivers? I can't see why the above tuners would need DVB.

drivers/media/Kconfig if VIDEO_TUNER_CUSTOMIZE · line 126

Quoted 7 lines

config TUNER_TDA8290

drivers/media/Kconfig +1 -1
 	tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select DVB_TDA827X
 	select DVB_TDA18271
 	default m if VIDEO_TUNER_CUSTOMIZE

Ok, this one may be broken.

I'm working on some changes that will hopefully fix this issue at the proper way.

Cheers,
Mauro

#14 lore raw
Quoted 18 lines · Mauro Carvalho Chehab
Quoted 8 lines · On Mon, 28 Apr 2008 18:24:21 +0200 Ingo Molnar <[email protected]> wrote:

fix build failure found via x86.git randconfig testing:

drivers/built-in.o: In function `tda829x_attach':
: undefined reference to tda827x_attach' drivers/built-in.o: In function tda829x_attach':
: undefined reference to `tda18271_attach'

Quoted 6 lines

config TUNER_XC2028
config TUNER_MT20XX
config TUNER_TEA5761
config TUNER_TEA5767
config TUNER_SIMPLE
config TUNER_TDA9887

Quoted 3 lines

Hmm... if the issues are with tda827x and tda18271, why have you touched on the above drivers? I can't see why the above tuners would need DVB.

ah, ok. I just copy & pasted to everything that had "depends on I2C".

Quoted 10 lines

drivers/media/Kconfig if VIDEO_TUNER_CUSTOMIZE · line 126

Quoted 7 lines

config TUNER_TDA8290

drivers/media/Kconfig +1 -1
 	tristate "TDA 8290/8295 + 8275(a)/18271 tuner combo"
-	depends on I2C
+	depends on I2C && ((DVB_CORE = m && m) || (DVB_CORE = y))
 	select DVB_TDA827X
 	select DVB_TDA18271
 	default m if VIDEO_TUNER_CUSTOMIZE

Ok, this one may be broken.

Quoted 2 lines

I'm working on some changes that will hopefully fix this issue at the proper way.

ok, great. FYI, this has been reported months ago too so it's a long-time breakage - would be nice to fix it upstream even if it's the initial fix is a band-aid.

Ingo

#15 lore raw
Quoted 6 lines
Quoted 2 lines

I'm working on some changes that will hopefully fix this issue at the proper way.

ok, great. FYI, this has been reported months ago too so it's a long-time breakage - would be nice to fix it upstream even if it's the initial fix is a band-aid.

Agreed. Probably, this is broken since 2.6.24, where hybrid tuner support started.

Cheers,
Mauro

#16 lore raw
Quoted 9 lines · Mauro Carvalho Chehab
Quoted 6 lines
Quoted 2 lines

I'm working on some changes that will hopefully fix this issue at the proper way.

ok, great. FYI, this has been reported months ago too so it's a long-time breakage - would be nice to fix it upstream even if it's the initial fix is a band-aid.

Agreed. Probably, this is broken since 2.6.24, where hybrid tuner support started.

yeah, i think i saw it last for the first time. It's probably not a too logical combination of config options that a real user would pick voluntarily, but it's worth fixing nevertheless as randconfig is such a useful tool.

Ingo

#17 lore raw

FYI, x86.git randconfig testing found another build bug as well:

http://redhat.com/~mingo/misc/config-Mon_Apr_28_23_14_46_CEST_2008.bad

build log below. Note that this seems to be a more clear-cut case as module support was disabled.

Ingo

--------------->
drivers/built-in.o: In function `cx23885_dvb_register':
: undefined reference to `dib7000p_attach'
drivers/built-in.o: In function `cx23885_initialize_codec':
cx23885-417.c:(.text+0x1dd5a7): undefined reference to cx2341x_update' drivers/built-in.o: In function cx23885_queryctrl':
cx23885-417.c:(.text+0x1de02e): undefined reference to cx2341x_ctrl_query' drivers/built-in.o: In function cx23885_417_register':
: undefined reference to cx2341x_fill_defaults' drivers/built-in.o: In function mpeg_do_ioctl':
cx23885-417.c:(.text+0x1dea0e): undefined reference to cx2341x_log_status' cx23885-417.c:(.text+0x1dea67): undefined reference to cx2341x_ctrl_get_menu' cx23885-417.c:(.text+0x1dec1a): undefined reference to cx2341x_ext_ctrls' cx23885-417.c:(.text+0x1deeaf): undefined reference to cx2341x_ext_ctrls' cx23885-417.c:(.text+0x1deedb): undefined reference to cx2341x_update' drivers/built-in.o:(.data+0x54c40): undefined reference to cx2341x_mpeg_ctrls' 6.22user 1.55system 0:03.08elapsed 251%CPU (0avgtext+0avgdata 0maxresident)k

#18 lore raw
Quoted 4 lines · Ingo Molnar

http://redhat.com/~mingo/misc/config-Mon_Apr_28_23_14_46_CEST_2008.bad

build log below. Note that this seems to be a more clear-cut case as module support was disabled.

ok, found one bug, find the fix for that below. One more bug to go:

drivers/built-in.o: In function `cx23885_dvb_register':
: undefined reference to `dib7000p_attach'

Ingo

-------------->
Subject: dvb: fix3
From: Ingo Molnar <[email protected]>
Date: Mon Apr 28 23:22:13 CEST 2008

---
 drivers/media/video/cx23885/Kconfig |    1 +
 1 file changed, 1 insertion(+)
drivers/media/video/cx23885/Kconfig +1 -0
Index: linux/drivers/media/video/cx23885/Kconfig
===================================================================
@@ -9,6 +9,7 @@ config VIDEO_CX23885
 	select VIDEO_IR
 	select VIDEOBUF_DVB
 	select VIDEO_CX25840
+	select VIDEO_CX2341X
 	select DVB_TUNER_MT2131 if !DVB_FE_CUSTOMISE
 	select DVB_S5H1409 if !DVB_FE_CUSTOMISE
 	select DVB_LGDT330X if !DVB_FE_CUSTOMISE
#19 lore raw
Quoted 4 lines · Ingo Molnar

ok, found one bug, find the fix for that below. One more bug to go:

drivers/built-in.o: In function `cx23885_dvb_register':
: undefined reference to `dib7000p_attach'

ok, the patch below fixes the bug fully here. (there might be other aspects to it though)

Ingo

-------------->
Subject: dvb: fix3
From: Ingo Molnar <[email protected]>
Date: Mon Apr 28 23:22:13 CEST 2008

---
 drivers/media/video/cx23885/Kconfig |    2 ++
 1 file changed, 2 insertions(+)
drivers/media/video/cx23885/Kconfig +2 -0
Index: linux/drivers/media/video/cx23885/Kconfig
===================================================================
@@ -9,6 +9,8 @@ config VIDEO_CX23885
 	select VIDEO_IR
 	select VIDEOBUF_DVB
 	select VIDEO_CX25840
+	select VIDEO_CX2341X
+	select DVB_DIB7000P
 	select DVB_TUNER_MT2131 if !DVB_FE_CUSTOMISE
 	select DVB_S5H1409 if !DVB_FE_CUSTOMISE
 	select DVB_LGDT330X if !DVB_FE_CUSTOMISE