Commit 786d0e7f authored by Tom Zanussi's avatar Tom Zanussi Committed by Herbert Xu

dmaengine: idxd: Add wq private data accessors

Add the accessors idxd_wq_set_private() and idxd_wq_get_private()
allowing users to set and retrieve a private void * associated with an
idxd_wq.

The private data is stored in the idxd_dev.conf_dev associated with
each idxd_wq.
Signed-off-by: default avatarTom Zanussi <tom.zanussi@linux.intel.com>
Reviewed-by: default avatarFenghua Yu <fenghua.yu@intel.com>
Acked-by: default avatarVinod Koul <vkoul@kernel.org>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 86d3a341
......@@ -618,6 +618,16 @@ static inline int idxd_wq_refcount(struct idxd_wq *wq)
return wq->client_count;
};
static inline void idxd_wq_set_private(struct idxd_wq *wq, void *private)
{
dev_set_drvdata(wq_confdev(wq), private);
}
static inline void *idxd_wq_get_private(struct idxd_wq *wq)
{
return dev_get_drvdata(wq_confdev(wq));
}
/*
* Intel IAA does not support batch processing.
* The max batch size of device, max batch size of wq and
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment