[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] Paravirt framebuffer console cleanups [5/5]



On Mon, 2006-09-04 at 10:02 +0100, Steven Smith wrote:
> > diff -r c859588adc5e -r 72582b968445 
> > linux-2.6-xen-sparse/drivers/char/tty_io.c
> > --- a/linux-2.6-xen-sparse/drivers/char/tty_io.c    Sat Sep 02 15:31:29 
> > 2006 -0400
> > +++ b/linux-2.6-xen-sparse/drivers/char/tty_io.c    Sat Sep 02 15:32:38 
> > 2006 -0400
> 
> It looks to me like this patch makes tty_io.c identical to the
> upstream version.  Is this correct?

Yep -- so actually could be removed from the sparse tree.  I'm usually
working in a non-sparse tree, so the diff is more relevant.


> > diff -r c859588adc5e -r 72582b968445 
> > linux-2.6-xen-sparse/drivers/xen/console/console.c
> > --- a/linux-2.6-xen-sparse/drivers/xen/console/console.c    Sat Sep 02 
> > 15:31:29 2006 -0400
> > +++ b/linux-2.6-xen-sparse/drivers/xen/console/console.c    Sat Sep 02 
> > 15:32:38 2006 -0400
> > @@ -663,6 +663,20 @@ static int __init xencons_init(void)
> >     printk("Xen virtual console successfully installed as %s%d\n",
> >            DRV(xencons_driver)->name, xc_num);
> >  
> > +        /* Don't need to check about graphical fb for domain 0 */
> > +        if (is_initial_xendomain())
> > +     return 0;
> > +
> > +   rc = 0;
> > +   if (xenbus_scanf(XBT_NIL, "console", "use_graphics", "%d", &rc) < 0)
> > +           printk(KERN_ERR "Unable to read console/use_graphics\n");
> > +   if (rc == 0) {
> > +               /* FIXME: this is ugly */
> > +          unregister_console(&kcons_info);
> > +          kcons_info.flags |= CON_CONSDEV;
> > +          register_console(&kcons_info);
> > +   }
> > +
> Could you pull the setting of CON_CONSDEV into xen_console_init and
> avoid this weirdness?

Nope -- when consoles are registered, we don't have enough
infrastructure to check xenbus to see if console/use_graphics is set or
not

> This whole passage is a little peculiar, in that you're only going to
> do anything if use_graphics is disabled.  I'd expect that just leaving
> the current behaviour alone would be the correct thing to do in that
> case.
> 
> Also, why do you need to set CON_CONSDEV at all?

Otherwise, you don't get kernel console messages.

Realistically, I think the better longer-term answer is to create an
early xenconsole -- then, when we do this later initialization, we can
deregister the early console and do the right registration for the
"real" console.  This mirrors pretty closely what's done on a few other
arches

Jeremy


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.