Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp571702rwb; Fri, 7 Oct 2022 00:45:40 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4BYlmusSKOMWkkLjq/O5bR86AnJKOWX4IfMYEGgbSwyOwjdcwQLjOgs5mqt3GTf/ki1AyM X-Received: by 2002:a17:906:58ca:b0:78d:7d3:e5e7 with SMTP id e10-20020a17090658ca00b0078d07d3e5e7mr3006366ejs.159.1665128740510; Fri, 07 Oct 2022 00:45:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665128740; cv=none; d=google.com; s=arc-20160816; b=nRzsaJZ6jiY0MShEH0ECro8EPd5WnUmhGOKDcAsSYxmJ3VMoBTq4uCSlbpq0/FOiXa D11IyYHBn2AntxfFhr8hp2WP3R4c+bEnma7eDmK7OlCnyV/KvvQzJO4m0P+h3OKkagv4 7r5Uc6JOsN28W7ATk+VgghueyburgOmH3zL/OY83iz01UiSLsGFI43a5E4eH1fDNDgoW bVGF/wntjnPrS13x4iB4by/KQxBRaTCUZbazvxqlKjdO02XpTrd+K0ge1cdgC272VlRd J9i/6/hTHMe2n9uN8W7i9Z0BgcvJlUb65BTz7o6RQdc4WV2PYxFrIF8XmjHEGPm4/jTh r9Dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:dkim-signature :dkim-signature:date; bh=lm+zJyR+J0G7xaOdlpm9edaU2VI7rEYfISYTe41x2PI=; b=G8NDGeOCBfIQK4RvsqFltKiCNfxWfamAdcLKQ1BoG88OaNVcm7LqzvtJlDBR0twaMF yKbzb4inc8bbBR7zfLUJYvRG2PDkVgn6YQ+Q+mWzx/E0zr+6Bu2nGHpCBW7GqcW4zI+v AWTQ9cwT4pcOmZtmg+aO/WcwIjBtuykSHiB8dcC3Xvji/YAPulmZqnzylpcRdxaTCZmW IjgAK3K9CTIeQzutLlLOfQrD9tK2V2mr55ZC9qiAGYZ+nv4uj3Fv/5eDODmS8hd3BQGr 8AupeghcTBKZbeKA/uL+/JoPVXnWoOmJ5RKwygNhkL4N77VYzDJWUcxLoqG81XIAH1xd fQ5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=1+2khprD; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=VYPDss3M; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id js14-20020a17090797ce00b00787b9cd2fedsi1914623ejc.875.2022.10.07.00.45.05; Fri, 07 Oct 2022 00:45:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=1+2khprD; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=VYPDss3M; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229890AbiJGH32 (ORCPT + 99 others); Fri, 7 Oct 2022 03:29:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34310 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229672AbiJGH31 (ORCPT ); Fri, 7 Oct 2022 03:29:27 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DDB99A8CC5; Fri, 7 Oct 2022 00:29:26 -0700 (PDT) Date: Fri, 7 Oct 2022 09:29:23 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1665127764; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=lm+zJyR+J0G7xaOdlpm9edaU2VI7rEYfISYTe41x2PI=; b=1+2khprDTIdzHGT8gt5NhRut+zyzZ8CxhkV/oPv1dk8sj+Vpvf1NpGTbi3vStdqKfJNyC2 H6I25/mr3cEs/pVduMdjjGX6P9xCHCu9slxeyI330aXwozBAsawDeZXwf3puTOOvSRfTeB AdnjgkQibDQLCveE5/FN9ai3SxCimFq+pcHvUdGNqJFquccW0CE2ijMh+qxgIaSvm6D/QB K6cW+coCp+zD28NjSprpOdGoCJI/Uf7pFwxoBH/uB1tq4jLleSaVG/JswoI2AtizwMqnuh ttAn3hrwDeDAjFBynQyfaDMh7q47owBSMA9Hc9LS8d7EOsWXl6RhQbiGmCxwAg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1665127764; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=lm+zJyR+J0G7xaOdlpm9edaU2VI7rEYfISYTe41x2PI=; b=VYPDss3M7TloK6FZDiEAotco6oYekfafspRvFm0VQJ98qrcYv7Q4TxpNt0kbx76i7zUrXP RLxZ9QcIG9GZpyAA== From: Sebastian Andrzej Siewior To: Sultan Alsawaf Cc: "Jason A. Donenfeld" , linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org, Dominik Brodowski Subject: Re: [PATCH 2/2] random: spread out jitter callback to different CPUs Message-ID: References: <20220930231050.749824-1-Jason@zx2c4.com> <20220930231050.749824-2-Jason@zx2c4.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On 2022-10-06 09:39:46 [-0700], Sultan Alsawaf wrote: > Hi Sebastian, Hi Sultan, > But since a timer is marked as not-pending prior to when it runs, add_timer_on() > can't detect if the timer is actively running; the above BUG_ON() won't be > tripped. So the UaF scenario I forsee is that doing this: > add_timer_on(timer, 0); > // timer is actively running on CPU0, timer is no longer pending > add_timer_on(timer, 1); // changes timer base, won't wait for timer to stop > del_timer_sync(timer); // only checks CPU1 timer base for the running timer /me taking notes. > Sultan Sebastian