tree:   git://people.freedesktop.org/~agd5f/linux.git amd-staging-dkms-4.18
head:   937a0a9df97d4c1c7cecf6faa2f501d175bc3c2a
commit: 3a357f8fc9464b3341938cb3b68930989cb0e064 [839/1379] drm/amdgpu: 
[hybrid] add direct gma(dgma) support
reproduce: make htmldocs

All warnings (new ones prefixed by >>):

   WARNING: convert(1) not found, for SVG to PDF conversion install ImageMagick 
(https://www.imagemagick.org)
   mm/mempool.c:228: warning: Function parameter or member 'pool' not described 
in 'mempool_init'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.ibss' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.connect' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.keys' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 'wext.ie' 
not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.ie_len' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.bssid' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.ssid' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.default_key' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.default_mgmt_key' not described in 'wireless_dev'
   include/net/cfg80211.h:4279: warning: Function parameter or member 
'wext.prev_bssid_valid' not described in 'wireless_dev'
   include/net/mac80211.h:2282: warning: Function parameter or member 
'radiotap_timestamp.units_pos' not described in 'ieee80211_hw'
   include/net/mac80211.h:2282: warning: Function parameter or member 
'radiotap_timestamp.accuracy' not described in 'ieee80211_hw'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.rates' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.rts_cts_rate_idx' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.use_rts' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.use_cts_prot' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.short_preamble' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.skip_table' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.jiffies' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.vif' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.hw_key' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.flags' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'control.enqueue_time' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 'ack' not 
described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'ack.cookie' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.rates' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.ack_signal' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.ampdu_ack_len' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.ampdu_len' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.antenna' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.tx_time' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.is_valid_ack_signal' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'status.status_driver_data' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'driver_rates' not described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 'pad' not 
described in 'ieee80211_tx_info'
   include/net/mac80211.h:955: warning: Function parameter or member 
'rate_driver_data' not described in 'ieee80211_tx_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'rx_stats_avg' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'rx_stats_avg.signal' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'rx_stats_avg.chain_signal' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.filtered' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.retry_failed' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.retry_count' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.lost_packets' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.last_tdls_pkt_time' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.msdu_retries' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.msdu_failed' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.last_ack' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.last_ack_signal' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.ack_signal_filled' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'status_stats.avg_ack_signal' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'tx_stats.packets' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'tx_stats.bytes' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'tx_stats.last_rate' not described in 'sta_info'
   net/mac80211/sta_info.h:588: warning: Function parameter or member 
'tx_stats.msdu' not described in 'sta_info'
   kernel/sched/fair.c:3760: warning: Function parameter or member 'flags' not 
described in 'attach_entity_load_avg'
   include/linux/device.h:93: warning: bad line: this bus.
   include/linux/dma-buf.h:307: warning: Function parameter or member 
'cb_excl.cb' not described in 'dma_buf'
   include/linux/dma-buf.h:307: warning: Function parameter or member 
'cb_excl.poll' not described in 'dma_buf'
   include/linux/dma-buf.h:307: warning: Function parameter or member 
'cb_excl.active' not described in 'dma_buf'
   include/linux/dma-buf.h:307: warning: Function parameter or member 
'cb_shared.cb' not described in 'dma_buf'
   include/linux/dma-buf.h:307: warning: Function parameter or member 
'cb_shared.poll' not described in 'dma_buf'
   include/linux/dma-buf.h:307: warning: Function parameter or member 
'cb_shared.active' not described in 'dma_buf'
   include/linux/dma-fence-array.h:54: warning: Function parameter or member 
'work' not described in 'dma_fence_array'
   include/linux/gpio/driver.h:142: warning: Function parameter or member 
'request_key' not described in 'gpio_irq_chip'
   include/linux/iio/hw-consumer.h:1: warning: no structured comments found
   include/linux/device.h:94: warning: bad line: this bus.
   include/linux/input/sparse-keymap.h:46: warning: Function parameter or 
member 'sw' not described in 'key_entry'
   include/linux/regulator/driver.h:227: warning: Function parameter or member 
'resume_early' not described in 'regulator_ops'
   drivers/regulator/core.c:4465: warning: Excess function parameter 'state' 
description in 'regulator_suspend_late'
   arch/s390/include/asm/cio.h:245: warning: Function parameter or member 
'esw.esw0' not described in 'irb'
   arch/s390/include/asm/cio.h:245: warning: Function parameter or member 
'esw.esw1' not described in 'irb'
   arch/s390/include/asm/cio.h:245: warning: Function parameter or member 
'esw.esw2' not described in 'irb'
   arch/s390/include/asm/cio.h:245: warning: Function parameter or member 
'esw.esw3' not described in 'irb'
   arch/s390/include/asm/cio.h:245: warning: Function parameter or member 
'esw.eadm' not described in 'irb'
   drivers/usb/dwc3/gadget.c:510: warning: Excess function parameter 'dwc' 
description in 'dwc3_gadget_start_config'
   drivers/gpu/drm/amd/amdgpu/amdgpu_prime.c:210: warning: Function parameter 
or member 'target_dev' not described in 'amdgpu_gem_map_attach'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1541: warning: Excess function 
parameter 'nodes' description in 'amdgpu_vm_bo_split_mapping'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:3030: warning: Excess function 
parameter 'dev' description in 'amdgpu_vm_get_task_info'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1542: warning: Function parameter or 
member 'vram_base_offset' not described in 'amdgpu_vm_bo_split_mapping'
>> drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1542: warning: Function parameter or 
>> member 'mem' not described in 'amdgpu_vm_bo_split_mapping'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1542: warning: Excess function 
parameter 'nodes' description in 'amdgpu_vm_bo_split_mapping'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:3031: warning: Function parameter or 
member 'adev' not described in 'amdgpu_vm_get_task_info'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:3031: warning: Excess function 
parameter 'dev' description in 'amdgpu_vm_get_task_info'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_pin' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_unpin' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_res_obj' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_get_sg_table' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_import_sg_table' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_vmap' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_vunmap' not described in 'drm_driver'
   include/drm/drm_drv.h:610: warning: Function parameter or member 
'gem_prime_mmap' not described in 'drm_driver'
   drivers/gpu/drm/i915/i915_vma.h:48: warning: cannot understand function 
prototype: 'struct i915_vma '
   drivers/gpu/drm/i915/i915_vma.h:1: warning: no structured comments found
   include/drm/tinydrm/tinydrm.h:34: warning: Function parameter or member 
'fb_dirty' not described in 'tinydrm_device'
   drivers/gpu/drm/tinydrm/mipi-dbi.c:272: warning: Function parameter or 
member 'crtc_state' not described in 'mipi_dbi_enable_flush'
   drivers/gpu/drm/tinydrm/mipi-dbi.c:272: warning: Function parameter or 
member 'plane_state' not described in 'mipi_dbi_enable_flush'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'dev_scratch' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'ip_defrag_offset' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'skb_mstamp' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'__cloned_offset' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'head_frag' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'__pkt_type_offset' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'encapsulation' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'encap_hdr_csum' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'csum_valid' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'csum_complete_sw' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'csum_level' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'inner_protocol_type' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'remcsum_offload' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'offload_fwd_mark' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'offload_mr_fwd_mark' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'sender_cpu' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'reserved_tailroom' not described in 'sk_buff'
   include/linux/skbuff.h:852: warning: Function parameter or member 
'inner_ipproto' not described in 'sk_buff'
   include/net/sock.h:234: warning: Function parameter or member 'skc_addrpair' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_portpair' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_ipv6only' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 
'skc_net_refcnt' not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_v6_daddr' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 
'skc_v6_rcv_saddr' not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_cookie' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_listener' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_tw_dr' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 'skc_rcv_wnd' 
not described in 'sock_common'
   include/net/sock.h:234: warning: Function parameter or member 
'skc_tw_rcv_nxt' not described in 'sock_common'
   include/net/sock.h:493: warning: Function parameter or member 
'sk_backlog.rmem_alloc' not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 
'sk_backlog.len' not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 
'sk_backlog.head' not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 
'sk_backlog.tail' not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 'sk_wq_raw' 
not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 
'tcp_rtx_queue' not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 
'sk_route_forced_caps' not described in 'sock'
   include/net/sock.h:493: warning: Function parameter or member 
'sk_validate_xmit_skb' not described in 'sock'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'adj_list.upper' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'adj_list.lower' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'gso_partial_features' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'switchdev_ops' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'l3mdev_ops' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'xfrmdev_ops' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'tlsdev_ops' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'name_assign_type' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'ieee802154_ptr' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'mpls_ptr' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'xdp_prog' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'gro_flush_timeout' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'nf_hooks_ingress' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'____cacheline_aligned_in_smp' not described in 'net_device'
   include/linux/netdevice.h:1997: warning: Function parameter or member 
'qdisc_hash' not described in 'net_device'
   include/linux/phylink.h:56: warning: Function parameter or member 
'__ETHTOOL_DECLARE_LINK_MODE_MASK(advertising' not described in 
'phylink_link_state'
   include/linux/phylink.h:56: warning: Function parameter or member 
'__ETHTOOL_DECLARE_LINK_MODE_MASK(lp_advertising' not described in 
'phylink_link_state'
   sound/soc/soc-core.c:2787: warning: Excess function parameter 
'legacy_dai_naming' description in 'snd_soc_register_dais'
   include/linux/rcupdate.h:571: ERROR: Unexpected indentation.
   include/linux/rcupdate.h:575: ERROR: Unexpected indentation.
   include/linux/rcupdate.h:579: WARNING: Block quote ends without a blank 
line; unexpected unindent.
   include/linux/rcupdate.h:581: WARNING: Block quote ends without a blank 
line; unexpected unindent.
   include/linux/rcupdate.h:581: WARNING: Inline literal start-string without 
end-string.
   lib/reed_solomon/reed_solomon.c:287: ERROR: Unknown target name: "gfp".
   include/linux/wait.h:110: WARNING: Block quote ends without a blank line; 
unexpected unindent.
   include/linux/wait.h:113: ERROR: Unexpected indentation.
   include/linux/wait.h:115: WARNING: Block quote ends without a blank line; 
unexpected unindent.
   kernel/time/hrtimer.c:1129: WARNING: Block quote ends without a blank line; 
unexpected unindent.
   kernel/signal.c:327: WARNING: Inline literal start-string without end-string.
   drivers/video/fbdev/core/modedb.c:647: WARNING: Inline strong start-string 
without end-string.
   drivers/video/fbdev/core/modedb.c:647: WARNING: Inline strong start-string 
without end-string.
   drivers/video/fbdev/core/modedb.c:647: WARNING: Inline strong start-string 
without end-string.
   drivers/video/fbdev/core/modedb.c:647: WARNING: Inline strong start-string 
without end-string.
   drivers/ata/libata-core.c:5946: ERROR: Unknown target name: "hw".
   drivers/message/fusion/mptbase.c:5054: WARNING: Definition list ends without 
a blank line; unexpected unindent.
   drivers/tty/serial/serial_core.c:1892: WARNING: Definition list ends without 
a blank line; unexpected unindent.
   include/linux/mtd/rawnand.h:1446: WARNING: Inline strong start-string 
without end-string.
   include/linux/mtd/rawnand.h:1448: WARNING: Inline strong start-string 
without end-string.
   include/linux/regulator/driver.h:279: ERROR: Unknown target name: 
"regulator_regmap_x_voltage".
   Documentation/driver-api/soundwire/locking.rst:50: ERROR: Inconsistent 
literal block quoting.
   Documentation/driver-api/soundwire/locking.rst:51: WARNING: Line block ends 
without a blank line.
   Documentation/driver-api/soundwire/locking.rst:55: WARNING: Inline 
substitution_reference start-string without end-string.
   Documentation/driver-api/soundwire/locking.rst:56: WARNING: Line block ends 
without a blank line.
   Documentation/driver-api/soundwire/stream.rst:177: WARNING: Explicit markup 
ends without a blank line; unexpected unindent.
   Documentation/driver-api/soundwire/stream.rst:203: WARNING: Explicit markup 
ends without a blank line; unexpected unindent.
   Documentation/driver-api/soundwire/stream.rst:248: WARNING: Explicit markup 
ends without a blank line; unexpected unindent.
   Documentation/driver-api/soundwire/stream.rst:277: WARNING: Explicit markup 
ends without a blank line; unexpected unindent.

vim +1542 drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c

  1513  
  1514  /**
  1515   * amdgpu_vm_bo_split_mapping - split a mapping into smaller chunks
  1516   *
  1517   * @adev: amdgpu_device pointer
  1518   * @exclusive: fence we need to sync to
  1519   * @pages_addr: DMA addresses to use for mapping
  1520   * @vm: requested vm
  1521   * @mapping: mapped range and flags to use for the update
  1522   * @flags: HW flags for the mapping
  1523   * @nodes: array of drm_mm_nodes with the MC addresses
  1524   * @fence: optional resulting fence
  1525   *
  1526   * Split the mapping into smaller chunks so that each update fits
  1527   * into a SDMA IB.
  1528   *
  1529   * Returns:
  1530   * 0 for success, -EINVAL for failure.
  1531   */
  1532  static int amdgpu_vm_bo_split_mapping(struct amdgpu_device *adev,
  1533                                        struct dma_fence *exclusive,
  1534                                        dma_addr_t *pages_addr,
  1535                                        struct amdgpu_vm *vm,
  1536                                        struct amdgpu_bo_va_mapping 
*mapping,
  1537                                        uint64_t vram_base_offset,
  1538                                        uint64_t flags,
  1539                                        struct ttm_mem_reg *mem,
  1540                                        struct dma_fence **fence)
> 1541  {
> 1542          struct drm_mm_node *nodes = mem ? mem->mm_node : NULL;
  1543          unsigned min_linear_pages = 1 << adev->vm_manager.fragment_size;
  1544          uint64_t pfn, start = mapping->start;
  1545          int r;
  1546  
  1547          /* normally,bo_va->flags only contians READABLE and WIRTEABLE 
bit go here
  1548           * but in case of something, we filter the flags in first place
  1549           */
  1550          if (!(mapping->flags & AMDGPU_PTE_READABLE))
  1551                  flags &= ~AMDGPU_PTE_READABLE;
  1552          if (!(mapping->flags & AMDGPU_PTE_WRITEABLE))
  1553                  flags &= ~AMDGPU_PTE_WRITEABLE;
  1554  
  1555          flags &= ~AMDGPU_PTE_EXECUTABLE;
  1556          flags |= mapping->flags & AMDGPU_PTE_EXECUTABLE;
  1557  
  1558          flags &= ~AMDGPU_PTE_MTYPE_MASK;
  1559          flags |= (mapping->flags & AMDGPU_PTE_MTYPE_MASK);
  1560  
  1561          if ((mapping->flags & AMDGPU_PTE_PRT) &&
  1562              (adev->asic_type >= CHIP_VEGA10)) {
  1563                  flags |= AMDGPU_PTE_PRT;
  1564                  flags &= ~AMDGPU_PTE_VALID;
  1565          }
  1566  
  1567          trace_amdgpu_vm_bo_update(mapping);
  1568  
  1569          pfn = mapping->offset >> PAGE_SHIFT;
  1570          if (nodes) {
  1571                  while (pfn >= nodes->size) {
  1572                          pfn -= nodes->size;
  1573                          ++nodes;
  1574                  }
  1575          }
  1576  
  1577          do {
  1578                  dma_addr_t *dma_addr = NULL;
  1579                  uint64_t max_entries;
  1580                  uint64_t addr, last;
  1581                  uint64_t count;
  1582  
  1583                  if (nodes) {
  1584                          addr = nodes->start << PAGE_SHIFT;
  1585                          max_entries = (nodes->size - pfn) *
  1586                                  (PAGE_SIZE / AMDGPU_GPU_PAGE_SIZE);
  1587                  switch (mem->mem_type) {
  1588                          case TTM_PL_TT:
  1589                                  max_entries = min(max_entries, 16ull * 
1024ull);
  1590                          for (count = 1;
  1591                                   count < max_entries / 
AMDGPU_GPU_PAGES_IN_CPU_PAGE;
  1592                                   ++count){
  1593                                  uint64_t idx = pfn + count;
  1594                                          if (pages_addr[idx] !=
  1595                                                  (pages_addr[idx - 1] + 
PAGE_SIZE))
  1596                                          break;
  1597                                  }
  1598                                  if (count < min_linear_pages) {
  1599                                          addr = pfn << PAGE_SHIFT;
  1600                                          dma_addr = pages_addr;
  1601                                  } else {
  1602                                          addr = pages_addr[pfn];
  1603                                          max_entries = count;
  1604                                  }
  1605                                  break;
  1606                          case AMDGPU_PL_DGMA_IMPORT:
  1607                                  addr = 0;
  1608                                  max_entries = min(max_entries, 16ull * 
1024ull);
  1609                                  dma_addr = pages_addr;
  1610                                  break;
  1611                          case AMDGPU_PL_DGMA:
  1612                                  addr += vram_base_offset +
  1613                                          
adev->mman.bdev.man[mem->mem_type].gpu_offset -
  1614                                          
adev->mman.bdev.man[TTM_PL_VRAM].gpu_offset;
  1615                                  addr += pfn << PAGE_SHIFT;
  1616                                  break;
  1617                          case TTM_PL_VRAM:
  1618                                  addr += vram_base_offset;
  1619                                  addr += pfn << PAGE_SHIFT;
  1620                                  break;
  1621                          default:
  1622                                  break;
  1623                          }
  1624                  } else {
  1625                          addr = 0;
  1626                          max_entries = S64_MAX;
  1627                  }
  1628  
  1629                  last = min((uint64_t)mapping->last, start + max_entries 
- 1);
  1630                  r = amdgpu_vm_bo_update_mapping(adev, exclusive, 
dma_addr, vm,
  1631                                                  start, last, flags, 
addr,
  1632                                                  fence);
  1633                  if (r)
  1634                          return r;
  1635  
  1636                  pfn += (last - start + 1) / 
AMDGPU_GPU_PAGES_IN_CPU_PAGE;
  1637                  if (nodes && nodes->size == pfn) {
  1638                          pfn = 0;
  1639                          ++nodes;
  1640                  }
  1641                  start = last + 1;
  1642  
  1643          } while (unlikely(start != mapping->last + 1));
  1644  
  1645          return 0;
  1646  }
  1647  

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Reply via email to