lkml.org 
[lkml]   [2008]   [Dec]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] Fixup MODULE_DEVICE_TABLE(dmi, ...)
From
Date
On Wed, 2008-12-03 at 00:41 -0800, Andrew Morton wrote:
> The changelog is too crappy for me. Why did that error occur, and how
> does the patch fix it?

Well, you repeated the explanation of what's wrong -- although I don't
see how it actually causes an _error_; it works here.

The problem is that the MODULE_DEVICE_TABLE(dmi, foo) line expands to...

extern const struct dmi_device_id __mod_dmi_device_table
__attribute__ ((unused, alias("foo")));

And 'struct dmi_device_id' doesn't exist -- what we have is 'struct
dmi_system_id'.

In practice, this doesn't seem to matter because we never ask the
compiler to look _inside_ that struct -- it's just like a forward
declaration of 'struct foo' and then using pointers to it.

But it looks like Alexey's managed to find a way to actually make a
compiler barf on it, so that increases the motivation to fix it
promptly...

--
David Woodhouse Open Source Technology Centre
David.Woodhouse@intel.com Intel Corporation



\
 
 \ /
  Last update: 2008-12-03 10:07    [W:0.069 / U:1.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site