Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4736520pxj; Tue, 25 May 2021 15:21:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw3zKua7IEx+GFAqIf4hfAA9bSXw9fE9DoN9z1NDSL0uhiyTNAy2KhtAXfjXealEe5plYqA X-Received: by 2002:a17:906:b048:: with SMTP id bj8mr30764544ejb.236.1621981310991; Tue, 25 May 2021 15:21:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621981310; cv=none; d=google.com; s=arc-20160816; b=Zel0DcRxZuR9Jfbpxa4OsIoGTakO4NOBOJzrHlDpzay46JmNFJpQ2+6Tv3LRer6tLe ca++ZHHIqhWZU9ABJVKoANuAag8h4gK7tr6yuA8mOkWvZWm+e6ttq1YUBuUDq1ptpLyg XHAKgQbEO4G4khr9weQTb8E8H/UlX5ioqmT8IbmECOiatTi6Vxkes3ls17kzuQeRvE7a NmnWQxMNu0sFo8bqQqzWXJYdfnHCiLitsqbEzJvB1EO2wHhgK/nXRLwB/y5boGszQXnV 1Ppp7XJSzkpFPdhkiVFqqfC3zzr4URugDx6ug89wwIG9WywSzTLXO0N7jzDLPsw0Q6MK HqiQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=pHX3VOrd9+dhkWdPAt0bdVC0sXVQ4HZoZn4NeyyTwiE=; b=dVYXZUmeJfD1GDHHEyMk9t0JfsVDByB570VZPOgC7YECKRgEm0+UIfyr6A2W3gIG1c QFWsGePE3VLXTTFY2Wgj6ulHJxaFsclMwC7ntpm0HA/EvX6yhe0hRsL2XCw70XFxvlW8 3gpX/n05ArbWc1dObge84NUexfxxHfiAUvsY3HvwzTxPwFD5ROxXDWypg7Uob0JRuGL7 23QsZ9wwVGMMqlnWb5fhc5ywsd4WiHj9tzII4MaPvLHD8hGydK9sY3soy5oogQSAO/m7 IF31zsskNPG8Zs1dXkfsYaOxt33xAHP3yCC+m5bGT1zRAojizH4+AsqVQpG9KjM9VpAK Fjtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel-dk.20150623.gappssmtp.com header.s=20150623 header.b=VKnKMVjP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w10si1760355edq.435.2021.05.25.15.21.25; Tue, 25 May 2021 15:21:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel-dk.20150623.gappssmtp.com header.s=20150623 header.b=VKnKMVjP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231442AbhEYTx5 (ORCPT + 99 others); Tue, 25 May 2021 15:53:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36010 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232842AbhEYTx4 (ORCPT ); Tue, 25 May 2021 15:53:56 -0400 Received: from mail-io1-xd30.google.com (mail-io1-xd30.google.com [IPv6:2607:f8b0:4864:20::d30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A93E7C061756 for ; Tue, 25 May 2021 12:52:26 -0700 (PDT) Received: by mail-io1-xd30.google.com with SMTP id r4so32152007iol.6 for ; Tue, 25 May 2021 12:52:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel-dk.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=pHX3VOrd9+dhkWdPAt0bdVC0sXVQ4HZoZn4NeyyTwiE=; b=VKnKMVjPweEwI1CTNqvFI9XC6XjICrCQjczeIABomg1t9UTgdLMtWJ0bVsWlKiSe10 NnJF2BjXB3N/xdY9qt5TpsuYKeuaxdar3HA2lolOe9RrK8RwZUOwQF187tnGysEn87Bk uOaVmfU+i/Z8ISPDU28bvG0ZstO4ucvl2f9bgGzKWcnHqKeyjoksmtl+08q5qJCeTfbY s5zjFOuyqc486+ZN1iHrSUqG4LrtSiJ7FK7ZAfqU5Hk9Q9FKZ1WfnNuY6MFUrcaiF9Hg sEFC/gDGr3YkngB/Q0i94jfKufU56b0tS3ZGSpatLNlooXePd0J7LQ9jq7+Viw12cJeD fRhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=pHX3VOrd9+dhkWdPAt0bdVC0sXVQ4HZoZn4NeyyTwiE=; b=DQC4sEdsAAU6QsfvyDUOYg+BO0s4AvwPRpR3telm366pms5oSUbEaNFDMS0E+7MP3W wfArPI/0GI/6HCs/LJo8ZwKIGD50Ff8xQnui9WbgduTEXKQ7CuVrJDh+Htz5HOV9NxQD KzXnmg6eBY+Nog8kTuiSd9XGgXESy1o4QiTkSR5RQGvn2fxooMPJZCDGNHRT5K5dhYO5 SrUOvLXSLjae4xSuOEzrt1zsQGN1P0hLUNqS1VMw22hgQjInkxHc72Y+9/EM2HM0rwLU aaEpZfah/R/2y+ngkxAlTmofR/l1Ze9CLUvNJZDOFyybBTuaDfP0E/J0OZ9JLi9KAe4h KYGg== X-Gm-Message-State: AOAM531aPV61XEpeQ8QOTzJYjjOwKQc3dlFj67ZCmG3/GeAm9SclrhGL zfIwBoEFvypS9prgEf+WgvgMHgAWyL5M2Pd0 X-Received: by 2002:a5d:8d87:: with SMTP id b7mr19325568ioj.46.1621972345794; Tue, 25 May 2021 12:52:25 -0700 (PDT) Received: from [192.168.1.30] ([65.144.74.34]) by smtp.gmail.com with ESMTPSA id j15sm13453063ilc.53.2021.05.25.12.52.25 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 25 May 2021 12:52:25 -0700 (PDT) Subject: Re: [PATCH] io_thread/x86: don't reset 'cs', 'ss', 'ds' and 'es' registers for io_threads To: Olivier Langlois , Linus Torvalds Cc: Stefan Metzmacher , Thomas Gleixner , Andy Lutomirski , Linux Kernel Mailing List , io-uring , the arch/x86 maintainers References: <8735v3ex3h.ffs@nanos.tec.linutronix.de> <8735v3jujv.ffs@nanos.tec.linutronix.de> <12710fda-1732-ee55-9ac1-0df9882aa71b@samba.org> <59ea3b5a-d7b3-b62e-cc83-1f32a83c4ac2@kernel.dk> <17471c9fec18765449ef3a5a4cddc23561b97f52.camel@trillion01.com> <3df541c3-728c-c63d-eaeb-a4c382e01f0b@kernel.dk> <4390e9fb839ebc0581083fc4fa7a82606432c0c0.camel@trillion01.com> From: Jens Axboe Message-ID: <5026f7eb-9cf3-065d-009d-fe0fd3e94c2b@kernel.dk> Date: Tue, 25 May 2021 13:52:24 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/25/21 1:39 PM, Olivier Langlois wrote: > On Fri, 2021-05-21 at 03:31 -0400, Olivier Langlois wrote: >> >> However, I can reproduce it at will with my real program. So as Linus >> has suggested, I'll investigate by searching where the PF_IO_WORKER is >> used. >> >> I'll keep the list updated if I discover something. >> > I think that I am about to stumble into the key to unravel the mystery > of my core dump generation issue. I am going ask you a quick question > and it is very likely to trigger an ahah moment... > > To what value is the task_struct mm field is set to for the io-wkr > threads? > > If I look in the create_io_thread() function, I can see that CLONE_VM > isn't set... It definitely should be, what kernel are you looking at? If CLONE_VM wasn't set, we'd have various issues with requests accessing user mm. -- Jens Axboe