Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp993984imu; Fri, 9 Nov 2018 09:13:19 -0800 (PST) X-Google-Smtp-Source: AJdET5dUYGKkH8UBcOEiduSDVCQPjaLz41e9So3cybAg5DgPIC50CTMdXTzkoGY6IvZat5/K2D1X X-Received: by 2002:a62:2782:: with SMTP id n124-v6mr10003112pfn.216.1541783599463; Fri, 09 Nov 2018 09:13:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541783599; cv=none; d=google.com; s=arc-20160816; b=CvrAUeO7WgJPJI6wh8nxpfSiZSfcVBzk21nQvvUoU7JppXMotP8xfUGFF7YEm1DLvI NfjFEuLlfDo5SJ0Q+HGeANdi/DqRUoeS1xR85b2VLYRtZd/rIemMpwYkNNCzL2sq/uNW yEALUPj4tjsGAzMi4tKrlbeBcHJfBcPzLDO47OZfGabE9Jl36CHekJhyTmeGaJoPgBA9 kGUSV4DaCQQziAPmcyTPBrqlfvcnEurQAF7YwRRo+sRCBDBut4V2JEaB2N64xEifPWLB uSHzdMAL94RIh6o+0JjPm2HuQBfs6EpLBnRcYMhDB5juDr3XvlwxZh5NwgKzkjtsL2Rj ZD7g== 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 :content-language:mime-version:user-agent:date:message-id:cc:to :subject:from; bh=3xe5pBJMFIopJSucEkz3SDux7N3ERETsyaFbinhRupE=; b=FjtNvQTj/zdLlZOzzN1GyAZPAotWlZyqYupNW7gRjpZKnQ5MQTsKjx71UgfXX2Jour de9pdrQY8k/LrTlW/VkV9Tb0bSr2Pa/adP2D3I+fBQUfPWdxgUSdnLdMe5wG6gEFBtgi LM2gc4D9wEj25rk5FTS/dD1kmMHgn547+A+I3UESC7ZsXeLivsZV9Iek/VOfgTMRN36N omg00ypKHjBUIhhntTmVr+Ke69wKZf2bCdtqCNuh7POLDJ1K5HfcxtoBvXqtr6q5bIMq U7xdiCdEff4z166TEbgmdmFnK6ndkYHbv9RVg+PKwb3cuMTyCGFRxb19fwsiliz+g4cT kh8g== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u128-v6si9324137pfc.145.2018.11.09.09.12.20; Fri, 09 Nov 2018 09:13:19 -0800 (PST) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728236AbeKJCwv (ORCPT + 99 others); Fri, 9 Nov 2018 21:52:51 -0500 Received: from pegase1.c-s.fr ([93.17.236.30]:20786 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727961AbeKJCwv (ORCPT ); Fri, 9 Nov 2018 21:52:51 -0500 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 42s6BB6mTlz9v0XK; Fri, 9 Nov 2018 18:11:14 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at c-s.fr Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [192.168.12.234]) (amavisd-new, port 10024) with ESMTP id 9qqDz3jeip2V; Fri, 9 Nov 2018 18:11:14 +0100 (CET) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 42s6BB6BLNz9v0XJ; Fri, 9 Nov 2018 18:11:14 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id AA23E8B899; Fri, 9 Nov 2018 18:11:20 +0100 (CET) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id BY4XbDnqDaX1; Fri, 9 Nov 2018 18:11:20 +0100 (CET) Received: from PO15451 (po15451.idsi0.si.c-s.fr [172.25.231.2]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 682598B887; Fri, 9 Nov 2018 18:11:20 +0100 (CET) From: Christophe LEROY Subject: UBSAN: Undefined behaviour in kernel/rcu/tree_plugin.h in 4.20-rc1 To: "Paul E. McKenney" Cc: "linuxppc-dev@lists.ozlabs.org" , "linux-kernel@vger.kernel.org" Message-ID: Date: Fri, 9 Nov 2018 18:11:20 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org (Resending due to error in Paul's address) Paul I get the following UBSAN reports in 4.20-rc1 on an MPC8321E (powerpc/book3s/32) I bisected it to 3e31009898699dfc ("rcu: Defer reporting RCU-preempt quiescent states when disabled") Thanks Christophe [ 4.919995] ================================================================================ [ 4.928428] UBSAN: Undefined behaviour in kernel/rcu/tree_plugin.h:623:28 [ 4.935198] signed integer overflow: [ 4.938766] 0 - -2147483648 cannot be represented in type 'int' [ 4.944678] CPU: 0 PID: 119 Comm: mkdir Not tainted 4.19.0-rc1-s3k-dev-00005-g5a60513 #214 [ 4.952908] Call Trace: [ 4.955382] [dec4fd20] [c02cb0d0] ubsan_epilogue+0x18/0x74 (unreliable) [ 4.962003] [dec4fd30] [c02cb5e0] handle_overflow+0xd0/0xe0 [ 4.967588] [dec4fdb0] [c007b424] rcu_preempt_deferred_qs+0xc0/0xc8 [ 4.973857] [dec4fdd0] [c007be28] rcu_note_context_switch+0x74/0x608 [ 4.980217] [dec4fe10] [c064b790] __schedule+0x58/0x6e0 [ 4.985448] [dec4fe50] [c064bfdc] preempt_schedule_common+0x48/0x9c [ 4.991717] [dec4fe70] [c01308c8] handle_mm_fault+0x10fc/0x1ecc [ 4.997639] [dec4fee0] [c001339c] do_page_fault+0x10c/0x760 [ 5.003225] [dec4ff40] [c001234c] handle_page_fault+0x14/0x40 [ 5.008968] --- interrupt: 401 at 0xff9cff8 [ 5.008968] LR = 0xfeefd78 [ 5.016170] ================================================================================ [ 5.024591] ================================================================================ [ 5.033005] UBSAN: Undefined behaviour in kernel/rcu/tree_plugin.h:627:28 [ 5.039775] signed integer overflow: [ 5.043342] -2147483648 + -2147483648 cannot be represented in type 'int' [ 5.050118] CPU: 0 PID: 119 Comm: mkdir Not tainted 4.19.0-rc1-s3k-dev-00005-g5a60513 #214 [ 5.058348] Call Trace: [ 5.060813] [dec4fd20] [c02cb0d0] ubsan_epilogue+0x18/0x74 (unreliable) [ 5.067433] [dec4fd30] [c02cb5e0] handle_overflow+0xd0/0xe0 [ 5.073014] [dec4fdb0] [c007b408] rcu_preempt_deferred_qs+0xa4/0xc8 [ 5.079283] [dec4fdd0] [c007be28] rcu_note_context_switch+0x74/0x608 [ 5.085640] [dec4fe10] [c064b790] __schedule+0x58/0x6e0 [ 5.090871] [dec4fe50] [c064bfdc] preempt_schedule_common+0x48/0x9c [ 5.097139] [dec4fe70] [c01308c8] handle_mm_fault+0x10fc/0x1ecc [ 5.103059] [dec4fee0] [c001339c] do_page_fault+0x10c/0x760 [ 5.108642] [dec4ff40] [c001234c] handle_page_fault+0x14/0x40 [ 5.114385] --- interrupt: 401 at 0xff9cff8 [ 5.114385] LR = 0xfeefd78 [ 5.121588] ================================================================================