public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Add note that lockdep is not allowed with non-GPL modules
@ 2006-07-04 20:29 Petr Vandrovec
  2006-07-04 20:53 ` Alexey Dobriyan
  0 siblings, 1 reply; 5+ messages in thread
From: Petr Vandrovec @ 2006-07-04 20:29 UTC (permalink / raw)
  To: mingo; +Cc: linux-kernel

Hi Ingo,
  can you add this small notice to the lockdep option ?  

Lock dependency infrastructure forces all legacy code which uses lock to now
depend on lockdep_init_map symbol, which is GPL-only.  It means that almost
no modules can work on kernel with CONFIG_LOCKDEP set.  Let's warn user about
that.

vmmon: module license 'unspecified' taints kernel.
vmmon: Unknown symbol lockdep_init_map

				Thanks,
					Petr Vandrovec

Signed-off-by: Petr Vandrovec <petr@vandrovec.name>


--- linux-2.6.17-3130.dist/lib/Kconfig.debug	2006-07-04 19:31:36.000000000 +0200
+++ linux-2.6.17-3130/lib/Kconfig.debug	2006-07-04 21:55:35.000000000 +0200
@@ -214,6 +214,9 @@
 
 	 For more details, see Documentation/lockdep-design.txt.
 
+	 Do not enable this option if you are using non-GPL modules, or
+	 they will fail to load due to missing symbol lockdep_init_map.
+
 config LOCKDEP
 	bool
 	depends on TRACE_IRQFLAGS_SUPPORT && STACKTRACE_SUPPORT && LOCKDEP_SUPPORT

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Add note that lockdep is not allowed with non-GPL modules
  2006-07-04 20:29 [PATCH] Add note that lockdep is not allowed with non-GPL modules Petr Vandrovec
@ 2006-07-04 20:53 ` Alexey Dobriyan
  2006-07-04 21:20   ` Petr Vandrovec
  0 siblings, 1 reply; 5+ messages in thread
From: Alexey Dobriyan @ 2006-07-04 20:53 UTC (permalink / raw)
  To: Petr Vandrovec; +Cc: mingo, linux-kernel

On Tue, Jul 04, 2006 at 10:29:04PM +0200, Petr Vandrovec wrote:
> Hi Ingo,
>   can you add this small notice to the lockdep option ?
>
> Lock dependency infrastructure forces all legacy code which uses lock to now
> depend on lockdep_init_map symbol, which is GPL-only.  It means that almost
> no modules can work on kernel with CONFIG_LOCKDEP set.  Let's warn user about
> that.

IANIngo, but the warning is already there:
* Proprietary module user probably already knows that major deviations from .config
  and kernel its module is released is no-no.
* Unknown symbol name contains "lockdep" which attentive proprietary
  module user will notice and correlate with enabling lockdep 5 minutes ago.
* Tomorrow Ingo will change it's name, add a couple of new lockdep only
  exports so should he update help text every time _he_ changes _his_
  code?
* Would you add similar notice to inotify help text? It also exports
  GPL-only symbols doncha know. Would you add such notices to everything
  exporting GPL-only symbols?

> vmmon: module license 'unspecified' taints kernel.
> vmmon: Unknown symbol lockdep_init_map

> +	 Do not enable this option if you are using non-GPL modules, or
> +	 they will fail to load due to missing symbol lockdep_init_map.

Lock validor found a bug in NVidia driver, film at 11.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Add note that lockdep is not allowed with non-GPL modules
  2006-07-04 20:53 ` Alexey Dobriyan
@ 2006-07-04 21:20   ` Petr Vandrovec
  2006-07-05  2:47     ` Valdis.Kletnieks
  0 siblings, 1 reply; 5+ messages in thread
From: Petr Vandrovec @ 2006-07-04 21:20 UTC (permalink / raw)
  To: Alexey Dobriyan; +Cc: mingo, linux-kernel

Alexey Dobriyan wrote:
> On Tue, Jul 04, 2006 at 10:29:04PM +0200, Petr Vandrovec wrote:
> 
>>Hi Ingo,
>>  can you add this small notice to the lockdep option ?
>>
>>Lock dependency infrastructure forces all legacy code which uses lock to now
>>depend on lockdep_init_map symbol, which is GPL-only.  It means that almost
>>no modules can work on kernel with CONFIG_LOCKDEP set.  Let's warn user about
>>that.
> 
> 
> IANIngo, but the warning is already there:
> * Proprietary module user probably already knows that major deviations from .config
>   and kernel its module is released is no-no.

Uh?  How it comes?  VMware modules work in any kernel configuration and 
architecture.  With exception of vmmon, which contains inline assembly 
for i386 & x86-64 only.  But all configs are supported.

> * Would you add similar notice to inotify help text? It also exports
>   GPL-only symbols doncha know. Would you add such notices to everything
>   exporting GPL-only symbols?

This is just nonsense.  I am not talking about using new API, I'm saying 
that API which was not GPL-only without lockdep has GPL-only portion 
with lockdep, and this GPL-only portion is needed by implementation of 
code which existed before lockdep.  To me this looks like unexpected 
change of kernel API, and as such should be documented and warned about.

>>vmmon: module license 'unspecified' taints kernel.
>>vmmon: Unknown symbol lockdep_init_map
> 
> 
>>+	 Do not enable this option if you are using non-GPL modules, or
>>+	 they will fail to load due to missing symbol lockdep_init_map.
> 
> 
> Lock validor found a bug in NVidia driver, film at 11.

I have no idea how NVidia managed to work around that problem, but 
VMware modules suddenly depend on this GPL-only symbol, although nothing 
in the module sources refers to lockdep (same sources which worked 
yesterday are being used).
					Thanks,
						Petr Vandrovec

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Add note that lockdep is not allowed with non-GPL modules
  2006-07-04 21:20   ` Petr Vandrovec
@ 2006-07-05  2:47     ` Valdis.Kletnieks
  2006-07-05  2:54       ` Petr Vandrovec
  0 siblings, 1 reply; 5+ messages in thread
From: Valdis.Kletnieks @ 2006-07-05  2:47 UTC (permalink / raw)
  To: Petr Vandrovec; +Cc: Alexey Dobriyan, mingo, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 653 bytes --]

On Tue, 04 Jul 2006 23:20:53 +0200, Petr Vandrovec said:
> > Lock validor found a bug in NVidia driver, film at 11.

It almost certainly didn't, as you have to do some major ugly and evil
things to get the NVidia driver to build (it won't pass modpost if the
kernel is built with lockdep due to the GPL-only exports that get sucked in).

> I have no idea how NVidia managed to work around that problem, but 
> VMware modules suddenly depend on this GPL-only symbol, although nothing 
> in the module sources refers to lockdep (same sources which worked 
> yesterday are being used).

It doesn't reference it directly - it gets sucked in via a #define.


[-- Attachment #2: Type: application/pgp-signature, Size: 226 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Add note that lockdep is not allowed with non-GPL modules
  2006-07-05  2:47     ` Valdis.Kletnieks
@ 2006-07-05  2:54       ` Petr Vandrovec
  0 siblings, 0 replies; 5+ messages in thread
From: Petr Vandrovec @ 2006-07-05  2:54 UTC (permalink / raw)
  To: Valdis.Kletnieks; +Cc: Alexey Dobriyan, mingo, linux-kernel

Valdis.Kletnieks@vt.edu wrote:
> On Tue, 04 Jul 2006 23:20:53 +0200, Petr Vandrovec said:
> 
>>>Lock validor found a bug in NVidia driver, film at 11.
> 
> 
> It almost certainly didn't, as you have to do some major ugly and evil
> things to get the NVidia driver to build (it won't pass modpost if the
> kernel is built with lockdep due to the GPL-only exports that get sucked in).
> 
> 
>>I have no idea how NVidia managed to work around that problem, but 
>>VMware modules suddenly depend on this GPL-only symbol, although nothing 
>>in the module sources refers to lockdep (same sources which worked 
>>yesterday are being used).
> 
> It doesn't reference it directly - it gets sucked in via a #define.

VMware code is shoot down due to use of init_waitqueue_head().  It is 
now virtually GPL-only because it is inlined and uses GPL-only function 
lockdep_init_map :-(
						Petr

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-07-05  2:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-04 20:29 [PATCH] Add note that lockdep is not allowed with non-GPL modules Petr Vandrovec
2006-07-04 20:53 ` Alexey Dobriyan
2006-07-04 21:20   ` Petr Vandrovec
2006-07-05  2:47     ` Valdis.Kletnieks
2006-07-05  2:54       ` Petr Vandrovec

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox