From patchwork Thu Jun 24 22:26:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 12343295 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9E7C5C49EA6 for ; Thu, 24 Jun 2021 22:29:23 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 65BE7610A0 for ; Thu, 24 Jun 2021 22:29:23 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 65BE7610A0 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=yDgTAgfhxQgAITCHUed5A3xTNG1y7CEeOPOB3vWks8I=; b=tyGFZLQe2pTOJT Nz+wpdyTMyOphdWu9fmfan4vV4pc9Rjr4yWznusHSSYJxHw7M/5v/n0QPKfI2fnPsX8AeHYGPPLH2 bYzIaBnQu/Fze7RVrNS5NeqPKJlN9fUqzRQ5LcE4Qm2FLqtrdQcCJa9wmtNLrgCSDyJRFDaZQuB6f 4bvlq7gXaw6nT+ZhgCCf9Ru+KQS+n88qUwFPi67C0Zm7/nuqJQ0at4oJnwVTb2gE5cgw9nRz8bpOj /ugY8Gv8gAU8HXMWoKM4/ra6BOdLB0Fnn91bUgSDGU1DIMB161icsXXtlo5E68xIsnRAucDqZ1Ytv xxuqAe9zCIZW6kUIfpDg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lwXoq-00GVA4-Ac; Thu, 24 Jun 2021 22:27:32 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lwXoU-00GV6Z-Gv for linux-arm-kernel@lists.infradead.org; Thu, 24 Jun 2021 22:27:11 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id E16606137D; Thu, 24 Jun 2021 22:27:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1624573630; bh=bSHnjsAOWAaXk6MagAsbXeDOrNG/Ncxs7ohUVA+0BuE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uRWhlRafjZbl+wBmI/y7AraGDR5rU9KdfJQc0ku6xPvkckDKJaijFM1CSZ4TWQ67V zK796sQS6yGypRB1t39rp+IpMkVj45LRUykEo//kvDaqx4+1RH/Q3LKPQketQ5Cmx8 XGHmSi/K2oKN4c/vtWjglLIQKKMskPYntKoKzieo+32Pz2u9b7WtXEFiC6FZmndBac nQP3C/tr5J79qEi6ipmCR1hjUr+rFOM21VyBVQo9XWfj1FvCL433RD6WoNGJVjjEB+ LDO9EO1ObUoMxC9T4mk/mWE8Luizo/NQugBARVa2NXgIikTcJlEm8g8cRTnDvKIBY3 DgECG4jXtwYXw== Received: by pali.im (Postfix) id 1717FBFC; Fri, 25 Jun 2021 00:27:08 +0200 (CEST) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Lorenzo Pieralisi , Thomas Petazzoni , Bjorn Helgaas , Rob Herring , Gregory Clement Cc: =?utf-8?q?Marek_Beh=C3=BAn?= , "Remi Pommarel" , Xogium , "Tomasz Maciej Nowak" , Nadav Haklai , Kostya Porotchkin , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [RESEND PATCH 2/5] PCI: Add PCI_EXP_DEVCTL_PAYLOAD_* macros Date: Fri, 25 Jun 2021 00:26:18 +0200 Message-Id: <20210624222621.4776-3-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20210624222621.4776-1-pali@kernel.org> References: <20210624222621.4776-1-pali@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210624_152710_615111_4DF689A7 X-CRM114-Status: UNSURE ( 7.97 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Define a macro PCI_EXP_DEVCTL_PAYLOAD_* for every possible Max Payload Size in linux/pci_regs.h, in the same style as PCI_EXP_DEVCTL_READRQ_*. Signed-off-by: Pali Rohár Reviewed-by: Marek Behún Acked-by: Bjorn Helgaas --- include/uapi/linux/pci_regs.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/uapi/linux/pci_regs.h b/include/uapi/linux/pci_regs.h index e709ae8235e7..ff6ccbc6efe9 100644 --- a/include/uapi/linux/pci_regs.h +++ b/include/uapi/linux/pci_regs.h @@ -504,6 +504,12 @@ #define PCI_EXP_DEVCTL_URRE 0x0008 /* Unsupported Request Reporting En. */ #define PCI_EXP_DEVCTL_RELAX_EN 0x0010 /* Enable relaxed ordering */ #define PCI_EXP_DEVCTL_PAYLOAD 0x00e0 /* Max_Payload_Size */ +#define PCI_EXP_DEVCTL_PAYLOAD_128B 0x0000 /* 128 Bytes */ +#define PCI_EXP_DEVCTL_PAYLOAD_256B 0x0020 /* 256 Bytes */ +#define PCI_EXP_DEVCTL_PAYLOAD_512B 0x0040 /* 512 Bytes */ +#define PCI_EXP_DEVCTL_PAYLOAD_1024B 0x0060 /* 1024 Bytes */ +#define PCI_EXP_DEVCTL_PAYLOAD_2048B 0x0080 /* 2048 Bytes */ +#define PCI_EXP_DEVCTL_PAYLOAD_4096B 0x00a0 /* 4096 Bytes */ #define PCI_EXP_DEVCTL_EXT_TAG 0x0100 /* Extended Tag Field Enable */ #define PCI_EXP_DEVCTL_PHANTOM 0x0200 /* Phantom Functions Enable */ #define PCI_EXP_DEVCTL_AUX_PME 0x0400 /* Auxiliary Power PM Enable */