From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C51E1387352 for ; Tue, 13 Jan 2026 09:09:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768295386; cv=none; b=TYkQMhTbwTOQmKe5o8aequ7y0BHc4NXa98D7gOcn6TLI/xikmQwZublRz+ivp5ODYT0giV1T27UWMei2eH/uz0ZFZC1Ffn/FS+p1SiNg9AjdXQeqGpa9Pq2rH9liEzYJyTZhNBKGG0hKD9Am2SNjz1o/vbtOzB9Ulzrg080S/xA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768295386; c=relaxed/simple; bh=McfIPn7PVhaggDFGHXD8Dk3EzbaBa42G8Yzwa0ncmV4=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=TrjdQCNK/RXzgsUC37fpCbMmMzlMa+K1odSzED4j1lW4f98pYJ5UnHXRUaqVNi8nSvdB7uyd0u/gX/xucBxy1omJtE9FMaruBCj3wDCFWP7OnfB7QcGsOVPriwheX8W2hePQcufDWo0a4ZtdRO/e+wSR71jCQEu1vX31y1wceh8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Qng1120a; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Qng1120a" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A0055C19422; Tue, 13 Jan 2026 09:09:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1768295386; bh=McfIPn7PVhaggDFGHXD8Dk3EzbaBa42G8Yzwa0ncmV4=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=Qng1120akvEEfwvIiScsqOAjDR751ylZ6AT5d07AuIpf+nQPJ91mQ5WAtvGHVyAD4 Vmg14Er5YUmTup6HsIbuq2avwPy/RWSffWIG8elED/CZXBPIzcYP5HT2aE2rnb4SU1 Hptjje7u4mKUTQ//R5krWy3mWC5EYxSY0TwvXr2R03O638I+L/Zeih1EgEc7Luq/Ig YC5UxXmXXsCa6FYs9zoU16k12QT1fhzkxUS8+aLjhbRMkzKppW2GVfpO9QTeyq0cD0 boi85G3FMohGaRrBLrM07ai/w/LhZ5Wse2v48Ru/TgNL8gmqV/6VkcuOYw2xawaB2O TvP+PpP4nl2DQ== From: Thomas Gleixner To: Eric Dumazet , Luigi Rizzo Cc: maz@kernel.org, rizzo.unipi@gmail.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] genirq: move clear of kstat_irqs to free_desc() In-Reply-To: References: <20260112083234.2665832-1-lrizzo@google.com> Date: Tue, 13 Jan 2026 10:09:42 +0100 Message-ID: <874iopg9pl.ffs@tglx> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain On Mon, Jan 12 2026 at 21:18, Eric Dumazet wrote: >> - scoped_guard(raw_spinlock_irqsave, &desc->lock) >> + scoped_guard(raw_spinlock_irqsave, &desc->lock) { >> desc_set_defaults(irq, desc, irq_desc_get_node(desc), NULL, NULL); >> + for_each_possible_cpu(cpu) >> + *per_cpu_ptr(desc->kstat_irqs, cpu) = (struct irqstat) { }; >> + } > > > It seems that for_each_possible_cpu(cpu) could be done outside of the > desc->lock protection. > > This would shorten hard-irq blocking by N cache line misses. Right, though it really does not matter unless you deeply care about: alpha, arc, hexagon, m68k, mips, parisc, sparc, xtensa and random old ARM32 platforms :)