Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Apr 2019 11:15:48 +0000 (UTC)
From:      Hans Petter Selasky <hselasky@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r345919 - stable/12/sys/compat/linuxkpi/common/include/linux
Message-ID:  <201904051115.x35BFmbu001885@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: hselasky
Date: Fri Apr  5 11:15:48 2019
New Revision: 345919
URL: https://svnweb.freebsd.org/changeset/base/345919

Log:
  MFC r345096:
  Implement dma_map_page_attrs() in the LinuxKPI.
  
  Submitted by:		Johannes Lundberg <johalun0@gmail.com>
  Sponsored by:		Limelight Networks
  Sponsored by:		Mellanox Technologies

Modified:
  stable/12/sys/compat/linuxkpi/common/include/linux/dma-mapping.h
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/compat/linuxkpi/common/include/linux/dma-mapping.h
==============================================================================
--- stable/12/sys/compat/linuxkpi/common/include/linux/dma-mapping.h	Fri Apr  5 11:14:27 2019	(r345918)
+++ stable/12/sys/compat/linuxkpi/common/include/linux/dma-mapping.h	Fri Apr  5 11:15:48 2019	(r345919)
@@ -185,6 +185,14 @@ dma_unmap_single_attrs(struct device *dev, dma_addr_t 
 {
 }
 
+static inline dma_addr_t
+dma_map_page_attrs(struct device *dev, struct page *page, size_t offset,
+    size_t size, enum dma_data_direction dir, unsigned long attrs)
+{
+
+	return (VM_PAGE_TO_PHYS(page) + offset);
+}
+
 static inline int
 dma_map_sg_attrs(struct device *dev, struct scatterlist *sgl, int nents,
     enum dma_data_direction dir, struct dma_attrs *attrs)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201904051115.x35BFmbu001885>