Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1422346

Re: [PATCH 2/7] liblockdep: Reduce MAX_LOCK_DEPTH to avoid overflowing lock_chain::depth

From Peter Zijlstra <peterz@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH 2/7] liblockdep: Reduce MAX_LOCK_DEPTH to avoid overflowing lock_chain::depth
Date 2016-06-14 23:20 +0200
Message-ID <rK3UB-1OB-13@gated-at.bofh.it> (permalink)
References <rK3rz-1nX-3@gated-at.bofh.it> <rK3rA-1nX-33@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Jun 14, 2016 at 09:47:53PM +0100, Ben Hutchings wrote:

> Even before that commit, which reduced lock_chain::depth from 8 bits
> to 6, MAX_LOCK_DEPTH was too large.

> -#define MAX_LOCK_DEPTH 2000UL
> +#define MAX_LOCK_DEPTH 63UL

So per that commit; there still is a 4 byte hole we could fill. So if a
bigger number is desired here, there is room to make that happen.

Good to see those assertions did their job, albeit somewhat belated.

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/7] Fixes for liblockdep Ben Hutchings <ben@decadent.org.uk> - 2016-06-14 22:50 +0200
  [PATCH 3/7] liblockdep: Define the ARRAY_SIZE() macro Ben Hutchings <ben@decadent.org.uk> - 2016-06-14 22:50 +0200
  [PATCH 5/7] liblockdep: Fix 'unused value' warnings Ben Hutchings <ben@decadent.org.uk> - 2016-06-14 22:50 +0200
  [PATCH 4/7] liblockdep: Enable -Wall by default Ben Hutchings <ben@decadent.org.uk> - 2016-06-14 22:50 +0200
  [PATCH 1/7] liblockdep: Fix undefined symbol prandom_u32 Ben Hutchings <ben@decadent.org.uk> - 2016-06-14 22:50 +0200
    Re: [PATCH 1/7] liblockdep: Fix undefined symbol prandom_u32 Sasha Levin <sasha.levin@oracle.com> - 2016-06-14 23:40 +0200
  [PATCH 2/7] liblockdep: Reduce MAX_LOCK_DEPTH to avoid overflowing  lock_chain::depth Ben Hutchings <ben@decadent.org.uk> - 2016-06-14 22:50 +0200
    Re: [PATCH 2/7] liblockdep: Reduce MAX_LOCK_DEPTH to avoid  overflowing lock_chain::depth Peter Zijlstra <peterz@infradead.org> - 2016-06-14 23:20 +0200
  Re: [PATCH 0/7] Fixes for liblockdep Sasha Levin <sasha.levin@oracle.com> - 2016-06-14 23:40 +0200

csiph-web