Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4601724yba; Tue, 30 Apr 2019 00:52:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqw19wUm33cBvQlnVHwufQkAO4M5krbSWtWJDvxL7SyM3Yi8dclSFoxDMNH++UgN/OkwAaSq X-Received: by 2002:a63:d709:: with SMTP id d9mr22566814pgg.38.1556610741370; Tue, 30 Apr 2019 00:52:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556610741; cv=none; d=google.com; s=arc-20160816; b=Hdcwgxwj/ChJxPumqdUKmoGpON+8DZX7HCRK8X5xMYkFMSXdVsu1cATJqL+mpwL9O3 ktCMa2btLyp890OJpsmMrr+edQixyfLq3D2uspuCpfSnJJjWVdmy6Dd5JEPHFZzbtVHJ IxeRJP04r3CDzA5fLYnteegAMMt0OEuuUcEPC9oAsGBfq+B1GFLkI3I0hVOuko6jsTwp trAfLto1z/uVc27CuLZdKyL+AFxEvnNx0FXQW5h2e/jheiVyM93VBKUz+hm7sGMEai/d Wl6PlgV527dtrRpOBR7z68d1ho5eh9xwaAILaFa8ELmCt4ZD5xPW5vUQF1g/eDt+SyFI 6Muw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=cmzEYzPzyEaLWlhrGQhxtbXIu4Cu7TGGUT6+bsN8HQ8=; b=KocoVtoBxNGUDdkUDA/3AExhj3A3G5AuWoS06f+4K9Mnj9ZEpNMaqfRMa8iZguj4MB 1VaFbXNE8jE1CPgqty7qPIoB90b1PpaxETGB2haouBBiahzBOwxrVn5YapiBwGgAJ+2I mqO/bwyuheh9J4j43mj6uvekioL72S0TQXjrgMH/TdrbhUnibOsDvWKMl/QPXaK5w/kO 0HiS/uE2xHi8zsmKHGlQqSS/iEed8TnaPaLtjqpkW+b8/FvD2EZBJeSDm7vFTQIcfxpu dQ8Hsmy5MS8WSxPhq124u2UEDzZfsPp8EiZuWYGtnU0dDu/IIrSH56FqyWl0DwMmApuB tDOg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="Gxo8Wm/J"; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q4si35705123plr.376.2019.04.30.00.52.05; Tue, 30 Apr 2019 00:52:21 -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=@kernel.org header.s=default header.b="Gxo8Wm/J"; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726437AbfD3HvN (ORCPT + 99 others); Tue, 30 Apr 2019 03:51:13 -0400 Received: from mail.kernel.org ([198.145.29.99]:38408 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725554AbfD3HvN (ORCPT ); Tue, 30 Apr 2019 03:51:13 -0400 Received: from linux-8ccs (unknown [95.90.219.244]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9C79A20835; Tue, 30 Apr 2019 07:51:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1556610672; bh=wYko4k9enIB2pNsP3VANKP6hvZL2c+kCSOeRtqgooLo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Gxo8Wm/J96X+SHMnvlPUQIYI2PGgm6KIqsSkwYVCShxR19EYl2X0HZ41dCILHMzcE Ok8hJ9c7TMkZaGOc6f2QaBWRhn1+GTJ7jq7hXCLA0gayxL4rNuOVrCz/0KSvFQIZUB d8H/0wEJ1BOWK85h0zh6yYocojLO0Ft5y0e/jdok= Date: Tue, 30 Apr 2019 09:51:08 +0200 From: Jessica Yu To: Prarit Bhargava Cc: Heiko Carstens , linux-kernel@vger.kernel.org Subject: Re: [PATCH] kernel/module: Reschedule while waiting for modules to finish loading Message-ID: <20190430075108.GA21092@linux-8ccs> References: <20190429151751.15424-1-prarit@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20190429151751.15424-1-prarit@redhat.com> X-OS: Linux linux-8ccs 5.1.0-rc1-lp150.12.28-default+ x86_64 User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org +++ Prarit Bhargava [29/04/19 11:17 -0400]: >Heiko, do you want a Signed-off-by or a Reported-by? Either one works >for me. > >P. I think you forgot to CC Heiko :) >----8<---- > >On a s390 z14 LAR with 2 cpus about stalls about 3% of the time while >loading the s390_trng.ko module. > >Add a reschedule point to the loop that waits for modules to complete >loading. > >Reported-by: Heiko Carstens >Fixes: linux-next commit f9a75c1d717f ("modules: Only return -EEXIST for modules that have finished loading") >Signed-off-by: Prarit Bhargava >Cc: Jessica Yu >--- > kernel/module.c | 1 + > 1 file changed, 1 insertion(+) > >diff --git a/kernel/module.c b/kernel/module.c >index 410eeb7e4f1d..48748cfec991 100644 >--- a/kernel/module.c >+++ b/kernel/module.c >@@ -3585,6 +3585,7 @@ static int add_unformed_module(struct module *mod) > finished_loading(mod->name)); > if (err) > goto out_unlocked; >+ cond_resched(); > goto again; > } > err = -EEXIST; >-- >2.18.1 >