Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp2904153ybi; Mon, 17 Jun 2019 12:25:10 -0700 (PDT) X-Google-Smtp-Source: APXvYqw6cvpE568ecMp7I/ML6lYIu6+G1NVo8T+BVsOL2Iv1mGPE+inc3lBkzR2CX0RwFkbU4bba X-Received: by 2002:a17:902:da4:: with SMTP id 33mr48173010plv.209.1560799510143; Mon, 17 Jun 2019 12:25:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560799510; cv=none; d=google.com; s=arc-20160816; b=bGmFxw4yf2mkyjF8WD6qnt06igx7u+Nt/xn3GIcr6BjON58yv2evpr1n2wOnIPZp95 MqmdriWso2TzOMoQn+FPB53GWk9lPIFbBDUHfULGzpMVAfKGkSVydb34Ry8B++OcLO+8 HEKUJiFGQwOj4hatQkfeswKJ/ZXZZTZ8W5Ji1ETfgB2JX1JGf9nBuydvegFOYsCdSxhW 5eSPXQNwkK6MBxReHNvA5+vTUyh2lLQBOSJee8x+7bV6SJ4jqof3VHyQ0TlHREdU7okC +HOWWWnWtB5NXYb8xtO3AX2sJDAnmjBS5pBmSWlkvLQCT4LHyroA8GLh6aDKJwCRUm6H WKhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:references:message-id:date :thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=XJY3HURf4B+Uyav3u4C4mG294/93fmChqXHtGwXZY20=; b=S5YAp3v56F2KF8jTo2OemaTi891kf2GAGMo5ti57BHUvk8S9hW3aQO1JKP+pklsD0D TebnWsfxNUByGGGdo0DUmE9XXjA+BadG61m5aruPVeoRYd2YjPHMtbdm2V+OIoAhZs4B YEM89t0SLLD68hQ/VQ1xoDwzlfgNSGxQ7inuBZ4YISO4GbLUfJr83SYjeVuVCHjycEIR qByf0wXRiKTAJSNPh7zLdJm9kkvfHN1TL0ZfMlKEDdMXjdt/SJW4x03YmXipcepevlpp GIlg7mHpfBA61otoVvNvOTYWgFoUG8whCuF8/tYcjbplqPqvnSaSSbhth9S9QQ8Nfpyr vWsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=WxJa7wXQ; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cd3si6948201plb.228.2019.06.17.12.24.48; Mon, 17 Jun 2019 12:25:10 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=WxJa7wXQ; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726822AbfFQTYa (ORCPT + 99 others); Mon, 17 Jun 2019 15:24:30 -0400 Received: from mail-eopbgr130072.outbound.protection.outlook.com ([40.107.13.72]:27430 "EHLO EUR01-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725938AbfFQTYa (ORCPT ); Mon, 17 Jun 2019 15:24:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XJY3HURf4B+Uyav3u4C4mG294/93fmChqXHtGwXZY20=; b=WxJa7wXQ97WsplDi3QUelB3xlibQ4TtRLl+0p0LFnBhpQ3aYm19T6/1pVfwJ2xXgu53s8wp0SblVU1keD+/bBEZRuskV8p5SeRizgbRKbMqVzN3z/xbFlcrYyA1Tlu7/pBUq8LVx5QQdde3SFCN0+B0YwDUQrK/aLS9wiDCDHlI= Received: from VI1PR04MB5055.eurprd04.prod.outlook.com (20.177.50.140) by VI1PR04MB5470.eurprd04.prod.outlook.com (20.178.121.208) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1987.13; Mon, 17 Jun 2019 19:24:25 +0000 Received: from VI1PR04MB5055.eurprd04.prod.outlook.com ([fe80::9577:379c:2078:19a1]) by VI1PR04MB5055.eurprd04.prod.outlook.com ([fe80::9577:379c:2078:19a1%7]) with mapi id 15.20.1987.014; Mon, 17 Jun 2019 19:24:25 +0000 From: Leonard Crestez To: Andrey Smirnov , "linux-crypto@vger.kernel.org" , Horia Geanta CC: Chris Spencer , Aymen Sghaier , Franck Lenormand , Cory Tusar , Chris Healy , Lucas Stach , "linux-kernel@vger.kernel.org" , Iuliana Prodan Subject: Re: [PATCH v3 2/5] crypto: caam - correct DMA address size for the i.MX8 Thread-Topic: [PATCH v3 2/5] crypto: caam - correct DMA address size for the i.MX8 Thread-Index: AQHVJSZIVXANdmo1E06O+7eMXYofbw== Date: Mon, 17 Jun 2019 19:24:25 +0000 Message-ID: References: <20190617160339.29179-1-andrew.smirnov@gmail.com> <20190617160339.29179-3-andrew.smirnov@gmail.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=leonard.crestez@nxp.com; x-originating-ip: [192.88.166.1] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 5460fb4b-aa15-493e-9f26-08d6f35968f6 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020);SRVR:VI1PR04MB5470; x-ms-traffictypediagnostic: VI1PR04MB5470: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-forefront-prvs: 0071BFA85B x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(346002)(39860400002)(396003)(366004)(136003)(376002)(199004)(189003)(71190400001)(6506007)(53936002)(26005)(81156014)(102836004)(186003)(7696005)(486006)(476003)(53546011)(14454004)(8936002)(52536014)(74316002)(81166006)(446003)(478600001)(7736002)(64756008)(256004)(3846002)(76116006)(66946007)(110136005)(66476007)(86362001)(8676002)(66446008)(68736007)(5660300002)(6436002)(4326008)(25786009)(99286004)(54906003)(6116002)(73956011)(76176011)(91956017)(66556008)(2501003)(71200400001)(66066001)(316002)(55016002)(229853002)(4744005)(44832011)(6246003)(9686003)(33656002)(2906002)(6636002)(305945005);DIR:OUT;SFP:1101;SCL:1;SRVR:VI1PR04MB5470;H:VI1PR04MB5055.eurprd04.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: S2UadDtTlYG6ImNGOtp01+woYApGyG5djlxC6QWaaUbs9CZwHZ3OcoIJV6ly3jDlco8a89UbQMrtPY+qQeriHswNG1VdV7iC+GA5VRKFCbuWprZiwrsE4JyyEYaRdyWXQXlmbO0GeNfl7gEhBKohqgse7yeCDrqlqgBmpQcypDGc3/rkgnNDpmrm7wsW3vXqNpHo1UXo0ccCfMt1bdVMjdLFSSrx/QHSW9iUpArehsJzJhj6zVh/A6ihtQX5ubLoQZlVPj84ixkH4E6JqCTRhb8qY1z6ozbGzcsypg/ma/C7dnuvKajUf3Gt3r2+ynnHkJyAtLg0spzXz0jyahi5IykWEjl3pqN3zYbEBvVHw2RyhShGGHw6DZ7g7PKaypyuQs5r+In/9eJoRbgl8jqoARPE7d6//VdSuYpO/6jzGWM= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5460fb4b-aa15-493e-9f26-08d6f35968f6 X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Jun 2019 19:24:25.6516 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: leonard.crestez@nxp.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB5470 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On 6/17/2019 7:04 PM, Andrey Smirnov wrote:=0A= > From: Chris Spencer =0A= > =0A= > The i.MX8 is arm64, but its CAAM DMA address size is 32-bits.=0A= =0A= > +/*=0A= > + * On i.MX8 boards the arch is arm64 but the CAAM dma address size is=0A= > + * 32 bits on 8MQ and 36 bits on 8QM and 8QXP.=0A= > + * For 8QM and 8QXP there is a configurable field PS called pointer size= =0A= > + * in the MCFGR register to switch between 32 and 64 (default 32)=0A= > + * But this register is only accessible by the SECO and is left to its= =0A= > + * default value.=0A= > + * Here we set the CAAM dma address size to 32 bits for all i.MX8=0A= > + */=0A= > +#if defined(CONFIG_ARM64) && defined(CONFIG_ARCH_MXC)=0A= > +#define caam_dma_addr_t u32=0A= > +#else=0A= > +#define caam_dma_addr_t dma_addr_t=0A= > +#endif=0A= =0A= Wait, doesn't this break Layerscape? Support for multiple SOC families =0A= can be enabled at the same time and it is something that we actually =0A= want to support.=0A= =0A= --=0A= Regards,=0A= Leonard=0A=