First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 181982
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Marien Zwart (RETIRED) <marienz@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Jephte CLAIN <Jephte.Clain@univ-reunion.fr>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
build.log the build log from /var/tmp/portage/x11-drivers/ati-drivers-8.37.6-r1/temp text/plain Jephte CLAIN 2007-06-14 07:31 0000 4.60 KB Details
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 181982 depends on: Show dependency tree
Bug 181982 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2007-06-14 05:31 0000
I'm trying to install openvz-sources (sys-kernel/openvz-sources-028.027) on my
desktop machine. the kernel configuration and installation is correct. I can
boot under the new kernel and manage openvz virtual machines from the command
line. all the drivers for my machine load correctly.

but when I try to compile the closed source ati-drivers
(x11-drivers/ati-drivers-8.37.6-r1, this is a desktop machine, remember), the
compile fail with the following message:

WARNING: "find_task_by_pid"
[/var/tmp/portage/x11-drivers/ati-drivers-8.37.6-r1/work/common/lib/modules/fglrx/build_mod/2.6.x/fglrx.ko]
undefined!
!!! ERROR: x11-drivers/ati-drivers-8.37.6-r1 failed.
Call stack:
  ebuild.sh, line 1615:   Called dyn_compile
  ebuild.sh, line 972:   Called qa_call 'src_compile'
  ebuild.sh, line 44:   Called src_compile
  ati-drivers-8.37.6-r1.ebuild, line 177:   Called linux-mod_src_compile
  linux-mod.eclass, line 516:   Called die

!!! Unable to make  GCC_VER_MAJ=4 KVER=2.6.18-028stab027 KDIR=/usr/src/linux
kmod_build.

I understand that find_task_by_pid is a common function, and I don't understand
why it does not work. I searched on google and I seem to be the first to have
this problem.

I don't even know if this is a bug or a problem with my machine. however,
everything work with everything else on both kernels, and I can compile
ati-drivers with my current kernel (gentoo-sources-2.6.20-r8)


Reproducible: Always

Steps to Reproduce:

------- Comment #1 From Jephte CLAIN 2007-06-14 05:32:26 0000 -------
# emerge --info

Portage 2.1.2.7 (default-linux/x86/2007.0/desktop, gcc-4.1.2, glibc-2.5-r3,
2.6.20-gentoo-r8 i686)
=================================================================
System uname: 2.6.20-gentoo-r8 i686 Intel(R) Pentium(R) M processor 2.13GHz
Gentoo Base System release 1.12.9
Timestamp of tree: Thu, 14 Jun 2007 04:50:01 +0000
dev-java/java-config: 1.3.7, 2.0.32
dev-lang/python:     2.4.4-r4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=i686 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config
/usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/revdep-rebuild
/etc/terminfo"
CXXFLAGS="-O2 -march=i686 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="http://gentoo.modulix.net/gentoo/
http://ftp.club-internet.fr/pub/mirrors/gentoo "
LANG="fr_FR"
LINGUAS="fr"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
--force --whole-file --delete --delete-after --stats --timeout=180
--exclude=/distfiles --exclude=/local --exclude=/packages
--filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="X acl acpi alsa apm arts berkdb bitmap-fonts cairo cdr cli cracklib crypt
cups dbus dri dvd dvdr dvdread eds emboss encode esd evo fam firefox fortran
gdbm gif glitz gnome gpm gstreamer gtk hal howl iconv ipv6 isdnlog java jpeg
kerberos ldap libg++ lm_sensors mad midi mikmod mp3 mpeg mudflap ncurses nls
nptl nptlonly nsplugin ogg opengl openmp oss pam pcre pdf pmu png pppd python
qt3support quicktime readline reflection sasl sdl session slang spell spl ssl
svg tcpd tiff truetype truetype-fonts type1-fonts unicode vorbis win32codecs
x86 xml xorg xv zlib" ALSA_CARDS="intel8x0" ALSA_PCM_PLUGINS="adpcm alaw asym
copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat
linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc"
INPUT_DEVICES="keyboard mouse synaptics" KERNEL="linux" LCD_DEVICES="bayrad
cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="fr"
USERLAND="GNU" VIDEO_CARDS="radeon fglrx vesa fbdev"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LDFLAGS,
PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS,
PORTDIR_OVERLAY

