From patchwork Mon Mar 13 15:42:09 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jens Axboe X-Patchwork-Id: 9621329 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 5E01860414 for ; Mon, 13 Mar 2017 15:42:53 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4E11226E76 for ; Mon, 13 Mar 2017 15:42:53 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3E6C427C2D; Mon, 13 Mar 2017 15:42:53 +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 7CB4326E81 for ; Mon, 13 Mar 2017 15:42:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751436AbdCMPmw (ORCPT ); Mon, 13 Mar 2017 11:42:52 -0400 Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:49558 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751401AbdCMPmv (ORCPT ); Mon, 13 Mar 2017 11:42:51 -0400 Received: from pps.filterd (m0109334.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.20/8.16.0.20) with SMTP id v2DFRlbw020586; Mon, 13 Mar 2017 08:42:17 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=subject : to : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=facebook; bh=Euma6X/V5+q48sFG21iVh1oAz9ggluQzaGLA65LA7PE=; b=JhweopLueLsQ+vBPLY3orqwd5Wlwx8YJuByfRuV2Ig+ew1l+hxU2hxnBQoR/P2Jsa81g K1eZWLWS5RRJZUkP9s200nfrYL0VdqvGbnMOn6vg+0Fd9AOeMZ9xpuMs2MXwqDKefHDr H+wOJue4X6FZLSs93pgneGnjYjSsxWIam+Q= Received: from maileast.thefacebook.com ([199.201.65.23]) by mx0a-00082601.pphosted.com with ESMTP id 295whh8560-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 13 Mar 2017 08:42:17 -0700 Received: from NAM03-DM3-obe.outbound.protection.outlook.com (192.168.183.28) by o365-in.thefacebook.com (192.168.177.28) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 13 Mar 2017 11:42:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.onmicrosoft.com; s=selector1-fb-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Euma6X/V5+q48sFG21iVh1oAz9ggluQzaGLA65LA7PE=; b=f/+940QWOKEARAkGmjioLMoxFWkYGNQOa+qr+SdpSMQ7XSBcPWO5SPaesoYysgaJcAofTpRZnUmC+mBPbd4mE5a62OGHHQMGCV1nVVbmsfhnA8AUvqeZoB/omd0/yh4sRA27N75aeaX9QZdHk3prD3d75RMcJ4Ac1GaSZinRLL4= Authentication-Results: lists.infradead.org; dkim=none (message not signed) header.d=none; lists.infradead.org; dmarc=none action=none header.from=fb.com; Received: from [192.168.1.154] (216.160.245.98) by MWHPR15MB1200.namprd15.prod.outlook.com (10.175.2.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.947.12; Mon, 13 Mar 2017 15:42:13 +0000 Subject: Re: NULL deref in cpu hot unplug on jens for-linus branch To: Sagi Grimberg , "linux-block@vger.kernel.org" , linux-nvme References: From: Jens Axboe Message-ID: <54f833f1-ab98-5d22-e7d4-5e6059a4c467@fb.com> Date: Mon, 13 Mar 2017 09:42:09 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: X-Originating-IP: [216.160.245.98] X-ClientProxiedBy: BN6PR07CA0019.namprd07.prod.outlook.com (10.173.33.157) To MWHPR15MB1200.namprd15.prod.outlook.com (10.175.2.142) X-MS-Office365-Filtering-Correlation-Id: 47da0423-38fa-4ecc-b9ae-08d46a2785bd X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:MWHPR15MB1200; X-Microsoft-Exchange-Diagnostics: 1; MWHPR15MB1200; 3:m7ObD8Qs3WZgdYO/Tvr4/jU/Mbu8459t2WhsdJ/mxpzbaNMU386PRRD36STG7mkwI/1EqVd1YR0ndNe5gyeFZurSmCWAbCcKC+zwh/59WYVucG5sdW9+4/DwLvtBQVk9RL17FyDe0UiscbWsnw94mgvX3iyy5QfrSo7s9l8Ve+X1bxYqk5e/Dzif/u9F+LDtU5jSb0kXH4yuLfxDcDQod9uu0+1df9Q0tUy5fwW5zCQr+zzwOE/fdSGtb7X2nnCeYp3KoZIV49764w5JVpmpkw==; 25:9IejZb+/LgfR2hvy+B9qe6g0A3nQFmpZqcc7jfaumr01E2v2WhkZ07UuWL0lQiZPvCAsf/IaNOpWRpVIbK0SUup38w0KFNbxPBG6fVpPzgOFKs2fIxWO1m3O+i6T1Bi9MMr4Yw1ThxZvha5bHfFe2pbY23CRhMXmKVzq3tDFL5Ac1hvVcxEUGSpOfD3QTh+oYyiEO9BeehTqcBxsTBEJoere/iW38MAu1w4kB1CW4myQudhAEft3ejRg3+QqZmsQKdwGAH0QhU26gOvRITNCtou69Cz2ged/dfCfNCQgjj56RWr5yjt2LtJVuikFRTprRpDCWgDMkssvXNjQKaobQxdmyOMjSruQawqu14XZe+VEWujdudeRJMAEWobtifsOcZwdjCRE/KbsSqwWgVYZH9VXedgldW5xAiv6RU/7MUD0ctcKsPa/vDJwhtQYUKkXZ7Q0qz0b7YZDpdmpcZp1qQ== X-Microsoft-Exchange-Diagnostics: 1; MWHPR15MB1200; 31:GovT99T8ZXYr5pXnhXMf3mWcymT/6lhN2daS5T4TSbkBPp/d9iemTOTEnwcvrE92poM6G6kgsA2lpKxThxR14sHIGVNwGbONs/kV3bPucm/xBOyfKZAf2zzJhjK47GG3HCiJzUDA/PLCniEz886l+EBMtPWeM9Y6OeU+zXrUQDTO/JHqpiJGRxEjC8LFx2WKSKqj2Maxrbf6y0TKA7CGl0YwdZhSGZKDpbdwFrv279CWbGXZaOQU3roavXCvDvDx; 20:Uu4R/dXpkwc8b+SY7ZmQDpd+5bQYrhiS4MacI8hLoftUKO45j0J10hwX/PivgaVGVVgz9BZLeCP0D8zX0dwju8zdE33GpKlT14WCIxZVGzCfKUFcM0NFntze2ryayKeD/0ufcgDZ5D8mk0F8oAWzAMThxES4Uzkw2za2ijGtsqXGiAiMrLKarSuhNOX3scbM4xk02wyZXR5DiCis75zWttUaWOLg8nRKQhs7v26KjJBv2MXF0BFns+I6MrELK8yd3EPLLEQ+FFdPdX/HBT8PCxFkC5eVLcJuNEgNJUHZheLGcWe/orjr8ys6CHgDI9ixDk84qaRVjUWrxq+JbB8ja4XgEpVBuGaml8GiZo3V06xU0fLbSFaTzNhUcTzcN/jzFY+9G6nTw9/AnwGGhg+AEZtSyngInlB8zfxos5Vl5oveZdwAveuf8hF2JyhgS+6ApCkDosVK1BnsxOtMaWTZT9GAL/4zPIjCCj0C6bLbuMPbxPbkVZEes/RThQ2sOqHE X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(5005006)(8121501046)(10201501046)(3002001)(6041248)(20161123564025)(20161123558025)(20161123562025)(20161123555025)(20161123560025)(6072148); SRVR:MWHPR15MB1200; BCL:0; PCL:0; RULEID:; SRVR:MWHPR15MB1200; X-Microsoft-Exchange-Diagnostics: 1; MWHPR15MB1200; 4:Iei/touD7hYxbuiC9DgKbutNKGmQoE2lCqnjMSJPpk8Bi6WtAv+W6546ndKS1uTU+Vafy4GVnUkYXw0pcv8zqyeiEv+lIA3M8nxkDO2UbwkJNYiz71y7MLMGK8TqI6NKGHPrm9zraaaS63Wm/x0vj795HbK4LN/uk29IWn6gi9UO1EMue3m2GQ2yjDsvmVWcvJlgs4AZS2F0kKk4VrrEX5GHeDPRwDUKnL9mEuvaXQH3yWhV9lrEmBt2ZUSB+xIPw6Y/pRWUWVTXjmoykIqpgNmLSQ2EkOzuyAUi/pq/3mi+ZrAO/5q7/LA4fCde0kgylNLpvYmWaeZk39H/ERD2/to8kcDKWPUq1rvvm1KbnETaSwFXvHxRWfPrthMqzxOzPh+PJsgpQot3v9eGDbcW5PsI6TOiH0u3EySWXqWuf2bM9vwA/A3a11ykS30RP26m9De6z5CdzW0wMkQ2kUdvO/ZUk2Ujw5ZmfN7h6RNLgMD6R/6/tWq983eGGjR3HOLkHp93+1JRqAAH0mwZkCxdvfb/EgfmXt8QyvRddZ+RpwdPrKN6TCdHH5E7cBn+Igu84mi6gFfzchOPiWSMby/YewXuVZaY/sFahzBdBl3djN0= X-Forefront-PRVS: 0245702D7B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(4630300001)(6049001)(6009001)(39410400002)(39830400002)(39450400003)(51234002)(377454003)(24454002)(42186005)(23676002)(6246003)(6666003)(575784001)(230700001)(86362001)(38730400002)(31696002)(31686004)(117156001)(50466002)(65826007)(2950100002)(36756003)(50986999)(189998001)(7736002)(3846002)(229853002)(64126003)(6116002)(25786008)(76176999)(2501003)(54356999)(53546006)(65956001)(83506001)(77096006)(2906002)(6486002)(53936002)(66066001)(90366009)(305945005)(33646002)(81166006)(8676002)(47776003)(5660300001); DIR:OUT; SFP:1102; SCL:1; SRVR:MWHPR15MB1200; H:[192.168.1.154]; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtNV0hQUjE1TUIxMjAwOzIzOk51eFN0WjdSYW5WeTRWZTd2NHlEWTEvcUhr?= =?utf-8?B?SVUydWFDb3ZWaDYxS0gvM2pLTmNLamRLVWdzQmV3SmVxUEtpdGZtMXlqZmxI?= =?utf-8?B?VURWUTduVUpaWEdRaGxXVzVabndBQzR2NitqYk4zRk9ZdUhVN2ZBZllmclU3?= =?utf-8?B?K0xXY1RzSkZVT1U2UmN1Z1JGbHN5Y2RXRDNvL0xiRTZlY1ljSVhrVU1PZnhr?= =?utf-8?B?WktYUytyTkNoZmdrNnB2TE1qeXEybVhRV2RVWG13cW5mdHBLbFljR2RyVFlu?= =?utf-8?B?bkVMbUNYazdVZThUUFRiRGNXVEhDS1pZdXJmcExweHVKU3p6NXZHNG9qay8x?= =?utf-8?B?YjRPaERVVmhtUDFhL0ZSRmhQdkpveVh3eXBla1ZDUDF6UlFOdU92citLQVcx?= =?utf-8?B?YjJkczZGVTRSUnRnOU5zRnEwcm1tVlo1di8zYlFXT1RhK3JvMk1mbktjOU5H?= =?utf-8?B?bzhud2EyNTJPMUdDL21ERTkyWnMyWXdWcjNleG1XUVZES0tNMFhtZkwyMXBX?= =?utf-8?B?bWFJb1NFYU16ZzRRb1NWZXN3VW03bXQ0WmJ0RWM0N3IzWEkyZ2VvMW9GamxB?= =?utf-8?B?eit0SklyTGkyZGlHbVhMSnRqUEdQZDlrZlYvMFV4YW55aEpLNGN5amNSZWhY?= =?utf-8?B?S0R1UmhXcHUxRE1Ba0htczBOcEcwVGV0MUl3MlpLa0FqTXZOcUtON0kyeEdn?= =?utf-8?B?QmpuamhpNzJFSVRxUE5jRGlFU2JsYU5vbnlsVU0wN0p5WnZ6bnpOb2xFMFln?= =?utf-8?B?TE0yRW1xeXZqNTNoRzh0YkxBM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hXyLdg+jXY+eWOnHj5kYr+Ft54+noTTIormg==; 20:/qpujGSn8wFx0vHs/rv8w1dV4QKpZniCqoQtWbTthGkBL4mPZoPEXpY97HUrGbL5aTx+5op9c/MbNXRKOmrTxp/jhrc+hfldiXKCEEYjQOtHmXSc4osu2mkh1zIlHxzTHcSqTA1/0OpqFWlqKdmkJKgaLZjaDPSbbggiKOECKhw= X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Mar 2017 15:42:13.8038 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR15MB1200 X-OriginatorOrg: fb.com X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-03-13_10:, , signatures=0 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On 03/13/2017 09:24 AM, Sagi Grimberg wrote: > Hey Jens, > > After some fixes to nvme-rdma in the area of cpu hot unplug and > rebase to jens for-linus branch I get the following NULL deref [1] > > This crash did not happen before I rebased to for-linus (unless I > screwed up something). > > I'm on my way out so I just send it out in hope that someone can > figure it out before I do... > > After I offlined a cpu, I got the nvmf target to disconnect > from the host, the host then schedules a reconnect. after the > host reconnects it issues a namespace scanning which removes > an old namespace. Then we get to blk_cleanup_queue which > then triggers the NULL deref. > > The strange thing is that we pass the > (blk_mq_hw_queue_mapped(hctx)) condition but still hit a NULL... > > [1] > -- > [ 55.865818] BUG: unable to handle kernel NULL pointer dereference at > 0000000000000008 > [ 55.867094] IP: __blk_mq_tag_idle+0x19/0x30 > [ 55.867825] PGD 0 > > [ 55.868477] Oops: 0002 [#1] SMP > [ 55.869010] Modules linked in: nvme_rdma nvme_fabrics nvme_core > mlx5_ib ppdev kvm_intel kvm irqbypass crct10dif_pclmul crc32_pclmul > ghash_clmulni_intel pcbc aesni_intel aes_x86_64 crypto_simd glue_helper > cryptd joydev input_leds serio_raw i2c_piix4 parport_pc parport mac_hid > ib_iser rdma_cm iw_cm ib_cm ib_core configfs iscsi_tcp libiscsi_tcp > libiscsi sunrpc scsi_transport_iscsi autofs4 cirrus ttm drm_kms_helper > syscopyarea sysfillrect sysimgblt mlx5_core fb_sys_fops ptp psmouse drm > floppy pps_core pata_acpi > [ 55.876358] CPU: 0 PID: 21 Comm: kworker/0:1 Not tainted 4.11.0-rc1+ #136 > [ 55.877492] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), > BIOS Ubuntu-1.8.2-1ubuntu1 04/01/2014 > [ 55.879055] Workqueue: events nvme_scan_work [nvme_core] > [ 55.879940] task: ffffa0b13e1d9080 task.stack: ffffad2000244000 > [ 55.880921] RIP: 0010:__blk_mq_tag_idle+0x19/0x30 > [ 55.881713] RSP: 0018:ffffad2000247c70 EFLAGS: 00010203 > [ 55.882582] RAX: 0000000000000000 RBX: ffffa0b13376f400 RCX: > ffffa0b13fc11d00 > [ 55.883808] RDX: 0000000000000001 RSI: ffffa0b13376f400 RDI: > ffffa0b13376f400 > [ 55.884983] RBP: ffffad2000247c70 R08: 0000000000000000 R09: > ffffffffbee42e20 > [ 55.886168] R10: ffffad2000247b88 R11: 0000000000000008 R12: > ffffa0b1384c6018 > [ 55.887343] R13: 0000000000000001 R14: 0000000000000080 R15: > 0000000000000000 > [ 55.888517] FS: 0000000000000000(0000) GS:ffffa0b13fc00000(0000) > knlGS:0000000000000000 > [ 55.889816] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > [ 55.890738] CR2: 0000000000000008 CR3: 000000003ba2f000 CR4: > 00000000003406f0 > [ 55.891878] Call Trace: > [ 55.892285] blk_mq_exit_hctx.isra.41+0xc4/0xd0 > [ 55.893020] blk_mq_free_queue+0x110/0x130 > [ 55.893693] blk_cleanup_queue+0xe0/0x150 > [ 55.894346] nvme_ns_remove+0x78/0xd0 [nvme_core] > [ 55.895109] nvme_validate_ns+0x8c/0x290 [nvme_core] > [ 55.895911] ? nvme_scan_work+0x28a/0x370 [nvme_core] > [ 55.896726] nvme_scan_work+0x2ad/0x370 [nvme_core] > [ 55.897523] process_one_work+0x16b/0x480 > [ 55.898174] worker_thread+0x4b/0x500 > [ 55.898771] kthread+0x101/0x140 > [ 55.899299] ? process_one_work+0x480/0x480 > [ 55.899977] ? kthread_create_on_node+0x40/0x40 > [ 55.900711] ? start_kernel+0x3bc/0x461 > [ 55.901336] ? acpi_early_init+0x83/0xf9 > [ 55.901980] ? acpi_load_tables+0x31/0x85 > [ 55.902632] ret_from_fork+0x2c/0x40 > [ 55.903215] Code: 74 09 48 8d 7b 48 e8 67 4b 06 00 5b 41 5c 5d c3 66 > 90 0f 1f 44 00 00 48 8b 87 08 01 00 00 f0 0f ba 77 18 01 72 01 c3 55 48 > 89 e5 ff 48 08 48 8d 78 10 e8 3a 4b 06 00 5d c3 0f 1f 84 00 00 00 > [ 55.906220] RIP: __blk_mq_tag_idle+0x19/0x30 RSP: ffffad2000247c70 > [ 55.907209] CR2: 0000000000000008 > [ 55.907750] ---[ end trace f016dee1082237cf ]--- Are you saying your code works on top of 4.11-rc2, but not on top of my for-linus? That seems odd. Looking at the oops, you are crashing with !tags in __blk_mq_tag_idle. The below should work around it, but I'm puzzled why this is new. Is it related to the other path you fixed in this patch: commit 0067d4b020ea07a58540acb2c5fcd3364bf326e0 Author: Sagi Grimberg Date: Mon Mar 13 16:10:11 2017 +0200 blk-mq: Fix tagset reinit in the presence of cpu hot-unplug Since that's also handling hctx->tags == NULL. diff --git a/block/blk-mq-tag.c b/block/blk-mq-tag.c index 9d97bfc4d465..1283f74bfdfb 100644 --- a/block/blk-mq-tag.c +++ b/block/blk-mq-tag.c @@ -54,9 +54,11 @@ void __blk_mq_tag_idle(struct blk_mq_hw_ctx *hctx) if (!test_and_clear_bit(BLK_MQ_S_TAG_ACTIVE, &hctx->state)) return; - atomic_dec(&tags->active_queues); + if (tags) { + atomic_dec(&tags->active_queues); - blk_mq_tag_wakeup_all(tags, false); + blk_mq_tag_wakeup_all(tags, false); + } } /*