From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR03-VE1-obe.outbound.protection.outlook.com (mail-eopbgr50066.outbound.protection.outlook.com [40.107.5.66]) by dpdk.org (Postfix) with ESMTP id 2D71F7CFD for ; Fri, 20 Apr 2018 06:05:08 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Rglyy9YQNm6pBx6OksVWB1oSIZSGqDwMQFIUsJzzUuE=; b=oSMsP49FJCZxmHHH+dUWJC0hYx2WiWRN/K2L3hWX0Gtzkz7OES3xanSKu/A/s5gz8uA4EOiwKNoSVnBSovf5RoMZgCkza4bglGCsWPawBEWYAvoKbft4wB3/ZgIAvJjgK8EUnYEEi0QiMP5XQY3QyDUeGH/Tp4WTe+h22dvoaBE= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=nipun.gupta@nxp.com; Received: from b27504-OptiPlex-790.ap.freescale.net (14.142.187.166) by DB6PR0401MB2422.eurprd04.prod.outlook.com (2603:10a6:4:4a::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.675.14; Fri, 20 Apr 2018 04:05:05 +0000 From: Nipun Gupta To: shreyansh.jain@nxp.com, thomas@monjalon.net, hemant.agrawal@nxp.com Cc: dev@dpdk.org, Nipun Gupta Date: Fri, 20 Apr 2018 09:34:16 +0530 Message-Id: <1524197062-1230-4-git-send-email-nipun.gupta@nxp.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1524197062-1230-1-git-send-email-nipun.gupta@nxp.com> References: <1523114224-9852-1-git-send-email-nipun.gupta@nxp.com> <1524197062-1230-1-git-send-email-nipun.gupta@nxp.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.142.187.166] X-ClientProxiedBy: BM1PR01CA0092.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:1::32) To DB6PR0401MB2422.eurprd04.prod.outlook.com (2603:10a6:4:4a::25) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(48565401081)(2017052603328)(7153060)(7193020); SRVR:DB6PR0401MB2422; X-Microsoft-Exchange-Diagnostics: 1; DB6PR0401MB2422; 3:ky+hj+A4wG4EBayq5A6zY5szT/g1ufz7bfp9vbTAHoZABcOPwC8P/mXxorqXy8b3M5uQAHU+x+Su02p6Dy+Y3z2YNaAcbMAJlRI84gMLD4fztDQ0Fwe7HL4PVfdm60Zm6DLEtH0Oa8tXyW3Ce/kHNIFXURMLaiuqsQYLRWToWCjAOLraRHT358vK07ufzUKXhMTXU9FCukiDRXbOMIdWTgXCc7InRu+B8RBvVmnH+N31E3eF/hM3gZjLMTDMJvX6; 25:tzXUEYK4X2jdOi/t4fbOUOEwpsHzaYQbshdWM57kbsvx6P2zQ+VwP4RKaKM4YokoRfX5xj82nm8hDlvmEl4y7/U2SWkCDNv57skarMNZgtCeQ1l17bXJvMNwQgNMQ0oML4/8C3lxCoeKfhyfLw4gId9fejQkOrqY1lpmrEh+64sIP9uO2iFsBNuIzhA0gJXVJIj+iM8miUe92lavlpbNGUSFqdWpNYl22CasxiPMagupxT2Evafgnaws3lMyrWGi+yB69u12P2UtR2tj0Bnx8JYu2YfzF1sTo1pUHD5G/xBH4Lxp972DZkoNFrzEql9RGQvXIPD/QjLIXl/OtKu6pQ==; 31:FkO5Gdclh4xBsq/S/pi9deDHz1K2b+5QK2uebEweC/6A8WrrdZ/HNb5Hh97wcGPVmt1pxJ3zVSzenOclKDVdtfxh8xC974Zn4K9o5DJAEk3OEbDWalKEl4W14RHnpH51xmWgmoiGXqzosFF5TAq4r2X2FyNQVC+e2qcS+Z3GIxGHxuimqU+HizBqp8HkECP/UrST5lTK2oxDOwGn9v2dGbsOUYnKL6Hiz5d1+VYYQJg= X-MS-TrafficTypeDiagnostic: DB6PR0401MB2422: X-Microsoft-Exchange-Diagnostics: 1; DB6PR0401MB2422; 20:Y8PIuF29i97+UX7QRXoNUILyxSndYKOwlVdAG8CN+TQnZOBPUqih8KbrU2yQ5PCIjrfVbQ2BZblI46bObdWY0Ywg7ALv5pIA+E2sbkUcoUWHUT5NAGLhBb6Lk8LfMzh1Xb+tB817Zt7cRk/+0u3NLkU1fh1LbPsHzWlkQ1NVhB4MPNoBFSi45MGET6ULrBXo//IQTGoOQxaWJLvq72lSbd21WK1Jo+ZsYpAUxqSdSRKinAuNcWFe9tHHBgFeS7z4POUnNAwcrWWiTDiD0SfiZdKTdpP9IRRMP1Dez9pxKs/FGwG9KTk0uvVl3th4cl9MxNaF0/TH9PoVud5oQZDiNUTsNu1z/GuuFLR3FNPxm7r+khWlJqYE3zvSjGJNo6ThZ0troRG5xIiBnsYI1ju5AsqtuEcyeyedoxJc6qWe9tCPQ6zoEOrYxBbrzaKLn0VWKRJ3n9gF0vGIdjpbZNRwzgxpaCH+jIVyg/9ssCYd3a/n92KP8IxBym83zLCaFSBA; 4:moVvgooiN6eRQ0ocsyINLkvCy909yFRjFuiiHbrKD2YKlu1ykW1XxvkX+yJDMOs2fzs+BtxeIuzc+CEL+60MeJUVSpiOvA6Jq2yMKzuXoRysjA1xmG52fkJOhN1sUZQlGxjIn0fXuxUNGQP9QYTxWjd1Sui9Uzx9OPsBrtlIqVMxMPEGygRKlMk5PxmmcKUYqYlgnr08y3cPdOVEU6qpwCfAUXd2fjfJCxfVtBd3P8ZoFITBc8Mk24EgAKr4bmrEbDclslOwme0hh0agz3hQfcWg4/dqVGaLw4ohGCv3rafKV0+nSyaWLs/fw2xo/50Mpa9FqV777q+IZ8EYi2obRmkyNWsPY8UUNO270hePfLM= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(275809806118684); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3002001)(93006095)(93001095)(10201501046)(3231232)(944501327)(52105095)(6055026)(6041310)(20161123564045)(20161123560045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(6072148)(201708071742011); SRVR:DB6PR0401MB2422; BCL:0; PCL:0; RULEID:; SRVR:DB6PR0401MB2422; X-Forefront-PRVS: 0648FCFFA8 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(366004)(376002)(39860400002)(39380400002)(396003)(346002)(7736002)(316002)(25786009)(51416003)(50466002)(16586007)(76176011)(66066001)(16526019)(47776003)(48376002)(81166006)(8936002)(8676002)(6512007)(50226002)(36756003)(52116002)(2906002)(4326008)(476003)(305945005)(6486002)(53936002)(2616005)(6636002)(956004)(6666003)(44832011)(386003)(11346002)(3846002)(5660300001)(26005)(6116002)(6506007)(5009440100003)(59450400001)(446003)(575784001)(478600001)(86362001)(110426005); DIR:OUT; SFP:1101; SCL:1; SRVR:DB6PR0401MB2422; H:b27504-OptiPlex-790.ap.freescale.net; FPR:; SPF:None; LANG:en; MLV:nov; PTR:InfoNoRecords; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DB6PR0401MB2422; 23:PD+0vPG85AH/Nd6bYRGnbD5SRzk9tegpBVXkIRe?= =?us-ascii?Q?a7VxhkpjLSX+TEbNV8V8FL3sTiO4umsJbe1nLA2k2k2Dnkt4V/XR/5M01NOo?= =?us-ascii?Q?6qDE5+UxFrFDtY8H1yIRaLW5tABtwyuQVl/2vQVkv6QQpobPcmEeNMLt1As4?= =?us-ascii?Q?8AyfkYNDTwX0s5D4RHYMtQX2XPcgV6o/Qot9B1+0JnWErC3YvK2TX5V72T4N?= =?us-ascii?Q?lzZxy85QvMe8oy3J8S8OIp9187RM4Nl0OzMb7G0CaMyamqku0+bYLmfsYB+8?= =?us-ascii?Q?ZlmeCgI1Sf23cjhsKxH1KmB48X+EcWD1wSLKo3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eez2T+gx3D1wQlgOJmm1zSz56ZQ4TEEiSpZ26kHq0Z90te6GY0qmewNW2VeDFOK1Qn0XZknroO0eYLw4qSZ2Z6YocIZPHPab9g9sP55/YTBitwg5b512brazvrijEGB870gKN9ozsB0f2SaDU4MnTF7hfRTXNDFIziRz4ON X-Microsoft-Exchange-Diagnostics: 1; DB6PR0401MB2422; 6:OrX5OG9GEXP+wcKW4lUwYxmbojM/o5kXY0cwdIWbaFqwdBosmFmiljTJuBqhvbaBQLb1jld7eU4msfHF/avR2CkIaX+oOktzky+AcEN2GFxMVdnQ1hIirwsIWrbH1VlVhVTSEhwwtOBXSLCGvs+7dQuj7mOhsFo30wqJ84wxgv879IkTeUqlF3sU0luEsrVoz6Zs1e80s/i4IshBCSKxyWuHeolW8HH8+Wp4TSb8gthpfj8fVUm5c/y/AkduT3iCdOVhzT5sMlpTyRjvbHmYemYVpFTkhVtso1RetJtxHPt+cTv1jf//wQxR71D+eAmKc/njN3/WcskbNGTaiyIsPHOsvS2+FVP8Dhsu5OqZ0ttJD0NnshbeIKPWch9e4g6FkbGwzVIqxLCNuNdtbN++5/pdWEYhrntjqrczUos4j5I9HcBDV5Qg/Cl7+K5ufZI7QhkRl1H31rtNAAq6KSUQxw==; 5:X9yCWrwIyKtD4Veifakdl165bw9oSbaGQBkidn3FnO3b1bFFZ9I9JeL0jt5usvl/kFQLmYxtwPlBhDDdJglQWKjt06Pb7z0Nf+0o5DMgpa1xmuhC1V98Qze+lu1w3FH/gDhjZF5Q16jLEU84v6YS9MjRX2Uj2hsQnQW9h9vNGxg=; 24:axPaJF6DZasw0g/aex+VKz2sFAKSGio28G1lyB+5Nbe6+4INtYBOD4fk7Q1bKeNJKSs/6WWNcm5KgBRuzh8GtwKEQJ1n3jvbityMUPdPi6g= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DB6PR0401MB2422; 7:bRsSc1seA/4VtpVgK0L94h2o0WNrcu925pV8jI+1FYBJzrFXCuUgXl27gyMUX4MJpLINnMAR52HMYDv948cXluj3zejoZNHVYTa1Z5krouQFdU8KFEeXBF6b/tLLVPZEY9TDHITf/E7/mS+q+ktyp66qcbm8+KrzIfy25EQ4Jwczv8+DJLOpX8V7PBW7sKKFRV4UXIMzCOjoy4MRX2d8DlLa4H/UcRc8XBmJ9MJXQ2gJZ0uCnIMIuLRNpTuNMNpN X-MS-Office365-Filtering-Correlation-Id: 3b7255ae-94cb-4fee-7d0d-08d5a673e70e X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Apr 2018 04:05:05.9635 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3b7255ae-94cb-4fee-7d0d-08d5a673e70e X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0401MB2422 Subject: [dpdk-dev] [PATCH 3/9 v2] bus/fslmc: add macros required by QDMA for FLE and FD X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2018 04:05:08 -0000 Signed-off-by: Nipun Gupta --- drivers/bus/fslmc/portal/dpaa2_hw_pvt.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h index 72aae43..1b67bed 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h +++ b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h @@ -188,7 +188,7 @@ enum qbman_fd_format { ((fd)->simple.frc = (0x80000000 | (len))) #define DPAA2_GET_FD_FRC_PARSE_SUM(fd) \ ((uint16_t)(((fd)->simple.frc & 0xffff0000) >> 16)) -#define DPAA2_SET_FD_FRC(fd, frc) ((fd)->simple.frc = frc) +#define DPAA2_SET_FD_FRC(fd, _frc) ((fd)->simple.frc = _frc) #define DPAA2_RESET_FD_CTRL(fd) ((fd)->simple.ctrl = 0) #define DPAA2_SET_FD_ASAL(fd, asal) ((fd)->simple.ctrl |= (asal << 16)) @@ -211,10 +211,12 @@ enum qbman_fd_format { } while (0) #define DPAA2_SET_FLE_OFFSET(fle, offset) \ ((fle)->fin_bpid_offset |= (uint32_t)(offset) << 16) +#define DPAA2_SET_FLE_LEN(fle, len) ((fle)->length = len) #define DPAA2_SET_FLE_BPID(fle, bpid) ((fle)->fin_bpid_offset |= (size_t)bpid) #define DPAA2_GET_FLE_BPID(fle) ((fle)->fin_bpid_offset & 0x000000ff) #define DPAA2_SET_FLE_FIN(fle) ((fle)->fin_bpid_offset |= 1 << 31) #define DPAA2_SET_FLE_IVP(fle) (((fle)->fin_bpid_offset |= 0x00004000)) +#define DPAA2_SET_FLE_BMT(fle) (((fle)->fin_bpid_offset |= 0x00008000)) #define DPAA2_SET_FD_COMPOUND_FMT(fd) \ ((fd)->simple.bpid_offset |= (uint32_t)1 << 28) #define DPAA2_GET_FD_ADDR(fd) \ @@ -224,6 +226,10 @@ enum qbman_fd_format { #define DPAA2_GET_FD_BPID(fd) (((fd)->simple.bpid_offset & 0x00003FFF)) #define DPAA2_GET_FD_IVP(fd) (((fd)->simple.bpid_offset & 0x00004000) >> 14) #define DPAA2_GET_FD_OFFSET(fd) (((fd)->simple.bpid_offset & 0x0FFF0000) >> 16) +#define DPAA2_GET_FD_FRC(fd) ((fd)->simple.frc) +#define DPAA2_GET_FD_FLC(fd) \ + (((uint64_t)((fd)->simple.flc_hi) << 32) + (fd)->simple.flc_lo) +#define DPAA2_GET_FD_ERR(fd) ((fd)->simple.bpid_offset & 0x000000FF) #define DPAA2_GET_FLE_OFFSET(fle) (((fle)->fin_bpid_offset & 0x0FFF0000) >> 16) #define DPAA2_SET_FLE_SG_EXT(fle) ((fle)->fin_bpid_offset |= (uint64_t)1 << 29) #define DPAA2_IS_SET_FLE_SG_EXT(fle) \ -- 1.9.1