Hi, all,
Today, I almost finish LinuxBIOS on Tyan s3992. A text-mode RedHat is booted, and a "Hello, World" is written and run. Thank a lot of people here. The mistake I made is building LinuxBIOS on a FC machine and testing it on another RH machine, many machine check panics arose.
The one thing left is that keyboard is not enabled in Linux. It seems it is not correctly configured in LinuxBIOS. I have to use a serial port and terminal to access the machine. Where the keyboard is enabled in LinuxBIOS? And maybe easier, Linux has some kind of application like Windows to configure keyboard or not?
Best Regards
丰立波 Feng Libo @ AMD Ext: 20906 Mobile Phone: 13683249071 Office Phone: 0086-010-62801406
On 8/2/07, Feng, Libo Libo.Feng@amd.com wrote:
Hi, all,
Today, I almost finish LinuxBIOS on Tyan s3992. A text-mode RedHat is booted, and a "Hello, World" is written and run. Thank a lot of people here. The mistake I made is building LinuxBIOS on a FC machine and testing it on another RH machine, many machine check panics arose.
The one thing left is that keyboard is not enabled in Linux. It seems it is not correctly configured in LinuxBIOS. I have to use a serial port and terminal to access the machine. Where the keyboard is enabled in LinuxBIOS? And maybe easier, Linux has some kind of application like Windows to configure keyboard or not?
This is great news!
What chip is the keyboard connected to? Then we can see how to enable it.
ron
Hi,
The Super IO is nsc-87417, there is a directory for the chip. I have enabled the keyboard device in mainboard Config.lb, as below,
Device pnp 2e.6 on io 0x60 = 0x60 io 0x62 = 0x64 irq 0x70 = 1 End However, in super/nsc/pc87417/superio.c, the keyboard pnp_info is {&ops, PC87417_KBCK, PNP_IO0 | PNP_IO1 | PNP_IRQ0, {0x7f8, 0}, {0x7f8, 4}}, is it correct? I think it should be PNP_IRQ1, {0x60, 0} and {0x60, 4}, I changed it, but still no keyboard. What should I do next?
Best Regards
??? Feng Libo @ AMD Ext: 20906 Mobile Phone: 13683249071 Office Phone: 0086-010-62801406
-----Original Message----- From: ron minnich [mailto:rminnich@gmail.com] Sent: Thursday, August 02, 2007 11:32 PM To: Feng, Libo Cc: linuxbios@linuxbios.org Subject: Re: [LinuxBIOS] No keyboard.
On 8/2/07, Feng, Libo Libo.Feng@amd.com wrote:
Hi, all,
Today, I almost finish LinuxBIOS on Tyan s3992. A text-mode RedHat is booted, and a "Hello, World" is written and run. Thank a lot of people here. The mistake I made is building LinuxBIOS on a FC machine and testing it on another RH machine, many machine check panics arose.
The one thing left is that keyboard is not enabled in Linux. It seems it is not correctly configured in LinuxBIOS. I have to use a serial port and terminal to access the machine. Where the keyboard is enabled in LinuxBIOS? And maybe easier, Linux has some kind of application like Windows to configure keyboard or not?
This is great news!
What chip is the keyboard connected to? Then we can see how to enable it.
ron
Hi,
On Thu, Aug 02, 2007 at 05:21:05PM +0800, Feng, Libo wrote:
Today, I almost finish LinuxBIOS on Tyan s3992. A text-mode RedHat is booted, and a "Hello, World" is written and run.
Excellent! :)
Thank a lot of people here. The mistake I made is building LinuxBIOS on a FC machine and testing it on another RH machine, many machine check panics arose.
The GNU toolchain (gcc and binutils) in the FC system may be unable to build LB correctly. Can you tell us what version of gcc and binutils you were using in the FC system that produced bad results, and what version you have used to produce a working result?
The one thing left is that keyboard is not enabled in Linux. It seems it is not correctly configured in LinuxBIOS. I have to use a serial port and terminal to access the machine. Where the keyboard is enabled in LinuxBIOS?
That depends on what the keyboard connects to. Is it a USB keyboard or a PS/2 keyboard? Whatever it is, could you also try the other? Also see Ron's question about which chip the keyboard is connected to.
And maybe easier, Linux has some kind of application like Windows to configure keyboard or not?
Not always an application, but there are configuration files in most if not all Linux distributions for setting up the keymap. That doesn't help if the kernel can't see the keyboard however. Feel free to send a serial port capture from a full boot with LB to the mailing list, we'll look at it and see if we can find something pointing to the error.
//Peter
Hi,
I built LinuxBIOS on Linux version 2.6.11-1.1369_FC4smp and gcc version 4.0.0 20050525, then tested LinuxBIOS on Linux version 2.6.9-22 Elsmp and gcc version 3.4.4 20050721. There were always many kind of machine check panics.
Now I build and test on Linux version 2.6.9-22 Elsmp and gcc version 3.4.4 20050721.
I have tried both USB and PS/2 keyboard, neither can work. I changed some code, it still doesn't work. Maybe I miss something. In Linux, kudzu can do some hardware detect, but don't work in this case. The attached is a log, maybe you can help me find some clue. Thank you. We just want to gain some BIOS experience, so the LinuxBIOS version is very old.
Best Regards
??? Feng Libo @ AMD Ext: 20906 Mobile Phone: 13683249071 Office Phone: 0086-010-62801406
-----Original Message----- From: linuxbios-bounces@linuxbios.org [mailto:linuxbios-bounces@linuxbios.org] On Behalf Of Peter Stuge Sent: Friday, August 03, 2007 4:43 AM To: linuxbios@linuxbios.org Subject: Re: [LinuxBIOS] No keyboard.
Hi,
On Thu, Aug 02, 2007 at 05:21:05PM +0800, Feng, Libo wrote:
Today, I almost finish LinuxBIOS on Tyan s3992. A text-mode RedHat is booted, and a "Hello, World" is written and run.
Excellent! :)
Thank a lot of people here. The mistake I made is building LinuxBIOS on a FC machine and testing it on another RH machine, many machine check panics arose.
The GNU toolchain (gcc and binutils) in the FC system may be unable to build LB correctly. Can you tell us what version of gcc and binutils you were using in the FC system that produced bad results, and what version you have used to produce a working result?
The one thing left is that keyboard is not enabled in Linux. It seems it is not correctly configured in LinuxBIOS. I have to use a serial port and terminal to access the machine. Where the keyboard is enabled in LinuxBIOS?
That depends on what the keyboard connects to. Is it a USB keyboard or a PS/2 keyboard? Whatever it is, could you also try the other? Also see Ron's question about which chip the keyboard is connected to.
And maybe easier, Linux has some kind of application like Windows to configure keyboard or not?
Not always an application, but there are configuration files in most if not all Linux distributions for setting up the keymap. That doesn't help if the kernel can't see the keyboard however. Feel free to send a serial port capture from a full boot with LB to the mailing list, we'll look at it and see if we can find something pointing to the error.
//Peter
-- linuxbios mailing list linuxbios@linuxbios.org http://www.linuxbios.org/mailman/listinfo/linuxbios
On Fri, Aug 03, 2007 at 06:34:23PM +0800, Feng, Libo wrote:
I built LinuxBIOS on Linux version 2.6.11-1.1369_FC4smp and gcc version 4.0.0 20050525, then tested LinuxBIOS on Linux version 2.6.9-22 Elsmp and gcc version 3.4.4 20050721. There were always many kind of machine check panics.
Now I build and test on Linux version 2.6.9-22 Elsmp and gcc version 3.4.4 20050721.
Kernel versions should not matter, but both kernels are patched (RedHat?) so we can't be sure. I don't trust patched kernels.
gcc version is the same on both the non-working system and the currently working system. Can you also check the version of binutils on old and new system? (e.g. by running ld --version or nm --version)
I have tried both USB and PS/2 keyboard, neither can work.
From the serial output I see that it is impossible for a USB keyboard
to work. More below. USB and PS/2 are quite different code paths in the kernel, until one of them is working there is surely some generic problem, quite possibly in LB.
I changed some code, it still doesn't work. Maybe I miss something. In Linux, kudzu can do some hardware detect, but don't work in this case.
Can you get more details from kudzu about why it fails? Perhaps by running it manually after the system has booted? Perhaps by looking in the syslog files? I don't know much about RedHat so I can't give much advice on kudzu. (On the other hand, kudzu itself is not very important, having the hardware work is important, and then kudzu will be happy too.)
The attached is a log, maybe you can help me find some clue. Thank you.
Great - see some comments below.
We just want to gain some BIOS experience, so the LinuxBIOS version is very old.
This can be both good and bad. If you started from a known working LB version then there's no big problem, but if a lot of changes and bugfixes have gone into LB since the version you are using, it could be worthwhile to try also a new version.
Comments on the log:
PCI: pci_scan_bus for bus 00 PCI: 00:01.0 [1166/0036] enabled
HT1000 PCI/PCI-X bridge
PCI: 00:02.0 [1166/0205] enabled
HT1000 Legacy South Bridge
PCI: 00:02.1 [1166/0214] enabled
HT1000 Legacy IDE controller
PCI: 00:02.2 [1166/0234] enabled
HT1000 LPC Bridge
PCI: 00:02.3 [1166/0238] enabled PCI: 00:02.4 [1166/0235] enabled PCI: 00:02.5 [1166/0235] enabled PCI: 00:02.6 [1166/0235] enabled
Not in my pci.ids.
PCI: 00:03.0 [1166/0223] enabled PCI: 00:03.1 [1166/0223] enabled PCI: 00:03.2 [1166/0223] enabled
3x HT1000 USB Controller
PCI: 00:04.0 [8086/1229] enabled
82557/8/9 [Ethernet Pro 100]
[..]
Reading resources...
[..]
PCI: 00:01.0 24 <- [0xfffffffffff00000 - 0xffffffffffefffff] bus 01 prefmem
[..]
PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:03.0 missing read_resources PCI: 00:04.0 missing read_resources PCI: 00:05.0 missing read_resources PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:01.1 missing read_resources PCI: 00:01.2 missing read_resources PCI: 00:01.3 missing read_resources PCI: 00:01.4 missing read_resources PCI: 00:01.5 missing read_resources PCI: 00:01.6 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:02.1 missing read_resources PCI: 00:02.2 missing read_resources PCI: 00:03.0 missing read_resources PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:03.0 missing read_resources PCI: 00:04.0 missing read_resources PCI: 00:05.0 missing read_resources PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:01.1 missing read_resources PCI: 00:01.2 missing read_resources PCI: 00:01.3 missing read_resources PCI: 00:01.4 missing read_resources PCI: 00:01.5 missing read_resources PCI: 00:01.6 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:02.1 missing read_resources PCI: 00:02.2 missing read_resources PCI: 00:03.0 missing read_resources PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:03.0 missing read_resources PCI: 00:04.0 missing read_resources PCI: 00:05.0 missing read_resources PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:01.1 missing read_resources PCI: 00:01.2 missing read_resources PCI: 00:01.3 missing read_resources PCI: 00:01.4 missing read_resources PCI: 00:01.5 missing read_resources PCI: 00:01.6 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:02.1 missing read_resources PCI: 00:02.2 missing read_resources PCI: 00:03.0 missing read_resources Done reading resources.
[..]
Setting resources...
[..]
PCI: 00:00.0 missing read_resources PCI: 00:01.0 missing read_resources PCI: 00:02.0 missing read_resources PCI: 00:03.0 missing read_resources PCI: 00:04.0 missing read_resources PCI: 00:05.0 missing read_resources
[..]
Does this matter, anyone? If there's no read_resources() op (or even no dev->ops) there's no fallback to generic routines in the code - are the devices likely to work anyway?
[..]
PCI: 00:02.0 90 <- [0x0000003040 - 0x000000304f] io PCI: 00:02.1 10 <- [0x0000003060 - 0x0000003067] io PCI: 00:02.1 14 <- [0x0000003080 - 0x0000003083] io PCI: 00:02.1 18 <- [0x0000003070 - 0x0000003077] io PCI: 00:02.1 1c <- [0x0000003090 - 0x0000003093] io PCI: 00:02.1 20 <- [0x0000003050 - 0x000000305f] io PCI: 00:02.1 64 <- [0x00000030a0 - 0x00000030a3] io PCI: 00:02.3 10 <- [0x00fc250000 - 0x00fc250fff] mem PCI: 00:02.4 10 <- [0x00fc251000 - 0x00fc251fff] mem PCI: 00:02.5 10 <- [0x00fc252000 - 0x00fc252fff] mem PCI: 00:02.6 10 <- [0x00fc253000 - 0x00fc253fff] mem
Some resources are being assigned either way..
[..]
Done setting resources. Done allocating resources. Enabling resources...
[..]
PCI: 00:01.0 bridge ctrl <- 0003 PCI: 00:01.0 cmd <- 147
[..]
PCI: 00:02.0 cmd <- 147 PCI: 00:02.1 cmd <- 141 PCI: 00:02.2 cmd <- 144 PCI: 00:02.3 cmd <- 146 PCI: 00:02.4 cmd <- 146 PCI: 00:02.5 cmd <- 146 PCI: 00:02.6 cmd <- 146 PCI: 00:03.0 cmd <- 143 PCI: 00:03.1 cmd <- 143 PCI: 00:03.2 cmd <- 143 PCI: 00:04.0 cmd <- 143
[..]
And some command seems to be sent, but..
PCI: 00:00.0 missing enable_resources PCI: 00:01.0 missing enable_resources PCI: 00:02.0 missing enable_resources PCI: 00:03.0 missing enable_resources PCI: 00:04.0 missing enable_resources PCI: 00:05.0 missing enable_resources PCI: 00:00.0 missing enable_resources PCI: 00:01.0 missing enable_resources PCI: 00:01.1 missing enable_resources PCI: 00:01.2 missing enable_resources PCI: 00:01.3 missing enable_resources PCI: 00:01.4 missing enable_resources PCI: 00:01.5 missing enable_resources PCI: 00:01.6 missing enable_resources PCI: 00:02.0 missing enable_resources PCI: 00:02.1 missing enable_resources PCI: 00:02.2 missing enable_resources PCI: 00:03.0 missing enable_resources
Here we go again about missing *_resources op or even dev->ops.
Is it just that none is needed for HT1000 or can this be the cause of the problems?
NB: Function 3 Misc Control.. done. PCI: 00:02.0 init PCI: 00:02.1 init PCI: 00:02.2 init RTC Init Invalid CMOS LB checksum PCI: 00:02.3 init PCI: 00:02.4 init PCI: 00:02.5 init PCI: 00:02.6 init PCI: 00:03.0 init PCI: 00:03.1 init PCI: 00:03.2 init PCI: 00:04.0 init
[..]
Devices initialized
So most of the devices are initialized, but that may not mean much.
FILO version 0.5 (fengl@localhost.localdomain) Sat Jul 7 02:41:14 CST 2007 menu: hda1:/grub/grub.conf
What about FILO - have you tried using a PS/2 keyboard there? (Compile FILO with a timeout for the boot prompt.) Until that works, there is not much reason to boot Linux. (Quicker cycles)
[..]
Linux version 2.6.9-22.ELsmp (bhcompile@crowe.devel.redhat.com) (gcc version 3.4.4 20050721 (Red Hat 3.4.4-2)) #1 SMP Mon Sep 19 18:00:54 EDT 2005
This kernel is almost two years old, you are ignoring the last 1/5 part of the lifetime of the Linux project.
I would strongly suggest building a recent kernel.org version of Linux (2.6.21.6 or 2.6.22.1) without modules and making sure it is configured according to the hardware you're working with. If you want the list to review your configuration, please feel free to send the .config created by make menuconfig. (or make xconfig or make qconfig)
[..]
usbcore: registered new driver hiddev usbcore: registered new driver usbhid drivers/usb/input/hid-core.c: v2.0:USB HID core driver mice: PS/2 mouse device common for all mice
No USB host controllers are found by Linux so it is impossible for a USB keyboard to work. The HID driver is loaded but it only depends on the USB core. Maybe the host controller drivers aren't enabled in this kernel, maybe the PCI devices don't respond properly (LB's fault) or maybe there are bugs in the HCI drivers. Too many unknowns.
There are at least two interesting things you could try:
1. Investigate the {read,enable}_resources messages from LB for HT1000 and fix the problem if there is in fact a problem. Best case this makes everything work. A good first test is if a PS/2 keyboard works in FILO.
2. Upgrade to the latest kernel, correctly configured for the system, and see what works/does not work. Perhaps that can give clues about what is wrong in LB. (if there is something more than 1)
(Could be useful to try 2 before 1 as well.)
//Peter
please check if bcm5785 bcm5780 is in the first ht link in your MB Config.lb. Or send out your MB Config.lb.
YH
Hi, Mr. Lu,
You are quit right. I commented out two statements in Config.lb as you suggest, the keyboard can work now. The attached is the modified file, a BTDC tag indicates where I modified. Thank you a lot.
Best Regards
??? Feng Libo @ AMD Ext: 20906 Mobile Phone: 13683249071 Office Phone: 0086-010-62801406
-----Original Message----- From: yhlu [mailto:yinghailu@gmail.com] Sent: Saturday, August 04, 2007 1:40 AM To: Feng, Libo Cc: Peter Stuge; linuxbios@linuxbios.org Subject: Re: [LinuxBIOS] No keyboard.
please check if bcm5785 bcm5780 is in the first ht link in your MB Config.lb. Or send out your MB Config.lb.
YH