Re: [PATCH v2 2/3] drm/amdgpu: convert code name to ip version for noretry set

2022-03-01 Thread Paul Menzel
Dear Christian, Am 02.03.22 um 08:46 schrieb Christian König: Am 01.03.22 um 16:24 schrieb Paul Menzel: […] Am 01.03.22 um 16:01 schrieb Yifan Zhang: Use IP version rather than codename for noretry set. Why? Why not? No idea as the commit message currently does not document the

Re: [PATCH v2 2/3] drm/amdgpu: convert code name to ip version for noretry set

2022-03-01 Thread Christian König
Am 01.03.22 um 16:01 schrieb Yifan Zhang: Use IP version rather than codename for noretry set. Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git

Re: [PATCH v2 2/3] drm/amdgpu: convert code name to ip version for noretry set

2022-03-01 Thread Christian König
Am 01.03.22 um 16:24 schrieb Paul Menzel: Dear Yifan, Thank you for your patch. Am 01.03.22 um 16:01 schrieb Yifan Zhang: Use IP version rather than codename for noretry set. Why? Why not? Signed-off-by: Yifan Zhang ---   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 17

RE: [PATCH Review 1/1] drm/amdgpu: support send bad channel info to smu

2022-03-01 Thread Zhou1, Tao
[AMD Official Use Only] > -Original Message- > From: Stanley.Yang > Sent: Tuesday, March 1, 2022 9:30 PM > To: amd-gfx@lists.freedesktop.org; Zhang, Hawking > ; Zhou1, Tao ; Joo, Maria > > Cc: Yang, Stanley > Subject: [PATCH Review 1/1] drm/amdgpu: support send bad channel info to >

[PATCH] drm/amdgpu: fix potential null dereference

2022-03-01 Thread Weiguo Li
"ctx" is dereferenced but null checked later. Swap their positions to avoid potential null dereference. Found using a Coccinelle script: https://coccinelle.gitlabpages.inria.fr/website/rules/mini_null_ref.cocci Signed-off-by: Weiguo Li --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 6 -- 1

Re: [PATCH v9] drm/amdgpu: add drm buddy support to amdgpu