------- Comment #2 From Jakub Moc (RETIRED) 2007-06-14 06:50:37 0000 -------
That's just a warning, not the compile error. You need to post more lines
above.

------- Comment #3 From Jephte CLAIN 2007-06-14 07:28:57 0000 -------
well, it's the only line that seems wrong. I attach the build log below

------- Comment #4 From Jephte CLAIN 2007-06-14 07:31:09 0000 -------
Created an attachment (id=122002) [edit]
the build log from /var/tmp/portage/x11-drivers/ati-drivers-8.37.6-r1/temp

------- Comment #5 From Jakub Moc (RETIRED) 2007-06-14 07:38:04 0000 -------
Shrug; does any other version of ati-drivers compile? 

------- Comment #6 From Jephte CLAIN 2007-06-14 08:19:43 0000 -------
well... it compiles with ati-drivers-8.35.5 (the latest stable). I should have
tested that first :-(. In fact, I was forced to switch to unstable ati-drivers
a while ago and never minded to switch back to stable after that...

ok then. I can use the stable ati-drivers and this solves my problem. now I
can't tell why 8.37.6 doesn't compile on kernel 2.6.18...

------- Comment #7 From Bugs Bunny 2007-06-27 15:20:10 0000 -------
(In reply to comment #6)
> well... it compiles with ati-drivers-8.35.5 (the latest stable). I should have
> tested that first :-(. In fact, I was forced to switch to unstable ati-drivers
> a while ago and never minded to switch back to stable after that...
> 
> ok then. I can use the stable ati-drivers and this solves my problem. now I
> can't tell why 8.37.6 doesn't compile on kernel 2.6.18...
> 

A header is missing in your 2.6.18, ati upstream does not support anything but
vanilla kernel so your on your own to figure out why linux/sched.h is not
included with the openvz-sources.

------- Comment #8 From miedo95f 2007-07-27 07:07:07 0000 -------
try create simbolic link ln -s /usr/src/linux/include/linux/ioctl.h
/usr/src/linux/include/linux/ioctl32.h


(In reply to comment #0)
> I'm trying to install openvz-sources (sys-kernel/openvz-sources-028.027) on my
> desktop machine. the kernel configuration and installation is correct. I can
> boot under the new kernel and manage openvz virtual machines from the command
> line. all the drivers for my machine load correctly.
> 
> but when I try to compile the closed source ati-drivers
> (x11-drivers/ati-drivers-8.37.6-r1, this is a desktop machine, remember), the
> compile fail with the following message:
> 
> WARNING: "find_task_by_pid"
> [/var/tmp/portage/x11-drivers/ati-drivers-8.37.6-r1/work/common/lib/modules/fglrx/build_mod/2.6.x/fglrx.ko]
> undefined!
> !!! ERROR: x11-drivers/ati-drivers-8.37.6-r1 failed.
> Call stack:
>   ebuild.sh, line 1615:   Called dyn_compile
>   ebuild.sh, line 972:   Called qa_call 'src_compile'
>   ebuild.sh, line 44:   Called src_compile
>   ati-drivers-8.37.6-r1.ebuild, line 177:   Called linux-mod_src_compile
>   linux-mod.eclass, line 516:   Called die
> 
> !!! Unable to make  GCC_VER_MAJ=4 KVER=2.6.18-028stab027 KDIR=/usr/src/linux
> kmod_build.
> 
> I understand that find_task_by_pid is a common function, and I don't understand
> why it does not work. I searched on google and I seem to be the first to have
> this problem.
> 
> I don't even know if this is a bug or a problem with my machine. however,
> everything work with everything else on both kernels, and I can compile
> ati-drivers with my current kernel (gentoo-sources-2.6.20-r8)
> 
> 
> Reproducible: Always
> 
> Steps to Reproduce:
> 

------- Comment #9 From Jephte CLAIN 2007-07-29 16:28:36 0000 -------
(In reply to comment #8)
> try create simbolic link ln -s /usr/src/linux/include/linux/ioctl.h
> /usr/src/linux/include/linux/ioctl32.h

I'm on vacations. I will try this in 2 weeks, an report the result. thanks for
the suggestion.

------- Comment #10 From Jephte CLAIN 2007-07-31 15:04:07 0000 -------
(In reply to comment #8)
> try create simbolic link ln -s /usr/src/linux/include/linux/ioctl.h
> /usr/src/linux/include/linux/ioctl32.h

ioctl32.h already exists, and its content is different from ioctl.h
I made the symbolic link (keeping a copy of ioctl32.h) and the problem is the
same:

# cd /usr/src/linux/include/linux
# mv ioctl32.h ioctl32.h.orig
# ln -s ioctl.h ioctl32.h
# emerge =ati-drivers-8.37.6-r1
...
WARNING: "find_task_by_pid"
[/var/tmp/portage/x11-drivers/ati-drivers-8.37.6-r1/work/common/lib/modules/fglrx/build_mod/2.6.x/fglrx.ko]
undefined!
make[2]: *** [__modpost] Erreur 1
make[1]: *** [modules] Erreur 2
make[1]: quittant le répertoire « /usr/src/linux-2.6.18-openvz-028.027 »
make: *** [kmod_build] Erreur 2

!!! ERROR: x11-drivers/ati-drivers-8.37.6-r1 failed.
Call stack:
  ebuild.sh, line 1621:   Called dyn_compile
  ebuild.sh, line 973:   Called qa_call 'src_compile'
  ebuild.sh, line 44:   Called src_compile
  ati-drivers-8.37.6-r1.ebuild, line 174:   Called linux-mod_src_compile
  linux-mod.eclass, line 516:   Called die

!!! Unable to make  GCC_VER_MAJ=4 KVER=2.6.18-028stab027 KDIR=/usr/src/linux
kmod_build.
!!! If you need support, post the topmost build error, and the call stack if
relevant.
!!! A complete build log is located at
'/var/tmp/portage/x11-drivers/ati-drivers-8.37.6-r1/temp/build.log'.

------- Comment #11 From Daniel Robbins 2007-11-16 21:45:22 0000 -------
The issue is that the openvz patch removes the find_task_by_pid macro, which
ati-drivers is now depending on.

The solution is to apply a fix to the upstream openvz patch so that this macro
still continues to exist for compatibility reasons.

Will see if I can get a patch for this.

------- Comment #12 From Daniel Robbins 2007-11-16 21:58:59 0000 -------
OK, here is the solution.

The openvz patch undefines find_task_by_pid and creates two new macros:
find_task_by_pid_ve and find_task_by_pid_all. It also updates all references in
the kernel source code to refer to the new macros.

The problem occurs when other kernel modules use these macros, in which case
they break. Since modules are typically not directly used in your VE's, I use
the following solution to get the ati-drivers to install and build (tested
against ati-drivers 8.40.4). Add the following to include/linux/sched.h:

// drobbins hackzor
#define find_task_by_pid(nr) find_task_by_pid_type_all(PIDTYPE_PID, nr)
extern struct task_struct *find_task_by_pid_type_all(int type, int pid);

This will give any modules that call the find_task_by_pid() macro the default
behavior. This may not be appropriate for all kernel modules, especially those
that need to be aware of VE's. But it is likely to be correct 99% of the time.

------- Comment #13 From Peter Volkov 2007-11-18 07:34:54 0000 -------
Thank you all for report, and Daniel for suggested fix. This bug should be
fixed in 2.6.18.028.049. Note, versioning changed so to emerge this new version
you have to run: 

emerge =sys-kernel/openvz-sources-2.6.18.028.049

Note 2: I did not manage to check that fix really works, as ati binary drivers
do not work with the recent xorg. So if this bug is not fixed, reopen, please.

Also I'm going to mark this new kernel stable in next few days, so if you have
some time, please, try it and report everything you encounter.

------- Comment #14 From Kir Kolyshkin 2008-03-12 19:32:21 0000 -------
Yup, the bug was fixed in 028stab049, here is some more info.

Upstream bug report:
http://bugzilla.openvz.org/show_bug.cgi?id=634

GIT commit:
http://git.openvz.org/?p=linux-2.6.18-openvz;a=commit;h=3d422a091cd4c871ca2781c0e9a6fcaf5180f77e

First Last Prev Next    No search results available      Search page      Enter new bug