Received: by 10.223.148.5 with SMTP id 5csp6447503wrq; Wed, 17 Jan 2018 13:58:54 -0800 (PST) X-Google-Smtp-Source: ACJfBot6EX8wrQjZcpqkscKoZBK7vL+RpuVBPjkDLp2/0MBov0JzLtyvpOloM9fmqV8Muc9tOoCo X-Received: by 10.99.42.83 with SMTP id q80mr33946780pgq.183.1516226334364; Wed, 17 Jan 2018 13:58:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516226334; cv=none; d=google.com; s=arc-20160816; b=HEc1QMynxKt22NTSLjXnpF62CNxthPhc3yKNvPhVHKFLZacguV7eyPWb/pd9olLvdq 74cmct2vc37Q7c4Ut423o54h4uZQ5U5eBIJEGnUOATAMJf8v3/5obpLExn0Ur1YWSkbq mCRxRArCIAxKM1U5Y87BsQyOUoAmIn/aMUv8pP1A/2nLHECExvArCxNyyFQAuAdxmHVk tN5MNeakdHFo6OGFFt/t8DOrEqOaSb++W6RdTbnTSGLINtn/Xg/u3f/29CsiJM91O+Fq qLwYPd1tPCE87l1XpPBjPy4fyKY916XRRBRoD90EiE+9DlkbPhcPero+h/mUVCrmazwZ yF5A== 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 :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=Xq0dGOA3l+sq9jgSGNyUiCRWP4DCFAO2xmVMfzBCgKE=; b=lb5hSC+T4NrK+6ZFLCbEjef0jsjbd/nNpC5ZUDybvNTzfH4EJJMWuNT3U1wMDkjjZN sc+y/stAUCGrexPYnKQKkZR8+cIiknwm9EEbH/qhBkA83uTENPJx8f14TFpn6zz5FWZm edxuVBhV+E0RhTB+vBJdEbE+uhUKbDBJcrNFVlnTW82ETQyD4tD05RiVhY5Z2zOdaf10 1CUaAjnAjoE47NM/OxE9Byba9i6w3qvifm5BNrRnKchfsdzJXonEeSjhjkfAmme0x1Sh rHkHCTYsO1OyP8ejb5M9KpfZa0PAMVgVAfq/zE4C0TnO29IPuPkb1wn+U317btG24nOC HITA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=CZVi2MZk; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q4si5103236plr.112.2018.01.17.13.58.39; Wed, 17 Jan 2018 13:58:54 -0800 (PST) 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=fail header.i=@gmail.com header.s=20161025 header.b=CZVi2MZk; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753301AbeAQV6N (ORCPT + 99 others); Wed, 17 Jan 2018 16:58:13 -0500 Received: from mail-io0-f193.google.com ([209.85.223.193]:36483 "EHLO mail-io0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750931AbeAQV6M (ORCPT ); Wed, 17 Jan 2018 16:58:12 -0500 Received: by mail-io0-f193.google.com with SMTP id l17so12669339ioc.3 for ; Wed, 17 Jan 2018 13:58:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=Xq0dGOA3l+sq9jgSGNyUiCRWP4DCFAO2xmVMfzBCgKE=; b=CZVi2MZk1bVpz5BtjmqvRF5cG+37vBDT8FkeipwOcatiwiUYdzByIr76+nGQDn86Aa jGTjw6ffoRAmoXTGcrTCCQLsd+OQFiXCaxiVBeTI7NIkeQo51c1tIhVZ/xWG8qnADGVc qk5lxqmEUdXAZzxwlVoNBB/d4Ue6uEVGWM0QFyTTKcW//8C2pvioMRzmpRYJF1Wj0KV/ N4XQfhK8Hblx9jEFXOcEns59oi82/stjiOGDjoslgABLA7xmmm6nIq6Q/i8SWTuZ0FIk vqKedskLO0u8bybYjAT2P0WVTzc0YYkapG0FwN2Tonl5pE+zpRh7SszQcvgtnpFn9BDT Ug7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=Xq0dGOA3l+sq9jgSGNyUiCRWP4DCFAO2xmVMfzBCgKE=; b=r88VB4IyPczJtEjdsXtoQxf8sOtVYHKyLy4zQ4KEYglNTQT7PzdFJPDWGJ270I6O8M brFMjcZxwcwW9LOD2+sRzmfkhfRewos7yQj2yzXOPA9PbPimEWYKVUH4kyonv2OR07/0 Y4TX1EYHAYGf5i1vZAzUsg8x/7HOKpmkCKiR3vQAAOi/bfOOPY+eEm/Z/g8aXQk7e8UD H7irlaaHIV5Ap0RbPhMn1K4aYMFszF4nu0AH/GK+qIPPksC+IMtZSpz1Kiu/iphJTkpD EqPIr7IKIG0Pdms/yoteuFBFEd1YCdSmHigYqakmzqAe7NQ1SWVBFbLQoUSV/5apEVjs oe3Q== X-Gm-Message-State: AKwxyte0nm35KGWv1cfP6pAGtAygw4Qj7xK3iQsCJZ3FK1XTGjDUPfsg reOC9vAzf4Ik3LdBQqeRrYWRTBEYe1w8gagDCp8= X-Received: by 10.107.132.3 with SMTP id g3mr27985221iod.46.1516226291892; Wed, 17 Jan 2018 13:58:11 -0800 (PST) MIME-Version: 1.0 Received: by 10.107.6.147 with HTTP; Wed, 17 Jan 2018 13:58:10 -0800 (PST) In-Reply-To: References: <1515782670.7007.3.camel@gmx.de> <20180117.153049.1803664333084879932.davem@davemloft.net> <20180117.164932.1269304606476934540.davem@davemloft.net> From: Linus Torvalds Date: Wed, 17 Jan 2018 13:58:10 -0800 X-Google-Sender-Auth: vQL-8zKCGI6LKHk2GPgeIJMD9sk Message-ID: Subject: Re: [RFC 1/2] softirq: Defer net rx/tx processing to ksoftirqd context To: Thomas Gleixner Cc: David Miller , Mike Galbraith , Peter Zijlstra , Eric Dumazet , Dmitry Safonov , Frederic Weisbecker , Linux Kernel Mailing List , Dmitry Safonov <0x7f454c46@gmail.com>, Andrew Morton , Frederic Weisbecker , Hannes Frederic Sowa , Ingo Molnar , Sasha Levin , Paolo Abeni , Paul McKenney , Radu Rendec , Rik van Riel , Stanislaw Gruszka , Wanpeng Li 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 Wed, Jan 17, 2018 at 1:54 PM, Thomas Gleixner wrote: > raise_softirq() -> raise_softirq_irqoff() > > set_softirq_bit(); > > if (!in_interrupt()) > wake_softirqd(); > > So if the caller is not in hard or soft interrupt context, which includes > bottom half disabled regions softirqd is woken. That does seem unnecessarily expensive, and maybe we could just do it with thread flag (TIF_NOTIFY_RESUME or whatever). In fact, that was what I *thought* we did. Maybe I just remember some historical behavior. Since networking seems to largely prefer softirqd anyway, maybe that wake_softirqd() is the right thing to do anyway. Linus