From patchwork Thu Oct 26 12:57:50 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 10028093 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 700CC6022E for ; Thu, 26 Oct 2017 12:58:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 61F6028DCD for ; Thu, 26 Oct 2017 12:58:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 56D3928DEB; Thu, 26 Oct 2017 12:58:39 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DB1CA28DF5 for ; Thu, 26 Oct 2017 12:58:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932382AbdJZM6i (ORCPT ); Thu, 26 Oct 2017 08:58:38 -0400 Received: from mail-lf0-f68.google.com ([209.85.215.68]:49442 "EHLO mail-lf0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932338AbdJZM6h (ORCPT ); Thu, 26 Oct 2017 08:58:37 -0400 Received: by mail-lf0-f68.google.com with SMTP id w21so3650713lfc.6 for ; Thu, 26 Oct 2017 05:58:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=pN3xD0hLaqyNwDuq0bcQB0UpjXhSz2HKmvoWz/RIWfY=; b=BFNp9M/ULjQD3zajZLYGqTFep6Ja4lJsnEUy1I4SZcHlHAcTI/2Qr233PhGzVof324 7MlsA2ZVBmpO5qrTcVv+E6tDxNRiVTxJ2LDoB0cMHQ5bQTD/S/zKXNzThoG5WB7/zvg/ YbtkdDUA/Y/VQr8ebziceUt0yiC4M8kPaYAX4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=pN3xD0hLaqyNwDuq0bcQB0UpjXhSz2HKmvoWz/RIWfY=; b=csTgrUzFh8X048xXp1jdQgbU7ECk6sCevMjSUDbUNpgtUAqk6YL5h7uWLbBLatJqup BN4eyIIMR7/QyWf13fHEuS9gFIZLCDg+rA+w2H0c/3v95CM19VnCiifrDD3sO1I9Si7O Mt6evIUajZiRvIJSeuMSfdpy+dQqoTUas9EkrJGa+bAm+ayw4vM6mY/rJ0Bor/CTTpKY LNCAs9aIkyQhOQKtZTAQ4nBfsAmCseie1J8KdXiQE4zi1vs4zmNhz/Titg+P94z8hmDu /Gr4tmxGtqNpUeSEeM1UQyQw5ZTKll6d3Mpazo/g3rgZxEgp+GR6Sw6cv/0/W4lYzwvV osVA== X-Gm-Message-State: AMCzsaWNSb5vhRU3VRIhAsbuq//5TIg4/bBQarlqIqzw9/qG+GdDVxms TPTw9t4o3hIn3cLnaI9BDl14tYptv/k= X-Google-Smtp-Source: ABhQp+QN2vM6ZvqvnixJjvYCeiLE0fFey8eCJMHuaS1xgvx0nMce2W91bs5gc9fWiMYehxd2yA+nRg== X-Received: by 10.25.195.88 with SMTP id t85mr8026720lff.214.1509022715598; Thu, 26 Oct 2017 05:58:35 -0700 (PDT) Received: from genomnajs.ideon.se ([85.235.10.227]) by smtp.gmail.com with ESMTPSA id 34sm1165600lfr.25.2017.10.26.05.58.34 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 26 Oct 2017 05:58:34 -0700 (PDT) From: Linus Walleij To: linux-mmc@vger.kernel.org, Ulf Hansson Cc: linux-block@vger.kernel.org, Jens Axboe , Christoph Hellwig , Arnd Bergmann , Bartlomiej Zolnierkiewicz , Paolo Valente , Avri Altman , Adrian Hunter , Linus Walleij Subject: [PATCH 05/12 v4] mmc: core: do away with is_new_req Date: Thu, 26 Oct 2017 14:57:50 +0200 Message-Id: <20171026125757.10200-6-linus.walleij@linaro.org> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20171026125757.10200-1-linus.walleij@linaro.org> References: <20171026125757.10200-1-linus.walleij@linaro.org> Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The host context member "is_new_req" is only assigned values, never checked. Delete it. Signed-off-by: Linus Walleij --- drivers/mmc/core/core.c | 1 - drivers/mmc/core/queue.c | 5 ----- include/linux/mmc/host.h | 2 -- 3 files changed, 8 deletions(-) diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index 68125360a078..ad832317f25b 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -2997,7 +2997,6 @@ void mmc_unregister_pm_notifier(struct mmc_host *host) */ void mmc_init_context_info(struct mmc_host *host) { - host->context_info.is_new_req = false; host->context_info.is_waiting_last_req = false; } diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c index c46be4402803..4a0752ef6154 100644 --- a/drivers/mmc/core/queue.c +++ b/drivers/mmc/core/queue.c @@ -55,7 +55,6 @@ static int mmc_queue_thread(void *d) req = blk_fetch_request(q); mq->asleep = false; cntx->is_waiting_last_req = false; - cntx->is_new_req = false; if (!req) { /* * Dispatch queue is empty so set flags for @@ -109,10 +108,6 @@ static void mmc_request_fn(struct request_queue *q) cntx = &mq->card->host->context_info; - if (cntx->is_waiting_last_req) { - cntx->is_new_req = true; - } - if (mq->asleep) wake_up_process(mq->thread); } diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h index d536325a9640..ceb58b27f402 100644 --- a/include/linux/mmc/host.h +++ b/include/linux/mmc/host.h @@ -241,11 +241,9 @@ struct mmc_slot { /** * mmc_context_info - synchronization details for mmc context - * @is_new_req wake up reason was new request * @is_waiting_last_req mmc context waiting for single running request */ struct mmc_context_info { - bool is_new_req; bool is_waiting_last_req; };