Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755328AbbHNOik (ORCPT ); Fri, 14 Aug 2015 10:38:40 -0400 Received: from mail-bl2on0074.outbound.protection.outlook.com ([65.55.169.74]:60896 "EHLO na01-bl2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751429AbbHNOig (ORCPT ); Fri, 14 Aug 2015 10:38:36 -0400 Authentication-Results: spf=fail (sender IP is 66.35.236.227) smtp.mailfrom=opensource.altera.com; infradead.org; dkim=none (message not signed) header.d=none; Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=atull@opensource.altera.com; Date: Fri, 14 Aug 2015 09:33:13 -0500 From: atull X-X-Sender: atull@linuxheads99 To: Moritz Fischer CC: Greg KH , Jason Gunthorpe , , Michal Simek , Michal Simek , , , , Pantelis Antoniou , , Grant Likely , , , , , "Philip Balister" , , , , , Nicolas Pitre , , , David Brown , Rob Landley , , , , , Linus Walleij , , , , Kumar Gala , , Petr Cvek , Alan Tull , , Subject: Re: [PATCH v10 3/8] add fpga manager core In-Reply-To: Message-ID: References: <1439487452-23977-1-git-send-email-atull@opensource.altera.com> <1439487452-23977-5-git-send-email-atull@opensource.altera.com> User-Agent: Alpine 2.02 (DEB 1266 2009-07-14) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-Originating-IP: [64.129.157.38] X-ClientProxiedBy: DM2PR07CA0011.namprd07.prod.outlook.com (10.141.52.139) To BLUPR03MB1508.namprd03.prod.outlook.com (25.163.81.26) X-Microsoft-Exchange-Diagnostics-untrusted: 1;BLUPR03MB1508;2:nSkNcCxoeU3+LsgDwK9vHTXPbwKU5kKtjuWCZmE1rM+71xQSfOUZmt9fK1nrcQS2X4HCN6iA9GhFA2W7jEp1aDtl375NMTnVhpqBW2QhnUfwADhw7U/oNQWl4EoCZVClpdZCUuOJobqf1Vff902y4C8TNOQltDXtETKbc7MmceA=;3:XG9OhoANrYpVVZXch7o5mvtdJzx4z8Qem7PVo96iuHzMddI4IFg5jG/ftb6C5VJQaY3ONwmb8EkkOYiFXvryACaZ2C6Zi2OavJeAEeHPsYEu05VOdN2kmVlXMAoXkfRrLbcMeij8dZKd2GfcmiwB0w==;25:37I0WjghnALk3VENKzOaIG7mpTgiU5Dz06mu12JDhjfq2nJA7OfpYkCVdvMTLIHELexDk8EYqpIotmCFnuDBEPproB2aFhbzzoRnh02mwoVRz7JuNlY2J9naiqZH8E+XKysZ01+DvYBaHS3y1k5kbfOypM6s3w48v9Yg68PTkTcAIs9Y5qmEbuOaQVn3IZGQvRHQzAu6NZ2NGaMfiwplHd7tRXixdiVaHIEczYMxVVFXFdlXivB7sOtBFbAfdHl+OcSKFnS2ZLo1hTNvB5TMAg==;20:ECPx/wzhLQdsgUKZ0di5xoHNbpETj45wq1xeDsjkbd2BiiRk3lJ2QsyiH2gEcX1OWcYI4gyFeQanbSDYR51k4W44Kl5NolQj52NvhNglBvhsN5YmRXsBwl+QZCRuxSSegdt5criE46SQ7C0NKwgvCKPUTGqCIzwz9LY27yrCz4A= X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BLUPR03MB1508;UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BLUPR03MB033; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:;UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(5005006)(3002001);SRVR:BLUPR03MB1508;BCL:0;PCL:0;RULEID:;SRVR:BLUPR03MB1508;BCL:0;PCL:0;RULEID:(601004)(5005006)(3002001);SRVR:BLUPR03MB033;BCL:0;PCL:0;RULEID:;SRVR:BLUPR03MB033; X-Microsoft-Exchange-Diagnostics-untrusted: 1;BLUPR03MB1508;4:lofq1NgElJl5bfm4Ebfo7N7WNibLsgETcVFfHWS9KBrmaW39Rw+PMG62LilflonvcOAmziLzrE9Q2aJsjzA6FLy/hyCTxXqvMx6eyy3xYkJDZ/NU0hNlwAbemONZ/2YYpR12C4UZr3kcjPx3ts5eFwOjOnYyVH9rpcGa4elOEPv+7MlaiCWJmDtlPnbOQdqxOfD/Ky94XQvLVzpvOX5nqnywlj1YoEDgUZo1lTwHi5cmYrErOlxUiFTSV7CcL4Gt6i4Y5y1fzOPIX5IzvcAYG1rY9XHYy5Dj+Krzk6mOOdk= X-Forefront-PRVS: 066898046A X-Forefront-Antispam-Report-Untrusted: SFV:NSPM;SFS:(10009020)(6009001)(199003)(51914003)(189002)(24454002)(105586002)(5001860100001)(5001960100002)(81156007)(4001350100001)(92566002)(4001540100001)(77096005)(106356001)(5001830100001)(53416004)(107886002)(110136002)(23726002)(54356999)(97736004)(64706001)(2950100001)(83506001)(101416001)(62966003)(50986999)(42186005)(86362001)(19580395003)(86152002)(15975445007)(122386002)(76176999)(5001920100001)(47776003)(189998001)(50466002)(68736005)(69596002)(33716001)(77156002)(87976001)(40100003)(66066001)(46102003)(46406003)(7059030)(4001430100001);DIR:OUT;SFP:1101;SCL:1;SRVR:BLUPR03MB1508;H:linuxheads99.altera.com;FPR:;SPF:None;PTR:InfoNoRecords;A:0;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics-untrusted: =?us-ascii?Q?1;BLUPR03MB1508;23:Z4FTNhRjFoOKLF89yVZbA+QSe9N/nolUAA9wglUGn?= =?us-ascii?Q?/xGYo5kkDuSN/8azZOXzC5/2r8PD0jXCHpqVNMN7C6Y1efWdchdEmQ4GQZnV?= =?us-ascii?Q?EbttutOBdBxAThcBARVhDU7YXP8CXjFLgMUUk8V7L06YPnE+Ubz1sBAfKJ0A?= =?us-ascii?Q?ZjWR+5EK2k9DBbzdPaKRD70d/rXnxaoyram39ihwxgn9DitR5eZ7CdA+TgtN?= =?us-ascii?Q?tg4bKlWkU7yfmrT76mRqVCpvhR+AfPvtEHj8qpiSs384gVXnfLVWy4u4h6x5?= =?us-ascii?Q?7uBBCiXANfYv4XbzICeJqRly7R12ois/mEDt/RENxK4BBxluuaHKdz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xpKigBtGAYxym5V9xdEbrtBBVnD89ZDKUyXAsw?= =?us-ascii?Q?/mIF83xlBkHxTcDF0CCpVhdcsfr06pth4eFLaAQRHmGndBqL1FnQZ+kFVUP9?= =?us-ascii?B?UT09?= X-Microsoft-Exchange-Diagnostics-untrusted: 1;BLUPR03MB1508;5:0iDgVbuPcW7S5PJA6a2VWrThaYSoP2BzdA4SvrHrPyUVYH+92MzZrcodINq/DVHT2KYeCQhl9KqFMyOd6/MgUby+aGDDN+mid6noIvq9qplK69xkzF+xRZaXKizoCOyzKVl7554PHtut963+d/CSDQ==;24:VG2bmuD+HURS4VIe6h6akBqhIKodN7x4gG2wCNFNLDZvmcn7ICEVR7xgzVgDzbbWYAxuHfoTIleBuSjcGCzCHUyRTHhayOTmP83WT4Gro+U=;20:C0ojF1pGZO/qsnv5fKycNUB++PCVSZogU1SCOBv1NgdBu+R3K3mTKp6CqRydpW7NmH5XGCEQwPFXRkJxk74FpcA/14c6VrnQSBOJJQYFYGgt6RGpD41sH+oAgZegsjeG4pNl2cfCbDQQAzPj9dBtIkycdv1AExD92Y86UvW9no0= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR03MB1508 X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: BN1BFFO11FD045.protection.gbl X-Microsoft-Exchange-Diagnostics: 1;BN1BFFO11FD045;1:9PoS13WAnyvvoWqXE6adoBTGlifw878gsJPfR5vTss3T1XsZeyzdFARhgAXndjENzrO57NiD/ENPxzBbs5u6I8GAp+r9C4qrbnQ83wRSd//AX9P9iBojczvNLu38ysqd63aVQN2PmDiMnZtZBHexctIONesr8NYtTMkoc7072w4gA1XG3O7NrSDFtD/y6MKjPze+RfNnU4ey5ul9o6o7mT0ZgE4H+7uE3hQRGsFibaA1HMUIdeUaMt/a2wdBYeRn0xqUZ+oUkbFG7N5o+wt4CYUuIN2hLu59M7Oax6jNAh4HuH598BEU5rVleXKTVR7sQku7O2NH0udEWcl+tUjqXztxoyGNB1ZAfohzbdNiUSKZR1PgWuRjg0ticQJNIbmKRgcqr1ufC4aAnZvSJ5yBbw== X-Forefront-Antispam-Report: CIP:66.35.236.227;CTRY:US;IPV:NLI;EFV:NLI;SFV:NSPM;SFS:(10009020)(6009001)(2980300002)(3050300001)(339900001)(199003)(24454002)(51914003)(189002)(6806004)(4001350100001)(4001540100001)(6070500001)(5001830100001)(5001860100001)(107886002)(189998001)(81156007)(122386002)(40100003)(5001960100002)(110136002)(97736004)(19580395003)(50466002)(23726002)(46406003)(46102003)(86152002)(2950100001)(86362001)(33716001)(83506001)(66066001)(85426001)(16796002)(76176999)(54356999)(15975445007)(106466001)(77096005)(92566002)(77156002)(62966003)(50986999)(68736005)(87936001)(64706001)(47776003)(53416004)(7099028)(7059030)(4001430100001);DIR:OUT;SFP:1101;SCL:1;SRVR:BLUPR03MB033;H:sj-itexedge03.altera.priv.altera.com;FPR:;SPF:Fail;PTR:InfoDomainNonexistent;A:0;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: 1;BLUPR03MB033;2:t9eqdMP/yt1trx9EpPn14IRWeCLsmvOhrZS+dx8ZhNSgjWnpy6R6fUTlR2GHZJRUaljVULnajRzfn19D/klYiiMO56f68y537kVyFLOuexKYE/Q5fjki2BsOJjlPfWUVx7LxPbM5LcUU5x/a8LGb+crPSuBIMKc65rixL/7gRMk=;3:bNtFNAP0hy1IzPx7MrWF9FsVAeN0pDX8OD9CAT1KB9Ivq2MTSvOZiYhz306dqTldrNy9205gbnagY4C+ifUhSAtrrKKyXSx0hBIhY2FNZ/G7ptOdmJkV3XY21zgW4EDXgdP7vr4h4tT2JfXmaNGgkss6ja/pMssAHgnLoR+ZHmny6RTaAe3RqTsA1omywai0ShBFN25vc17GGeKR0WTWYYXI45ZpDvCrMj8nsoVs9lQ=;25:vbv17RlpLz47RDHT+Zsbn0IIkMTTg97b0SDKWyIUB3k/A1iWF5wbub5T7nz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Pcv51fUL?= =?us-ascii?Q?ChJvn2l1/YMPnU1WCpUa0LsgfAoofkEu0gd1drw5FKOX4+wDJ0hETG69VvWQ?= =?us-ascii?Q?izjVqxjIZe5ieV/WMKccU1qd5E/qDYDLNU4hzZ24HxNfgWIWoadjuvXpd57m?= =?us-ascii?Q?fsrzIUgmk942woF8znkWdAUTE1utEf5WwY4yXERW0yNCFtcrrjEl9d5mVyM+?= =?us-ascii?Q?Q+07g7QR8csq7OXIqr5iSDFEbgtGPMCRZKgyudRkmmiX9IsJRio1W258lak3?= =?us-ascii?Q?yBbQ=3D=3D?= X-Microsoft-Exchange-Diagnostics: 1;BLUPR03MB033;5:dRADnhTAGkVkiNX04Jesx1yTLkh16VFQAYDR5pJJ6DlYR6wzzuJ17tSzaaafA9Aejj3L06r4awK80zIJNBgnczw4Ci8yip0vHojl+8Ii2hlHk52eE0lRTRo+2lDLhMsxg1l0ZDwcqApqEh9VXppllw==;24:0C1l0e8NPl+KRL1+bGzj/fNmR+8qq6Mhcxv9sH5H3oVTpPKRaYkSZiw49xevBCWx6C+NVTphPOn4G1BkxndecfTrAs5Z0Rfgja30NX7BBNI=;20:nJetqksKkcEVSHdZ42Y+0oxcoHWgVSl3xVl5y0cR6yHUBVM/vOu0yJszpQqJnskGGvcNtKQGS7cynlSS8yHUDt7XkTML6iEIkeAsNj/K3SNrgljbaFFQ8w4oXi3LxGEhJ0/7kCoP3EQZKJd3qbc5MZpxVQGfixBknI3mRS2hf1c= X-OriginatorOrg: opensource.altera.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Aug 2015 14:38:24.4818 (UTC) X-MS-Exchange-CrossTenant-Id: fbd72e03-d4a5-4110-adce-614d51f2077a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=fbd72e03-d4a5-4110-adce-614d51f2077a;Ip=[66.35.236.227];Helo=[sj-itexedge03.altera.priv.altera.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR03MB033 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1748 Lines: 49 On Fri, 14 Aug 2015, Moritz Fischer wrote: > Hi Alan, > > I've updated my Zynq driver (it can be found in an older version > against your v8 in the Xilinx tree, too) > > https://github.com/mfischer/linux/tree/alan-fpga-mgr-v10 Since we are both already using this and have been for a while now, I hope it can go up into the mainstream instead of continuing to exist only in Altera and Xilinx's git trees. > > to use your v10 version of the patch. Either I'm using the API wrong , > or it never gets to the 'operating state'. I'm sure you are doing it right. > > + } > > + > > + /* > > + * After all the FPGA image has been written, do the device specific > > + * steps to finish and set the FPGA into operating mode. > > + */ > > + mgr->state = FPGA_MGR_STATE_WRITE_COMPLETE; > > + ret = mgr->mops->write_complete(mgr, flags); > > + if (ret) { > > + dev_err(dev, "Error after writing image data to FPGA\n"); > > + mgr->state = FPGA_MGR_STATE_WRITE_COMPLETE_ERR; > > + return ret; > > + } > Maybe I'm misunderstanding something here. Shouldn't we set mgr->state > = FPGA_MGR_STATE_OPERATING > here, seen that the _show function below uses the mgr->state? The FPGA gets programmed, but state wasn't getting updated. Should have "mgr->state = FPGA_MGR_STATE_OPERATING" here. Will add in v11. Thanks for the review and the ack. If you see anything else that seems wrong, please let me know. Alan -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/