From: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> To: Lars Persson <lars.persson@axis.com> Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Tejun Heo <tj@kernel.org> Subject: [PATCH] dwc_eth_qos: Remove deprecated create_singlethread_workqueue Date: Sat, 16 Jul 2016 13:53:28 +0530 [thread overview] Message-ID: <20160716082328.GA7254@Karyakshetra> (raw) alloc_workqueue replaces deprecated create_singlethread_workqueue(). A dedicated workqueue has been used since the workitem viz lp->txtimeout_reinit is involved in reinitialization if a TX timeout occurs, which is necessary to guarantee forward progress in packet processing. As a network device can be used during memory reclaim, the workqueue needs forward progress guarantee under memory pressure. WQ_MEM_RECLAIM has been set to ensure this. Since there is only a single work item, explicit concurrency limit is unnecessary here. Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> --- drivers/net/ethernet/synopsys/dwc_eth_qos.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/synopsys/dwc_eth_qos.c b/drivers/net/ethernet/synopsys/dwc_eth_qos.c index 158213c..44c4cd6 100644 --- a/drivers/net/ethernet/synopsys/dwc_eth_qos.c +++ b/drivers/net/ethernet/synopsys/dwc_eth_qos.c @@ -2934,7 +2934,8 @@ static int dwceqos_probe(struct platform_device *pdev) (unsigned long)ndev); tasklet_disable(&lp->tx_bdreclaim_tasklet); - lp->txtimeout_handler_wq = create_singlethread_workqueue(DRIVER_NAME); + lp->txtimeout_handler_wq = alloc_workqueue(DRIVER_NAME, + WQ_MEM_RECLAIM, 0); INIT_WORK(&lp->txtimeout_reinit, dwceqos_reinit_for_txtimeout); platform_set_drvdata(pdev, ndev); -- 2.1.4
WARNING: multiple messages have this Message-ID (diff)
From: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> To: Lars Persson <lars.persson@axis.com> Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Tejun Heo <tj@kernel.org> Subject: [PATCH] dwc_eth_qos: Remove deprecated create_singlethread_workqueue Date: Sat, 16 Jul 2016 13:53:28 +0530 [thread overview] Message-ID: <20160716082328.GA7254@Karyakshetra> (raw) alloc_workqueue replaces deprecated create_singlethread_workqueue(). A dedicated workqueue has been used since the workitem viz lp->txtimeout_reinit is involved in reinitialization if a TX timeout occurs, which is necessary to guarantee forward progress in packet processing. As a network device can be used during memory reclaim, the workqueue needs forward progress guarantee under memory pressure. WQ_MEM_RECLAIM has been set to ensure this. Since there is only a single work item, explicit concurrency limit is unnecessary here. Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> --- drivers/net/ethernet/synopsys/dwc_eth_qos.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/synopsys/dwc_eth_qos.c b/drivers/net/ethernet/synopsys/dwc_eth_qos.c index 158213c..44c4cd6 100644 --- a/drivers/net/ethernet/synopsys/dwc_eth_qos.c +++ b/drivers/net/ethernet/synopsys/dwc_eth_qos.c @@ -2934,7 +2934,8 @@ static int dwceqos_probe(struct platform_device *pdev) (unsigned long)ndev); tasklet_disable(&lp->tx_bdreclaim_tasklet); - lp->txtimeout_handler_wq = create_singlethread_workqueue(DRIVER_NAME); + lp->txtimeout_handler_wq = alloc_workqueue(DRIVER_NAME, + WQ_MEM_RECLAIM, 0); INIT_WORK(&lp->txtimeout_reinit, dwceqos_reinit_for_txtimeout); platform_set_drvdata(pdev, ndev);
next reply other threads:[~2016-07-16 8:23 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2016-07-16 8:23 Bhaktipriya Shridhar [this message] 2016-07-16 8:23 ` [PATCH] dwc_eth_qos: Remove deprecated create_singlethread_workqueue Bhaktipriya Shridhar 2016-07-18 5:27 ` David Miller
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20160716082328.GA7254@Karyakshetra \ --to=bhaktipriya96@gmail.com \ --cc=lars.persson@axis.com \ --cc=linux-kernel@vger.kernel.org \ --cc=netdev@vger.kernel.org \ --cc=tj@kernel.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.