Helgrim.com

Hit any user to continue. 

Software » FreeBSD » Fujitsu-Siemens C1020

Notes on running FreeBSD on a Fujitsu-Siemens C1020 Laptop

Introduction

It seems that if you have a laptop and are running *nix on it, the polite thing to do is to stick up a page reporting on your failures or successes. Don't ask me why though, it must be a tradition, or an old charter, or something. There are two approaches to doing this: the short approach, where one lists what works, what doesn't, and provide copies of relevant configuration files; and the rambling approach, where one gives a long and colourful account of all the trials and tribulations, the joys and sorrows, before emerging triumphant, to the accolades of all three people who bother to read it - your cat, your wife, and Jon, a rather helpful fellow from California who sent you an email to point out that you misspelled the word 'colourful' in paragraph one, "colour should be spelled C-O-L-O-R".
Like colon, but with an r. I should mention that I don't have a cat, and I don't have a wife. Anyway, never one to limit people's choices, I'll use both methods, and I'll leave the shorter one to the end, as that is strangely pleasing to me.

Hardware

So I finally bought myself a laptop, a Fujitsu-Siemens C1020. Those of you who read the big bold heading will not be too surprised by this. The C1020 is marketed as an entry-level corporate notebook, which sounded good to me. I'm an entry level corporation. More to the point, it has a serial port, and the '|\' key is to the left of the 'Z' key, just as I like it. I thought it had two PS/2 ports also, but it turns out they were simply a figment of my imagination. I'm slightly concerned that my hallucinations consist of fictitous peripheral connectors, and not something more usual and mundane such as barrels of beer, or scantily clad women. It does have two USB ports though so all is not lost. I've yet to find a three buttoned wireless optical USB notebook mouse in Dublin though. I've found four buttoned optical USB notebook mouses, five buttoned wireless optical desktop mouses, and a two buttoned wireless trackball notebook mouse, but so far it's a case of close, but no banana. Or rather, close, but no three buttoned wireless optical USB notebook mouse. You can buy a 'port replicator' for the C1020, which is actually a docking station without a base, just the bits at the back, and a funky new name that the marketing people probably wet themselves over. Also, apparently Fujitsu-Siemens sell dual-booting versions with windows and linux, so I figured the hardware can't be too disgusting. I was further encouraged when a bit of googling revealed that the internal modem isn't a winmodem, and works happily under linux. The full C1020 specifications are here (PDF, 82K).

Microsoft

So having bought the laptop, time to turn it on. It shipped with windows XP, so I was eager to get started. I've always wondered what happens when you say 'No' to the EULA. I had mental images of a search and destroy squad bursting through the windows, or at least a flyover by a helicopter gunship, but I was to be disappointed. A message was displayed explaining that I wouldn't be able to use the software until I agreed to the terms of the license. No gunshots, no suspicous downdrafts.

Installation

Dissillusioned, I reached for my FreeBSD discs. For the record, the four 4.7-Release CDs, which I'd downloaded and burnt, and the two installation floppies, kern.flp and mfsroot.flp, which I'd downloaded and, er, put onto floppies. No wonder floppy discs are on the way out - no 'cool' verb for copying data onto them. Heck, even the name is a misnomer. I bet if CD's were called compact squares, they'd be on their way out too. Actually, they are, but not until DVD writers come down in price. I digress. I placed CD 1 into the DVD drive, and rebooted. Unfortunately it wouldn't boot as it couldn't figure out what disks were there, and what disk it was running off, and generally became rather confused. Now this may be that it genuinely won't work, or simply that I screwed up some option when burning the CD. At present I'm too lazy to see it the machine 4 feet behind me will boot from it, as I simply used the floppies instead.

The installation went swimmingly, or as swimmingly as a laptop should ever go. I used defaults for everything, and had no trouble reading the CD. I skipped the post install configuration first time round, just to be sure that it worked, which it did.

Having confirmed that it did what it did do, I redid what I'd done. The laptop can be upgraded to 1GB DDR SDRAM, and I hope to do so soon enough, so I wanted to allocate enough swap space. For those unaware of these things, apparently you should allocate at least twice as much swap space as you have physical memory. As an aside, the C1020 doesn't do suspend to disk, only suspend to RAM, thus there's no need to allocate a dos partition to support this.

X

