From patchwork Sun Jun 12 20:34:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Ian King X-Patchwork-Id: 12878799 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A112DC433EF for ; Sun, 12 Jun 2022 20:35:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=n8ELEnGPZcXw5AfnrI/KPutuVaCOsqFiZ09LUsxeQwg=; b=tjv0nkeWBdms/2 N0zwth+/PkuX01M9MfAA1WtmAuFnPidM9D3Q2SuxA7ZnzZzWptpezcRVNM9aVgpw9KiVROEHEKdUc Ju24eFdd9mA6Gye9AIhso5YiN4jVEKpqY8G8ABMl9rsPL9RKP+cg5T1hXNrXNoLB9yFvYYF1VldJO 9blxu6HyBvoSTj1dVFIMR4F03IVdCwpRWEv9VPp4NzdZClLuK2hp8icYpM10QXNWJtt+u58K3/Qr1 MbOxhzfVGT+dIIFLwQG3FXlzzswGw2x49gXT3HR0L/M6cQnpx+j9LxtaJRE9g70zaepMCZZm9TnwO 9W13Zx/m1ZW8+HMgETpg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o0UI8-0003ZH-1t; Sun, 12 Jun 2022 20:34:36 +0000 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o0UI4-0003Yk-UY for linux-arm-kernel@lists.infradead.org; Sun, 12 Jun 2022 20:34:34 +0000 Received: by mail-wr1-x430.google.com with SMTP id q15so4827807wrc.11 for ; Sun, 12 Jun 2022 13:34:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=pLO4+liZettN7NhTXRO4r2yJBN1H2FVkqYbOicYerBo=; b=X5OBdH28x9HgFoBcWsY3ulpULpoUF3jFjFVlEFMpFgUx3IREZW/hJYT/c1iQaKfxeq ndL1X8IFDh05l0q3leMTlePr/vGN8J4dEo8G+CyygvfkLz2o7s4amu4W2jQtVS+l/+u3 NyvQqX6LDPRcdgV4mvF2uUchiySoVVwzxWGSLQqHaI7zPvUHqoQKt3DJdxyhBRI8hlmL doKoD3lVtTzZiJMkNHOQWQMo5R3/7bdvwG7hKlSw2IIZ9jq77ku8z9/xjLrxbvX4ElfV QWFetwJJlZQjHNiar2TR1PWGQ9VjKsKQZ5t+95CF2b9gbmDJ/HFSFo8KxDtJ+xSEmNmL E6QQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=pLO4+liZettN7NhTXRO4r2yJBN1H2FVkqYbOicYerBo=; b=skcxOj/WF1hYIqzVMkcVKX3SmVPC4LeEiiHHsx1rqsrO+Gow4fKpeb6PHBPbiekLPO fCAgp8O5LzHK/cqDKLZOWW+qtGc8ZsvYKj26yxVgGGLa8DeAlWvTTx1ufYMleXdz73EZ v3M45dQ7j0lTd4rC9ix+gNUVktBRc6glDWwBlMGcce8+I9shn6Q4Jg7Aih0JuFM3qWnz h5kC30A/uN1pqRs3wMrxgg9MMJUS9bwG/ItHW80GEC1Ud9t86oTWi46dFcUh4ROR7Bu4 gAME5QgCLwpoXrq3kG9vAvVTRO4j59EEMPN43+ZYVVXurVBnaqMSQBIsCbvQa2s4BdMu va2w== X-Gm-Message-State: AOAM531fLECOrRsYPZT2qINizU0vpyL96u681ZFa6LczYMwOhskdlMab GAy/UoXMNx9fA7KqVF3uS8M= X-Google-Smtp-Source: ABdhPJzUlKOUvC8cBsTg326yD2TNlhEPA2C1hFzYli75wU1R8FclFOC5cNtWRhXNszJsuzDOQrKDfQ== X-Received: by 2002:adf:fb05:0:b0:20a:e113:8f3f with SMTP id c5-20020adffb05000000b0020ae1138f3fmr53765523wrr.534.1655066069955; Sun, 12 Jun 2022 13:34:29 -0700 (PDT) Received: from localhost (cpc154979-craw9-2-0-cust193.16-3.cable.virginm.net. [80.193.200.194]) by smtp.gmail.com with ESMTPSA id e10-20020a5d4e8a000000b00210320d9fbfsm7706817wru.18.2022.06.12.13.34.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 12 Jun 2022 13:34:29 -0700 (PDT) From: Colin Ian King To: Krzysztof Kozlowski , Andi Shyti , Mark Brown , Alim Akhtar , linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH][next] spi: s3c64xx: set pointers to null using NULL rather than 0 Date: Sun, 12 Jun 2022 21:34:28 +0100 Message-Id: <20220612203428.2754823-1-colin.i.king@gmail.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220612_133433_049907_93967EA6 X-CRM114-Status: GOOD ( 12.17 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org There are pointers being set to null using use. Use NULL instead. Signed-off-by: Colin Ian King Reviewed-by: Alim Akhtar --- drivers/spi/spi-s3c64xx.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 0ce58105dbac..819b660dae82 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -354,7 +354,7 @@ static int s3c64xx_spi_prepare_transfer(struct spi_master *spi) sdd->rx_dma.ch = dma_request_chan(&sdd->pdev->dev, "rx"); if (IS_ERR(sdd->rx_dma.ch)) { dev_err(&sdd->pdev->dev, "Failed to get RX DMA channel\n"); - sdd->rx_dma.ch = 0; + sdd->rx_dma.ch = NULL; return 0; } @@ -362,8 +362,8 @@ static int s3c64xx_spi_prepare_transfer(struct spi_master *spi) if (IS_ERR(sdd->tx_dma.ch)) { dev_err(&sdd->pdev->dev, "Failed to get TX DMA channel\n"); dma_release_channel(sdd->rx_dma.ch); - sdd->tx_dma.ch = 0; - sdd->rx_dma.ch = 0; + sdd->tx_dma.ch = NULL; + sdd->rx_dma.ch = NULL; return 0; } @@ -808,8 +808,8 @@ static int s3c64xx_spi_transfer_one(struct spi_master *master, if (sdd->rx_dma.ch && sdd->tx_dma.ch) { dma_release_channel(sdd->rx_dma.ch); dma_release_channel(sdd->tx_dma.ch); - sdd->rx_dma.ch = 0; - sdd->tx_dma.ch = 0; + sdd->rx_dma.ch = NULL; + sdd->tx_dma.ch = NULL; } return status;