Skip to content

lib, stackdepot: check stackdepot handle before accessing slabs

Imran Khan dri-devel intel-gfx linux-mm lkml 5 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 1 replyIn review 1 of 3 applied
  2. v2 posting 2/23 patches 1 replySuperseded
  3. v1 posting 2/23 patches 0 repliesSuperseded 1 of 3 applied
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v2 RFC posting 1/22 patches5 repliesSuperseded
v1 RFC posting 1/22 patches5 repliesSuperseded

Changes in v3 from the cover letter

- Fixed build error [1], due to missing EXPORT_SYMBOL_GPL in patch-3

[1] https://patchwork.freedesktop.org/series/94696/#rev2

Patches in v3 1 of 3 applied

#Subject and filesSizeRepliesApplied
1/3lib, stackdepot: check stackdepot handle before accessing slabs.lib/stackdepot.c+3 -00 replies
2/3lib, stackdepot: Add helper to print stack entries.include/linux/stackdepot.h lib/stackdepot.c mm/kasan/report.c +1 more+27 -210 replies
3/3lib, stackdepot: Add helper to print stack entries into buffer.drivers/gpu/drm/drm_dp_mst_topology.c drivers/gpu/drm/drm_mm.c drivers/gpu/drm/i915/i915_vma.c +4 more+37 -310 repliesApplied

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchVlastimil BabkaAlexander Potapenko
1/3A-b
2/3A-b R-b
3/3A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH RESEND v3 0/3] lib, stackdepot: check stackdepot handle before accessing slabs

Changes in v3:
- Fixed build error [1], due to missing EXPORT_SYMBOL_GPL in patch-3

[1] https://patchwork.freedesktop.org/series/94696/#rev2

Changes in v2:
- Fixed compilation error [1] due to typo in patch-3 (stack_depot_print used in place of stack_depot_snprint)
This compilation error appears with CONFIG_DRM_I915_DEBUG_RUNTIME_PM=y and this was missed by my test config (x86_64_defconfig)

[1] https://patchwork.freedesktop.org/series/94696/

Original cover letter
------------------------------------------
This patch series consolidates the changes submitted and reviewed at [1] and [2].
The patches at [1] and [2] were submitted separarely, but they have some inter dependency (later patches were created on top of earlier ones). As both sets are still under review, I have put them in a single change set here, so that it can be reviewed/included together and also to avoid automation build failures where git am fails because of absent parent.

I have included Acked-by (from Vlastimil) and Reviewed-by (from Alexander) tags obtained so far for these changes and have also addressed last review comment from Vlastimil [3].

To summarize, the changes in this set are as follows:

PATCH-1: Checks validity of a stackdepot handle before proceeding to access stackdepot slab/objects.

PATCH-2: Adds a helper in stackdepot, to allow users to print stack entries just by specifying the stackdepot handle. It also changes such users to use this new interface.

PATCH-3: Adds a helper in stackdepot, to allow users to print stack entries into buffers just by specifying the stackdepot handle and destination buffer. It also changes such users to use this new interface.

[1] https://lore.kernel.org/lkml/[email protected]/
[2] https://lore.kernel.org/lkml/[email protected]/
[3] https://lore.kernel.org/lkml/[email protected]/

Imran Khan (3):
lib, stackdepot: check stackdepot handle before accessing slabs. lib, stackdepot: Add helper to print stack entries. lib, stackdepot: Add helper to print stack entries into buffer.

 drivers/gpu/drm/drm_dp_mst_topology.c   |  5 +--
 drivers/gpu/drm/drm_mm.c                |  5 +--
 drivers/gpu/drm/i915/i915_vma.c         |  5 +--
 drivers/gpu/drm/i915/intel_runtime_pm.c | 20 +++--------
 include/linux/stackdepot.h              |  5 +++
 lib/stackdepot.c                        | 46 +++++++++++++++++++++++++
 mm/kasan/report.c                       | 15 ++------
 mm/page_owner.c                         | 18 +++-------
 8 files changed, 67 insertions(+), 52 deletions(-)

base-commit: 70ced02f322fd5bde59e805e77b19c811950d165

Signature · 1 line
2.30.2