From: Ian Campbell Subject: Re: [PATCH v2 2/2] tools/console: xenconsole tolerate tty errors Date: Wed, 19 Mar 2014 09:57:52 +0000 Message-ID: <1395223072.10203.34.camel@kazak.uk.xensource.com> References: <21288.35166.479652.469692@mariner.uk.xensource.com> <1395165628-1838-1-git-send-email-ian.jackson@eu.citrix.com> <1395165628-1838-2-git-send-email-ian.jackson@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1395165628-1838-2-git-send-email-ian.jackson@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Jackson Cc: George Dunlap , xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On Tue, 2014-03-18 at 18:00 +0000, Ian Jackson wrote: > Since 28d386fc4341 (XSA-57), libxl writes an empty value for the > console tty node, with read-only permission for the guest, when > setting up pv console "frontends". (The actual tty value is later set > by xenconsoled.) Writing an empty node is not strictly necessary to > stop the frontend from writing dangerous values here, but it is a good > belt-and-braces approach. > > Unfortunately this confuses xenconsole. It reads the empty value, and > tries to open it as the tty. xenconsole then exits. > > Fix this by having xenconsole treat an empty value the same way as no > value at all. > > Also, make the error opening the tty be nonfatal: we just print a > warning, but do not exit. I think this is helpful in theoretical > situations where xenconsole is racing with libxl and/or xenconsoled. > > Signed-off-by: Ian Jackson Acked-by: Ian Campbell