All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefano Stabellini <sstabellini@kernel.org>
To: Bhupinder Thakur <bhupinder.thakur@linaro.org>
Cc: xen-devel@lists.xenproject.org, Wei Liu <wei.liu2@citrix.com>,
	Ian Jackson <ian.jackson@eu.citrix.com>
Subject: Re: [PATCH 09/12 v3] xen/arm: vpl011: Add support for vuart in xenconsole
Date: Tue, 16 May 2017 16:44:44 -0700 (PDT)	[thread overview]
Message-ID: <alpine.DEB.2.10.1705161642100.6833@sstabellini-ThinkPad-X260> (raw)
In-Reply-To: <1494426918-32737-4-git-send-email-bhupinder.thakur@linaro.org>

On Wed, 10 May 2017, Bhupinder Thakur wrote:
> Xenconsole supports only PV console currently. This patch adds support
> for vuart console, which allows emulated pl011 UART to be accessed
> as a console.
> 
> Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
> ---
> 
> One review comment was to keep the vuart code under CONFIG_ARM64 && CONFIG_ACPI flags.
> This code review could not be incorporated as I could not find out the appropriate flags
> unders which this code can be kept. Are the CONFIG* flags exported to xenconsole?

Not sure about ACPI, but CONFIG_ARM_64 definitely should be.

This patch looks good, however I don't feel confident giving my acked-by
until I can review properly the previous one.


>  tools/console/daemon/io.c | 29 +++++++++++++++++++++++++++++
>  1 file changed, 29 insertions(+)
> 
> diff --git a/tools/console/daemon/io.c b/tools/console/daemon/io.c
> index 9bb14de..19a2f35 100644
> --- a/tools/console/daemon/io.c
> +++ b/tools/console/daemon/io.c
> @@ -115,6 +115,7 @@ struct console_data {
>  };
>  
>  static int map_pvcon_ring_ref(struct console *, int );
> +static int map_vuartcon_ring_ref(struct console *, int );
>  
>  static struct console_data console_data[] = {
>  
> @@ -124,6 +125,12 @@ static struct console_data console_data[] = {
>  		.mapfunc = map_pvcon_ring_ref,
>  		.mandatory = true
>  	},
> +	{
> +		.xsname = "/vuart/0",
> +		.ttyname = "tty",
> +		.mapfunc = map_vuartcon_ring_ref,
> +		.mandatory = false
> +	}
>  };
>  
>  #define MAX_CONSOLE (sizeof(console_data)/sizeof(struct console_data))
> @@ -751,6 +758,28 @@ out:
>  	return err;
>  }
>  
> +static int map_vuartcon_ring_ref(struct console *con, int ring_ref)
> +{
> +	int err = 0;
> +	struct domain *dom = con->d;
> +
> +	if (!con->interface) {
> +		con->interface = xc_map_foreign_range(xc,
> +											  dom->domid,
> +											  XC_PAGE_SIZE,
> +											  PROT_READ|PROT_WRITE,
> +											  (unsigned long)ring_ref);
> +		if (con->interface == NULL) {
> +			err = EINVAL;
> +			goto out;
> +		}
> +		con->ring_ref = ring_ref;
> +	}
> +
> +out:
> +	return err;
> +}
> +
>  static int console_create_ring(struct console *con)
>  {
>  	int err, remote_port, ring_ref;
> -- 
> 2.7.4
> 
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> https://lists.xen.org/xen-devel
> 

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  parent reply	other threads:[~2017-05-16 23:44 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-10 14:35 [PATCH 06/12 v3] xen/arm: vpl011: Add a new vuart node in the xenstore Bhupinder Thakur
2017-05-10 14:35 ` [PATCH 07/12 v3] xen/arm: vpl011: Allocate a new GFN in the toolstack for vuart Bhupinder Thakur
2017-05-11 11:10   ` Wei Liu
2017-05-16 22:59   ` Stefano Stabellini
2017-05-10 14:35 ` [PATCH 08/12 v3] xen/arm: vpl011: Modify xenconsole to support multiple consoles Bhupinder Thakur
2017-05-11 11:15   ` Wei Liu
2017-05-16 23:41   ` Stefano Stabellini
2017-05-25 10:57     ` Bhupinder Thakur
2017-05-25 18:24       ` Stefano Stabellini
2017-05-10 14:35 ` [PATCH 09/12 v3] xen/arm: vpl011: Add support for vuart in xenconsole Bhupinder Thakur
2017-05-11 11:17   ` Wei Liu
2017-05-16 23:44   ` Stefano Stabellini [this message]
2017-05-22 14:37     ` Julien Grall
2017-05-10 14:35 ` [PATCH 10/12 v3] xen/arm: vpl011: Add a new vuart console type to xenconsole client Bhupinder Thakur
2017-05-11 11:17   ` Wei Liu
2017-05-16 23:02   ` Stefano Stabellini
2017-05-10 14:35 ` [PATCH 11/12 v3] xen/arm: vpl011: Add a pl011 uart DT node in the guest device tree Bhupinder Thakur
2017-05-11 11:18   ` Wei Liu
2017-05-16 23:05   ` Stefano Stabellini
2017-05-22 14:42   ` Julien Grall
2017-05-10 14:35 ` [PATCH 12/12 v3] xen/arm: vpl011: Update documentation for vuart console support Bhupinder Thakur
2017-05-11 11:19   ` Wei Liu
2017-05-16 23:10   ` Stefano Stabellini
2017-05-11 11:10 ` [PATCH 06/12 v3] xen/arm: vpl011: Add a new vuart node in the xenstore Wei Liu
2017-05-12  9:32   ` Bhupinder Thakur
2017-05-16 15:18     ` Wei Liu
2017-05-22 11:03       ` Bhupinder Thakur
2017-05-30 11:58         ` Wei Liu
2017-06-01  8:43           ` Bhupinder Thakur

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.10.1705161642100.6833@sstabellini-ThinkPad-X260 \
    --to=sstabellini@kernel.org \
    --cc=bhupinder.thakur@linaro.org \
    --cc=ian.jackson@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.