ia64/xen-unstable

changeset 8352:a7bb7b704071

Most drivers have their own range of devices they claim and the tty
index is identical to the device file index. For us, the tty index is
always zero regardless of the device file index.

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
author kaf24@firebug.cl.cam.ac.uk
date Tue Dec 13 22:05:18 2005 +0100 (2005-12-13)
parents 455b2b93542c
children 89250c81cdd2
files linux-2.6-xen-sparse/drivers/xen/console/console.c
line diff
     1.1 --- a/linux-2.6-xen-sparse/drivers/xen/console/console.c	Tue Dec 13 19:20:29 2005 +0100
     1.2 +++ b/linux-2.6-xen-sparse/drivers/xen/console/console.c	Tue Dec 13 22:05:18 2005 +0100
     1.3 @@ -168,7 +168,7 @@ static void kcons_write_dom0(
     1.4  
     1.5  static struct tty_driver *kcons_device(struct console *c, int *index)
     1.6  {
     1.7 -	*index = c->index;
     1.8 +	*index = 0;
     1.9  	return xencons_driver;
    1.10  }
    1.11  
    1.12 @@ -213,6 +213,9 @@ static int __init xen_console_init(void)
    1.13  		return __RETCODE;
    1.14  	}
    1.15  
    1.16 +	/* We only bind to one device index (-1 means all indexes). */
    1.17 +	kcons_info.index = xc_num;
    1.18 +
    1.19  	wbuf = alloc_bootmem(wbuf_size);
    1.20  
    1.21  	register_console(&kcons_info);