lkml.org 
[lkml]   [2019]   [Apr]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC patch 28/41] dma/debug: Simplify stracktrace retrieval
On Wed, Apr 10, 2019 at 12:28:22PM +0200, Thomas Gleixner wrote:
> Replace the indirection through struct stack_trace with an invocation of
> the storage array based interface.
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> Cc: iommu@lists.linux-foundation.org
> Cc: Robin Murphy <robin.murphy@arm.com>
> Cc: Christoph Hellwig <hch@lst.de>
> Cc: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
> kernel/dma/debug.c | 13 +++++--------
> 1 file changed, 5 insertions(+), 8 deletions(-)
>
> --- a/kernel/dma/debug.c
> +++ b/kernel/dma/debug.c
> @@ -89,8 +89,8 @@ struct dma_debug_entry {
> int sg_mapped_ents;
> enum map_err_types map_err_type;
> #ifdef CONFIG_STACKTRACE
> - struct stack_trace stacktrace;
> - unsigned long st_entries[DMA_DEBUG_STACKTRACE_ENTRIES];
> + unsigned int st_len;
> + unsigned long st_entries[DMA_DEBUG_STACKTRACE_ENTRIES];

nit: st_entries isn't very readable. Thanks to the magic of compilers,
the characters are free, so why not call them "stacktrace_entries" and
"stacktrace_len".

--
Josh

\
 
 \ /
  Last update: 2019-04-11 05:03    [W:0.172 / U:8.376 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site