dmaengine: idxd: create idxd_device sub-driver
authorDave Jiang <dave.jiang@intel.com>
Thu, 15 Jul 2021 18:44:24 +0000 (11:44 -0700)
committerVinod Koul <vkoul@kernel.org>
Wed, 21 Jul 2021 04:39:16 +0000 (10:09 +0530)
commit034b3290ba257f1a3c8730f3fba72e11645e7b50
tree69195a5183e732366e8bbe7e58163bb72ea0362e
parent5fee6567ec387088ec965ee60c63051bbe102cac
dmaengine: idxd: create idxd_device sub-driver

The original architecture of /sys/bus/dsa invented a scheme whereby a
single entry in the list of bus drivers, /sys/bus/drivers/dsa, handled
all device types and internally routed them to different drivers.
Those internal drivers were invisible to userspace. Now, as
/sys/bus/dsa wants to grow support for alternate drivers for a given
device, for example vfio-mdev instead of kernel-internal-dmaengine, a
proper bus device-driver model is needed. The first step in that process
is separating the existing omnibus/implicit "dsa" driver into proper
individual drivers registered on /sys/bus/dsa. Establish the idxd_drv
driver that control the enabling and disabling of the accelerator device.

Reviewed-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Link: https://lore.kernel.org/r/162637466439.744545.15210886092627144577.stgit@djiang5-desk3.ch.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/idxd/device.c
drivers/dma/idxd/idxd.h
drivers/dma/idxd/init.c