Alright, I know I ask too many questions, but what would cause uart_init to hang? I'm trying to get serial output on ite it8705f, and my POST card tells me that it's hanging during uart_init. I've made a bunch of changes to it8705f_early_serial.c, mainly to set up serial port 1 manually, but nothing seems to help. Also, there's one small error in the last line of that file, according to the datasheet:
it8705f_sio_write(0x00, IT8705F_CONFIG_REG_CC, 0x02); //need to change 0x02 to 0x01
Before I "fixed" that, LB got clear to the jump to RAM (according to the POST card), but I had no serial output. Now I still have no serial output and a hang at some point during uart_init. My mainboard code is mostly a copy-and-paste of Via Epia-M, with the vga init code ripped out for now. I'm using the "normal" 115200 baud and 8-N-1 settings, and I've already checked that my serial setup is working, and according to linux, the serial header is actually COM1/ttyS0.
The other question is, does anything have to be done to the via vt8235 before serial setup?
Just for reference, if anyone wants them, datasheets: ITE IT8705f: http://www.iteusa.com/product_info/file/pc/IT8705F_V.0.4.1.pdf Via vt8235m: http://www.datasheetarchive.com/datasheet.php?article=3833808
Thanks, Corey
On Mon, Mar 26, 2007 at 02:10:20AM -0400, Corey Osgood wrote:
Alright, I know I ask too many questions, but what would cause uart_init to hang? I'm trying to get serial output on ite it8705f, and my POST card tells me that it's hanging during uart_init. I've made a bunch of changes to it8705f_early_serial.c, mainly to set up serial port 1 manually, but nothing seems to help. Also, there's one small error in the last line of that file, according to the datasheet:
it8705f_sio_write(0x00, IT8705F_CONFIG_REG_CC, 0x02); //need to
change 0x02 to 0x01
This line is correct, I think. The datasheet says
Set bit 1 of the Configure Control Register (Index: 02h) to "1" to exit the MB PnP mode.
IT8705F_CONFIG_REG_CC is 0x02, and the 0x02 in the line above is correct because it sets bit 1 (not bit 0).
I _think_ I got serial output with that Super I/O at some point, but I can't remember exactly, so maybe there's still something todo...
Uwe.
Uwe Hermann wrote:
On Mon, Mar 26, 2007 at 02:10:20AM -0400, Corey Osgood wrote:
Alright, I know I ask too many questions, but what would cause uart_init to hang? I'm trying to get serial output on ite it8705f, and my POST card tells me that it's hanging during uart_init. I've made a bunch of changes to it8705f_early_serial.c, mainly to set up serial port 1 manually, but nothing seems to help. Also, there's one small error in the last line of that file, according to the datasheet:
it8705f_sio_write(0x00, IT8705F_CONFIG_REG_CC, 0x02); //need to
change 0x02 to 0x01
This line is correct, I think. The datasheet says
Set bit 1 of the Configure Control Register (Index: 02h) to "1" to exit the MB PnP mode.
IT8705F_CONFIG_REG_CC is 0x02, and the 0x02 in the line above is correct because it sets bit 1 (not bit 0).
I _think_ I got serial output with that Super I/O at some point, but I can't remember exactly, so maybe there's still something todo...
Uwe.
I've attached my it8705f_early_serial.c and auto.c. And yes, Uwe, you were right, it was correct. I even put in a comment about it and still read it wrong. But, I'm still not getting serial output, even with that fixed. I've put in a few outb()s, and that tells me it's finishing with the early serial, but not leaving uart_init(). I'm wondering if the vt8235 is somehow interfering with the serial output. Suggestions?
Thanks, Corey
Okay, so now I'm getting something, after I moved early_mtrr_init to the start of auto.c. It looks like question marks in hexagons, all across minicom's screen, but it is actually working. I've tried testing it at various other speeds/settings, and the output changes, but it's all still useless. Also, instead of hanging during uart_init(), I'm now hanging in console_init(). Why do I always seem to end up with picky hardware? Oh yeah, because I'm cheap :D
I'm tempted right now to just give up on the serial port and see if I can get a VGA rom to run, but I don't know if I could do it blindly, especially since I haven't been able to get the VGA rom to extract yet. Anyone have one for an epia-m that they'd care to send me?
Thanks, Corey
On Tue, Mar 27, 2007 at 01:34:59AM -0400, Corey Osgood wrote:
Okay, so now I'm getting something, after I moved early_mtrr_init to the start of auto.c. It looks like question marks in hexagons, all across minicom's screen, but it is actually working.
Don't give up, yet. This looks good, you're getting output. Now it's "just" a matter of finding the part of the init code which is not quite right, yet.
Try explicitly setting everything which is marked as default in the datasheet, maybe there's some hardware quirk/bug... Also, is there any errata document for this Super I/O?
Uwe.
Uwe Hermann wrote:
On Tue, Mar 27, 2007 at 01:34:59AM -0400, Corey Osgood wrote:
Okay, so now I'm getting something, after I moved early_mtrr_init to the start of auto.c. It looks like question marks in hexagons, all across minicom's screen, but it is actually working.
Don't give up, yet. This looks good, you're getting output. Now it's "just" a matter of finding the part of the init code which is not quite right, yet.
Try explicitly setting everything which is marked as default in the datasheet, maybe there's some hardware quirk/bug... Also, is there any errata document for this Super I/O?
Uwe.
Success!!
After trying every combination of configurations and tweaks I could think of, I got pissed off at it, so I decided to nuke the code and grabbed an SMSC chip and ported it over. Works perfectly! I'm not quite sure still where your code wasn't working right, but the generic pnp functions used by the smsc seem to be doing the trick just fine. Uwe, when you get a chance, can you give your code another shot? It may be I just messed something up somewhere. It's not terribly important, since I've got something working, but I'd like to know if it was just me or not.
-Corey
* Corey Osgood corey_osgood@verizon.net [070329 10:15]:
Uwe Hermann wrote: After trying every combination of configurations and tweaks I could think of, I got pissed off at it, so I decided to nuke the code and grabbed an SMSC chip and ported it over. Works perfectly!
Cool. Please send a patch.
Stefan
* Corey Osgood corey_osgood@verizon.net [070327 02:37]:
I've attached my it8705f_early_serial.c and auto.c. And yes, Uwe, you were right, it was correct. I even put in a comment about it and still read it wrong. But, I'm still not getting serial output, even with that fixed. I've put in a few outb()s, and that tells me it's finishing with the early serial, but not leaving uart_init(). I'm wondering if the vt8235 is somehow interfering with the serial output. Suggestions?
Maybe you have two SuperIOs?
Stefan Reinauer wrote:
- Corey Osgood corey_osgood@verizon.net [070327 02:37]:
I've attached my it8705f_early_serial.c and auto.c. And yes, Uwe, you were right, it was correct. I even put in a comment about it and still read it wrong. But, I'm still not getting serial output, even with that fixed. I've put in a few outb()s, and that tells me it's finishing with the early serial, but not leaving uart_init(). I'm wondering if the vt8235 is somehow interfering with the serial output. Suggestions?
Maybe you have two SuperIOs?
From what I can tell, it's just the one, but I can't be absolutely sure.
The Via VT8235 in linuxbios has code to set up serial output. But the VT8235M datasheet, which is the part I have, doesn't mention anything about super io functions. And there's definately no other super io chip. I'm so lost right now...
I've tried setting up the ite super io at 0x4e, and still no dice. Tomorrow I'm going to play with VGA roms, I think.
Thanks, Corey