From patchwork Fri Oct 13 13:56:43 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrey Ryabinin X-Patchwork-Id: 10004783 X-Patchwork-Delegate: herbert@gondor.apana.org.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6AFD760360 for ; Fri, 13 Oct 2017 13:53:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5BCF929060 for ; Fri, 13 Oct 2017 13:53:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 503BA2907F; Fri, 13 Oct 2017 13:53:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 71DF029060 for ; Fri, 13 Oct 2017 13:53:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753258AbdJMNxs (ORCPT ); Fri, 13 Oct 2017 09:53:48 -0400 Received: from mail-he1eur01on0119.outbound.protection.outlook.com ([104.47.0.119]:13769 "EHLO EUR01-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753231AbdJMNxq (ORCPT ); Fri, 13 Oct 2017 09:53:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=/1EOzWvgYW9TT3fNYaaJJlScDx0vbj1KEzuWsCoH2q8=; b=b26cyKb8UTXEi58sIqkYf5mlQbtp4wiBYcD8xU6VEOaN+xsTdTxElsNbIzLmBfr/FcnxQr3tLaCy6RjEAX1q8eXyZQcQuqnfYa04vDrOax7z4Vwz2X854oL8AB9f7sROClyopKD/IrQ78hXapE7JxnK5gtQombHM/ixbLny70Tw= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=aryabinin@virtuozzo.com; Received: from [172.16.25.12] (195.214.232.6) by AM4PR08MB2819.eurprd08.prod.outlook.com (2603:10a6:205:d::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Fri, 13 Oct 2017 13:53:39 +0000 Subject: Re: [lkp-robot] [x86/kconfig] 81d3871900: BUG:unable_to_handle_kernel To: Josh Poimboeuf , Christopher Lameter Cc: kernel test robot , Ingo Molnar , Andy Lutomirski , Borislav Petkov , Brian Gerst , Denys Vlasenko , "H. Peter Anvin" , Jiri Slaby , Linus Torvalds , Mike Galbraith , Peter Zijlstra , Thomas Gleixner , LKML , lkp@01.org, linux-mm@kvack.org, Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Megha Dey , Herbert Xu , "David S. Miller" , linux-crypto@vger.kernel.org References: <20171010121513.GC5445@yexl-desktop> <20171011023106.izaulhwjcoam55jt@treble> <20171011170120.7flnk6r77dords7a@treble> <20171013044521.662ck56gkwaw3xog@treble> From: Andrey Ryabinin Message-ID: <9a1c3232-86e3-7301-23f8-50116abf37d3@virtuozzo.com> Date: Fri, 13 Oct 2017 16:56:43 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: <20171013044521.662ck56gkwaw3xog@treble> Content-Language: en-US X-Originating-IP: [195.214.232.6] X-ClientProxiedBy: AM5PR06CA0013.eurprd06.prod.outlook.com (2603:10a6:206:2::26) To AM4PR08MB2819.eurprd08.prod.outlook.com (2603:10a6:205:d::25) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 433d26dd-498b-4f6b-a119-08d51241cfed X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254152)(2017052603199)(201703131423075)(201703031133081)(201702281549075); SRVR:AM4PR08MB2819; X-Microsoft-Exchange-Diagnostics: 1; AM4PR08MB2819; 3:FS8QD2AkEb0ywTEHf16nVUuJBzLdr18UGx1aswifBxZu7gGSU4XLN99pXlskcZ8p4F3e1cMvUMn6Vtlwp+fxVDQ+eCcUzjF4fPfD7UtfN2VDb4B50B24T/Zve4L3ro2f4X2BK7rxCWZpzTdxf1OSseNHZKH1MsN18f2mWU1oiKjvP77MiWg8lVod1xRJW8W5iQChP84ZR9Zz8lQcE/EGrslLiPyPZYJT+MaQJQSjVzBF2AvFF/RcEyDqKnxRu/jy; 25:8n6qZv8dRNWQhXx1ILyilUuSpNlkAFActodwSC8cYjIUwzaLFyB+y4Pi+1xa2x1kAIpkU8EsUws9S7d9AXmzhoPhrt3dFIuiJiiRxmN6nIk5OFM/oYcam13AYWPXqcEaVGkytrF6E/w+/JSRMYkC3xP08pmRWEb5ohElSfkAq5ZWGPOAYMRY5+aoxwIPW1jPOtTSu1fox2Vhm9aA9zKQJ8zsSczANTCX4nTXBLLu/HIhMs2w21VnmoAiZapnQxVO2rF8FjUJ2QNfDHrHGkYmZs5ZkVQ1ctHyQoE7A5e0dhhspNwBnSVwFaP+rA7JV3dZ+XXOQ0BPePNbKm1QDglisw==; 31:XBpL6T7+Geh/BqLn85SXPJ4SKAVSFK5lIu3tnZqo+PisHD5qRUy4rVFmsQPASoYFtPjHgAGXKtXAF3FooEfJX0X7o1RuZHUaqJUhA4G+ULSAkFzTVgYvCKie6O0dYL5+yBx/IkjtvJEyqg3HsoFaMCuswwG/Xy/DquY7a+Nei5kmtzUggxDnPQjnJgGnZDPpTmNtI6Sfe2CrP8zkEkMRYX/zAaPVtSfkBlad7G17ZlU= X-MS-TrafficTypeDiagnostic: AM4PR08MB2819: X-Microsoft-Exchange-Diagnostics: 1; AM4PR08MB2819; 20:6gVvUEkn4gLa8ImENnKaCjI6SfpnHSDi//ddwFe70lQvubLiJZ4grlZnpUp+kx51j3UlIVsodng1v+5slIy0IbiH2TAprIf7GN24IiVXCPgAUAGvXM4p1ywzmTCkQC0DNso5uQsQYbi2hEqtfbfZ6bwyWvWRTRUF9RoyqaCOAK6fDVI85gpoKnPvYiwyNsjR3eTcmM3hqjyI6E2OBfxaZ7C5mDgUcasXQTqI6v5zYn7E58zqWVmc65bTqumGLnT7/qAvH3IJ+wSJa+nd/qUuEVTSyBEeJi4hpu/C4pBaO6Qv7km7NiU6SAFffUBrFVXQwYKkBjo1+DNkQH8w9Mhs/NaDj+2XByfJ0Vf8+HCeLFDwN9P0/cCZhVAiOrsAdGtvD49/LOxaMTW3onMXVwvx8lWSNX9jbHSkqV7FVrUIpCs=; 4:yWirFVyzPLKT3g9I89t18lHt9Aa3R80HbbP6dv3l04dVu2l5j6ayX8+Xm3KLz+x16UtqtZzc2vlF9xSHsca5iOwbgLFw8QBx2sU645486VXJUYu0PWglIjkyb0CmLwl2T5zMVDz6vth7ZCyYQ7r5+dnxsz8hubiggMKDnjxTiWMR0Rz2hb/GQpItD2foh9+bjLEdh72+nfW6TFyhB8rQsNTaQXgwAAxo/PGQ1wPZPT8+HTOMlDy2t1vxGr1UO8MI X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(8121501046)(5005006)(10201501046)(3002001)(100000703101)(100105400095)(93006095)(93001095)(6041248)(20161123555025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123564025)(20161123560025)(20161123558100)(20161123562025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:AM4PR08MB2819; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:AM4PR08MB2819; X-Forefront-PRVS: 04599F3534 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(6009001)(6049001)(346002)(376002)(24454002)(199003)(189002)(377454003)(51234002)(93886005)(105586002)(36756003)(7416002)(478600001)(189998001)(7736002)(76176999)(68736007)(45080400002)(305945005)(54356999)(50986999)(86362001)(6486002)(33646002)(8676002)(77096006)(8936002)(101416001)(31696002)(106356001)(53546010)(6666003)(2906002)(229853002)(65826007)(39060400002)(110136005)(81166006)(58126008)(47776003)(230700001)(8666007)(31686004)(316002)(54906003)(25786009)(6246003)(2950100002)(97736004)(83506001)(23676002)(81156014)(66066001)(4326008)(50466002)(3846002)(53936002)(16526018)(5660300001)(64126003)(65956001)(16576012)(6116002)(65806001); DIR:OUT; SFP:1102; SCL:1; SRVR:AM4PR08MB2819; H:[172.16.25.12]; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: virtuozzo.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtBTTRQUjA4TUIyODE5OzIzOlRmTkZIRkxWaGhCMUxKR0pvaUhkMzVtSDBk?= =?utf-8?B?cVVtU0JMdDFSQ05UaHIxcWlRZWpVajNtckc5MFZoaERQOHVEMEFKU0x6MEhS?= =?utf-8?B?a1c2dGtvRGlSazBZdDZsS3J2NnYwOG9ibVJ4NktXakp2ODlwWWpPMzNUWEp0?= =?utf-8?B?Y05zVk94b0lodEJDb3VobUVCUG9wTnFHNHAwZ3RkMHg5Tk5BOGlSYk80WlpB?= =?utf-8?B?Wm9ZaVV3Y0Fma0Q5dm5MeTBmclkxNXRXaDJXM0kwKzZjc1FEZ2ltdmV2dmVu?= =?utf-8?B?eXFPL3JjSU5zeXV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IXElY3xSymd7XRksURCXmwB7uWaPepW3O05BN5CcOI= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Oct 2017 13:53:39.9830 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM4PR08MB2819 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On 10/13/2017 07:45 AM, Josh Poimboeuf wrote: > On Thu, Oct 12, 2017 at 12:05:04PM -0500, Christopher Lameter wrote: >> On Wed, 11 Oct 2017, Josh Poimboeuf wrote: >> >>> I failed to add the slab maintainers to CC on the last attempt. Trying >>> again. >> >> >> Hmmm... Yea. SLOB is rarely used and tested. Good illustration of a simple >> allocator and the K&R mechanism that was used in the early kernels. >> >>>> Adding the slub maintainers. Is slob still supposed to work? >> >> Have not seen anyone using it in a decade or so. >> >> Does the same config with SLUB and slub_debug on the commandline run >> cleanly? >> >>>> I have no idea how that crypto panic could could be related to slob, but >>>> at least it goes away when I switch to slub. >> >> Can you run SLUB with full debug? specify slub_debug on the commandline or >> set CONFIG_SLUB_DEBUG_ON > > Oddly enough, with CONFIG_SLUB+slub_debug, I get the same crypto panic I > got with CONFIG_SLOB. The trapping instruction is: > > vmovdqa 0x140(%rdi),%xmm0 It's unaligned access. Look at %rdi. vmovdqa requires 16-byte alignment. Apparently, something fed kmalloc()'ed data here. But kmalloc() guarantees only sizeof(unsigned long) alignment. slub_debug changes slub's objects layout, so what happened to be 16-bytes aligned without slub_debug, may become 8-byte aligned with slub_debg on. > I'll try to bisect it tomorrow. It at least goes back to v4.10. Probably no point. I bet this bug always was here (since this code added). This could be fixed by s/vmovdqa/vmovdqu change like bellow, but maybe the right fix would be to align the data properly? --- arch/x86/crypto/sha256-mb/sha256_mb_mgr_flush_avx2.S | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/x86/crypto/sha256-mb/sha256_mb_mgr_flush_avx2.S b/arch/x86/crypto/sha256-mb/sha256_mb_mgr_flush_avx2.S index 8fe6338bcc84..7fd5d9b568c7 100644 --- a/arch/x86/crypto/sha256-mb/sha256_mb_mgr_flush_avx2.S +++ b/arch/x86/crypto/sha256-mb/sha256_mb_mgr_flush_avx2.S @@ -155,8 +155,8 @@ LABEL skip_ %I .endr # Find min length - vmovdqa _lens+0*16(state), %xmm0 - vmovdqa _lens+1*16(state), %xmm1 + vmovdqu _lens+0*16(state), %xmm0 + vmovdqu _lens+1*16(state), %xmm1 vpminud %xmm1, %xmm0, %xmm2 # xmm2 has {D,C,B,A} vpalignr $8, %xmm2, %xmm3, %xmm3 # xmm3 has {x,x,D,C} @@ -176,8 +176,8 @@ LABEL skip_ %I vpsubd %xmm2, %xmm0, %xmm0 vpsubd %xmm2, %xmm1, %xmm1 - vmovdqa %xmm0, _lens+0*16(state) - vmovdqa %xmm1, _lens+1*16(state) + vmovdqu %xmm0, _lens+0*16(state) + vmovdqu %xmm1, _lens+1*16(state) # "state" and "args" are the same address, arg1 # len is arg2