Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp3048418ybz; Mon, 27 Apr 2020 09:05:13 -0700 (PDT) X-Google-Smtp-Source: APiQypIYGeAkDxkGf3LZcde4hiAoNrj96JunVyOnjZyz7RZF/UGjXnnb9t03I48Q6PEJQlR7p/wc X-Received: by 2002:aa7:c04a:: with SMTP id k10mr5043425edo.241.1588003513136; Mon, 27 Apr 2020 09:05:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588003513; cv=none; d=google.com; s=arc-20160816; b=LHVRfs6mUD7mJhgbwnlvcUSDOlJCYZ3HrHf89wU30zKulxNnbxQFaIlW4e5a6wItxp nC4xNjA6UTeKHGoWC1O2WkGxHPc+y+WQgkaqhhJIWw0qjjgQAAIhVuOMRCX76AHxJ/ad bSjUyhyjiZKexoY78vV/O61ckjvOakZeO4FRFSUk8RauHg6aX2RXew1Sr/PwpV8FKtTn C98fkTtY50d/jSbbvhk14TZpAJLKVe6T3whf+8XAiemm3X+sD89jVvtD/LJ3x2wmrhXs 1vEEgsPGRTh48lOZ6yPqbZP2ld+VZSOxgFBEfwOscoIf9npulUaA4gC360fg1vR6js+K /Zbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=orCZLMpuSXbZgVNHr5vobXIsUlb5BOvGJFuGtKPcQnQ=; b=XmSQ6fKAtAlQDf1YucFDa6u/DgwnoUZBojLCSu2/lQXV6zaYHIyOs2asZ66N1ZC1yG gZeErfOYBQM+l2y9neVlVnymOJsS+8WLw4+zvo3ZYRXxnPRClMgYJMInlAIGHCPLQ+qi DBsvAGgZBt34OWCPO7lgVY0vQjvTCEPRfhpMEs3dCTByrXgzss4Aaf6k1Ld3Rp3GoIPF K2m8qEh0tSaA+F2M6+Q3SmBXwv6eESnW3lmlQYctEv8WE1/Q2meUZ34rQhtKlyE9Ssv2 40BHY/6CiICe8r42j2zgoFfkljzSGIqbFX4RzTSRLTdmk+VB9KT91ezad24Vo6l1yAK0 lolQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Rp0rYw2Y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p23si13619eju.299.2020.04.27.09.04.17; Mon, 27 Apr 2020 09:05:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Rp0rYw2Y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728642AbgD0QBJ (ORCPT + 99 others); Mon, 27 Apr 2020 12:01:09 -0400 Received: from mail.kernel.org ([198.145.29.99]:36340 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728616AbgD0QBH (ORCPT ); Mon, 27 Apr 2020 12:01:07 -0400 Received: from localhost (unknown [171.76.79.70]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C5591206D4; Mon, 27 Apr 2020 16:01:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1588003267; bh=Wq5GVLt/5AqJffo/SS4zwlcP1ymmbgtvTCi7gp4FIMY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Rp0rYw2YnUFJhZZYykL50L9xHe0xC7HdCM1c6+eaSRcRAOuM8Saniwrt5Y5FvFQxT Xfb4Csix3XfQRg1z8gay/1dkJ0cOKKkt82aZGA5oaqqps5Okk24H1ZjJzPWlpPimBM IBBK8xwvkf5NTsMZEuiuk43plKHGQIvGlIdnad+w= Date: Mon, 27 Apr 2020 21:31:03 +0530 From: Vinod Koul To: Alan Mikhak Cc: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, gustavo.pimentel@synopsys.com, dan.j.williams@intel.com, kishon@ti.com, maz@kernel.org, paul.walmsley@sifive.com Subject: Re: [PATCH v2][next] dmaengine: dw-edma: Check MSI descriptor before copying Message-ID: <20200427160103.GF56386@vkoul-mobl.Dlink> References: <1587607101-31914-1-git-send-email-alan.mikhak@sifive.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1587607101-31914-1-git-send-email-alan.mikhak@sifive.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 22-04-20, 18:58, Alan Mikhak wrote: > From: Alan Mikhak > > Modify dw_edma_irq_request() to check if a struct msi_desc entry exists > before copying the contents of its struct msi_msg pointer. > > Without this sanity check, __get_cached_msi_msg() crashes when invoked by > dw_edma_irq_request() running on a Linux-based PCIe endpoint device. MSI > interrupt are not received by PCIe endpoint devices. If irq_get_msi_desc() > returns null, then there is no cached struct msi_msg to be copied. > > This patch depends on the following patch: > [PATCH v2] dmaengine: dw-edma: Decouple dw-edma-core.c from struct pci_dev > https://patchwork.kernel.org/patch/11491757/ > > Rebased on linux-next which has above patch applied. These two para above should be added after s-o-b line as git-am skips the lines after the marker. The above line are useful for applying but not when applied. I have stripped these and applied the patch, thanks -- ~Vinod