2022-03-01 Thread kernel test robot
Hi Arunpravin, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on drm/drm-next] [also build test WARNING on drm-tip/drm-tip] [cannot apply to drm-intel/for-linux-next v5.17-rc6 next-20220301] [If your patch is applied to the wrong git tree, kindly drop us a note

RE: [PATCH] drm/amdgpu: Move common initialization operations of each ras block to one function

2022-03-01 Thread Chai, Thomas
[AMD Official Use Only] Hi Stanley, Thanks for your suggestion. I add a comment after your comment. -Original Message- From: Yang, Stanley Sent: Tuesday, March 1, 2022 9:50 PM To: Chai, Thomas ; amd-gfx@lists.freedesktop.org Cc: Zhou1, Tao ; Zhang, Hawking ; Clements, John ;

Re: [PATCH 6/6] treewide: remove check of list iterator against head past the loop body

2022-03-01 Thread Linus Torvalds
So looking at this patch, I really reacted to the fact that quite often the "use outside the loop" case is all kinds of just plain unnecessary, but _used_ to be a convenience feature. I'll just quote the first chunk in it's entirely as an example - not because I think this chunk is particularly

[PATCH v9] drm/amdgpu: add drm buddy support to amdgpu

2022-03-01 Thread Arunpravin
- Remove drm_mm references and replace with drm buddy functionalities - Add res cursor support for drm buddy v2(Matthew Auld): - replace spinlock with mutex as we call kmem_cache_zalloc (..., GFP_KERNEL) in drm_buddy_alloc() function - lock drm_buddy_block_trim() function as it calls

Re: [PATCH v13 5/5] drm/amdgpu: add drm buddy support to amdgpu

2022-03-01 Thread Arunpravin
On 22/02/22 6:24 pm, Christian König wrote: > Am 21.02.22 um 17:45 schrieb Arunpravin: >> - Remove drm_mm references and replace with drm buddy functionalities >> - Add res cursor support for drm buddy >> >> v2(Matthew Auld): >>- replace spinlock with mutex as we call kmem_cache_zalloc >>

[PATCH AUTOSEL 5.15 16/23] drm/amdgpu: bypass tiling flag check in virtual display case (v2)

2022-03-01 Thread Sasha Levin
From: Guchun Chen [ Upstream commit e2b993302f40c4eb714ecf896dd9e1c5be7d4cd7 ] vkms leverages common amdgpu framebuffer creation, and also as it does not support FB modifier, there is no need to check tiling flags when initing framebuffer when virtual display is enabled. This can fix below

[PATCH AUTOSEL 5.16 20/28] drm/amdgpu: bypass tiling flag check in virtual display case (v2)

2022-03-01 Thread Sasha Levin
From: Guchun Chen [ Upstream commit e2b993302f40c4eb714ecf896dd9e1c5be7d4cd7 ] vkms leverages common amdgpu framebuffer creation, and also as it does not support FB modifier, there is no need to check tiling flags when initing framebuffer when virtual display is enabled. This can fix below

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Tue, Mar 1, 2022 at 11:06 AM Linus Torvalds wrote: > > So instead of that simple "if (!entry)", we'd effectively have to > continue to use something that still works with the old world order > (ie that "if (list_entry_is_head())" model). Just to prove my point about how this is painful, that

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Tue, Mar 1, 2022 at 10:14 AM Kees Cook wrote: > > The first big glitch with -Wshadow was with shadowed global variables. > GCC 4.8 fixed that, but it still yells about shadowed functions. What > _almost_ works is -Wshadow=local. Heh. Yeah, I just have long memories of "-Wshadow was a

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Matthew Wilcox
On Tue, Mar 01, 2022 at 10:14:07AM -0800, Kees Cook wrote: > On Mon, Feb 28, 2022 at 04:45:11PM -0800, Linus Torvalds wrote: > > Really. The "-Wshadow doesn't work on the kernel" is not some new > > issue, because you have to do completely insane things to the source > > code to enable it. > >

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Mon, Feb 28, 2022 at 2:29 PM James Bottomley wrote: > > However, if the desire is really to poison the loop variable then we > can do > > #define list_for_each_entry(pos, head, member) \ > for (pos = list_first_entry(head, typeof(*pos), member);\ >

Re: [PATCH 2/2] drm/amdgpu: Bump minor version for hot plug tests enabliing.

2022-03-01 Thread Alex Deucher
On Tue, Mar 1, 2022 at 1:08 PM Andrey Grodzovsky wrote: > > This will allow to enable the tests only after latest fix > after which the tests passed on my system. > > I tested on NV21 standalone and Vega 10 and Polaris as > pair with DRI_PRIME. > > It's possible there might be still issues on

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Greg KH
On Tue, Mar 01, 2022 at 06:40:04PM +0100, Jakob Koschel wrote: > > > > On 1. Mar 2022, at 18:36, Greg KH wrote: > > > > On Tue, Mar 01, 2022 at 12:28:15PM +0100, Jakob Koschel wrote: > >> > >> > >>> On 1. Mar 2022, at 01:41, Linus Torvalds > >>> wrote: > >>> > >>> On Mon, Feb 28, 2022 at

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Kees Cook
On Mon, Feb 28, 2022 at 04:45:11PM -0800, Linus Torvalds wrote: > Really. The "-Wshadow doesn't work on the kernel" is not some new > issue, because you have to do completely insane things to the source > code to enable it. The first big glitch with -Wshadow was with shadowed global variables.

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Kees Cook
On Tue, Mar 01, 2022 at 12:28:15PM +0100, Jakob Koschel wrote: > Based on the coccinelle script there are ~480 cases that need fixing > in total. I'll now finish all of them and then split them by > submodules as Greg suggested and repost a patch set per submodule. > Sounds good? To help with

[PATCH 2/2] drm/amdgpu: Bump minor version for hot plug tests enabliing.

2022-03-01 Thread Andrey Grodzovsky
This will allow to enable the tests only after latest fix after which the tests passed on my system. I tested on NV21 standalone and Vega 10 and Polaris as pair with DRI_PRIME. It's possible there might be still issues on ASICs i don't have at my posession but that that the point of enbling the

[PATCH 1/2] drm/amdgpu: Fix sigsev when accessing MMIO on hot unplug.

2022-03-01 Thread Andrey Grodzovsky
Protect with drm_dev_enter/exit Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c index

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Greg KH
On Tue, Mar 01, 2022 at 12:28:15PM +0100, Jakob Koschel wrote: > > > > On 1. Mar 2022, at 01:41, Linus Torvalds > > wrote: > > > > On Mon, Feb 28, 2022 at 1:47 PM Jakob Koschel > > wrote: > >> > >> The goal of this is to get compiler warnings right? This would indeed be > >> great. > > >

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Greg KH
On Mon, Feb 28, 2022 at 01:06:57PM +0100, Jakob Koschel wrote: > > > > On 28. Feb 2022, at 12:20, Greg KH wrote: > > > > On Mon, Feb 28, 2022 at 12:08:18PM +0100, Jakob Koschel wrote: > >> If the list does not contain the expected element, the value of > >> list_for_each_entry() iterator will

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Jakob Koschel
> On 1. Mar 2022, at 18:36, Greg KH wrote: > > On Tue, Mar 01, 2022 at 12:28:15PM +0100, Jakob Koschel wrote: >> >> >>> On 1. Mar 2022, at 01:41, Linus Torvalds >>> wrote: >>> >>> On Mon, Feb 28, 2022 at 1:47 PM Jakob Koschel >>> wrote: The goal of this is to get compiler

Re: [PATCH] mm: split vm_normal_pages for LRU and non-LRU handling

2022-03-01 Thread David Hildenbrand
>> >>> if (PageReserved(page)) >>> diff --git a/mm/migrate.c b/mm/migrate.c >>> index c31d04b46a5e..17d049311b78 100644 >>> --- a/mm/migrate.c >>> +++ b/mm/migrate.c >>> @@ -1614,7 +1614,7 @@ static int add_page_for_migration(struct mm_struct >>> *mm, unsigned long addr, >>>

Re: [PATCH] mm: split vm_normal_pages for LRU and non-LRU handling

2022-03-01 Thread David Hildenbrand
On 01.03.22 17:30, Felix Kuehling wrote: > Am 2022-03-01 um 11:22 schrieb David Hildenbrand: > if (PageReserved(page)) > diff --git a/mm/migrate.c b/mm/migrate.c > index c31d04b46a5e..17d049311b78 100644 > --- a/mm/migrate.c > +++ b/mm/migrate.c > @@

[PATCH 13/13] drm_print: use DEFINE_DYNAMIC_DEBUG_CLASSBITS for drm.debug

2022-03-01 Thread Jim Cromie
if CONFIG_DRM_USE_DYNAMIC_DEBUG=y, use new macro to create the sysfs bitmap to control drm.debug callsites. DEFINE_DYNAMIC_DEBUG_CLASSBITS( debug, __drm_debug, "p", "drm.debug - control summary", /* inline vector of _ddebug.class_id's to be controlled, max 14 vals */

[PATCH 11/13] drm_print: prefer bare printk KERN_DEBUG on generic fn

2022-03-01 Thread Jim Cromie
drm_print.c calls pr_debug() just once, from __drm_printfn_debug(), which is a generic/service fn. The callsite is compile-time enabled by DEBUG in both DYNAMIC_DEBUG=y/n builds. For dyndbg builds, reverting this callsite back to bare printk is correcting a few anti-features: 1- callsite is

[PATCH 12/13] drm_print: add _ddebug desc to drm_*dbg prototypes

2022-03-01 Thread Jim Cromie
Add a struct _ddebug ptr to drm_dbg() and drm_dev_dbg() protos. And upgrade the current use of _dynamic_func_call_no_desc(); ie drop the '_no_desc', since the factory macro's callees (these 2 functions) are now expecting the arg. This lets those functions act more like pr_debug(). It also means

[PATCH 10/13] drm_print: refine drm_debug_enabled for dyndbg+jump-label

2022-03-01 Thread Jim Cromie
In order to use dynamic-debug's jump-label optimization in drm-debug, its clarifying to refine drm_debug_enabled into 3 uses: 1. drm_debug_enabled - legacy, public 2. __drm_debug_enabled - optimized for dyndbg jump-label enablement. 3. _drm_debug_enabled - pr_debug instrumented, observable 1.

[PATCH 09/13] drm_print: wrap drm_*_dbg in dyndbg jumplabel

2022-03-01 Thread Jim Cromie
For CONFIG_DRM_USE_DYNAMIC_DEBUG=y, wrap drm_dbg() & drm_dev_dbg() in one of dyndbg's Factory macros: _dynamic_func_call_no_desc(). This makes the (~4000) callsites controllable, typically by class: # 0 is DRM_UT_CORE #> echo module drm class 0 +p > /proc/dynamic_debug/control =N: keeps

[PATCH 08/13] drm_print: interpose drm_*dbg with forwarding macros

2022-03-01 Thread Jim Cromie
drm_dev_dbg() & drm_dbg() sit below the categorized layer of the DRM debug API, and implement most of it. These are good places to insert dynamic-debug jump-label mechanics, allowing DRM to avoid the runtime cost of drm_debug_enabled(). Set up for this by changing the func names by adding '__'

[PATCH 07/13] drm_print: condense enum drm_debug_category

2022-03-01 Thread Jim Cromie
enum drm_debug_category has 10 "classes", explicitly initialized with 0x-bitmasks which could be simplified as BIT(X)s. But lets go further: use natural enumeration (int, starting at 0), and do the BIT(cat) in drm_debug_enabled(cat) at runtime. While this slightly pessimizes the bit-test, the

[PATCH 04/13] dyndbg: drop EXPORTed dynamic_debug_exec_queries

2022-03-01 Thread Jim Cromie
This exported fn is effectively obsoleted by Commit:HEAD~2, so remove it. The export was added here: commit a2d375eda771 ("dyndbg: refine export, rename to dynamic_debug_exec_queries()") commit 4c0d77828d4f ("dyndbg: export ddebug_exec_queries") Its intent was to allow drm.debug to use the

[PATCH 06/13] dyndbg: abstract dyndbg_site_is_printing

2022-03-01 Thread Jim Cromie
Hide flags test in a macro. no functional changes. Signed-off-by: Jim Cromie --- include/linux/dynamic_debug.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h index 664bb83778d2..106065244f73 100644 ---

[PATCH 05/13] dyndbg: improve change-info to have old and new

2022-03-01 Thread Jim Cromie
move site.flag update after the v4pr_info("change") message, and improve the message to print both old and new flag values. Heres new form: dyndbg: changed net/ipv4/tcp.c:2424 [tcp]tcp_recvmsg_locked pT -> _ Signed-off-by: Jim Cromie --- lib/dynamic_debug.c | 11 ++- 1 file changed,

[PATCH 03/13] dyndbg: add DEFINE_DYNAMIC_DEBUG_CLASSBITS macro and callbacks

2022-03-01 Thread Jim Cromie
DEFINE_DYNAMIC_DEBUG_CLASSBITS(fsname, var, bitmap_desc, classes..) allows users to create a drm.debug style (bitmap) sysfs interface, to control sets of pr_debug's according to their .class_id's This wraps existing "class" keyword and behavior: echo "module drm -p ; module drm class 0 +p ;

[PATCH 02/13] dyndbg: add class_id field and query support

2022-03-01 Thread Jim Cromie
DRM defines/uses 10 enum drm_debug_category's to create exclusive classes of debug messages. To support this directly in dynamic-debug, add the following: - struct _ddebug.class_id:4 - 4 bits is enough - define _DPRINTK_SITE_UNCLASSED 15 - see below and the query support: - struct

[PATCH 01/13] dyndbg: fix static_branch manipulation

2022-03-01 Thread Jim Cromie
In https://lore.kernel.org/lkml/20211209150910.ga23...@axis.com/ Vincent's patch commented on, and worked around, a bug toggling static_branch's, when a 2nd PRINTK-ish flag was added. The bug results in a premature static_branch_disable when the 1st of 2 flags was disabled. The cited commit

[PATCH 00/12] use dynamic-debug under drm.debug api

2022-03-01 Thread Jim Cromie
hi Jason, Greg, Daniel, DRM-everyone drm.debug api provides ~23 macros to issue 10 categories of debug messages, each enabled by a bit in /sys/module/drm/parameters/debug. drm_debug_enabled(category) tests these bits at runtime; while cheap individually, the costs accumulate. Daniel, I think

[PATCH] drm/amdgpu/discovery: add a comment about ip_discovery firmware

2022-03-01 Thread Alex Deucher
The firmware is optional and only used as a fallback when the IP discovery table is not available (e.g., during asic bring up). Once the chip goes into production, the table will always be available on the part itself. Unfortunately, there is no way to mark a firmware as optional.

Re: [PATCH] mm: split vm_normal_pages for LRU and non-LRU handling

2022-03-01 Thread Felix Kuehling
Am 2022-03-01 um 11:22 schrieb David Hildenbrand: if (PageReserved(page)) diff --git a/mm/migrate.c b/mm/migrate.c index c31d04b46a5e..17d049311b78 100644 --- a/mm/migrate.c +++ b/mm/migrate.c @@ -1614,7 +1614,7 @@ static int add_page_for_migration(struct mm_struct *mm, unsigned

RE: [PATCH] drm/amdgpu: Move CAP firmware loading to the beginning of PSP firmware list

2022-03-01 Thread Zhang, Bokun
[AMD Official Use Only] Reviewed-by: Bokun Zhang Thanks! -Original Message- From: Yifan Zha Sent: Tuesday, March 1, 2022 2:19 AM To: amd-gfx@lists.freedesktop.org; Zhang, Bokun Cc: Chen, Jingwen ; Liu, Monk ; Chen, Guchun ; Zha, YiFan(Even) Subject: [PATCH] drm/amdgpu: Move CAP

Re: [PATCH] mm: split vm_normal_pages for LRU and non-LRU handling

2022-03-01 Thread Felix Kuehling
Am 2022-03-01 um 03:03 schrieb David Hildenbrand: On 28.02.22 21:34, Alex Sierra wrote: DEVICE_COHERENT pages introduce a subtle distinction in the way "normal" pages can be used by various callers throughout the kernel. They behave like normal pages for purposes of mapping in CPU page

[PATCH 1/3] drm/amdgpu: remove unused gpu_info firmwares

2022-03-01 Thread Alex Deucher
These were leftover from bring up and are no longer necessary. The information is available via the IP discovery table. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 23 -- 1 file changed, 23 deletions(-) diff --git

[PATCH 3/3] drm/amdgpu/sdma5: drop unused cyan skillfish firmware

2022-03-01 Thread Alex Deucher
Leftover from bring up. Not used anymore. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c b/drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c index

[PATCH 2/3] drm/amdgpu/gfx10: drop unused cyan skillfish firmware

2022-03-01 Thread Alex Deucher
Leftover from bring up. Not used anymore. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 12 +--- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c index

Re: [PATCH v2 2/3] drm/amdgpu: convert code name to ip version for noretry set

2022-03-01 Thread Paul Menzel
Dear Yifan, Thank you for your patch. Am 01.03.22 um 16:01 schrieb Yifan Zhang: Use IP version rather than codename for noretry set. Why? Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-)

Re: [PATCH v2 1/3] drm/amdgpu: move amdgpu_gmc_noretry_set after ip_versions populated

2022-03-01 Thread Alex Deucher
Series is: Reviewed-by: Alex Deucher On Tue, Mar 1, 2022 at 10:02 AM Yifan Zhang wrote: > > otherwise adev->ip_versions is still empty when amdgpu_gmc_noretry_set > is called. > > Signed-off-by: Yifan Zhang > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- > 1 file changed, 1

[PATCH v2 3/3] drm/amdgpu: set noretry=1 for gc 10.3.6

2022-03-01 Thread Yifan Zhang
this patch to set noretry=1 for gc 10.3.6. Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c index fbc22b7b6315..7c2a9555b7cc 100644 ---

[PATCH v2 2/3] drm/amdgpu: convert code name to ip version for noretry set

2022-03-01 Thread Yifan Zhang
Use IP version rather than codename for noretry set. Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c

[PATCH v2 1/3] drm/amdgpu: move amdgpu_gmc_noretry_set after ip_versions populated

2022-03-01 Thread Yifan Zhang
otherwise adev->ip_versions is still empty when amdgpu_gmc_noretry_set is called. Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

撤回: [PATCH] drm/amdgpu: Move common initialization operations of each ras block to one function

2022-03-01 Thread Yang, Stanley
Yang, Stanley 将撤回邮件“[PATCH] drm/amdgpu: Move common initialization operations of each ras block to one function”。

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Jakob Koschel
> On 1. Mar 2022, at 01:41, Linus Torvalds > wrote: > > On Mon, Feb 28, 2022 at 1:47 PM Jakob Koschel wrote: >> >> The goal of this is to get compiler warnings right? This would indeed be >> great. > > Yes, so I don't mind having a one-time patch that has been gathered > using some

Re: [PATCH 3/3] drm/amdgpu: enable gfxoff routine for GC 10.3.7

2022-03-01 Thread Alex Deucher
Series is: Reviewed-by: Alex Deucher On Tue, Mar 1, 2022 at 7:30 AM Prike Liang wrote: > > Enable gfxoff routine for GC 10.3.7. > > Signed-off-by: Prike Liang > --- > drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 3 +++ > drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c | 1 + > 2 files

Re: [PATCH] drm/amdgpu: enable gfx clock gating control for GC 10.3.7

2022-03-01 Thread Deucher, Alexander
[Public] Reviewed-by: Alex Deucher From: Liang, Prike Sent: Monday, February 28, 2022 10:01 PM To: amd-gfx@lists.freedesktop.org Cc: Deucher, Alexander ; Huang, Ray ; Liang, Prike Subject: [PATCH] drm/amdgpu: enable gfx clock gating control for GC 10.3.7

回复: [PATCH] drm/amdgpu: Move common initialization operations of each ras block to one function

2022-03-01 Thread Yang, Stanley
[AMD Official Use Only] Hi yipe, One suggestion for this patch, please check my comment. Regards, Stanley > -邮件原件- > 发件人: amd-gfx 代表 yipechai > 发送时间: Tuesday, March 1, 2022 5:46 PM > 收件人: amd-gfx@lists.freedesktop.org > 抄送: Zhou1, Tao ; Zhang, Hawking > ; Clements, John ; > Chai,

[PATCH Review 1/1] drm/amdgpu: support send bad channel info to smu

2022-03-01 Thread Stanley . Yang
Message SMU bad channel information bitmap to update OOB table Change-Id: I49a79af64d5263c28db059ecb8b8405a471431b4 Signed-off-by: Stanley.Yang --- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 7 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_ras.h | 3 ++

Re: [PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6

2022-03-01 Thread Christian König
Am 01.03.22 um 14:05 schrieb Yifan Zhang: From: Aaron Liu By default, set noretry=1 for kfd exception test. Signed-off-by: Aaron Liu Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 7 +++ 1 file changed, 7 insertions(+) diff --git

[PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6

2022-03-01 Thread Yifan Zhang
From: Aaron Liu By default, set noretry=1 for kfd exception test. Signed-off-by: Aaron Liu Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c

[PATCH 1/2] drm/amdgpu: move amdgpu_gmc_noretry_set after ip_versions populated

2022-03-01 Thread Yifan Zhang
otherwise adev->ip_versions is still empty when amdgpu_gmc_noretry_set is called. Signed-off-by: Yifan Zhang --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

[PATCH 3/3] drm/amdgpu: enable gfxoff routine for GC 10.3.7

2022-03-01 Thread Prike Liang
Enable gfxoff routine for GC 10.3.7. Signed-off-by: Prike Liang --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 3 +++ drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c | 1 + 2 files changed, 4 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c

[PATCH 2/3] drm/amdgpu: enable gfx power gating for GC 10.3.7

2022-03-01 Thread Prike Liang
Enable gfx power gating for GC 10.3.7. Signed-off-by: Prike Liang --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 2 ++ drivers/gpu/drm/amd/amdgpu/nv.c| 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c

[PATCH 1/3] drm/amdgpu/nv: enable clock gating for GC 10.3.7 subblock

2022-03-01 Thread Prike Liang
This will enable the following block clock gating. - MC - SDMA - HDP - ATHUB - IH - VCN/JPEG Signed-off-by: Prike Liang --- drivers/gpu/drm/amd/amdgpu/nv.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH] drm/amdgpu: Move common initialization operations of each ras block to one function

2022-03-01 Thread yipechai
Define amdgpu_ras_sw_init function to initialize all ras blocks. Signed-off-by: yipechai --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 + drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c| 2 - drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c| 143 -

RE: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread David Laight
From: Linus Torvalds > Sent: 28 February 2022 19:56 > On Mon, Feb 28, 2022 at 4:19 AM Christian König > wrote: > > > > I don't think that using the extra variable makes the code in any way > > more reliable or easier to read. > > So I think the next step is to do the attached patch (which

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Mon, Feb 28, 2022 at 4:38 PM Segher Boessenkool wrote: > > In C its scope is the rest of the declaration and the entire loop, not > anything after it. This was the same in C++98 already, btw (but in > pre-standard versions of C++ things were like you remember, yes, and it > was painful).

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Segher Boessenkool
On Mon, Feb 28, 2022 at 05:28:58PM -0500, James Bottomley wrote: > On Mon, 2022-02-28 at 23:59 +0200, Mike Rapoport wrote: > > > > On February 28, 2022 10:42:53 PM GMT+02:00, James Bottomley < > > james.bottom...@hansenpartnership.com> wrote: > > > On Mon, 2022-02-28 at 21:07 +0100, Christian

RE: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread David Laight
From: Matthew Wilcox > Sent: 28 February 2022 20:16 > > On Mon, Feb 28, 2022 at 12:10:24PM -0800, Linus Torvalds wrote: > > We can do > > > > typeof(pos) pos > > > > in the 'for ()' loop, and never use __iter at all. > > > > That means that inside the for-loop, we use a _different_ 'pos'

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Mon, Feb 28, 2022 at 3:26 PM Matthew Wilcox wrote: > > #define ___PASTE(a, b) a##b > #define __PASTE(a, b) ___PASTE(a, b) > #define _min(a, b, u) ({ \ Yeah, except that's ugly beyond belief, plus it's literally not what we do in the kernel. Really. The "-Wshadow doesn't work on the

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Mon, Feb 28, 2022 at 1:47 PM Jakob Koschel wrote: > > The goal of this is to get compiler warnings right? This would indeed be > great. Yes, so I don't mind having a one-time patch that has been gathered using some automated checker tool, but I don't think that works from a long-term

Re: [PATCH] mm: split vm_normal_pages for LRU and non-LRU handling

2022-03-01 Thread David Hildenbrand
On 28.02.22 21:34, Alex Sierra wrote: > DEVICE_COHERENT pages introduce a subtle distinction in the way > "normal" pages can be used by various callers throughout the kernel. > They behave like normal pages for purposes of mapping in CPU page > tables, and for COW. But they do not support LRU

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Matthew Wilcox
On Mon, Feb 28, 2022 at 12:37:15PM -0800, Linus Torvalds wrote: > On Mon, Feb 28, 2022 at 12:16 PM Matthew Wilcox wrote: > > > > Then we can never use -Wshadow ;-( I'd love to be able to turn it on; > > it catches real bugs. > > Oh, we already can never use -Wshadow regardless of things like

Re: [PATCH 2/6] treewide: remove using list iterator after loop body as a ptr

2022-03-01 Thread Linus Torvalds
On Mon, Feb 28, 2022 at 4:45 PM Linus Torvalds wrote: > > Yeah, except that's ugly beyond belief, plus it's literally not what > we do in the kernel. (Of course, I probably shouldn't have used 'min()' as an example, because that is actually one of the few places where we do exactly that, using

Re: [PATCH v5 3/7] PCI: Drop the `is_thunderbolt` attribute from PCI core

2022-03-01 Thread Mika Westerberg
Hi, On Mon, Feb 28, 2022 at 10:36:59PM +, Limonciello, Mario wrote: > [AMD Official Use Only] > > > -Original Message- > > From: Lukas Wunner > > Sent: Monday, February 28, 2022 16:33 > > To: Bjorn Helgaas > > Cc: Limonciello, Mario ; Mika Westerberg > > ; Michael Jamet > > ; open