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 155DE78B73; Wed, 21 Feb 2024 14:26:53 +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=1708525613; cv=none; b=o6j2vuabDwdgRyVzvVyXUGJ8dueJ4jCMHzTAHmpAReGPSNdvF0SusnzCi+q/AB+ojr0sZFjM3OokQQGG29a8JjHxW2hF8lyl8p1xVvQt3OLxP1I0/56TUwU3LI42NQBqHHRIvP0w+q0pZYSP35YyuxembLyyNUMBbyA6qpKI0Qk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708525613; c=relaxed/simple; bh=s38D0c4HOp1YF/MbXehLWjyqsR5WazeNqbq6Ul0I//o=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=ejcOLyr9Nbcbgpy2ihfZS0Ff3jmA7dSr3+z69CGbBaFmB3/C6Y07+yWJQewRD49zoA0p09dgzhnbJBn2bHwQyAHUm17bQSR2Owa1/YXO5WWnW82gJ4ZKPKTnj1ftw6NxqZQT8n+gY4fznUSo6X16g4Qih8BGrjT0SQyYKxaF6Yk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=oSGuhqWO; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="oSGuhqWO" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7A430C433C7; Wed, 21 Feb 2024 14:26:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1708525613; bh=s38D0c4HOp1YF/MbXehLWjyqsR5WazeNqbq6Ul0I//o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oSGuhqWObCOiVqmMQNwAjs1H93egIkSPGeDJZp6Mwcfh1Lv/XBVOlxBbNWq9iyvG8 VEDD4CiTgjmUW/OI4Zs0VOMy4/nL4JmMPg1jtMo+Ms4pq/64zITGmujt1iUenawijw inp4Iqnl+iYSiXJDKPlKx6i+2SoPvlLYi3l5imZo= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , Mark Brown , Sasha Levin Subject: [PATCH 5.4 209/267] spi: ppc4xx: Drop write-only variable Date: Wed, 21 Feb 2024 14:09:10 +0100 Message-ID: <20240221125946.744765349@linuxfoundation.org> X-Mailer: git-send-email 2.43.2 In-Reply-To: <20240221125940.058369148@linuxfoundation.org> References: <20240221125940.058369148@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 5.4-stable review patch. If anyone has any objections, please let me know. ------------------ From: Uwe Kleine-König [ Upstream commit b3aa619a8b4706f35cb62f780c14e68796b37f3f ] Since commit 24778be20f87 ("spi: convert drivers to use bits_per_word_mask") the bits_per_word variable is only written to. The check that was there before isn't needed any more as the spi core ensures that only 8 bit transfers are used, so the variable can go away together with all assignments to it. Fixes: 24778be20f87 ("spi: convert drivers to use bits_per_word_mask") Signed-off-by: Uwe Kleine-König Link: https://lore.kernel.org/r/20240210164006.208149-8-u.kleine-koenig@pengutronix.de Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- drivers/spi/spi-ppc4xx.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/spi/spi-ppc4xx.c b/drivers/spi/spi-ppc4xx.c index 0ea2d9a369d9..738a1e4e445e 100644 --- a/drivers/spi/spi-ppc4xx.c +++ b/drivers/spi/spi-ppc4xx.c @@ -170,10 +170,8 @@ static int spi_ppc4xx_setupxfer(struct spi_device *spi, struct spi_transfer *t) int scr; u8 cdm = 0; u32 speed; - u8 bits_per_word; /* Start with the generic configuration for this device. */ - bits_per_word = spi->bits_per_word; speed = spi->max_speed_hz; /* @@ -181,9 +179,6 @@ static int spi_ppc4xx_setupxfer(struct spi_device *spi, struct spi_transfer *t) * the transfer to overwrite the generic configuration with zeros. */ if (t) { - if (t->bits_per_word) - bits_per_word = t->bits_per_word; - if (t->speed_hz) speed = min(t->speed_hz, spi->max_speed_hz); } -- 2.43.0