Sony Vaio VGN-CS21S
This is a work in-progress howto guide for installing Gentoo on a Sony Vaio VGN-CS21S (and familiar). Please feel free to update this page. Of course all editors of this page do not give any guarantees.
The basic installation of gentoo is the same as described in the Handbook. Detail for some specialties follow later in this article.
Contents |
[edit] Hardware
CPU unit : Intel(R) Core(TM)2 Duo CPU T6400 @ 2.00GHz
RAM : 4Gb DDR2 SDRAM (2x2Gb; 400Mhz)
Harddisk : Sata Hardisk of 320Gb
Optical media : DVD player/burner (all types including dual layer)
Screen : LCD 14.1 inch (1280x800 32bits 50Hz)
Display adapter : NVIDIA GeForce 9300M GS GPU (external RGB connector)
Wiredlan LAN : Marvell Technology, 88E8040 (RJ45)
Wireless LAN : Intel Wifi Link 5100
Bluetooth : <type unknown>
Modem : <type unknown>
USB : 3 ports (version 2.0)
Firewire : 1 port, Ricoh, R5C832
Card readers : 2 types (SD and Magic Gate pro)
Soundcard : Intel HD Audio Controller (1 mic in; 1 headphones out; stereo speakers)
Webcam : Motion eye webcam (usb; Ricoh)
The official list can be found on the Sony Website.
Below is a detailed summary generated by listing all PCI devices (with lspci)
| Code: # lspci |
00:00.0 Host bridge: Intel Corporation Mobile 4 Series Chipset Memory Controller Hub (rev 07) 00:01.0 PCI bridge: Intel Corporation Mobile 4 Series Chipset PCI Express Graphics Port (rev 07) 00:1a.0 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #4 (rev 03) 00:1a.1 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #5 (rev 03) 00:1a.7 USB Controller: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #2 (rev 03) 00:1b.0 Audio device: Intel Corporation 82801I (ICH9 Family) HD Audio Controller (rev 03) 00:1c.0 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 1 (rev 03) 00:1c.2 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 3 (rev 03) 00:1c.4 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 5 (rev 03) 00:1d.0 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #1 (rev 03) 00:1d.1 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #2 (rev 03) 00:1d.2 USB Controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #3 (rev 03) 00:1d.7 USB Controller: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #1 (rev 03) 00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev 93) 00:1f.0 ISA bridge: Intel Corporation ICH9M LPC Interface Controller (rev 03) 00:1f.2 SATA controller: Intel Corporation ICH9M/M-E SATA AHCI Controller (rev 03) 00:1f.3 SMBus: Intel Corporation 82801I (ICH9 Family) SMBus Controller (rev 03) 01:00.0 VGA compatible controller: nVidia Corporation GeForce 9300M GS (rev a1) 02:00.0 Ethernet controller: Marvell Technology Group Ltd. 88E8040 PCI-E Fast Ethernet Controller (rev 12) 03:00.0 Network controller: Intel Corporation Wireless WiFi Link 5100 06:02.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05) 06:02.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22) 06:02.2 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12) |
The below listing shows the details on the CPU unit:
| Code: # cat /proc/cpuinfo |
processor : 0 and 1
vendor_id : GenuineIntel
cpu family : 6
model : 23
model name : Intel(R) Core(TM)2 Duo CPU T6400 @ 2.00GHz
stepping : 10
cpu MHz : 1200.000
cache size : 2048 KB
physical id : 0
siblings : 2
core id : 0
cpu cores : 2
apicid : 0
initial apicid : 0
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm
constant_tsc arch_perfmon pebs bts pni dtes64 monitor ds_cpl est tm2 ssse3 cx16 xtpr pdcm sse4_1 xsave lahf_lm
bogomips : 3989.86
clflush size : 64
power management:
|
[edit] Stage and make.conf
The core 2 processor is an x64 cpu, so get an amd64 stage. The march setting is nocona.
CFLAGS="-O2 -mtune=nocona -pipe"
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j5"
...
[edit] Kernel configuration
You can simply use gentoo-sources for this machine. For a reported working vanilla-sources configuration, see File:Sony-vaio-cs21s-vanilla-sources.2.6.29.config.txt (32bit). File:Sony-vaio-cs21s-vanilla-sources.2.6.30-64bit.config.txt (64bit)
[edit] Processor settings
The Core 2 Duo is a processor family type which can be selected. You also need SMP and multi core scheduler support.
| Linux Kernel Configuration: Processor |
Processor type and features --->
[*] Symmetric multi-processing support
Subarchitecture Type (PC Compatible) --->
Processor family (Core 2/newer Xeon) -->
(2) Maximum number of CPUs (2-255)
[*] Multi-core scheduler support
|
[edit] IDE controller
The laptop has a SATA controller for it's HD and DVD-recorder. The following options are needed in the kernel. The manufacture and type of the SATA controller is: Intel Corporation ICH9M/M-E SATA AHCI Controller.
| Linux Kernel Configuration: SATA device |
Device Drivers --->
Serial ATA (prod) and Parallel ATA (experimental) drivers -->
[*] ATA ACPI Support
[*] SATA Port Multiplier support
[*] AHCI SATA support
<*> ATA SFF support
<*> Intel ESB, ICH, PIIX3, PIIX4 PATA/SATA support
SCSI device support --->
<*> SCSI disk support
<*> SCSI target support
<*> SCSI CDROM support
|
When correctly configured the following information about the devices can be found here:
| Code: cat /proc/scsi/scsi |
Attached devices: Host: scsi0 Channel: 00 Id: 00 Lun: 00 Vendor: ATA Model: Hitachi HTS54323 Rev: FB4O Type: Direct-Access ANSI SCSI revision: 05 Host: scsi1 Channel: 00 Id: 00 Lun: 00 Vendor: MATSHITA Model: DVD-RAM UJ880AS Rev: 1.20 Type: CD-ROM ANSI SCSI revision: 05 |
[edit] USB support
To enable usb for this machine activate the following options in the kernel config.
| Linux Kernel Configuration: USB device |
Device Drivers --->
[*] USB support --->
<*> Support for Host-side USB
[*] USB announce new devices
[*] USB device filesystem
[*] USB selective suspend/resume and wakeup
<M> EHCI HCD (USB 2.0) support
<M> UHCI HCD (most Intel and VIA) support
<M> USB Mass Storage support
|
[edit] Power management
To use power management functions activate the ACPI support in the kernel config.
| Linux Kernel Configuration: ACPI |
Power management options --->
[*] Power Management support
[*] Suspend/resume event tracing
[*] Suspend to RAM and standby
[*] Hibernation (aka 'suspend to disk')
[*] ACPI (Advanced Configuration and Power Interface) Support --->
[*] Deprecated power /proc/acpi folders
[*] Future power /sys interface
[*] Deprecated /proc/acpi/event support
<M> AC Adapter
<M> Battery
<M> Button
<M> Fan
<M> Dock
<M> Processor
<M> Thermal Zone
(0) Disable ACPI for systems before Jan 1st this year
CPU Frequency scaling --->
[*] CPU Frequency scaling
[ ] Enable CPUfreq debugging
Default CPUFreq governor (ondemand) --->
-*- 'performance' governor
<*> 'powersave' governor
<*> 'userspace' governor for userspace frequency scaling
-*- 'ondemand' cpufreq policy governor
<*> 'conservative' cpufreq governor
*** CPUFreq processor drivers ***
<M> ACPI Processor P-States driver
-*- CPU idle PM support
|
[edit] Wired network adapter
For the Marvell Technology, 88E8040 ethernet adapter you needed the following driver. This driver suggest that the adapter support 1Gbit although the Sony website states 100Mbit.
| Linux Kernel Configuration: Wired Ethernet |
Device Drivers --->
[*] Network device support --->
[*] Ethernet (1000 Mbit) --->
<*> SysKonnect Yukon2 support
|
[edit] Wireless network adapter
For the Intel Wireless WiFi Link 5100 you need the following stuff in your kernel. Enable the "mac80211" WLAN stack and crypto options for WEP, WPA and WPA2 support.
| Linux Kernel Configuration: Wireless |
Device Drivers --->
[*] Network device support --->
Wireless LAN --->
[*] Wireless LAN (IEEE 802.11)
{*} Intel Wireless Wifi Core
[*] Iwlwifi RF kill support
<*> Intel Wireless WiFi Next Gen AGN
[*] Enable Spectrum Measurement in iwlagn driver
[*] Enable LEDS features in iwlagn driver
[*] Intel Wireless WiFi 5000AGN
[*] Cryptographic API --->
--- Cryptographic API
<*> Cryptographic algorithm manager
<*> SHA1 digest algorithm
<*> SHA224 and SHA256 digest algorithm
<*> ECB support
<*> CBC support
<*> PCBC support
<*> AES cipher algorithms
<*> ARC4 cipher algorithm
<*> Michael MIC keyed digest algorithm
|
Besides the kernel options you need to emerge a firmware package. The command to do this is:
[edit] Bluetooth
Bluetooth can be configured by following the comprehensive instructions in the Gentoo Blutooth Guide [1]. Bellow is the bluetooth kernel-configuration for this laptop
| Linux Kernel Configuration: Sound |
Networking --->
<*> Bluetooth subsystem support --->
<*> L2CAP protocol support
<*> SCO links support
<*> RFCOMM protocol support
[*] RFCOMM TTY support
<*> BNEP protocol support
[*] Multicast filter support
[*] Protocol filter support
<*> HIDP protocol support
Bluetooth device drivers --->
<*> HCI USB driver
[*] SCO (voice) support
<*> HCI UART driver
[*] UART (H4) protocol support
[*] BCSP protocol support
[*] Transmit CRC with every BCSP packet
|
[edit] Sound card
The chipset used is an Intel HDA one. The kernel-driver you need to enable is Intel HD Audio:
| Linux Kernel Configuration: Sound |
Device Drivers --->
Sound --->
<*> Sound card support
Advanced Linux Sound Architecture --->
<*> Advanced Linux Sound Architecture
PCI devices --->
<*> Intel HD Audio
|
Emerge media-sound/alsa-utils for the ALSA init-script.
Also see the ALSA guide for further instruction.
[edit] Videocard
You best use the binary nvidia drivers with this laptop.
Note that brightness control does not work either with the Sony laptop module or the standard video ACPI module.
Brightness can be controlled using the nvclock utility.
To install nvclock, issue the following command:
The brightness can the be set with:
Or:
See:
for more details.
These commands can be mapped to hotkeys in KDE using khotkeys in Control Centre.
You can also place an entry in rc.local to set the default brightness on boot to (eg 80%).
KDE4 users might also be interested in: kdedimmer (on sf.net) [2]. There is an (beta) ebuild file for this you can find it here: File:Kde-misc-kdedimmer-0.1.2-r2.ebuild.txt.
[edit] Webcam
The webcam in this sony vaio is called "motion eye". Unfortunately this name is used for several types of webcams. The webcam in this computer is an usb device which can easily be detected using lsusb (part of sys-apps/usbutils). It is a Ricoh.
| Code: # lsusb |
... Bus 001 Device 002: ID 05ca:183f Ricoh Co., Ltd ... |
This webcam is supported by the in-kernel uvcvideo driver [3] by enabling the following kernel options:
| Linux Kernel Configuration: Webcam |
Device Drivers --->
Multimedia devices --->
<M> Video For Linux
[*] Video capture adapters --->
[*] Autoselect pertinent encoders/decoders and other helper chips
[*] V4L USB devices --->
<*> USB Video Class (UVC)
[*] UVC input events device support
|
There is a simple console tool to test the webcam. Install it using this command:
Run the tool by executing:
Also see webcam.