3.10 dma-buf updates
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAABAgAGBQJRgQj+AAoJEAG+/NWsLn5b+ZgP/2To0IUb3hyvcfCEnGytzOu1 zIkDMyqTYtPy3r+gdZ7LkZYJkJ0NrO9DwWUDcPEY/9mBL0kwOBIgWumUi2ABESQI /tuTYzG0MKo5UNRr/aSK5erLSZeSbRht4DE8oiK9mw1O6/mUq5c4J/V+z6AYWC8m 4cad8+XGU6x1g0a13VIhO8p2OcfV/ZyGwOeHN4SMZhkoHt3Le8wVXYMUDDofmCKs lkkCetleQFcHLtwIMRC3SX15mIF57LhicK5JfmvEYvI4ghVu5eKi5B59aGdhG0R9 p7cKZ10TgDbr2I8gvQNZ/jSKhMCxLeGHeA781YWqJRU/YdvoYltVVOeWH60YZJdF K/dwaPsVkE68xVpTO5xieCTY9nSk1q258gQLgPkgThQYuRuPgWwAN/GbaFYGJjew vGmpp2F7VZxrVjBO89Rqgp47KWZE9ibEpc4Gb6pg7thqRl/joi6sosP0zGUApnFT fJSKMvXgNGDk6r8b5F2EYKTeLAHDuQ+FqzZeZ1+B/IOEwmyUosqslUlhmEVXqawW CUMO0MkimIfv7stPcgx/v7e3lQDz/8EGI8NBjJIipkeF+Fo39bUt4MA56SVp/lBC YyPokFjZGcqtADKHxZzNYTpGx/9NTMCDR510qhqITWQXd+e6ygbmLUgwdOOiBlQM gQDdPh29sPULSad37tbr =VZTM -----END PGP SIGNATURE----- Merge tag 'tag-for-linus-3.10' of git://git.linaro.org/people/sumitsemwal/linux-dma-buf Pull dma-buf updates from Sumit Semwal: "Added debugfs support to dma-buf" * tag 'tag-for-linus-3.10' of git://git.linaro.org/people/sumitsemwal/linux-dma-buf: dma-buf: Add debugfs support dma-buf: replace dma_buf_export() with dma_buf_export_named()
This commit is contained in:
commit
b0ca4d0123
3 changed files with 189 additions and 9 deletions
|
|
@ -112,6 +112,8 @@ struct dma_buf_ops {
|
|||
* @file: file pointer used for sharing buffers across, and for refcounting.
|
||||
* @attachments: list of dma_buf_attachment that denotes all devices attached.
|
||||
* @ops: dma_buf_ops associated with this buffer object.
|
||||
* @exp_name: name of the exporter; useful for debugging.
|
||||
* @list_node: node for dma_buf accounting and debugging.
|
||||
* @priv: exporter specific private data for this buffer object.
|
||||
*/
|
||||
struct dma_buf {
|
||||
|
|
@ -123,6 +125,8 @@ struct dma_buf {
|
|||
struct mutex lock;
|
||||
unsigned vmapping_counter;
|
||||
void *vmap_ptr;
|
||||
const char *exp_name;
|
||||
struct list_head list_node;
|
||||
void *priv;
|
||||
};
|
||||
|
||||
|
|
@ -162,8 +166,13 @@ struct dma_buf_attachment *dma_buf_attach(struct dma_buf *dmabuf,
|
|||
struct device *dev);
|
||||
void dma_buf_detach(struct dma_buf *dmabuf,
|
||||
struct dma_buf_attachment *dmabuf_attach);
|
||||
struct dma_buf *dma_buf_export(void *priv, const struct dma_buf_ops *ops,
|
||||
size_t size, int flags);
|
||||
|
||||
struct dma_buf *dma_buf_export_named(void *priv, const struct dma_buf_ops *ops,
|
||||
size_t size, int flags, const char *);
|
||||
|
||||
#define dma_buf_export(priv, ops, size, flags) \
|
||||
dma_buf_export_named(priv, ops, size, flags, __FILE__)
|
||||
|
||||
int dma_buf_fd(struct dma_buf *dmabuf, int flags);
|
||||
struct dma_buf *dma_buf_get(int fd);
|
||||
void dma_buf_put(struct dma_buf *dmabuf);
|
||||
|
|
@ -185,5 +194,6 @@ int dma_buf_mmap(struct dma_buf *, struct vm_area_struct *,
|
|||
unsigned long);
|
||||
void *dma_buf_vmap(struct dma_buf *);
|
||||
void dma_buf_vunmap(struct dma_buf *, void *vaddr);
|
||||
|
||||
int dma_buf_debugfs_create_file(const char *name,
|
||||
int (*write)(struct seq_file *));
|
||||
#endif /* __DMA_BUF_H__ */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue