From patchwork Sat Nov 27 01:20:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Gleixner X-Patchwork-Id: 12641711 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CDC6DC4707A for ; Sat, 27 Nov 2021 01:23:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345304AbhK0B0T (ORCPT ); Fri, 26 Nov 2021 20:26:19 -0500 Received: from Galois.linutronix.de ([193.142.43.55]:35064 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345438AbhK0BYI (ORCPT ); Fri, 26 Nov 2021 20:24:08 -0500 Message-ID: <20211126230524.355599952@linutronix.de> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1637976018; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: references:references; bh=eU/+MzcFFw4K2a/jF7MWe8bjN6ge/wr+X0hgqu8YCCQ=; b=37q0V1cbSuIIBymAUrmV6vNbD0AG9OhMRNskcj82I53q40Eo+MPVhg9OV3PPrI+vgf4Qae 00OY4DmpKexitvBVgwNQhbp9/fozZeZ+4BpSQZSm/65H82KVpqc+wm5XstEezuZy3aX7Ia ezIJIq/W39ScORxoxOeztywmxVN04GEwt0DIYoLqyVUSBJx2pMS2puOtcT6b+M9lKl02wW DDfqSCxmFBAl4spcZCo8BfS4fDaYnwnjJijv85HCTJ7v6gKzZLqwmYAU/qlu+OqhGxTzf0 ZrvZK5+NDO4xKKNbv8zZCSZ1r3cmU5PM767ECfySrY/+l7AM6FBdJZCNhWJbHQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1637976018; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: references:references; bh=eU/+MzcFFw4K2a/jF7MWe8bjN6ge/wr+X0hgqu8YCCQ=; b=rYicKTlUm2Sg+aAsLf2zZH11aPVNUVCcQpbGPeExh9jfY/pxFsA9qZS4IfVsfuUORtN6WK JmeK4LXSsAc/2cDQ== From: Thomas Gleixner To: LKML Cc: Bjorn Helgaas , Marc Zygnier , Alex Williamson , Kevin Tian , Jason Gunthorpe , Megha Dey , Ashok Raj , linux-pci@vger.kernel.org, Greg Kroah-Hartman , Nishanth Menon , Tero Kristo , Santosh Shilimkar , linux-arm-kernel@lists.infradead.org, iommu@lists.linux-foundation.org, dmaengine@vger.kernel.org, Stuart Yoder , Laurentiu Tudor , x86@kernel.org, Vinod Koul , Mark Rutland , Will Deacon , Sinan Kaya Subject: [patch 07/37] soc: ti: ti_sci_inta_msi: Allocate MSI device data on first use References: <20211126224100.303046749@linutronix.de> MIME-Version: 1.0 Date: Sat, 27 Nov 2021 02:20:17 +0100 (CET) Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org Allocate the MSI device data on first invocation of the allocation function. Signed-off-by: Thomas Gleixner Cc: Nishanth Menon Cc: Tero Kristo Cc: Santosh Shilimkar Cc: linux-arm-kernel@lists.infradead.org --- drivers/soc/ti/ti_sci_inta_msi.c | 4 ++++ 1 file changed, 4 insertions(+) --- a/drivers/soc/ti/ti_sci_inta_msi.c +++ b/drivers/soc/ti/ti_sci_inta_msi.c @@ -120,6 +120,10 @@ int ti_sci_inta_msi_domain_alloc_irqs(st if (pdev->id < 0) return -ENODEV; + ret = msi_setup_device_data(dev); + if (ret) + return ret; + nvec = ti_sci_inta_msi_alloc_descs(dev, res); if (nvec <= 0) return nvec;