[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YmQqGOoNDwkKSbZr@infradead.org>
Date: Sat, 23 Apr 2022 09:32:24 -0700
From: Christoph Hellwig <hch@...radead.org>
To: Oleksandr Tyshchenko <olekstysh@...il.com>
Cc: xen-devel@...ts.xenproject.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
Oleksandr Tyshchenko <oleksandr_tyshchenko@...m.com>,
Stefano Stabellini <sstabellini@...nel.org>,
Russell King <linux@...linux.org.uk>,
Catalin Marinas <catalin.marinas@....com>,
Will Deacon <will@...nel.org>,
Boris Ostrovsky <boris.ostrovsky@...cle.com>,
Juergen Gross <jgross@...e.com>,
Logan Gunthorpe <logang@...tatee.com>,
David Hildenbrand <david@...hat.com>,
Martin Oliveira <martin.oliveira@...eticom.com>,
Kees Cook <keescook@...omium.org>,
Jean-Philippe Brucker <jean-philippe@...aro.org>,
Julien Grall <julien@....org>,
"Michael S. Tsirkin" <mst@...hat.com>,
Christoph Hellwig <hch@...radead.org>
Subject: Re: [PATCH V1 1/6] arm/xen: Introduce xen_setup_dma_ops()
On Fri, Apr 22, 2022 at 07:50:58PM +0300, Oleksandr Tyshchenko wrote:
> +#ifndef _ASM_ARM_XEN_OPS_H
> +#define _ASM_ARM_XEN_OPS_H
> +
> +#include <xen/swiotlb-xen.h>
> +
> +static inline void xen_setup_dma_ops(struct device *dev)
> +{
> +#ifdef CONFIG_XEN
> + if (xen_swiotlb_detect())
> + dev->dma_ops = &xen_swiotlb_dma_ops;
> +#endif
Maybe create a proper !CONFIG_XEN stub for xen_swiotlb_detect instead
of the ifdef here, but otherwise this looks good to me.
Powered by blists - more mailing lists