Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753847AbdLDKg3 (ORCPT ); Mon, 4 Dec 2017 05:36:29 -0500 Received: from mga07.intel.com ([134.134.136.100]:64905 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753496AbdLDKfJ (ORCPT ); Mon, 4 Dec 2017 05:35:09 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,358,1508828400"; d="scan'208";a="181050747" Message-ID: <1512383705.4394.18.camel@linux.intel.com> Subject: Re: [PATCH] drm/i915: Mark expected switch fall-throughs From: Joonas Lahtinen To: "Gustavo A. R. Silva" , Jani Nikula , Rodrigo Vivi , David Airlie Cc: intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Kees Cook Date: Mon, 04 Dec 2017 12:35:05 +0200 In-Reply-To: <20171127221701.GA15983@embeddedor.com> References: <20171127221701.GA15983@embeddedor.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.26.2 (3.26.2-1.fc27) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 485 Lines: 16 On Mon, 2017-11-27 at 16:17 -0600, Gustavo A. R. Silva wrote: > In preparation to enabling -Wimplicit-fallthrough, mark switch cases > where we are expecting to fall through. I have to say I'm totally not sold on regexps matching comment contents. Was something more explicit ever considered? Like: #define FALLTHROUGH __attribute__((fallthrough)); With the appropriate version checks, of course. Regards, Joonas -- Joonas Lahtinen Open Source Technology Center Intel Corporation