Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752644AbdHVW3Y (ORCPT ); Tue, 22 Aug 2017 18:29:24 -0400 Received: from mail-bl2nam02on0050.outbound.protection.outlook.com ([104.47.38.50]:51744 "EHLO NAM02-BL2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751292AbdHVW3W (ORCPT ); Tue, 22 Aug 2017 18:29:22 -0400 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=David.Daney@cavium.com; Subject: Re: [PATCH][next] MIPS,bpf: fix missing break in switch statement To: Colin King , Ralf Baechle , David Daney , "David S . Miller" , Daniel Borkmann , linux-mips@linux-mips.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org References: <20170822220349.5648-1-colin.king@canonical.com> From: David Daney Message-ID: <93479b06-c3a2-a08a-fe5c-d8f155efeacc@caviumnetworks.com> Date: Tue, 22 Aug 2017 15:29:15 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20170822220349.5648-1-colin.king@canonical.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [50.233.148.156] X-ClientProxiedBy: SN1PR0701CA0082.namprd07.prod.outlook.com (10.163.126.50) To MWHPR07MB3503.namprd07.prod.outlook.com (10.164.192.30) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 510bedc1-4de4-40ed-a60d-08d4e9ad3afa X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095);SRVR:MWHPR07MB3503; X-Microsoft-Exchange-Diagnostics: 1;MWHPR07MB3503;3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G0ai9dAl1FrEWU2pC8ILp/8GQuv3AcX4kV8+WYvtIQjAhqkU1v+ZB+4LqOTJKFJ5QdVQfVeIFaisYWrGaaQpBZtWZYGE4X5MNTMSyXdiN6j1XXhQvD5OjnlPZA8B+ShFDnkJxJC7ogvmtYO/96xubTTaA5cQtUhTjXC7/APenD5a376kp/ej6+6sB11pdhN/UxpOupN9FvNcQpaqidX5ncCQcTWuOaRCQZDibWHv5iSmfMPa93XWLLtamHb3GMUzxqHehfFAs6Pn/T/u1EBhvYB8KTAL3m9Sj5YEqgAoxy3VHi+mkFrQAaCOatVLMdpXTz+WLAktVaHiXS6duj2E6RYgiARBHtqAdp/qrNL1CxAkhOwtl9tx3GGo8nUtzwtYc9Jjmnbj4p5VxTe/nd/z39kys2Rd2/0brPLBYNZ71o6VsCf73HG3LwCRzs=;4:7ZleAo0jSJprCU8YLQNPvu4osG5lwHtHXSYpz9rEKq1ewJ+Zn6WDpGji0BVuxH5GVQiuSgfFM/fX8L7Exxq13W1Iy7wQ/lmYmt2V5vmkZeiN6lKOHZ0P/VqifkPLHkrmpZAsAPgBhjQjviar8lTpVcT1TIeqf1C5MTKLbL9c56MJ96ACGmA5eNId1hrxoISt2Yp5OwJ5ThkDHuA9fD14w5+4Vd7gV3gsvlepaIGPFcvtzdDF3W6Pv6wA1R9oDVH8IKUpPhvpIZPlGxEdx5N+UYIDF47WgnlgnVCYn8ByT5k= X-Exchange-Antispam-Report-Test: UriScan:(198206253151910); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(3002001)(100000703101)(100105400095)(93006095)(10201501046)(6041248)(20161123562025)(20161123555025)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(20161123558100)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:MWHPR07MB3503;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:MWHPR07MB3503; X-Forefront-PRVS: 04073E895A X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(4630300001)(7370300001)(6009001)(24454002)(189002)(199003)(377454003)(105586002)(106356001)(2906002)(8676002)(7736002)(305945005)(2950100002)(5660300001)(47776003)(65806001)(189998001)(33646002)(65826007)(65956001)(64126003)(575784001)(53546010)(66066001)(83506001)(6486002)(31696002)(50466002)(69596002)(229853002)(230700001)(6666003)(6116002)(81166006)(42882006)(3846002)(7350300001)(4326008)(53416004)(25786009)(54356999)(42186005)(72206003)(101416001)(4001350100001)(81156014)(6246003)(31686004)(76176999)(50986999)(97736004)(68736007)(23676002)(6506006)(53936002)(478600001)(6512007)(36756003)(142933001);DIR:OUT;SFP:1101;SCL:1;SRVR:MWHPR07MB3503;H:ddl.caveonetworks.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtNV0hQUjA3TUIzNTAzOzIzOmhESk9zL0dmZ2JDV2xPRkZvQjZaVWxZNnVH?= =?utf-8?B?SHBTVndnekZDVEJqR3d6a3NlczQ4cDhxdGRBSnNIMGVYdFVJWmMxOGQzQi9h?= =?utf-8?B?blRvRW5OSVQwU2VJWU10RE15cU5yaTB3ak5RTlNxYVlLd0JVSVRWQ0c4Yjcr?= =?utf-8?B?SnEwQ3hMNlF1QlorZVg1UXVKS3BEd3crZlYzaVNXYW1keCtVYUwreXg4TEhR?= =?utf-8?B?MURDY2NGZStMNENNSDFzVThjSGdSem1UNFJuZkZGWVRDRmhZQjdQS0FlVllF?= =?utf-8?B?WWNjSW92aHZWNkt0amVBeFFsQ2J6Ui9XQVgvaDJEWXlRd1FsQ2VQa0RMNjYv?= =?utf-8?B?SWl5dG1Wdk9wMG51MzBxN3lHKzBTWnd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TIkAk87JQEJOKXrimsvUUavFa2tY3NtbvQfGOjpXBcva8MtWtGartOBHhbB7LOq2Ljf62hPoP1cBcEhFd/yfCXQ2MUsWiNyicOFWbXTeZuXmfzAj/v3dw5A==;5:BUbzilRFQxCR/pP0LJFjhkEtvDH+7MZ9NCAznE3yAgpl0muJexnfZZegGURflDzxcK1CmlQfqm5zL6BuLAbJhyGC547hjSQKPIBOnlfnzHbKVgMyAz7lrk+xiR8NfMfDcl1htCEPlDC7XrW92guS1Q==;24:fIK+7FW9oSKOLPd/Bg6lyjvyiI54dh+sDlMs1ynh4zrsTOwnT3W8Pfo8+NtxqUKidXK7yr2LupVjL/I6Xtm7B7XAbE8knBNPjjFb6sImg4o=;7:5u3tuDBbyJbENRDGLDN2YRyMsLcICkZPgEoM3fmnErotzdoqNntAHoOHkkkAhrc37GiZPNrYpSrH0hpnssdtZljlhlT3CeUAyX9249zy1aL6bqTt8pw1/JD4FpEpMhVsxUyyNxXUSGQeiF7jWbjYcMM4cEyl9C+oemRYATx0uE/jGGIbLSYfW4gtFrfCe3JGpq0guKlNKdU9sNvJQG62Vyy8VCbKX7zjB/k85Ev9A8U= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Aug 2017 22:29:18.4361 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR07MB3503 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1138 Lines: 37 On 08/22/2017 03:03 PM, Colin King wrote: > From: Colin Ian King > > There is a missing break causing a fall-through and setting > ctx.use_bbit_insns to the wrong value. Fix this by adding the > missing break. > > Detected with cppcheck: > "Variable 'ctx.use_bbit_insns' is reassigned a value before the old > one has been used. 'break;' missing?" > > Fixes: 8d8d18c3283f ("MIPS,bpf: Fix using smp_processor_id() in preemptible splat.") > Signed-off-by: Colin Ian King Crap! That slipped through. Thanks for fixing it. Tested and ... Acked-by: David Daney > --- > arch/mips/net/ebpf_jit.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/mips/net/ebpf_jit.c b/arch/mips/net/ebpf_jit.c > index 44ddc12cbb0e..7646891c4e9b 100644 > --- a/arch/mips/net/ebpf_jit.c > +++ b/arch/mips/net/ebpf_jit.c > @@ -1892,6 +1892,7 @@ struct bpf_prog *bpf_int_jit_compile(struct bpf_prog *prog) > case CPU_CAVIUM_OCTEON2: > case CPU_CAVIUM_OCTEON3: > ctx.use_bbit_insns = 1; > + break; > default: > ctx.use_bbit_insns = 0; > } >