Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2638719pxa; Mon, 17 Aug 2020 15:09:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwf+uJpJwR2gki4UR6YsVVhdownMv+DnfecjIf0pjR+G5ga/dA4ZiYqWOckciTJxR8hLvqg X-Received: by 2002:a17:906:c1d7:: with SMTP id bw23mr17973314ejb.315.1597702184217; Mon, 17 Aug 2020 15:09:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597702184; cv=none; d=google.com; s=arc-20160816; b=oBj471slF57sFwJt0YCltfZkQ/yzN65b4hqq0SJsweWcO6NBgpozfhBffp46NUOD/Y 5SF5P5tnVtX/mANs1GhCHc0aB1QLZzjnRIYkoCRvfysEgPVsZjLKzVC0Ek2+6qcIisAd XWA02W6mC03GqDjk8+Lg8QemVYShgTtnH26GRo18ZvwER2FVU4f45F7laQVbU9pN0url ldSE6qLMPJ1zo6Y2wToUV8He5wa4mZHux52r8fTr2pngBoN/PPK+lLutx7jOWV/K+0/N 9F6HQTlTC2Zk5W4jT3gnAml35jrHjmVsGZEKW3lc3NBKXGD74x8zfTHuCMy8YyubTZPT qbyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=1h0FuFKrCMOQAT4CZkGtuj0qPsjlDsPX5mJBxxuqDto=; b=0opzt5g00X3P5TBDmQ4zpqQLjKISkD7MH4R0EjcE0lLQ0dCf4QhB8hBUBWmeP4qL6o BST6xRPz541YPF/p/aWZWOtIw+TXzOC9mElxErEQ/1ZmEysGiOTqKW7Et+Vi6FWHvKb8 Lv3sj4xJVhXvBLAqOd5gDv9/jpvhuNAJaz7+hCX0px6U5K60TmUV7Cq3GKF/9xw2IiT4 wBfSItWp9ixK90hEL+bsfx9ej2H2kye3IAiYKY5BMQ8IDfJeh+l7m754wtnlCGw4Azg8 gV/14z9tLmm8GvbLsS81G+lntpMlEy8xHevKWIVhSKUDDioBSOYdmEFdJ0x3KT7VzBPc fsKw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=WkG5IOQ5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w10si8817730edl.122.2020.08.17.15.09.20; Mon, 17 Aug 2020 15:09:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=WkG5IOQ5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730834AbgHQQ2h (ORCPT + 99 others); Mon, 17 Aug 2020 12:28:37 -0400 Received: from mail.kernel.org ([198.145.29.99]:38744 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387858AbgHQPwe (ORCPT ); Mon, 17 Aug 2020 11:52:34 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 4A4B32063A; Mon, 17 Aug 2020 15:52:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597679553; bh=OICnLkXlVe5P+5n/vyf978ebwQib89u725aBI8qOb9s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WkG5IOQ5m4bdCIdSFAPFn+ZcZjbuF4PZV1kgaOznT+eO2gMvyZ1Elzzjy3oNJdvBb +5A4fcIUctEKvJlWtEIYvih4l94/GQwiPdYg5kBJ5bVyxNPewNeWP15tBa1/EA5ICk 2rGnx/wCZyY7K9g8QtjCazZTRnhQZhZ9JSdp3IZE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hauke Mehrtens , Mark Brown , Sasha Levin Subject: [PATCH 5.7 223/393] spi: lantiq-ssc: Fix warning by using WQ_MEM_RECLAIM Date: Mon, 17 Aug 2020 17:14:33 +0200 Message-Id: <20200817143830.440172053@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200817143819.579311991@linuxfoundation.org> References: <20200817143819.579311991@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hauke Mehrtens [ Upstream commit ba3548cf29616b58c93bbaffc3d636898d009858 ] The lantiq-ssc driver uses internally an own workqueue to wait till the data is not only written out of the FIFO but really written to the wire. This workqueue is flushed while the SPI subsystem is working in some other system workqueue. The system workqueue is marked as WQ_MEM_RECLAIM, but the workqueue in the lantiq-ssc driver does not use WQ_MEM_RECLAIM for now. Add this flag too to prevent this warning. This fixes the following warning: [ 2.975956] WARNING: CPU: 1 PID: 17 at kernel/workqueue.c:2614 check_flush_dependency+0x168/0x184 [ 2.984752] workqueue: WQ_MEM_RECLAIM kblockd:blk_mq_run_work_fn is flushing !WQ_MEM_RECLAIM 1e100800.spi:0x0 Fixes: 891b7c5fbf61 ("mtd_blkdevs: convert to blk-mq") Signed-off-by: Hauke Mehrtens Link: https://lore.kernel.org/r/20200717215648.20522-1-hauke@hauke-m.de Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- drivers/spi/spi-lantiq-ssc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-lantiq-ssc.c b/drivers/spi/spi-lantiq-ssc.c index 44600fb71c484..049a64451c750 100644 --- a/drivers/spi/spi-lantiq-ssc.c +++ b/drivers/spi/spi-lantiq-ssc.c @@ -909,7 +909,7 @@ static int lantiq_ssc_probe(struct platform_device *pdev) master->bits_per_word_mask = SPI_BPW_RANGE_MASK(2, 8) | SPI_BPW_MASK(16) | SPI_BPW_MASK(32); - spi->wq = alloc_ordered_workqueue(dev_name(dev), 0); + spi->wq = alloc_ordered_workqueue(dev_name(dev), WQ_MEM_RECLAIM); if (!spi->wq) { err = -ENOMEM; goto err_clk_put; -- 2.25.1