From owner-freebsd-current@FreeBSD.ORG Wed Jun 23 04:07:01 2010 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 619731065670; Wed, 23 Jun 2010 04:07:01 +0000 (UTC) (envelope-from faber@zod.isi.edu) Received: from zod.isi.edu (zod.isi.edu [128.9.168.221]) by mx1.freebsd.org (Postfix) with ESMTP id 4518E8FC0A; Wed, 23 Jun 2010 04:07:00 +0000 (UTC) Received: from zod.isi.edu (localhost [127.0.0.1]) by zod.isi.edu (8.14.4/8.14.4) with ESMTP id o5N46v9T025900; Tue, 22 Jun 2010 21:06:57 -0700 (PDT) (envelope-from faber@zod.isi.edu) Received: (from faber@localhost) by zod.isi.edu (8.14.4/8.14.4/Submit) id o5N46uIs025899; Tue, 22 Jun 2010 21:06:56 -0700 (PDT) (envelope-from faber) Date: Tue, 22 Jun 2010 21:06:56 -0700 From: Ted Faber To: Hans Petter Selasky Message-ID: <20100623040656.GC23023@zod.isi.edu> References: <201006230238.06831.hselasky@c2i.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="PuGuTyElPB9bOcsM" Content-Disposition: inline In-Reply-To: <201006230238.06831.hselasky@c2i.net> User-Agent: Mutt/1.4.2.3i X-url: http://www.isi.edu/~faber Cc: freebsd-hackers@freebsd.org, freebsd-current@freebsd.org Subject: Re: [HEADS UP] Kernel modules don't work properly in FreeBSD 8.1-RC1 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jun 2010 04:07:01 -0000 --PuGuTyElPB9bOcsM Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jun 23, 2010 at 02:38:06AM +0200, Hans Petter Selasky wrote: > It appears many kmods are broken because the linker is stripping away sta= tic=20 > data declared with the section attribute in FreeBSD 8.1-RC1. >=20 > >=20 > I added those lines to the LDFLAGS in Makefile.kmod in the cuse4bsd port > made the module and the result loads and creates the /dev/cuse file. Hi. I'm the fellow in Hans's .... If someone's looking into this, it's worth mentioning that the sample cdev kmodule in /usr/share/examples/kld/cdev/ also exhibits the behavior. On my 8.1-PRERELEASE system that module does not create the /dev/cedv device, but if you add the line=20 LDFLAGS +=3D -u __start_set_sysinit_set -u __start_set_sysuninit_set \ -u __start_set_sysctl_set -u __start_set_modmetadata_set \ -u __stop_set_sysinit_set -u __stop_set_sysuninit_set \ -u __stop_set_sysctl_set -u __stop_set_modmetadata_set right before the=20 =2Einclude in /usr/share/examples/kld/cdev/module/Makefile and remake everything, the module creates the /dev/cdev file when it's loaded. That magical line was suggested by Ryan Stone in another thread: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=3D120718+0+current/freebsd-hac= kers Happy hunting, and I'm happy to test patches or provide more information. --=20 Ted Faber http://www.isi.edu/~faber PGP: http://www.isi.edu/~faber/pubkeys.= asc Unexpected attachment on this mail? See http://www.isi.edu/~faber/FAQ.html#= SIG --PuGuTyElPB9bOcsM Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkwhiGAACgkQaUz3f+Zf+XvhngCgm+78NGZnUFXI4z9hJu8fe+H3 CzEAn31VtQ6ByJMglAxKmRIDk/7SUqpF =LPYM -----END PGP SIGNATURE----- --PuGuTyElPB9bOcsM--