From owner-freebsd-hackers@FreeBSD.ORG Fri Feb 17 16:08:20 2012 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4414A1065670 for ; Fri, 17 Feb 2012 16:08:20 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: from mail-vw0-f54.google.com (mail-vw0-f54.google.com [209.85.212.54]) by mx1.freebsd.org (Postfix) with ESMTP id F0C808FC12 for ; Fri, 17 Feb 2012 16:08:18 +0000 (UTC) Received: by vbbfa15 with SMTP id fa15so3417628vbb.13 for ; Fri, 17 Feb 2012 08:08:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=XxbmxHcpIY3eYjwCklu3Jd8w0CZDUVF8MJmNBrZaxOw=; b=Q/uUuWFjI7x5E71Jr2OBKY8fElH6v4qbdXFuy1lypdCt6+qX3HgRr/qVbUAuod763F dLxwrzAYhsQknSYHK51wkAi37+29/w/PkVgIHMu6xIxAChzpH1MgZ5KSSXx1fHZHtEBj Jo+HXRbVyzVq9D7nKRnd+OvoqmFZ38On6aRnQ= MIME-Version: 1.0 Received: by 10.220.210.134 with SMTP id gk6mr4016595vcb.32.1329494898567; Fri, 17 Feb 2012 08:08:18 -0800 (PST) Received: by 10.220.192.135 with HTTP; Fri, 17 Feb 2012 08:08:18 -0800 (PST) In-Reply-To: References: <201202171612.36971.hselasky@c2i.net> <4F3E72B7.2050005@gmail.com> Date: Fri, 17 Feb 2012 08:08:18 -0800 Message-ID: From: Freddie Cash To: Alex Goncharov Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: matt , freebsd-hackers@freebsd.org, hselasky@c2i.net Subject: Re: 8 to 9: Kernel modularization -- did it change? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Feb 2012 16:08:20 -0000 On Fri, Feb 17, 2012 at 8:04 AM, Alex Goncharov wrote: > ,--- You/matt (Fri, 17 Feb 2012 07:31:03 -0800) ----* > | It's in the kernel in later versions of 9-CURRENT and in 9-RELEASE on. > | > | You can't kldload or unload it because it's not a module, but part of > | the kernel. > | That doesn't preclude the presence of the file, I think. > | > | 'kldstat -v | less' should show you what's "in there". > > Thanks, indeed: > > ---------------------------------------- > uname -sr; echo =3D=3D; kldstat | grep hda; echo =3D=3D; kldstat -v | gre= p hda > =3D> > FreeBSD 8.2-STABLE > =3D=3D > 11 =C2=A0 =C2=A01 0xffffffff81039000 14580 =C2=A0 =C2=A0snd_hda.ko > =3D=3D > 11 =C2=A0 =C2=A01 0xffffffff81039000 14580 =C2=A0 =C2=A0snd_hda.ko (/boot= /kernel/snd_hda.ko) > =C2=A0 =C2=A0 =C2=A0 =C2=A0456 hdac/snd_hda_pcm > =C2=A0 =C2=A0 =C2=A0 =C2=A0457 pci/snd_hda > ---------------------------------------- > > uname -sr; echo =3D=3D; kldstat | grep hda; echo =3D=3D; kldstat -v | gre= p hda > =3D> > FreeBSD 9.0-STABLE > =3D=3D > =3D=3D > =C2=A0 =C2=A0 =C2=A0 =C2=A0253 pci/snd_hda > =C2=A0 =C2=A0 =C2=A0 =C2=A0252 hdac/snd_hda_pcm > ---------------------------------------- > > But am I not screwed up then? -> > > I need to adjust the sound card pin assignments so that the sound can > be directed to the headphones when they are plugged in. > > With FreeBSD 8, on several machines, I had gone through somewhat > painful but ultimately meaningful and manageable routine of building > the device.hints file. > > Essentially (consider the following an non-ordered set): > > =C2=A0 =C2=A0kldunload snd_hda.ko > =C2=A0 =C2=A0kenv | grep hdac > =C2=A0 =C2=A0sysctl hw.snd.verbose > =C2=A0 =C2=A0sysctl hw.snd.verbose=3D4 > =C2=A0 =C2=A0kldload snd_hda.ko > =C2=A0 =C2=A0cat /dev/sndstat > =C2=A0 =C2=A0dmesg | grep ^hdac0 > =C2=A0 =C2=A0kenv hint.hdac.0.cad0.nid15.config=3D"as=3D1 seq=3D15 device= =3DHeadphones" > =C2=A0 =C2=A0kldload snd_hda.ko > > I don't believe I can do it now that the snd_hda module cannot be > reloaded in a modified kernel environment. > > So, how do I go about finding and modifying the sound card pin > assignments in FreeBSD 9? =C2=A0(If I can't do it without temporarily > installing FreeBSD 8, it would be a huge disappointment. :) Stick the hint into /boot/loader.conf and reboot. --=20 Freddie Cash fjwcash@gmail.com