So I reinstalled, this time with as many bells and whistles as possible. However, since FreeBSD never supports sound with it's generic installs, the bells and whistles numbered zero. Mind you, I think this is to change with the next major release, more on this later. My first problem was getting X running. The GUI X configurator, xf86cfg, choked instantly as it has with every other machine I've had (don't ask). However the ncurses version of it works fine. The main choices were PS/2 Mouse, Emulate3Buttons, Generic 105 Keyboard, High Frequency SVGA (31.5 - 57.0), 1024x768 @ 70 Hz, vertical sync range 50-90, S3 ProSavage, 24 bits, 16Mb colors, 1024x768. If this doesn't work, use my XF86Config file. Just copy it to /etc/X11 and it should work. Now, this may not all be optimal, but it worked, which at this point in time was all I was interested in. The graphics card apparently supports up to 1600x1200 screen resolution on external CRTs, but I haven't tested this yet.

Network

Next up was to test the builtin network card and modem. According to dmesg, the network card is a RealTek 8139, so it picks it up and installs it as /dev/rl0. So I connected my network cable between my laptop and my desktop, and tried pinging between them, but to no avail. However, I wasn't too worried, as I only had one cable, and I expected that the cable itself was dodgy, or something stupid like that.

Indeed, it was something stupid like that - or rather, something stupid like me. The astute among you will have realised that I wasn't using a network hub, just plugged the cable into the two cards. In order to do this, you need to use a crossover cable, not a normal cable, but being the moron that I am, it wasn't until the following day that I remembered. To make matters worse, I couldn't find the crimper, so I ended up having to buy the damn cable. But it works fine, not a bother. While I'm on the subject, and so I remember where I put it, here's the layout for crimping a crossover cable:
RJ45-568 straight-through wiring
Straight-through
RJ45-568b cross-over wiring
Cross-over

Sound and Modem

The internal modem didn't work. It was recognised by dmesg, but playing with ppp didn't do anything with it. Since the specs describe it as an 'audio modem' I guessed it may by tied in with the soundcard, so I rebuilt my kernel, adding 'device pcm' to try enabling the sound, and 'device apm0' to enable power management. Having rebuilt and rebooted, they appeared as:

pcm0: <VIA VT8233> port 0xe100-0xe1ff irq 10 at device 17.5 on pci0
chip1: <VIA 82C686 AC97 Modem> port 0xe200-0xe2ff irq 10 at device 17.6 on pci0
However, all was silent. As mentioned before the modem apparently works with linux, so I figured to leave this to the mailing lists. I played with a few other configurations for the sound card, but not in any great detail, again adding that to lists.

Power management

It's always nice to know when your battery is running out. Especially since the C1020 doesn't give any warning beeps, it just dies. I've never used power management before, but I knew KDE comes with power indicators and the like, so I figured that's a good place to start. Unfortunately, it reported that 'my kernel doesn't support power management'. Now I'd definately turned on APM in my new kernel, so it was time to google. I found a linux site which mentioned that it wouldn't work until it had the battery had been calibrated. When you turn the laptop on, you're given the option of pressing F6 to calibrate the battery. This involves leaving the laptop to run while it studies the performance of the battery. Unfortunately, there's no mention of how this should be carried out. Do you plug the laptop in? Should you start with a full battery, and let it run out, or an empty battery? How long will it take? I sought enlightenment in the laptop documentation, found the section dealing with 'battery auto-learning' and discovered that it should be done every six months. I was kinda hoping for something more precise... In the end, I let it run through a full battery, without external power, And then plugged it in and let it run overnight. I must check with Siemens about this.

The next day, I tried again, but still to no avail. Finally, I noticed in the Siemens documentation that the power management is described as 'ACPI'. Google revealed that this is a new 'standard' for power management functions, and that it's not supported on FreeBSD 4.7. The good news however is that it will be supported by 5.0, so I guess I'll have to do without power management for a while.

Infrared

The other thing I haven't particularily tried out is the infrared port. According to the BIOS it's attached as COM2, so I'm told that it should work out of the box with the comms/birda package. I dabbled briefly with it and my phone, with mixed results. When I say 'mixed results', I really mean 'no results'. I didn't have any successes, but then, I didn't encounter any errors either. I've never used the IrDa stuff before, so I'm probably doing something wrong. Another one for the mailing lists I guess.

Short version

Now here's the short version of everything that has gone before: FreeBSD 4.7 works on it, but you may need to boot from the floppies. The screen works at 1024x768, with the following XF86Config, but the soundcard, modem, and power management don't. The IrDa hasn't been tested properly.

Given that ACPI is supported in 5.0, the sensible thing to do it to see how well 5.0 works with it, and see if the sound etc maybe work too. So, coming soon, "how to dual boot 4.7 and 5.0". Right now, I'm going to bed. You probably should too.

© Feargal Reilly 2003-2008 | feargal@helgrim.com | Hosting by FBI | Valid HTML 4.01 | Valid CSS