[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-ia64-devel] serial console settings on Tiger4
On Fri, 2007-02-09 at 18:25 +0900, KUWAMURA Shin'ya wrote: > >>>>> On Thu, 08 Feb 2007 06:23:30 -0700 > >>>>> alex.williamson@xxxxxx(Alex Williamson) said: > > > > Check this changeset: > > > > http://xenbits.xensource.com/ext/xen-ia64-unstable.hg?cs=7efb3a06c56a > > > > Thank you for your information. > It works fine when I revert this changeset. > > On Tiger4, the following message outputs: > ERROR: I/O base address must be specified. > This error is written by ns16550_parse_port_config() at > xen/drivers/char/ns16550.c if iobase == 0. > > I think that In case of Tiger4 ns16550_com1.io_base is 0, so the code > to initialize com2 does not run. > > # Notice that Tiger4 has one serial port. Ok, sorry for breaking it, I was assuming all Tigers had both 0x3f8 and 0x2f8 UARTs. My bad. Since you seem to be specifying the UART parameters anyway, does the below patch work? The down side is that you'll have to specify the full com2= down to the io_base to make it work, so com2=115200,8n1 won't work anymore, it would have to be com2=115200,8n1,0x2f8. Why use com2 anyway? It seems like you should be able to do the same thing on com1 (ie. com1=115200,8n1,0x2f8). If anyone wants to write some auto-detection of these, it should be pretty easy. I would start with something like xen/arch/ia64/xen/pcdp.c:pcdp_hp_irq_fixup(), determine you're on a Tiger2 or Tiger4 based on XSDT oem_id and oem_table_id and poke the right values into the ns16550_com1 and ns16550_com2 structures. Based on google searches for boot logs, you're probably looking for "INTEL" and "SR870xxx", where the last 3 characters of the oem_table_id might distinguish between a Tiger2 and Tiger4. Thanks, Alex Signed-off-by: Alex Williamson <alex.williamson@xxxxxx> --- diff -r 3050c8339da6 xen/arch/ia64/xen/pcdp.c --- a/xen/arch/ia64/xen/pcdp.c Thu Feb 08 18:18:56 2007 +0000 +++ b/xen/arch/ia64/xen/pcdp.c Fri Feb 09 09:11:55 2007 -0700 @@ -140,7 +140,7 @@ setup_serial_console(struct pcdp *pcdp, setup_serial_console(struct pcdp *pcdp, struct pcdp_uart *uart) { - ns16550_com1.baud = uart->baud; + ns16550_com1.baud = uart->baud ? uart->baud : BAUD_AUTO; ns16550_com1.io_base = uart->addr.address; if (uart->bits) ns16550_com1.data_bits = uart->bits; diff -r 3050c8339da6 xen/arch/ia64/xen/xensetup.c --- a/xen/arch/ia64/xen/xensetup.c Thu Feb 08 18:18:56 2007 +0000 +++ b/xen/arch/ia64/xen/xensetup.c Fri Feb 09 08:54:54 2007 -0700 @@ -147,7 +147,6 @@ void early_cmdline_parse(char **cmdline_ } struct ns16550_defaults ns16550_com1 = { - .baud = BAUD_AUTO, .data_bits = 8, .parity = 'n', .stop_bits = 1 @@ -158,7 +157,6 @@ unsigned int ns16550_com1_trigger; unsigned int ns16550_com1_trigger; struct ns16550_defaults ns16550_com2 = { - .baud = BAUD_AUTO, .data_bits = 8, .parity = 'n', .stop_bits = 1 @@ -271,12 +269,7 @@ void start_kernel(void) hpsim_serial_init(); else { ns16550_init(0, &ns16550_com1); - if (ns16550_com1.io_base == 0x3f8) { - /* Also init com2 for Tiger4. */ - ns16550_com2.io_base = 0x2f8; - ns16550_com2.irq = 3; - ns16550_init(1, &ns16550_com2); - } + ns16550_init(1, &ns16550_com2); } serial_init_preirq(); _______________________________________________ Xen-ia64-devel mailing list Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-ia64-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |