Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp7662456ybi; Tue, 9 Jul 2019 02:15:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqyzn8c9ErbHGwXEEN3YSdWlti2pffuSwQJyPBXJk9+m2BSSlH744m857TP0lYU+lXvMhEYa X-Received: by 2002:a63:5964:: with SMTP id j36mr28837291pgm.428.1562663757430; Tue, 09 Jul 2019 02:15:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562663757; cv=none; d=google.com; s=arc-20160816; b=asF/QNmOZCP3DvLy3adjEgKQ3Q43lSIPYTDSPuVJ0gU8DHbBDpQPMBwLuUm8UT8zNa EYf00s7rFgQypJpyCn54ugEN12nrHGOYO5bGF5r2RDiL4UruhlB/I9gvH/p+S8z1orZ7 A1hD5TzBBqAuCFZ0eUsRXL9xT8RfrmH/+0JTPhVlpZYv9GqaaMxiW0lE3yR1mc/+ngtm OYEZlBlmZhRsfRYktjaE6GZfu/ulXFu1bI5pDzuxFl+G6y1oCQvWABN3uP54NjT0+LgC AvJwKrodVJbfC5xK8Vv19+6bL5nF5RwI39nM0YSwG0OrwsTPHd7MCrmHGkOo6QJcLg6s 14iw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=9LTtPPOn4Ak8eK9FW8AabXZcBEJh0Lnb8xIdmS0/IJU=; b=SPmbvK7W1iQAk/Fbrh8azgKqPfyd3ti7CGe523PibMEhNH89nNDKFV2frbPZKGebzl 40c3s5R9BKRd6C2TcPKh95kZxoRGXMXMXCxHBsJDbsMTWXXY4v0K6HOfQsBi1QwTkYDM hw5MdFmZe3C27k7vkglhhynQFJhvrgC41KtxXpsc05Hbn+hz0qFpiHvFh9I8gglh0Uq+ M4nQ9t555T03HBFpfGeacp7J8XqIj+8kowMLbj0SIgRYOGYtimrq5/rmZSmEbed+aIei DI+c4O5fiuYpMFsiiwiExb9OxEoEn0nFnGhKCxgLCzwJ4fu+NSzaG47RaMb+vq5fBI26 z31A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=QpsAKtUK; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x13si12195877plr.111.2019.07.09.02.15.40; Tue, 09 Jul 2019 02:15:57 -0700 (PDT) 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; dkim=pass header.i=@linaro.org header.s=google header.b=QpsAKtUK; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726565AbfGIJLa (ORCPT + 99 others); Tue, 9 Jul 2019 05:11:30 -0400 Received: from mail-lj1-f193.google.com ([209.85.208.193]:40792 "EHLO mail-lj1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726525AbfGIJLa (ORCPT ); Tue, 9 Jul 2019 05:11:30 -0400 Received: by mail-lj1-f193.google.com with SMTP id m8so9328342lji.7 for ; Tue, 09 Jul 2019 02:11:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=9LTtPPOn4Ak8eK9FW8AabXZcBEJh0Lnb8xIdmS0/IJU=; b=QpsAKtUKi/9eTxa+EeMW6C9efPOxUkmSK+eftMzIKmxy/utKmzJkDuPGkCNljZhsc5 7iGyYTINlQH1eyfo1fjveiJ4DUGoW55nFZnlng1tG8AIyVg2vFN0ut9eN0lBIMq1EkE5 f++VbpJFM+hwEokcwO+WXfLlCQwI9IaiH3l1EKg0RMDB27aXHmOLIUwRPhlh6FZ3KSnm qSa1D99CUlPAR/fI5sejfEI19alRwKz0FrBuodUW1DWIJEu95TRxrWHXgnLm9HGrVJ1q BQZX54uMeqpe7Fe0u9LObF19YHlaNubRtH+zSJfn1UwBuWYpB+mxCouPVukEYPIuEhFj 14Nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=9LTtPPOn4Ak8eK9FW8AabXZcBEJh0Lnb8xIdmS0/IJU=; b=UsGpeprMmCOy/144ieQPss7nGyiVnpaExpzkRFUG2Y8OUoBoi/qYEkLQJIjJamvELD i6FvR5SA9NrzzvoJhczRlsz7aQQHvG7ApmgJ7ubN4YKI0IEPCN2MhzxlmjhXqh41TSBP PUb2G4p34EkhBq5ILvVJIwmfHjKpymylkFHDklOJ/fTqi1jZADvDlRHke7RjnWGC9VDz 51nmfWSHxkwUz1AVUeTZvsNe70HgzlI8AcvVOgg+ZlTtBmhtGD0l99spOSUFmv3yc9C2 1bS8yKgidN4GwPYdv0fOuh8yESQZw61N5Ge0+JckIaTr7XuDwkfdDMvlxhgOKMnKMpRH CBvw== X-Gm-Message-State: APjAAAUHhM6+vsUYr/T0WLIA0m9+/zowHgHy+pRVTu4UdeI/gjV+cucl iIavtoydqRRrgbJ90xi2npyG3oeBW5kEs+J6/KnUeg== X-Received: by 2002:a2e:9593:: with SMTP id w19mr10055087ljh.69.1562663488615; Tue, 09 Jul 2019 02:11:28 -0700 (PDT) MIME-Version: 1.0 References: <1561671168-29896-1-git-send-email-opendmb@gmail.com> In-Reply-To: <1561671168-29896-1-git-send-email-opendmb@gmail.com> From: Linus Walleij Date: Tue, 9 Jul 2019 11:11:16 +0200 Message-ID: Subject: Re: [PATCH] ARM: mm: only adjust sections of valid mm structures To: Doug Berger Cc: Linux ARM , Russell King , Laura Abbott , Mike Rapoport , Andrew Morton , Florian Fainelli , Rob Herring , "Steven Rostedt (VMware)" , Peng Fan , Geert Uytterhoeven , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 27, 2019 at 11:33 PM Doug Berger wrote: > A timing hazard exists when an early fork/exec thread begins > exiting and sets its mm pointer to NULL while a separate core > tries to update the section information. > > This commit ensures that the mm pointer is not NULL before > setting its section parameters. The arguments provided by > commit 11ce4b33aedc ("ARM: 8672/1: mm: remove tasklist locking > from update_sections_early()") are equally valid for not > requiring grabbing the task_lock around this check. > > Fixes: 08925c2f124f ("ARM: 8464/1: Update all mm structures with section adjustments") > Signed-off-by: Doug Berger Cc: stable@vger.kernel.org ? I'm not smart enough to say whether it is the right solution, but I also want to test this on some boards I have. I suspect this may be part of the problem I have with mounting root on a USB stick on some early mpcore machines, so I might come back with a Tested-by. Yours, Linus Walleij