Bug 12483 - Reference to inexistent struct dmi_device_id breaks the build
Summary: Reference to inexistent struct dmi_device_id breaks the build
Status: CLOSED CODE_FIX
Alias: None
Product: Platform Specific/Hardware
Classification: Unclassified
Component: i386 (show other bugs)
Hardware: All Linux
: P1 high
Assignee: Henrik Rydberg
URL:
Keywords:
Depends on:
Blocks: 11808
  Show dependency tree
 
Reported: 2009-01-19 01:29 UTC by Jean Delvare
Modified: 2009-01-29 14:05 UTC (History)
4 users (show)

See Also:
Kernel Version: 2.6.28
Subsystem:
Regression: Yes
Bisected commit-id:


Attachments

Description Jean Delvare 2009-01-19 01:29:50 UTC
Latest working kernel version: 2.6.27.10
Earliest failing kernel version: 2.6.28
Distribution: Slackware 11.0
Hardware Environment: i386
Software Environment: gcc 3.4.6, GNU ld 2.15.92.0.2
Problem Description:

Kernel build fails with either of the following errors:
drivers/hwmon/applesmc.c:1582: error: storage size of '__mod_dmi_device_table' isn't known
drivers/video/backlight/mbp_nvidia_bl.c:114: error: storage size of '__mod_dmi_device_table' isn't known

This is because MODULE_DEVICE_TABLE(dmi, ...) expands to:
extern const struct dmi_device_id __mod_dmi_device_table ...
and struct dmi_device_id doesn't exist.

Steps to reproduce:
Build kernel 2.6.28 or 2.6.29-rc2 on x86 with gcc 3.

Apparently the problem doesn't happen with gcc 4.

This problem has already been discussed:
http://lkml.org/lkml/2008/12/11/441
https://kerneltrap.org/mailarchive/linux-kernel/2008/11/14/4156904/thread
But a patch still has to be submitted to mainline and then ported to 2.6.28-stable.
Comment 1 Henrik Rydberg 2009-01-27 10:52:37 UTC
Patch sent: http://lkml.org/lkml/2009/1/27/271
Comment 2 Jean Delvare 2009-01-27 11:47:33 UTC
Great, thanks!

Note You need to log in before you can comment on or make changes to this bug.