[prev in list] [next in list] [prev in thread] [next in thread]
List: freebsd-mobile
Subject: Thinkpad T23 Setup (part 1)
From: "Michael W. Collette" <metrol () metrol ! net>
Date: 2002-05-14 10:00:36
[Download RAW message or body]
Have a bit too much here to cover in a single E-Mail, so I'm breaking this up
in parts. Mostly I want to get around to addressing the proper X config, but
there are some preliminary issues that need addressed prior to that.
First off, if you're planning on using either KDE or Gnome you really need to
have sound functioning before getting into compiling either one. I didn't
try to compile either prior to sound working, but as I recall from a long ago
battle with these things you'd end up having to recompile after getting your
sound configured. Not sure exactly how long Gnome took, but KDE was well
over 4 hours of compiling here.
Before you get into doing the sound, you'll want to make sure that APM support
is up and running. I actually did this last, which I found out the hard way
was a serious mistake. Without APM going, if you suspend the laptop then
resume operations, an attempt to access sound will hard lock the system.
Don't bother asking me why, I'm just a silly user type out here. With APM,
you can suspend while in the middle of playing sound without a problem.
Last note before I seriously get into this. The configuration for the sound
device is a temporary hack. I simply haven't had the time to test out a more
comprehensive solution posted to this list. I can say with reasonable
certainty that this have been very stable for me, and it even sounds good!
Just note that this information is pretty much obsolete as I write this.
Before FreeBSD:
------------------------------------------------------------------------
If you still have that Windows thing on your system, I would recommend getting
the 2 bios updates that IBM has on their web site. I was going to provide a
link here, but IBM's site is slower than heck at the moment. There's a bios
upgrade and a device upgrade patch that you'll be looking for in there. I
don't know if they are needed to proceed, but they sure didn't hurt anything
here. I loaded both of these just prior to completely deleting the Windows
partition. That felt gooood.
What to do:
------------------------------------------------------------------------
Going to need to do some source code tweaking to 3 files, and get the kernel
config all proper to get this going. This should address sound, apm, and
keyboard issues.
Thanks to Troy for pointing me in the right direction of the pr's that cover
the sound issues...
http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/36716
http://www.freebsd.org/cgi/query-pr.cgi?pr=i386/36972
If you edit the files described in these pr's you stand a chance of having
your system actually be able recognize the sound card. I personally just
edited these with ee.
Then you'll need to get in and fix up ac97.c with this bit of a hack to change
the delay timing. Where the above tweaks allow FreeBSD to see the card, this
tweak is needed to actually get some noise out.
/usr/src/sys/dev/sound/pcm/ac97.c
replace:
DELAY (10000);
with:
DELAY (40000);
You'll find this twice in that file. With those quickies outta the way you
should be ready to tweak on the kernel config.
Here's what all I've got for a kernel configuration. There's a couple of
things in here that aren't exactly obvious. I'll talk about them briefly
below.
Kernel config:
------------------------------------------------------------------------
#
# MetKernel -- Metrol kernel configuration file for FreeBSD/i386
# for use with IBM Thinkpad T23 Type 2647
#
# $FreeBSD: src/sys/i386/conf/MetKernel 2002/05/13
machine i386
cpu I686_CPU
ident MetKernel
maxusers 128
options MATH_EMULATE #Support for x87 emulation
options INET #InterNETworking
# options INET6 #IPv6 communications protocols
options FFS #Berkeley Fast Filesystem
options FFS_ROOT #FFS usable as root device [keep this!]
options SOFTUPDATES #Enable FFS soft updates support
options UFS_DIRHASH #Improve performance on big directories
# options MFS #Memory Filesystem
options MD_ROOT #MD is a potential root device
options NFS #Network Filesystem
options NFS_ROOT #NFS usable as root device, NFS required
options MSDOSFS #MSDOS Filesystem
options CD9660 #ISO 9660 Filesystem
options CD9660_ROOT #CD-ROM usable as root, CD9660 required
options PROCFS #Process filesystem
options COMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!]
# options SCSI_DELAY=15000 #Delay (in ms) before probing SCSI
options UCONSOLE #Allow users to grab the console
options USERCONFIG #boot -c editor
options VISUAL_USERCONFIG #visual boot -c editor
options KTRACE #ktrace(1) support
options SYSVSHM #SYSV-style shared memory
options SYSVMSG #SYSV-style message queues
options SYSVSEM #SYSV-style semaphores
options P1003_1B #Posix P1003_1B real-time extensions
options _KPOSIX_PRIORITY_SCHEDULING
options ICMP_BANDLIM #Rate limit bad replies
options KBD_INSTALL_CDEV # install a CDEV entry in /dev
options NETSMB #SMB/CIFS requester
options NETSMBCRYPTO #encrypted password support for SMB
options LIBMCHAIN #mbuf management library
# Kernel side iconv library
options LIBICONV
device isa
device eisa
device pci
# Floppy drives
device fdc0 at isa? port IO_FD1 irq 6 drq 2
device fd0 at fdc0 drive 0
# device fd1 at fdc0 drive 1
# ATA and ATAPI devices
device ata0 at isa? port IO_WD1 irq 14
device ata1 at isa? port IO_WD2 irq 15
device ata
device atadisk # ATA disk drives
device atapicd # ATAPI CDROM drives
# device atapifd # ATAPI floppy drives
# device atapist # ATAPI tape drives
options ATA_STATIC_ID #Static device numbering
# SCSI peripherals
device scbus # SCSI bus (required)
device da # Direct Access (disks)
# atkbdc0 controls both the keyboard and the PS/2 mouse
device atkbdc0 at isa? port IO_KBD
device atkbd0 at atkbdc? irq 1 flags 0x1
device psm0 at atkbdc? irq 12
device vga0 at isa?
options VESA
options SC_PIXEL_MODE
# splash screen/screen saver
pseudo-device splash
# syscons is the default console driver, resembling an SCO console
device sc0 at isa? flags 0x100
# Enable this and PCVT_FREEBSD for pcvt vt220 compatible console driver
device vt0 at isa?
options XSERVER # support for X server on a vt console
options FAT_CURSOR # start with block cursor
# If you have a ThinkPAD, uncomment this along with the rest of the PCVT lines
options PCVT_SCANSET=2 # IBM keyboards are non-std
# Floating point support - do not disable.
device npx0 at nexus? port IO_NPX irq 13
# Power management support (see LINT for more options)
device apm0 at nexus?
options SPIGOT_UNSECURE
# PCCARD (PCMCIA) support
device card
device pcic0 at isa? irq 0 port 0x3e0 iomem 0xd0000
device pcic1 at isa? irq 0 port 0x3e2 iomem 0xd4000 disable
# Serial (COM) ports
device sio0 at isa? port IO_COM1 flags 0x10 irq 4
device sio1 at isa? port IO_COM2 irq 3
device sio2 at isa? disable port IO_COM3 irq 5
device sio3 at isa? disable port IO_COM4 irq 9
# Parallel port
device ppc0 at isa? irq 7
device ppbus # Parallel port bus (required)
device lpt # Printer
device ppi # Parallel port interface device
# PCI Ethernet NICs that use the common MII bus controller code.
# NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
device miibus # MII bus support
device fxp # Intel EtherExpress PRO/100B (82557, 82558)
# Pseudo devices - the number indicates how many units to allocate.
pseudo-device loop # Network loopback
pseudo-device ether # Ethernet support
pseudo-device sl 1 # Kernel SLIP
pseudo-device ppp 1 # Kernel PPP
pseudo-device tun # Packet tunnel.
pseudo-device pty # Pseudo-ttys (telnet etc)
pseudo-device bpf #Berkeley packet filter
# USB support
device uhci # UHCI PCI->USB interface
device ohci # OHCI PCI->USB interface
device usb # USB Bus (required)
device ugen # Generic
device uhid # "Human Interface Devices"
device ukbd # Keyboard
device ulpt # Printer
device umass # Disks/Mass storage - Requires scbus and da
device ums # Mouse
device uscanner # Scanners
device urio # Diamond Rio MP3 Player
# Sound Support
device smbus
device ichsmb
device smb
device pcm
options PCI_ENABLE_IO_MODES
------------------------------------------------------------------------
Turns out you really do need to enable that PCVT_SCANSET line for these
Thinkpads. Didn't really notice a keyboard problem until I started trying to
map keys in KDE. Some of the combos weren't being picked up.
The apm0 config is a little different from what is sitting in GENERIC. I
picked up this line from tweaking on an older Compaq laptop. The unsecure
thing in there is so mere mortal users can access the power functions.
Yes, you really need all that stuff for the sound support. I don't understand
all the details, but I am listening to the B-52's at this moment so it can't
be all bad.
And to finish off this config stuff for the base system, here is a copy of my
rc.conf that seems to be working well enough for me.
/etc/rc.conf
------------------------------------------------------------------------
# /etc/rc.conf
# Give this here perty laptop a name
#
hostname="metlap.priv.metrol.net"
# Security Settings
#
kern_securelevel_enable="NO"
check_quotas="NO"
# Basic Network Settings
#
network_interfaces="fxp0 lo0"
ifconfig_lo0="inet 127.0.0.1"
ifconfig_fxp0="inet 192.168.0.4 netmask 255.255.255.0"
defaultrouter="192.168.0.2"
# Network Services
#
inetd_enable="YES"
nfs_client_enable="NO"
sshd_enable="YES"
sendmail_enable="YES"
ntpdate_enable="YES"
# Hardware Services
#
apm_enable="YES"
usbd_enable="YES"
pccard_enable="YES"
moused_enable="YES"
# Put down the pitch fork and pretend to be a penquin
linux_enable="YES"
# Some kinda NFS thing. Need to read up on this.
nfs_reserved_port_only="YES"
# Tell NTPD who to ask for the time.
ntpdate_flags="ntp.ucsd.edu"
# Console side screen saver.
saver="daemon"
# Turn off that freaking Bell! Ack, ppht, hrrmph!
keybell="off"
------------------------------------------------------------------------
I have not yet performed any testing with USB devices, PCMCIA cards, or the
modem as of yet. Due to this, I can't say if this config will be sufficient
for dealing with those topics.
Next up, configuring X.
Later on,
--
"Outside of a dog, a book is man's best friend. Inside of a dog, it's too dark
to read."
- Groucho Marx
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic