Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp2759494ybi; Sun, 28 Jul 2019 17:13:44 -0700 (PDT) X-Google-Smtp-Source: APXvYqxLCMHM+R4JzTnp8405GneDsk1yXxahbjYHWHJNAzulJRnIxgK2LfCYIqOeb4Ybc1AR5DYI X-Received: by 2002:a63:61cd:: with SMTP id v196mr20868267pgb.210.1564359224191; Sun, 28 Jul 2019 17:13:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564359224; cv=none; d=google.com; s=arc-20160816; b=ijbHhKTO1/Dad3u9paQcX4UlUNIWQJgD8wLvZWv3NGuFadPEOclbc/1cCxOZ2hT0Jx 3Ef0o/NfUpGk0eEEIq7LtvFX2PczBbOjplFWDL8XZsg/ljsTcC519l4/VTTGeTKuK7Xk 0fYBl3GRce1HM3s8UZ8hJ/w6eaWy0MqYgXR00NBgtruDVIPHICTc6xHfIC4Yv9XZYvpM sqeHSyxwSgwBm2OJLZBW/1Fn5bZPAOMJVoRcId5UVX1jPzpc6TZba73mHfAlRUdGPig6 g/B00ZsxhCIFNLWXALJdg2ROjkwXEKBXHdTIxoHvzLW0CGbVdg/9WS0jyXOIOS2ehCjO xvBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=VA4nO4VREXkp8GYoBYLdJmNPFBFhMx5Fwe9xzhsD62A=; b=DgWEi9kO74/pn653KtGIIwCEa2MSjZUZdHm9Dts6GhTNv/KPGta4KeuYgrref/fQJ2 vyZH6MXm6rjZjZEHY2XiOhqriOqjaVe/PLVEmmNuWLmXZT9WQ0WnT23dEhJOpLbdp33K LT9y9zp8WjkhadmJ3R/STTTM6NASK1YzozpCWGr7wlriGjHdA8d+itv+IUSoTjRzl24D OMK5bChgWPSezTPnB2cEcTN8S2wW7PCQ9/zGidm/qJnA5oPk9l4LTqnE2Cu6jqTDN/1x qOrWR+7vgZk/YjqgAkJmV5EU9ge8Yvm03ZZttstGddJdoI3YAlw8OrvVk0LIAhjzVta8 c6Qw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 64si23188727plk.36.2019.07.28.17.13.28; Sun, 28 Jul 2019 17:13:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726314AbfG2AL1 (ORCPT + 99 others); Sun, 28 Jul 2019 20:11:27 -0400 Received: from mail-wr1-f68.google.com ([209.85.221.68]:44651 "EHLO mail-wr1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726247AbfG2AL1 (ORCPT ); Sun, 28 Jul 2019 20:11:27 -0400 Received: by mail-wr1-f68.google.com with SMTP id p17so59827223wrf.11 for ; Sun, 28 Jul 2019 17:11:26 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=VA4nO4VREXkp8GYoBYLdJmNPFBFhMx5Fwe9xzhsD62A=; b=PhhB9+drCP9XxGFoqQN9KxudjfF79AIV8FJxeV6nmajYnCbC6kQy/02yDrvBQZU/Mt e/li4iA9jG5mnOgMHG8CvTPqsiRMniCrWVFZZQpbJXsp94zG4/RHQi0jiEZjHKdaa0p3 7+Fo5DjwyZpo2B44YvnbKhKFJQhz4v7dBjRaQU6ZUe9Xs3fuQH9z70DOS0Jb7G2Bum/y rDXBy3Cy/4VVqxEDcreh30M7B280rPwEnK9nb5qSGN2wzOTmwh5DH+OaaSo14dATxyPv UDBjehBwlaMPT1Z02sEmiovnEuX3RpWdbBfDE+RHCNjspFfN9vNnPJ/G4yq9K2p0vtH6 rSgg== X-Gm-Message-State: APjAAAV6UlfpdGO5Fp+jz4gxxl4Pst+wBfXikt8HA5G1+sUy1LBWbA29 QD8/C15j8rc/6PBshpBAVayKgI/Rj2M+JQ== X-Received: by 2002:adf:eec4:: with SMTP id a4mr108237314wrp.85.1564359085228; Sun, 28 Jul 2019 17:11:25 -0700 (PDT) Received: from mcroce-redhat.homenet.telecomitalia.it (host221-208-dynamic.27-79-r.retail.telecomitalia.it. [79.27.208.221]) by smtp.gmail.com with ESMTPSA id o20sm154140692wrh.8.2019.07.28.17.11.24 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Sun, 28 Jul 2019 17:11:24 -0700 (PDT) From: Matteo Croce To: linux-kernel@vger.kernel.org Cc: Thomas Gleixner , Jason Cooper , Marc Zyngier Subject: [PATCH] irqchip/gic-v3: mark expected switch fall-through Date: Mon, 29 Jul 2019 02:11:19 +0200 Message-Id: <20190729001119.2478-1-mcroce@redhat.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Mark switch cases where we are expecting to fall through, fixes the following warnings: drivers/irqchip/irq-gic-v3.c: In function ‘gic_cpu_sys_reg_init’: ./arch/arm64/include/asm/sysreg.h:853:2: warning: this statement may fall through [-Wimplicit-fallthrough=] asm volatile(__msr_s(r, "%x0") : : "rZ" (__val)); \ ^~~ ./arch/arm64/include/asm/arch_gicv3.h:20:29: note: in expansion of macro ‘write_sysreg_s’ #define write_gicreg(v, r) write_sysreg_s(v, SYS_ ## r) ^~~~~~~~~~~~~~ drivers/irqchip/irq-gic-v3.c:773:4: note: in expansion of macro ‘write_gicreg’ write_gicreg(0, ICC_AP0R2_EL1); ^~~~~~~~~~~~ drivers/irqchip/irq-gic-v3.c:774:3: note: here case 6: ^~~~ drivers/irqchip/irq-gic-v3.c:788:3: note: in expansion of macro ‘write_gicreg’ write_gicreg(0, ICC_AP1R2_EL1); ^~~~~~~~~~~~ CC net/ipv4/af_inet.o drivers/irqchip/irq-gic-v3.c:789:2: note: here case 6: ^~~~ ./arch/arm64/include/asm/arch_gicv3.h:20:29: note: in expansion of macro ‘write_sysreg_s’ #define write_gicreg(v, r) write_sysreg_s(v, SYS_ ## r) ^~~~~~~~~~~~~~ drivers/irqchip/irq-gic-v3.c:790:3: note: in expansion of macro ‘write_gicreg’ write_gicreg(0, ICC_AP1R1_EL1); ^~~~~~~~~~~~ drivers/irqchip/irq-gic-v3.c:791:2: note: here case 5: ^~~~ Signed-off-by: Matteo Croce --- drivers/irqchip/irq-gic-v3.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/irqchip/irq-gic-v3.c b/drivers/irqchip/irq-gic-v3.c index 9bca4896fa6f..4a5d220698f6 100644 --- a/drivers/irqchip/irq-gic-v3.c +++ b/drivers/irqchip/irq-gic-v3.c @@ -771,8 +771,10 @@ static void gic_cpu_sys_reg_init(void) case 7: write_gicreg(0, ICC_AP0R3_EL1); write_gicreg(0, ICC_AP0R2_EL1); + /* fallthrough */ case 6: write_gicreg(0, ICC_AP0R1_EL1); + /* fallthrough */ case 5: case 4: write_gicreg(0, ICC_AP0R0_EL1); @@ -786,8 +788,10 @@ static void gic_cpu_sys_reg_init(void) case 7: write_gicreg(0, ICC_AP1R3_EL1); write_gicreg(0, ICC_AP1R2_EL1); + /* fallthrough */ case 6: write_gicreg(0, ICC_AP1R1_EL1); + /* fallthrough */ case 5: case 4: write_gicreg(0, ICC_AP1R0_EL1); -- 2.21.0