From patchwork Mon Jul 17 13:08:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vincent Whitchurch X-Patchwork-Id: 12135 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:c923:0:b0:3e4:2afc:c1 with SMTP id j3csp1104123vqt; Mon, 17 Jul 2023 06:15:28 -0700 (PDT) X-Google-Smtp-Source: APBJJlFQKgbYPVNpCZx+4qPiIGRetik6XDBWmB/9GW+d5PQtI05kjnIPGcCcqQfd8EVo8UjOChDQ X-Received: by 2002:a05:6402:149a:b0:51a:5ebe:4ab9 with SMTP id e26-20020a056402149a00b0051a5ebe4ab9mr10976576edv.14.1689599728425; Mon, 17 Jul 2023 06:15:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689599728; cv=none; d=google.com; s=arc-20160816; b=RublNtdCOZ6WE+km5Vqrs1hnf/MXYCciGJ9ulFW/hRvt5wsSd8Sv0r2yZh8F7fQ+ln CabKBvMIvw4EQBovMi8TOHh9PnKbjLk2IkIIb/Nscg9/XyQ/1JoyDRxOR8OBuRxi7sYY Tr+jsj7b/XvUbHt0eQoyn7XcVpzjm/RRIQB4MF6+NPDl+HULmdo/uIBoieW+ygfj38VX rAd1hXZl2j9sAecR4vlR496Fo9/W/gsOjVJr0feMst16SSw4wKyVxMqVlFUT/sKSVI9c zsws0BL7Zbx4921BwgPSJMBEULHphLaAo5F+uBeCOz/vxrCHJEDo662hFFjKbDh92XxJ b7Mg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:content-transfer-encoding:mime-version :message-id:date:subject:from:dkim-signature; bh=O5DQ9JSl1jzwQRO2zJHId2P9HoG7Jsu0sEGb288kCQs=; fh=NLM2g2hm6dV9mNM8bxQ6gCpPSRIG0jJznP+F5p4lmsE=; b=hGRMer8oFlI9m4Ix7WwTR2zEJRpnm2UQ2+yVoc3Q6Pr1gCorVzLXw70IOolfFzXQNi OgElXChGaKPnfqChvhEzpUsvMLq+Oqm14DWVs9pvUFpfEqtkoyjAY4HF3+vF+esL6RxO GYSoHNHsLj0VnkQeiz59FZNt1ynTgWPAPJSyOLsYX0zrRv9kpIh27D/CB8V64smY2b6Z KphFBwMMt+AG3h+moFai/WUOm1DHKiLBuEy7ONaNnUCVua+7Y16BaUn2RHK3Sojdln4Z 33F9gN2AaiFOgscFOlAGJN5IsDm3iS4p53PQhdXgAh6mYj4S0kt53o1Ud1Hiw/aLg4rp fEIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@axis.com header.s=axis-central1 header.b=P541cTqD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=axis.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a12-20020aa7cf0c000000b0051e01f391besi12735945edy.581.2023.07.17.06.15.04; Mon, 17 Jul 2023 06:15:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@axis.com header.s=axis-central1 header.b=P541cTqD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=axis.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231419AbjGQNIr (ORCPT + 99 others); Mon, 17 Jul 2023 09:08:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49242 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231338AbjGQNIp (ORCPT ); Mon, 17 Jul 2023 09:08:45 -0400 Received: from smtp1.axis.com (smtp1.axis.com [195.60.68.17]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 69F58C0; Mon, 17 Jul 2023 06:08:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axis.com; q=dns/txt; s=axis-central1; t=1689599325; x=1721135325; h=from:subject:date:message-id:mime-version: content-transfer-encoding:to:cc; bh=O5DQ9JSl1jzwQRO2zJHId2P9HoG7Jsu0sEGb288kCQs=; b=P541cTqDV0rzQhh/ESfcK5tRXktNemGTWHIi+IpTzkPugiaFoxEEYxrE cXv9TafltQS0gSDYLf/p4jwfruVKPQhdXI+eNF0Ddckvuy5t0SU+lmUIi zOtnlKrUKD/DfxjEmzkmjrbGZQqCFO43TaiR1Om+x6MjpvOx7kBpVS4/n o0Hk9jxzfoKYIhOhB9PsIDBHjWmIZpX/AHWVDqwki7eK5j/QlFRzh39u1 H/ZKRQi5KirqcXWi5aOHVZadZDVIs1XstZNe02zKVWUWdRh8rjCtKwzbp 2WARSriI/2CM61JoGGF0wPHlWtllDNK8nvPUp98TDuU1aUnQcs2XMK9jF g==; From: Vincent Whitchurch Subject: [PATCH 0/2] dmaengine: Use-after-free fix and dummy DMAC Date: Mon, 17 Jul 2023 15:08:39 +0200 Message-ID: <20230717-dummy-dmac-v1-0-24348b6fb56b@axis.com> MIME-Version: 1.0 X-B4-Tracking: v=1; b=H4sIAFc9tWQC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE vPSU3UzU4B8JSMDI2MDc0Nz3ZTS3NxK3ZTcxGRdy0SjVPNU45SUJCNLJaCGgqLUtMwKsGHRsbW 1AG15UYlcAAAA To: Vinod Koul CC: , , , Vincent Whitchurch X-Mailer: b4 0.12.3 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771673724721461342 X-GMAIL-MSGID: 1771673724721461342 This series has a fix for a use-after-free in the DMA engine framework and adds a dummy CPU-based "DMA" controller driver which can be used for testing the DMA engine framework and clients on systems without a real DMA engine, such as under KVM. --- Vincent Whitchurch (2): dmaengine: Fix use-after-free on release dmaengine: Add dummy DMA controller driver drivers/dma/Kconfig | 14 +++ drivers/dma/Makefile | 1 + drivers/dma/dmaengine.c | 30 ++++-- drivers/dma/dummy-dmac.c | 258 +++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 294 insertions(+), 9 deletions(-) --- base-commit: fdf0eaf11452d72945af31804e2a1048ee1b574c change-id: 20230717-dummy-dmac-9a2e7e3ddb29 Best regards,