Bug 247321 - kernel-devel does not provide usable config
kernel-devel does not provide usable config
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: mash (Show other bugs)
7
ppc64 Linux
low Severity low
: ---
: ---
Assigned To: Bill Nottingham
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-07-06 17:57 EDT by Marc Dietrich
Modified: 2014-03-16 23:07 EDT (History)
4 users (show)

See Also:
Fixed In Version: 0.1.18-2.fc7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-11-01 17:22:12 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Marc Dietrich 2007-07-06 17:57:46 EDT
Description of problem:

I'm trying to compile an external module (v4l-dvb to be exact) on my ps3. The 
module compiles, but does not load, because of the .config (provided with 
kernel-devel) mismatch, which is configured for ppc32/non smp. Even copying 
the /boot/config-... into the kernel source, doing make oldconfig, make 
modules_prepare does not solve the problem.

Version-Release number of selected component (if applicable):

Current kernel is kernel-2.6.21-1.3228.fc7. I have installed 
kernel-devel-2.6.21-1.3228.fc7. uname -a gives "Linux localhost 
2.6.21-1.3228.fc7 #1 SMP Tue Jun 12 14:37:12 EDT 2007 ppc64 ppc64 ppc64 
GNU/Linux"

How reproducible:

allways
try to compile an external module, e.g. from 
http://linuxtv.org/hg/v4l-dvb/archive/tip.tar.bz2)

Steps to Reproduce:
1. get a ppc64 machine with 64-bit kernel installed, userspace is 32-bit. 
2. get the v4l-dvb tree from http://linuxtv.org/hg/v4l-dvb/archive/tip.tar.bz2 
and unpack it.
3. cd to the build directory and fire make; make install; modprobe mt2060
  
Actual results:

modprobe mt2060 gives:
FATAL: Error inserting mt2060 
(/lib/modules/2.6.21-1.3228.fc7/kernel/drivers/media/dvb/frontends/mt2060.ko): 
Invalid module format 
and modinfo -F vermagic mt2060
2.6.21-1.3228.fc7 mod_unload
(neither smp nor ppc64)

using the supplied config in /boot/config-2.6.21-1.3228.fc7 cause the same 
modprobe error and modinfo gives
2.6.21-1.3228.fc7 SMP mod_unload

file v4l/mt2060.ko gives
v4l/mt2060.ko: ELF 64-bit MSB relocatable, 64-bit PowerPC or cisco 7500, 
version 1 (SYSV), not stripped

Expected results:

load the module

Additional info:

this should work out of the box. At least with the config found 
in /boot/config-...
Comment 1 Chuck Ebbert 2007-07-06 18:10:56 EDT
I don't have a clue how to build kernel modules on a PS3. Adding David Woodhouse
to the cc:, maybe he can help.
Comment 2 David Woodhouse 2007-07-06 18:15:43 EDT
There's absolutely nothing special about building kernel modules on the PS3. As
always, you need to make sure you have the right kernel-devel package installed.
Sounds like you have the ppc.rpm installed, not ppc64.rpm.
Comment 3 Marc Dietrich 2007-07-07 07:49:35 EDT
yes you are right. IMHO this should be automatical choosen. I installed the 
ppc64 package manually and the module loads. Is there a way to tell yum about 
the ppc64 repo? Why is this not choosen automatically?
Comment 4 Ian Romanick 2007-07-12 19:49:33 EDT
I have also encountered this while trying to build DRM modules on ppc64.  The
problem seems to be that there is no kernel-devel.ppc64 package.  I replaced
/usr/src/kernels/$(uname -r)/.config with a symlink to /boot/config-$(uname -r)
and I can build.

I'd swear that this worked out-of-the box on FC6.

Just to be clear, I'm on a vanilla PowerMac G5, not a PS3, pSeries, or anything
else out of the ordinary.
Comment 5 Ian Romanick 2007-07-12 19:59:43 EDT
Hmm...I take that back.  My build still didn't work.  After doing a little more
poking around, I found that there is a kernel-devel.ppc64 package, but, for
reasons I can't fathom, it's a different repo than all the rest of the ppc
pages.  In fact, it's in a non $basearch repo.  Whose genius idea was *that*?!?

To respond to comment #3:

Add the following to /etc/yum.repos.d/fedora-updates.repo:

[updates64]
name=Fedora $releasever - $basearch - Updates64
#baseurl=http://download.fedora.redhat.com/pub/fedora/linux/updates/$releasever/ppc64/
mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=updates-released-f$releasever&arch=ppc64
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora
Comment 6 Bernard Li 2007-08-31 06:49:35 EDT
After discussing with dwmw2 on IRC, he mentioned this bug should be re-filed
against distribution.  kernel-devel.ppc64 should be available via yum
repository, presently this is still not available when you do a `yum search
kernel-devel`.  Any ETA on when this will be fixed?

Thanks.
Comment 7 Jesse Keating 2007-09-04 14:03:30 EDT
argh.  I fscking hate ppc(64) crap like this.  Looking into fixing the multilib
creation tool.
Comment 8 Jesse Keating 2007-09-04 14:09:38 EDT
Actually, looking at the mash code, it seems it would select both
kernel-devel.ppc32 and kernel-devel.ppc64 to be multilib.  sending in
reinforcements (notting).
Comment 9 Bill Nottingham 2007-09-04 15:08:50 EDT
Should be fixed in mash-0.2.2. Will see about backporting to F-7.
Comment 10 Fedora Update System 2007-09-07 13:17:56 EDT
mash-0.1.18-2.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.
Comment 11 Bill Nottingham 2007-09-20 15:35:33 EDT
Should be fixed for updates now.
Comment 12 Fedora Update System 2007-11-01 17:22:08 EDT
mash-0.1.18-2.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.

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