提交 2895e1f8 编写于 作者: N Niklas Söderlund 提交者: Vinod Koul

dma-mapping: fix ia64 build, use PHYS_PFN

kbuild test robot reports:

   In file included from include/linux/skbuff.h:34:0,
                    from include/linux/tcp.h:21,
                    from drivers/net/ethernet/amd/xgbe/xgbe-drv.c:119:
   include/linux/dma-mapping.h: In function 'dma_map_resource':
>> include/linux/dma-mapping.h:274:22: error: implicit declaration of function '__phys_to_pfn' [-Werror=implicit-function-declaration]
     unsigned long pfn = __phys_to_pfn(phys_addr);
                         ^~~~~~~~~~~~~

ia64 does not provide __phys_to_pfn(), use the PHYS_PFN() alias.
Signed-off-by: NNiklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: NVinod Koul <vinod.koul@intel.com>
上级 9f878603
......@@ -271,7 +271,7 @@ static inline dma_addr_t dma_map_resource(struct device *dev,
unsigned long attrs)
{
struct dma_map_ops *ops = get_dma_ops(dev);
unsigned long pfn = __phys_to_pfn(phys_addr);
unsigned long pfn = PHYS_PFN(phys_addr);
dma_addr_t addr;
BUG_ON(!valid_dma_direction(dir));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册