Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2381286pxj; Sun, 6 Jun 2021 00:08:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwiNXDksVrwTn1btgeOqUfYsRfu93dx7HQ96124nTxQGuft1HZd3TiHXHVtQZcP6Mq25nAK X-Received: by 2002:a17:906:c289:: with SMTP id r9mr9631653ejz.355.1622963310190; Sun, 06 Jun 2021 00:08:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622963310; cv=none; d=google.com; s=arc-20160816; b=BSL4LuSHDKerV9hsx+0LWeF2qVu97TFM9PVCQzKAM4e0/6wlU8d+L7rJvwQx98SRVt O3GcYmfM5lB1SrcLKRdt4u6k1ISueNJzREtl88BSU9AXsiL+TabroC0bjOKCI68e+Fn8 DOZG0E3YuG7q2Jge/HeCyRvPFodUAby2MW/Pb6jd6Hx/g2L4nAM88tS3cbGlx0J0JrKQ VL19r+3dqDBtsO8YO0S4xcxWkbv/RRrzdoDAwP7UExtV00oSXng9EpOHS6/9HvwVTS0A TRny6HWliRaKyRTlG4IFMpCt+SZI3S1zfaKmo6/8lCJjzbztrkkNYZ6U+WIwqtPT4K7y 3DgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=5+ypx9Rj8P3lUr4MhiNDQWc6dLd11JIlQkIpaR01+QE=; b=ueNot80Pqs2iG4AI+msRTLHbF5my4j5+kzxtDajaL93PjfgAkOAP65hqjiIAbwngcG 0IuKyeObguvOG3J/AMPM0XL5FlsgREwRW3QpjH8P5jzD/FJlNN5iJ85o+TP2rNy0iL7D YMjM1Tg1BTtchND/jlIbyweSZsypunfDLJCUVu5QMg7n6+NdrL8YeY0Z03FEQrExeaps DpBQjUc4KdsCXBEGKI2p9/xQqNBzWYVFXKQqg4Mhwpz/jcXzWjGkSCjHOaCgozOGejHV h6hbjAfS2WESty78mTTR5c0llcJ/66B5zpqfXqplE0D7UKxK+9+jaQfZLp6b55IWjllN VaVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=KLf6SbUA; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d19si8795682ejo.263.2021.06.06.00.08.07; Sun, 06 Jun 2021 00:08:30 -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=@gmail.com header.s=20161025 header.b=KLf6SbUA; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230139AbhFFHHO (ORCPT + 99 others); Sun, 6 Jun 2021 03:07:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39376 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229478AbhFFHHN (ORCPT ); Sun, 6 Jun 2021 03:07:13 -0400 Received: from mail-pg1-x52b.google.com (mail-pg1-x52b.google.com [IPv6:2607:f8b0:4864:20::52b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8AB35C061766; Sun, 6 Jun 2021 00:05:24 -0700 (PDT) Received: by mail-pg1-x52b.google.com with SMTP id q15so11346634pgg.12; Sun, 06 Jun 2021 00:05:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=5+ypx9Rj8P3lUr4MhiNDQWc6dLd11JIlQkIpaR01+QE=; b=KLf6SbUADB+x9z3VxprjCJD8KLPIuGQ58gp9lkDcQap5DqMRANgjoRm8EjvzyzM+PT dGQF3IZSSKZSnRTWmubz8hic85nLkmr4/8ti9o2Fth/DktZX2P134jWCPQcwEJ6fTxL8 cwK6nhQ7LHmI1q5dbnBdwmO9SWMdA9obZxySLH3ZPzf6Pk3+jNuRHX335w3zraY09yNJ zsHuq3/n5wzi9NOKonP6cuEe7sJ+HRmxJa8+id8p0od/r0Ca/XeaSSKfy8neLhKz/l/i vaR8BV5c4M2/iqW7AZMfYuMdhSmHBujOG7y2PfiQKPBelVhwBkTRmJzkr7pXN7q26Mnm 7UBw== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=5+ypx9Rj8P3lUr4MhiNDQWc6dLd11JIlQkIpaR01+QE=; b=kflqNfRvBy6KdhRoQ/4GkkGD3ngX/PtjlfU05Mflln2utUFriGpUk00dmG7znX1Xm9 J9GxaRKgOjg9+yduNSbBu7Zz7vbpGKej2y2r93uzbT0s5AmFyG+X3pPSMVpqjsTQwsyk 1kbHSjb5EN5WngE5vYZ70R7gvDkJyZqFCVCs14fm4ywXUp7tQikq8bIDFQ235sAc8gju EVvx9gtX/vdzxqyTrgu7LG8eUEechahUSoaPxMTk2yAwxKBOQHsZH/WOc+rIwPu+WqLO 4xUH0HJ78r/LlB/a+OPGMAxy/2tOxAYcXtG8y+Ma/pc5eIEHXxbvROyXMbiBsGAtZypy vUjA== X-Gm-Message-State: AOAM532mLHF55OsiRhyVIXvkwiI1TdA3XEykWS14coLYnVgVgPS5PuZC eIgxHk9YMyFZDEFqyHlm4JY= X-Received: by 2002:a63:1a49:: with SMTP id a9mr12628609pgm.63.1622963124130; Sun, 06 Jun 2021 00:05:24 -0700 (PDT) Received: from localhost (185.212.56.112.16clouds.com. [185.212.56.112]) by smtp.gmail.com with ESMTPSA id o17sm8629945pjp.33.2021.06.06.00.05.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 06 Jun 2021 00:05:23 -0700 (PDT) From: Dejin Zheng To: helgaas@kernel.org, corbet@lwn.net, jarkko.nikula@linux.intel.com, andriy.shevchenko@linux.intel.com, mika.westerberg@linux.intel.com, rric@kernel.org, bhelgaas@google.com, linux-doc@vger.kernel.org, linux-i2c@vger.kernel.org, linux-pci@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Dejin Zheng Subject: [PATCH v6 2/4] Documentation: devres: Add pcim_alloc_irq_vectors() Date: Sun, 6 Jun 2021 15:05:09 +0800 Message-Id: <20210606070511.778487-3-zhengdejin5@gmail.com> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210606070511.778487-1-zhengdejin5@gmail.com> References: <20210606070511.778487-1-zhengdejin5@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add pcim_alloc_irq_vectors(), a device-managed version of pci_alloc_irq_vectors(). introducing this function can simplify the error handling path in many drivers. Reviewed-by: Robert Richter Signed-off-by: Dejin Zheng --- v5 -> v6: - rebase to 5.13-rc4 v4 -> v5: - No change v3 -> v4: - No change v2 -> v3: - No change v1 -> v2: - Modify some commit messages. Documentation/driver-api/driver-model/devres.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/driver-api/driver-model/devres.rst b/Documentation/driver-api/driver-model/devres.rst index e0814d214048..fad7d26ccf35 100644 --- a/Documentation/driver-api/driver-model/devres.rst +++ b/Documentation/driver-api/driver-model/devres.rst @@ -382,6 +382,7 @@ PCI devm_pci_alloc_host_bridge() : managed PCI host bridge allocation devm_pci_remap_cfgspace() : ioremap PCI configuration space devm_pci_remap_cfg_resource() : ioremap PCI configuration space resource + pcim_alloc_irq_vectors() : managed IRQ vectors allocation pcim_enable_device() : after success, all PCI ops become managed pcim_pin_device() : keep PCI device enabled after release -- 2.30.1