From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932446AbcFNUsI (ORCPT ); Tue, 14 Jun 2016 16:48:08 -0400 Received: from shadbolt.e.decadent.org.uk ([88.96.1.126]:52716 "EHLO shadbolt.e.decadent.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753078AbcFNUsE (ORCPT ); Tue, 14 Jun 2016 16:48:04 -0400 Date: Tue, 14 Jun 2016 21:48:03 +0100 From: Ben Hutchings To: Sasha Levin Cc: linux-kernel@vger.kernel.org Message-ID: <20160614204803.GV7555@decadent.org.uk> References: <20160614204437.GS7555@decadent.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="c/UxJciryulPFo89" Content-Disposition: inline In-Reply-To: <20160614204437.GS7555@decadent.org.uk> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: ben@decadent.org.uk Subject: [PATCH 3/7] liblockdep: Define the ARRAY_SIZE() macro X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on shadbolt.decadent.org.uk) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --c/UxJciryulPFo89 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable lockdep.c now uses ARRAY_SIZE(). Fixes: 75dd602a5198 ("lockdep: Fix lock_chain::base size") Signed-off-by: Ben Hutchings --- tools/lib/lockdep/uinclude/linux/kernel.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/lib/lockdep/uinclude/linux/kernel.h b/tools/lib/lockdep/= uinclude/linux/kernel.h index 276c7a8b2ed1..da87bd9ad2c1 100644 --- a/tools/lib/lockdep/uinclude/linux/kernel.h +++ b/tools/lib/lockdep/uinclude/linux/kernel.h @@ -7,6 +7,8 @@ #include #include =20 +#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) + #ifndef container_of #define container_of(ptr, type, member) ({ \ const typeof(((type *)0)->member) * __mptr =3D (ptr); \ --c/UxJciryulPFo89 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIVAwUBV2Btgue/yOyVhhEJAQowcRAAwQthqCCKioaTRXp6bom8/h77HB5Zgf5p QRMIFJCzN12D79A1HaaZQ1holLEr+1/3pYKfwJ0id5ojXu2ao5LGNzqOG7vjfT3i KtXuSe96Tt9pQ9Mu4H5ZdBnl5C8DbgY+jGI+lIWsXn1SiOYz4mzR/APxVYn8R0Ef zyNQzivwWJMbgC5z+68u8V8b6tuYuLO1qZXkghhGzrqDiGbndbYHW4r0sxRK4YeN aTWDIBc81Bv+D/Y2UG8iz/7ihOWSkdMt00Neb5d21qxEDYCR0g1obA9kwVR9RooT yFx1tVYEH077YjG1yrySbpzEDq8GILimmLPG2J7oiXwICaug/vtRjtNOdsIaR2rt g3ON6C4yrjUCs5jhW+POl3zzdtbE9DxQQ+PLgBZOife68R7D2MmxTD7GwZ3KzCzd XCwq+eN2UhK0Ea60G+KbGW+sW0CSOmCLYV/WRkkwFcxEsWMUy9ggzCbjPuUfVlZ7 FzWRMHUK7Q4hnH3i0QVt0PGN/JYwlZTdBFAbHhZeOmdBRU8NisDfknj1ItX1oMUE eyTW8cy/M8ZrjQRNBZ3V1r3qWmuxOiQVbcyLti8uH4RN9n08uS4KHQSaieROJ+RX 3EJSd9w1nL65RAFCJZqF8BZayas/B8GEnDjafMybtsVc3liNVNvNh/oa7cS9Ge46 8BiQRHmnVkI= =5y5Z -----END PGP SIGNATURE----- --c/UxJciryulPFo89--