[PATCH v3 2/4] drm/amdkfd: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-27 Thread Kefeng Wang
Use the helpers to simplify code. Cc: Felix Kuehling Cc: Alex Deucher Cc: "Christian König" Cc: "Pan, Xinhui" Cc: David Airlie Cc: Daniel Vetter Reviewed-by: David Hildenbrand Reviewed-by: Felix Kuehling Signed-off-by: Kefeng Wang --- drivers/gpu/drm/amd/amdkfd/kf

[PATCH v3 1/4] mm: factor out VMA stack and heap checks

2023-07-27 Thread Kefeng Wang
Factor out VMA stack and heap checks and name them vma_is_initial_stack() and vma_is_initial_heap() for general use. Cc: Christian Göttsche Cc: David Hildenbrand Reviewed-by: David Hildenbrand Signed-off-by: Kefeng Wang --- fs/proc/task_mmu.c | 24 fs/proc

[PATCH v3 3/4] selinux: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-27 Thread Kefeng Wang
Use the helpers to simplify code. Cc: Paul Moore Cc: Stephen Smalley Cc: Eric Paris Acked-by: Paul Moore Reviewed-by: David Hildenbrand Signed-off-by: Kefeng Wang --- security/selinux/hooks.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/security/selinux

[PATCH v3 4/4] perf/core: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-27 Thread Kefeng Wang
Use the helpers to simplify code, also kill unneeded goto cpy_name. Cc: Peter Zijlstra Cc: Arnaldo Carvalho de Melo Reviewed-by: David Hildenbrand Signed-off-by: Kefeng Wang --- kernel/events/core.c | 33 +++-- 1 file changed, 11 insertions(+), 22 deletions

[PATCH v3 0/4] mm: convert to vma_is_initial_heap/stack()

