From patchwork Tue Oct 9 05:47:45 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joel Fernandes X-Patchwork-Id: 10631937 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A7CBC15E8 for ; Tue, 9 Oct 2018 05:48:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 991DD2890F for ; Tue, 9 Oct 2018 05:48:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8D03B28928; Tue, 9 Oct 2018 05:48:33 +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=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3F5872890F for ; Tue, 9 Oct 2018 05:48:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject: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=1aSyx/haGSgIJm+r7Idu7jKGRKtAXnBHwEEa7PGsppk=; b=DFkQ0+lf9bqWPW WtrZzhWhU2m1+6bA9hXAUcuT3OvwUqtAZJcxaKLchbuh6derQMSWxkImKAZf+qXs5QfWZLWheyf6w udfXxNwy0WJxeC9jkgMWpr3KHeguhEnbvwNP7mYNUSN5xyZc0rX1FcOqweJ4VGYFbpp+1SxG1XYtL mgWzDSaZYAOX+asK7oAA262kMyoBxfO527AFIkUwWcQDSEb+eBImGlbhogqCaLxZ/ox9a0yjSMzHm 5A9rPQIu9mMW4UlAO0rlIZA87XW+4rNtmj0QiglxHGuUzehCWTdPV64VkgkFQ59BHXxTb6cMiMB9R Mk++AHIiqC/iIjYvoOYA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1g9ksW-0005nr-QN; Tue, 09 Oct 2018 05:48:20 +0000 Received: from mail-pf1-x441.google.com ([2607:f8b0:4864:20::441]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1g9ksR-0005jH-Vr for linux-arm-kernel@lists.infradead.org; Tue, 09 Oct 2018 05:48:17 +0000 Received: by mail-pf1-x441.google.com with SMTP id d4-v6so268620pfn.0 for ; Mon, 08 Oct 2018 22:48:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=B6NcMaIl8d3D6UR4+uWdY83sbscXJ4RqMS51ybyZOEU=; b=ruvwGaiCq/tRIA2K2jgj1Af9WK4v6W2dlbJ2QJIDxliOnz276/hnYbBsa7jfLajOkm 0aLKnbBrINdqJ3bgbg7WztoPqSSNx6Qlu2fGsFWbUVJgSXcJC1TamsiqMniQSKDPRKUB cCjMZYqgdQreMgRb3YVgteXLghPQwIyeiG8sA= 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:mime-version :content-transfer-encoding; bh=B6NcMaIl8d3D6UR4+uWdY83sbscXJ4RqMS51ybyZOEU=; b=NC8utit0Tm2mTrXEWGo3MBXh8jh9mMX/KWTl2yQocJ8wDcLDXqVzPBSvn++076UoFo GV+xQ4mAsoDcKOL/HcPnCEqRs4a1/cw6xAMHRVw/SxK3bvypeulDBemiBfGJ0zMH0ocw ZYDbrt4C0zCju/x56FRo4fOObEfDVOAWerXvWQF5qYiragV3zCgiDhXglODD5ALGPB8h 2zNpyNkkayWLejvdLyffPo6tvFqjmqWBCXQYRR4qkKfe84Tq9inHYzShJeHjm/zZYuMb gOA61Z6P0izMIZ0fHgZKVwup7sHDsBbJPKqiy81qxNDHoT0WWpsdH8zJHOrMH+aXT3JY OlbQ== X-Gm-Message-State: ABuFfoi44zM5rNwF1sPdsIi+esMCRot3FMfcLU9aGtI7pd5PPtnkrdBe l6HnUZYkzHScbBX7ABAnau98rA== X-Google-Smtp-Source: ACcGV61RLBhF+8+YOYMURmOgjSpiaVNDhZIqKE0EQNZ3ozqL8lqcZ8jVcK6ksmU9feg8BQ8Lldq59A== X-Received: by 2002:a63:7f0e:: with SMTP id a14-v6mr24175266pgd.296.1539064084964; Mon, 08 Oct 2018 22:48:04 -0700 (PDT) Received: from joelaf.mtv.corp.google.com ([2620:0:1000:1601:3aef:314f:b9ea:889f]) by smtp.gmail.com with ESMTPSA id a15-v6sm16886234pff.8.2018.10.08.22.48.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 08 Oct 2018 22:48:03 -0700 (PDT) From: "Joel Fernandes (Google)" To: stable@vger.kernel.org Subject: [PATCH 0/7] NULL pointer deref fix for stm32-dma Date: Mon, 8 Oct 2018 22:47:45 -0700 Message-Id: <20181009054752.145978-1-joel@joelfernandes.org> X-Mailer: git-send-email 2.19.0.605.g01d371f741-goog MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181008_224816_049361_2DAC94FF X-CRM114-Status: GOOD ( 10.20 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Alexandre Torgue , Vinod Koul , gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, dmaengine@vger.kernel.org, Maxime Coquelin , "Joel Fernandes \(Google\)" , Dan Williams , "moderated list:ARM/STM32 ARCHITECTURE" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Hi Greg, While looking at android-4.14, I found a NULL pointer deref with stm32-dma driver using Coccicheck errors. I found that upstream had a bunch of patches on stm32-dma that have fixed this and other issues, I applied these patches cleanly onto Android 4.14. I believe these should goto stable and flow into Android 4.14 from there, but I haven't tested this since I have no hardware to do so. Atleast I can say that the coccicheck error below goes away when running: make coccicheck MODE=report ./drivers/dma/stm32-dma.c:567:18-24: ERROR: chan -> desc is NULL but dereferenced. Anyway, please consider this series for 4.14 stable, I have CC'd the author and others, thanks. Pierre Yves MORDRET (7): dmaengine: stm32-dma: threshold manages with bitfield feature dmaengine: stm32-dma: fix incomplete configuration in cyclic mode dmaengine: stm32-dma: fix typo and reported checkpatch warnings dmaengine: stm32-dma: Improve memory burst management dmaengine: stm32-dma: fix DMA IRQ status handling dmaengine: stm32-dma: fix max items per transfer dmaengine: stm32-dma: properly mask irq bits drivers/dma/stm32-dma.c | 287 +++++++++++++++++++++++++++++++++------- 1 file changed, 240 insertions(+), 47 deletions(-)