All of lore.kernel.org
 help / color / mirror / Atom feed
* [agd5f:amd-staging-drm-next 7/7] drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c:1750 amdgpu_ttm_init() warn: inconsistent indenting
@ 2021-04-21  5:47 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-04-21  5:47 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 7887 bytes --]

tree:   https://gitlab.freedesktop.org/agd5f/linux.git amd-staging-drm-next
head:   b2987e229a0d616d97063b3b695e7c9483933c27
commit: b2987e229a0d616d97063b3b695e7c9483933c27 [7/7] drm/amdgpu/ttm: fix ifdefs for non-x86
config: ia64-randconfig-m031-20210421 (attached as .config)
compiler: ia64-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

New smatch warnings:
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c:1750 amdgpu_ttm_init() warn: inconsistent indenting

Old smatch warnings:
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c:267 amdgpu_ttm_map_buffer() warn: should 'i << 12' be a 64 bit type?

vim +1750 drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c

d38ceaf99ed015 Alex Deucher      2015-04-20  1745  
a05502e5cfa9ab Horace Chen       2017-09-29  1746  	/*
a05502e5cfa9ab Horace Chen       2017-09-29  1747  	 *The reserved vram for firmware must be pinned to the specified
a05502e5cfa9ab Horace Chen       2017-09-29  1748  	 *place on the VRAM, so reserve it early.
a05502e5cfa9ab Horace Chen       2017-09-29  1749  	 */
f5ec697e37023c Alex Deucher      2017-12-14 @1750  	r = amdgpu_ttm_fw_reserve_vram_init(adev);
a05502e5cfa9ab Horace Chen       2017-09-29  1751  	if (r) {
a05502e5cfa9ab Horace Chen       2017-09-29  1752  		return r;
a05502e5cfa9ab Horace Chen       2017-09-29  1753  	}
a05502e5cfa9ab Horace Chen       2017-09-29  1754  
778e8c428f90d7 Tianci.Yin        2019-09-30  1755  	/*
83d7f66a530aa1 Likun Gao         2020-05-21  1756  	 * only NAVI10 and onwards ASIC support for IP discovery.
83d7f66a530aa1 Likun Gao         2020-05-21  1757  	 * If IP discovery enabled, a block of memory should be
83d7f66a530aa1 Likun Gao         2020-05-21  1758  	 * reserved for IP discovey.
778e8c428f90d7 Tianci.Yin        2019-09-30  1759  	 */
72de33f8f7ba0f Alex Deucher      2020-07-29  1760  	if (adev->mman.discovery_bin) {
83d7f66a530aa1 Likun Gao         2020-05-21  1761  		r = amdgpu_ttm_reserve_tmr(adev);
778e8c428f90d7 Tianci.Yin        2019-09-30  1762  		if (r)
778e8c428f90d7 Tianci.Yin        2019-09-30  1763  			return r;
e862b08b4650be Monk Liu          2020-03-04  1764  	}
778e8c428f90d7 Tianci.Yin        2019-09-30  1765  
50da51744f005f Tom St Denis      2018-05-09  1766  	/* allocate memory as required for VGA
50da51744f005f Tom St Denis      2018-05-09  1767  	 * This is used for VGA emulation and pre-OS scanout buffers to
50da51744f005f Tom St Denis      2018-05-09  1768  	 * avoid display artifacts while transitioning between pre-OS
50da51744f005f Tom St Denis      2018-05-09  1769  	 * and driver.  */
cacbbe7c006559 Alex Deucher      2020-07-29  1770  	r = amdgpu_bo_create_kernel_at(adev, 0, adev->mman.stolen_vga_size,
857d913d057f8e Alex Deucher      2015-08-27  1771  				       AMDGPU_GEM_DOMAIN_VRAM,
cacbbe7c006559 Alex Deucher      2020-07-29  1772  				       &adev->mman.stolen_vga_memory,
14b18937cb60a4 Alex Deucher      2020-07-28  1773  				       NULL);
d38ceaf99ed015 Alex Deucher      2015-04-20  1774  	if (r)
d38ceaf99ed015 Alex Deucher      2015-04-20  1775  		return r;
cacbbe7c006559 Alex Deucher      2020-07-29  1776  	r = amdgpu_bo_create_kernel_at(adev, adev->mman.stolen_vga_size,
cacbbe7c006559 Alex Deucher      2020-07-29  1777  				       adev->mman.stolen_extended_size,
0635019412eb2d Alex Deucher      2020-07-28  1778  				       AMDGPU_GEM_DOMAIN_VRAM,
cacbbe7c006559 Alex Deucher      2020-07-29  1779  				       &adev->mman.stolen_extended_memory,
14b18937cb60a4 Alex Deucher      2020-07-28  1780  				       NULL);
d38ceaf99ed015 Alex Deucher      2015-04-20  1781  	if (r)
d38ceaf99ed015 Alex Deucher      2015-04-20  1782  		return r;
5f6a556f98de42 Xiaojie Yuan      2019-10-10  1783  
d38ceaf99ed015 Alex Deucher      2015-04-20  1784  	DRM_INFO("amdgpu: %uM of VRAM memory ready\n",
770d13b19fdf36 Christian König   2018-01-12  1785  		 (unsigned) (adev->gmc.real_vram_size / (1024 * 1024)));
36d3837266c53a Christian König   2017-07-07  1786  
50da51744f005f Tom St Denis      2018-05-09  1787  	/* Compute GTT size, either bsaed on 3/4th the size of RAM size
50da51744f005f Tom St Denis      2018-05-09  1788  	 * or whatever the user passed on module init */
424e2c8580286b Roger He          2017-11-10  1789  	if (amdgpu_gtt_size == -1) {
424e2c8580286b Roger He          2017-11-10  1790  		struct sysinfo si;
424e2c8580286b Roger He          2017-11-10  1791  
424e2c8580286b Roger He          2017-11-10  1792  		si_meminfo(&si);
24562523688beb Andrey Grodzovsky 2017-12-15  1793  		gtt_size = min(max((AMDGPU_DEFAULT_GTT_SIZE_MB << 20),
770d13b19fdf36 Christian König   2018-01-12  1794  			       adev->gmc.mc_vram_size),
24562523688beb Andrey Grodzovsky 2017-12-15  1795  			       ((uint64_t)si.totalram * si.mem_unit * 3/4));
24562523688beb Andrey Grodzovsky 2017-12-15  1796  	}
24562523688beb Andrey Grodzovsky 2017-12-15  1797  	else
36d3837266c53a Christian König   2017-07-07  1798  		gtt_size = (uint64_t)amdgpu_gtt_size << 20;
50da51744f005f Tom St Denis      2018-05-09  1799  
50da51744f005f Tom St Denis      2018-05-09  1800  	/* Initialize GTT memory pool */
158d20d1857fe5 Dave Airlie       2020-08-04  1801  	r = amdgpu_gtt_mgr_init(adev, gtt_size);
d38ceaf99ed015 Alex Deucher      2015-04-20  1802  	if (r) {
d38ceaf99ed015 Alex Deucher      2015-04-20  1803  		DRM_ERROR("Failed initializing GTT heap.\n");
d38ceaf99ed015 Alex Deucher      2015-04-20  1804  		return r;
d38ceaf99ed015 Alex Deucher      2015-04-20  1805  	}
d38ceaf99ed015 Alex Deucher      2015-04-20  1806  	DRM_INFO("amdgpu: %uM of GTT memory ready.\n",
36d3837266c53a Christian König   2017-07-07  1807  		 (unsigned)(gtt_size / (1024 * 1024)));
d38ceaf99ed015 Alex Deucher      2015-04-20  1808  
50da51744f005f Tom St Denis      2018-05-09  1809  	/* Initialize various on-chip memory pools */
473633540c2f51 Christian König   2020-07-23  1810  	r = amdgpu_ttm_init_on_chip(adev, AMDGPU_PL_GDS, adev->gds.gds_size);
d38ceaf99ed015 Alex Deucher      2015-04-20  1811  	if (r) {
d38ceaf99ed015 Alex Deucher      2015-04-20  1812  		DRM_ERROR("Failed initializing GDS heap.\n");
d38ceaf99ed015 Alex Deucher      2015-04-20  1813  		return r;
d38ceaf99ed015 Alex Deucher      2015-04-20  1814  	}
d38ceaf99ed015 Alex Deucher      2015-04-20  1815  
473633540c2f51 Christian König   2020-07-23  1816  	r = amdgpu_ttm_init_on_chip(adev, AMDGPU_PL_GWS, adev->gds.gws_size);
d38ceaf99ed015 Alex Deucher      2015-04-20  1817  	if (r) {
d38ceaf99ed015 Alex Deucher      2015-04-20  1818  		DRM_ERROR("Failed initializing gws heap.\n");
d38ceaf99ed015 Alex Deucher      2015-04-20  1819  		return r;
d38ceaf99ed015 Alex Deucher      2015-04-20  1820  	}
d38ceaf99ed015 Alex Deucher      2015-04-20  1821  
473633540c2f51 Christian König   2020-07-23  1822  	r = amdgpu_ttm_init_on_chip(adev, AMDGPU_PL_OA, adev->gds.oa_size);
d38ceaf99ed015 Alex Deucher      2015-04-20  1823  	if (r) {
d38ceaf99ed015 Alex Deucher      2015-04-20  1824  		DRM_ERROR("Failed initializing oa heap.\n");
d38ceaf99ed015 Alex Deucher      2015-04-20  1825  		return r;
d38ceaf99ed015 Alex Deucher      2015-04-20  1826  	}
d38ceaf99ed015 Alex Deucher      2015-04-20  1827  
d38ceaf99ed015 Alex Deucher      2015-04-20  1828  	return 0;
d38ceaf99ed015 Alex Deucher      2015-04-20  1829  }
d38ceaf99ed015 Alex Deucher      2015-04-20  1830  

:::::: The code at line 1750 was first introduced by commit
:::::: f5ec697e37023ce60dc1c38bf6b2bf32de767376 drm/amdgpu: move fw_reserve functions to amdgpu_ttm.c

:::::: TO: Alex Deucher <alexander.deucher@amd.com>
:::::: CC: Alex Deucher <alexander.deucher@amd.com>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 37750 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-04-21  5:47 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-21  5:47 [agd5f:amd-staging-drm-next 7/7] drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c:1750 amdgpu_ttm_init() warn: inconsistent indenting kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.