2023-07-27 Thread Kefeng Wang
Add vma_is_initial_stack() and vma_is_initial_heap() helper and use them to simplify code. v2: - add comment for heap helper and remove one more goto cpy_name, per David Hildenbrand - add RB v2: - address comments per David Hildenbrand and Christian Göttsche - fix selinux build Kefeng Wang (4

Re: [PATCH v2 3/4] selinux: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-20 Thread Kefeng Wang
On 2023/7/19 23:25, Paul Moore wrote: On Wed, Jul 19, 2023 at 6:23 AM Kefeng Wang wrote: On 2023/7/19 17:02, Christian Göttsche wrote: On Wed, 19 Jul 2023 at 09:40, Kefeng Wang wrote: Use the helpers to simplify code. Cc: Paul Moore Cc: Stephen Smalley Cc: Eric Paris Acked-by: Paul

Re: [PATCH v2 4/4] perf/core: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-19 Thread Kefeng Wang
On 2023/7/19 17:29, Peter Zijlstra wrote: On Wed, Jul 19, 2023 at 03:51:14PM +0800, Kefeng Wang wrote: Use the helpers to simplify code, also kill unneeded goto cpy_name. Grrr.. why am I only getting 4/4 ? I'm going to write a bot that auto NAKs all partial series :/ Sorry, I should add

Re: [PATCH v2 3/4] selinux: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-19 Thread Kefeng Wang
On 2023/7/19 17:02, Christian Göttsche wrote: On Wed, 19 Jul 2023 at 09:40, Kefeng Wang wrote: Use the helpers to simplify code. Cc: Paul Moore Cc: Stephen Smalley Cc: Eric Paris Acked-by: Paul Moore Signed-off-by: Kefeng Wang --- security/selinux/hooks.c | 7 ++- 1 file

[PATCH v2 3/4] selinux: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-19 Thread Kefeng Wang
Use the helpers to simplify code. Cc: Paul Moore Cc: Stephen Smalley Cc: Eric Paris Acked-by: Paul Moore Signed-off-by: Kefeng Wang --- security/selinux/hooks.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c

[PATCH v2 4/4] perf/core: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-19 Thread Kefeng Wang
Use the helpers to simplify code, also kill unneeded goto cpy_name. Cc: Peter Zijlstra Cc: Arnaldo Carvalho de Melo Signed-off-by: Kefeng Wang --- kernel/events/core.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/kernel/events/core.c b/kernel

[PATCH v2 2/4] drm/amdkfd: use vma_is_initial_stack() and vma_is_initial_heap()

2023-07-19 Thread Kefeng Wang
Use the helpers to simplify code. Cc: Felix Kuehling Cc: Alex Deucher Cc: "Christian König" Cc: "Pan, Xinhui" Cc: David Airlie Cc: Daniel Vetter Signed-off-by: Kefeng Wang --- drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 5 + 1 file changed, 1 insertion(+), 4 dele

[PATCH v2 0/4] mm: convert to vma_is_initial_heap/stack()

2023-07-19 Thread Kefeng Wang
Add vma_is_initial_stack() and vma_is_initial_heap() helper and use them to simplify code. v2: - address comments per David Hildenbrand and Christian Göttsche - fix selinux build Kefeng Wang (4): mm: factor out VMA stack and heap checks drm/amdkfd: use vma_is_initial_stack

[PATCH v2 1/4] mm: factor out VMA stack and heap checks

2023-07-19 Thread Kefeng Wang
Factor out VMA stack and heap checks and name them vma_is_initial_stack() and vma_is_initial_heap() for general use. Cc: Christian G??ttsche Cc: David Hildenbrand Signed-off-by: Kefeng Wang --- fs/proc/task_mmu.c | 24 fs/proc/task_nommu.c | 15

Re: [PATCH 2/5] mm: use vma_is_stack() and vma_is_heap()

2023-07-17 Thread Kefeng Wang
On 2023/7/17 18:25, David Hildenbrand wrote: On 12.07.23 16:38, Kefeng Wang wrote: Use the helpers to simplify code. Signed-off-by: Kefeng Wang ---   fs/proc/task_mmu.c   | 24   fs/proc/task_nommu.c | 15 +--   2 files changed, 5 insertions(+), 34

[PATCH 3/5] drm/amdkfd: use vma_is_stack() and vma_is_heap()

2023-07-12 Thread Kefeng Wang
Use the helpers to simplify code. Signed-off-by: Kefeng Wang --- drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_svm.c b/drivers/gpu/drm/amd/amdkfd/kfd_svm.c index 479c4f66afa7..19ce68a7e1a8 100644

[PATCH 2/5] mm: use vma_is_stack() and vma_is_heap()

2023-07-12 Thread Kefeng Wang
Use the helpers to simplify code. Signed-off-by: Kefeng Wang --- fs/proc/task_mmu.c | 24 fs/proc/task_nommu.c | 15 +-- 2 files changed, 5 insertions(+), 34 deletions(-) diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c index cfab855fe7e9

[PATCH 4/5] selinux: use vma_is_stack() and vma_is_heap()

2023-07-12 Thread Kefeng Wang
Use the helpers to simplify code. Signed-off-by: Kefeng Wang --- security/selinux/hooks.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 4e46cf3d67b6..289ef2d6a427 100644 --- a/security/selinux/hooks.c +++ b

[PATCH 1/5] mm: introduce vma_is_stack() and vma_is_heap()

2023-07-12 Thread Kefeng Wang
Introduce the two helpers for general use. Signed-off-by: Kefeng Wang --- include/linux/mm.h | 12 1 file changed, 12 insertions(+) diff --git a/include/linux/mm.h b/include/linux/mm.h index 1462cf15badf..0bbeb31ac750 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h

[PATCH 5/5] perf/core: use vma_is_stack() and vma_is_heap()

2023-07-12 Thread Kefeng Wang
Use the helpers to simplify code, also kill unneeded goto cpy_name. Signed-off-by: Kefeng Wang --- kernel/events/core.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/kernel/events/core.c b/kernel/events/core.c index 78ae7b6f90fd..cb271f449b81 100644

[PATCH 0/5] mm: convert to vma_is_heap/stack()

2023-07-12 Thread Kefeng Wang
Add vma_is_stack() and vma_is_heap() helper and use them to simplify code. Kefeng Wang (5): mm: introduce vma_is_stack() and vma_is_heap() mm: use vma_is_stack() and vma_is_heap() drm/amdkfd: use vma_is_stack() and vma_is_heap() selinux: use vma_is_stack() and vma_is_heap() perf/core

[PATCH next 04/25] drm/exynos: Use dev_get_drvdata()

2019-04-24 Thread Kefeng Wang
Using dev_get_drvdata directly. Cc: Inki Dae Cc: Joonyoung Shim Cc: Seung-Woo Kim Cc: Kyungmin Park Cc: David Airlie Cc: Daniel Vetter Cc: dri-devel@lists.freedesktop.org Cc: linux-samsung-...@vger.kernel.org Signed-off-by: Kefeng Wang --- drivers/gpu/drm/exynos/exynos_drm_fimc.c | 8

[PATCH next 05/25] drm/msm: Use dev_get_drvdata()

2019-04-24 Thread Kefeng Wang
Using dev_get_drvdata directly. Cc: Rob Clark Cc: Sean Paul Cc: David Airlie Cc: Daniel Vetter Cc: dri-devel@lists.freedesktop.org Cc: freedr...@lists.freedesktop.org Signed-off-by: Kefeng Wang --- drivers/gpu/drm/msm/adreno/adreno_device.c | 6 ++ drivers/gpu/drm/msm/disp/dpu1

[PATCH next 06/25] drm/omap: Use dev_get_drvdata()

2019-04-24 Thread Kefeng Wang
Using dev_get_drvdata directly. Cc: Tomi Valkeinen Cc: David Airlie Cc: Daniel Vetter Cc: dri-devel@lists.freedesktop.org Signed-off-by: Kefeng Wang --- .../gpu/drm/omapdrm/displays/panel-dsi-cm.c| 18 ++ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git

[PATCH next 25/25] video: fbdev: Use dev_get_drvdata()

2019-04-24 Thread Kefeng Wang
Using dev_get_drvdata directly. Cc: Wan ZongShun Cc: Kukjin Kim Cc: Bartlomiej Zolnierkiewicz Cc: Krzysztof Kozlowski Cc: Michal Januszewski Cc: dri-devel@lists.freedesktop.org Cc: linux-fb...@vger.kernel.org Signed-off-by: Kefeng Wang --- drivers/video/fbdev/nuc900fb.c | 2 +- drivers