All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vikram Garhwal <fnu.vikram@xilinx.com>
To: Anthony PERARD <anthony.perard@citrix.com>
Cc: <xen-devel@lists.xenproject.org>, <sstabellini@kernel.org>,
	<julien@xen.org>, <bertrand.marquis@arm.com>,
	<volodymyr_babchuk@epam.com>, Ian Jackson <iwj@xenproject.org>,
	Wei Liu <wl@xen.org>, Juergen Gross <jgross@suse.com>
Subject: Re: [XEN][RFC PATCH v2 10/12] tools/libs/ctrl: Implement new xc interfaces for dt overlay
Date: Thu, 11 Nov 2021 11:46:36 -0800	[thread overview]
Message-ID: <20211111194634.GA211320@xilinx.com> (raw)
In-Reply-To: <YY1KwUC7EaJC4vJa@perard>

On Thu, Nov 11, 2021 at 04:54:25PM +0000, Anthony PERARD wrote:
Hi Anthony,
> On Mon, Nov 08, 2021 at 11:02:25PM -0800, Vikram Garhwal wrote:
> > xc_dt_overlay() sends the device tree binary overlay, size of .dtbo and overlay
> > operation type i.e. add or remove to xen.
> > 
> > Signed-off-by: Vikram Garhwal <fnu.vikram@xilinx.com>
> > ---
> >  tools/include/xenctrl.h      |  5 +++++
> >  tools/libs/ctrl/Makefile     |  1 +
> >  tools/libs/ctrl/xc_overlay.c | 51 ++++++++++++++++++++++++++++++++++++++++++++
> >  3 files changed, 57 insertions(+)
> >  create mode 100644 tools/libs/ctrl/xc_overlay.c
> > 
> > diff --git a/tools/include/xenctrl.h b/tools/include/xenctrl.h
> > index 07b96e6..cfd7c5c 100644
> > --- a/tools/include/xenctrl.h
> > +++ b/tools/include/xenctrl.h
> > @@ -2684,6 +2684,11 @@ int xc_livepatch_replace(xc_interface *xch, char *name, uint32_t timeout, uint32
> >  int xc_domain_cacheflush(xc_interface *xch, uint32_t domid,
> >                           xen_pfn_t start_pfn, xen_pfn_t nr_pfns);
> >  
> > +#if defined (CONFIG_OVERLAY_DTB)
> > +int xc_dt_overlay(xc_interface *xch, void *overlay_fdt, int overlay_fdt_size,
> > +                  uint8_t overlayop);
> > +#endif
> > +
> >  /* Compat shims */
> >  #include "xenctrl_compat.h"
> >  
> > diff --git a/tools/libs/ctrl/Makefile b/tools/libs/ctrl/Makefile
> > index 519246b..a21a949 100644
> > --- a/tools/libs/ctrl/Makefile
> > +++ b/tools/libs/ctrl/Makefile
> > @@ -3,6 +3,7 @@ include $(XEN_ROOT)/tools/Rules.mk
> >  
> >  SRCS-y       += xc_altp2m.c
> >  SRCS-y       += xc_cpupool.c
> > +SRCS-$(CONFIG_OVERLAY_DTB) += xc_overlay.c
> 
> So, this patch seems to introduce the use of CONFIG_OVERLAY_DTB, is
> there a reason why the new functionality can't be always builtin?
> 
Above, if you meant removing "CONFIG_OEVRLAY_DTB" then here is my answer:
This feature is supported by ARM based FPGA devices only so there were a few
comments on v1 series to keep the code inside a config only. Now, for the tool
side also I kept the CONFIG_OVERLAY_DTB to align the xen-tools with Xen.

Although, now i saw your comments on patch 10 regarding  "always provide
libxl_dt_overlay() but which would return ENOSYS when libxl is built without
CONFIG_OVERLAY_DTB". That seems better approach here for all three xen-tool
patches.

Initially, i was not sure what to do here that's why i wrote a question in the
cover letter about this.

Also, do you know how to enable this config via menuconfig when building the Xen
tools? I know how to enable for Xen but not sure about tools.

Thanks for reviewing this.

Regards,
Vikram Garhwal

> Thanks,
> 
> -- 
> Anthony PERARD


  reply	other threads:[~2021-11-11 19:47 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-09  7:02 [XEN][RFC PATCH v2 00/12] dynamic node programming using overlay dtbo Vikram Garhwal
2021-11-09  7:02 ` [XEN][RFC PATCH v2 01/12] device tree: Remove __init from function type Vikram Garhwal
2021-11-09  7:02 ` [XEN][RFC PATCH v2 02/12] xen: arm: Add CONFIG_OVERLAY_DTB Vikram Garhwal
2021-12-22 14:02   ` Julien Grall
2021-11-09  7:02 ` [XEN][RFC PATCH v2 03/12] libfdt: Keep fdt functions after init for CONFIG_OVERLAY_DTB Vikram Garhwal
2021-11-09 11:10   ` Jan Beulich
2021-12-22 14:03   ` Julien Grall
2021-11-09  7:02 ` [XEN][RFC PATCH v2 04/12] libfdt: Add fdt_ prefix to overlay_get_target() Vikram Garhwal
2021-12-22 14:07   ` Julien Grall
2021-11-09  7:02 ` [XEN][RFC PATCH v2 05/12] device tree: Add _dt_find_node_by_path() to find nodes in device tree Vikram Garhwal
2021-11-09  7:02 ` [XEN][RFC PATCH v2 06/12] xen/smmu: Add remove_device callback for smmu_iommu ops Vikram Garhwal
2021-12-22 14:31   ` Julien Grall
2021-11-09  7:02 ` [XEN][RFC PATCH v2 07/12] " Vikram Garhwal
2021-12-22 14:38   ` Julien Grall
2021-11-09  7:02 ` [XEN][RFC PATCH v2 08/12] xen/arm: Implement device tree node removal functionalities Vikram Garhwal
2021-11-09 11:16   ` Jan Beulich
2021-12-22 16:13   ` Julien Grall
2021-12-24  0:45     ` Stefano Stabellini
2021-11-09  7:02 ` [XEN][RFC PATCH v2 09/12] xen/arm: Implement device tree node addition functionalities Vikram Garhwal
2021-11-09 11:19   ` Jan Beulich
2021-11-09 17:55     ` Vikram Garhwal
2021-11-09  7:02 ` [XEN][RFC PATCH v2 10/12] tools/libs/ctrl: Implement new xc interfaces for dt overlay Vikram Garhwal
2021-11-11 16:54   ` Anthony PERARD
2021-11-11 19:46     ` Vikram Garhwal [this message]
2021-11-12 14:21       ` Anthony PERARD
2021-11-09  7:02 ` [XEN][RFC PATCH v2 11/12] tools/libs/light: Implement new libxl functions for device tree overlay ops Vikram Garhwal
2021-11-11 16:44   ` Anthony PERARD
2021-11-09  7:02 ` [XEN][RFC PATCH v2 12/12] tools/xl: Add new xl command overlay Vikram Garhwal

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=20211111194634.GA211320@xilinx.com \
    --to=fnu.vikram@xilinx.com \
    --cc=anthony.perard@citrix.com \
    --cc=bertrand.marquis@arm.com \
    --cc=iwj@xenproject.org \
    --cc=jgross@suse.com \
    --cc=julien@xen.org \
    --cc=sstabellini@kernel.org \
    --cc=volodymyr_babchuk@epam.com \
    --cc=wl@xen.org \
    --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.