[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <563959B1.5020101@codeaurora.org>
Date: Tue, 3 Nov 2015 20:04:49 -0500
From: Sinan Kaya <okaya@...eaurora.org>
To: Arnd Bergmann <arnd@...db.de>
Cc: dmaengine@...r.kernel.org, timur@...eaurora.org,
cov@...eaurora.org, jcm@...hat.com,
Rob Herring <robh+dt@...nel.org>,
Pawel Moll <pawel.moll@....com>,
Mark Rutland <mark.rutland@....com>,
Ian Campbell <ijc+devicetree@...lion.org.uk>,
Kumar Gala <galak@...eaurora.org>,
Vinod Koul <vinod.koul@...el.com>,
Dan Williams <dan.j.williams@...el.com>,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] dma: add Qualcomm Technologies HIDMA management
driver
On 11/3/2015 7:42 AM, Arnd Bergmann wrote:
> You have a distinct "compatible" string for qemu, right? It sounds like
> this is not the same device if the dependencies are different, and
> you could just have two ways to probe the same device.
>
No, it is the same dma channel object that gets probed by the same name
like the hypervisor. The channel object gets unbound from the
hypervisor, it then gets bound to VFIO. Then, eventually QEMU takes
over. The channel driver does not know under which OS it is running and
it works in both environments as it is without any code changes at this
moment.
> The split between the two drivers still feels a little awkward overall,
> it might be good to give it some more thought.
I see. I'd like to keep the management driver as independent as possible
from the channel driver for security and functionality reasons. I need
to keep the management addresses and functionality in the hypervisor only.
> > Would it work to describe the combination of the channel and management
> registers as a single device with a single driver, but the management
> parts being optional? That way, the management registers could be
> intergrated better into the dmaengine framework, to provide a consistent
> API to user space.
I can compile both management driver and channel driver into the same
module if it sounds better. I can probe one with channel and another
with the management name. I just need to be careful about not sharing
any kind of data structure between them otherwise virtualization will break.
I consider the management driver a client of the DMA engine API at this
moment.
--
Sinan Kaya
Qualcomm Technologies, Inc. on behalf of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a
Linux Foundation Collaborative Project
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists