From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E6B50CCA479 for ; Wed, 13 Jul 2022 14:19:07 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BE8BB83F30; Wed, 13 Jul 2022 16:19:04 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=amd.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="v2N0c6N/"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 0FFD983C91; Wed, 13 Jul 2022 16:19:01 +0200 (CEST) Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1anam02on2084.outbound.protection.outlook.com [40.107.96.84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 72E0083EE0 for ; Wed, 13 Jul 2022 16:18:57 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=amd.com Authentication-Results: phobos.denx.de; spf=fail smtp.mailfrom=michal.simek@amd.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XZBw0rxcJor7qaOhO4knNmAkhYI2JBFrCd6bFlpv+MBkrhU4OSgHWajLNx2FdacvcRVqUUggR65nE5WM0CeaPkLL7glO/MvxpRdY7NT0K9pfhdmbQ2Bm4eLceNcgCIeBSNZ40rpmjYKKDoqHYqk88IX6gbghgv+TFlBYiyUE/c5CaWSQmbQVDcNphpxBJsUMYpE70t4c8JI9aUZh58eautJGNw85TebvWWLrPb8ONUraD6Cn63YyYW/STW2GPZtqcrrtO45IVOziREPdSFazcTJzv2RYT07ulCSvG1ZaS+Ve4QnNXeI2zcUQ39ZGg2AyFFCUEipc2rP2mXVYZkknkg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Dh+WqlZS7Ky6pvcwq7mAi5zbDkN8oYaV4gXBua1yQCE=; b=ZiZYLRkFgirbcXt4GnEmZlE9HIoG/qN9iXLIWaNVFnmwmdUZa2Hoah3sgMKQZxfdr3WEkQiKOJ7dQ/poFZxhE2r/qZz20CF1BRkiIqv6imzlL5ZksKft3JwVGmhgaWAsQpUgul8TlDCKMj1ASoEpjLL6/GjEyqRrf9+VQcU8XLcQm4qG2246RgEXmKYKRazQaLGBtiNc4kmMhocFSmXfjuAQWYDBBFruF6Ac1hS4DvaEe9dVyQrH2JW28MYg3NQ5dnqX7v3LYxByTDmVn/SgGW6yb7jcPB8J/yWigGZr8szvmx6GBsEXAgK4J1VC6TIj2wcYz6Uz8g1hfNJXfKPECg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lespocky.de smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Dh+WqlZS7Ky6pvcwq7mAi5zbDkN8oYaV4gXBua1yQCE=; b=v2N0c6N/fXjPza9usEKUPee/KPlgPxPrcw395ZYJej+GCgz/4PjNC8k+8nIbVO6/n+NA2B4qbGQgsOxo3K8f5N4TV9CQKATQrqVhzyx4PZT4TqCQZCgO4ezk2e3Ko2S6tzhn8jL6E/6Y7Hm7ZgKIDO7wz+3XeyGOXzJcehYNfyQ= Received: from BN9PR03CA0706.namprd03.prod.outlook.com (2603:10b6:408:ef::21) by BY5PR12MB3874.namprd12.prod.outlook.com (2603:10b6:a03:1ad::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5417.16; Wed, 13 Jul 2022 14:18:53 +0000 Received: from BN8NAM11FT045.eop-nam11.prod.protection.outlook.com (2603:10b6:408:ef:cafe::e9) by BN9PR03CA0706.outlook.office365.com (2603:10b6:408:ef::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5417.16 via Frontend Transport; Wed, 13 Jul 2022 14:18:52 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by BN8NAM11FT045.mail.protection.outlook.com (10.13.177.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5438.12 via Frontend Transport; Wed, 13 Jul 2022 14:18:52 +0000 Received: from [10.254.241.52] (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Wed, 13 Jul 2022 09:18:49 -0500 Message-ID: <667a7c1e-c722-b44a-503e-94bc84a354cc@amd.com> Date: Wed, 13 Jul 2022 16:18:47 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH v2 1/2] fpga: Convert SYS_FPGA_CHECK_CTRLC to Kconfig Content-Language: en-US To: Alexander Dahl CC: , Alexander Dahl , Simon Glass , Stefan Roese References: <20220713123307.21314-1-post@lespocky.de> <20220713123307.21314-2-post@lespocky.de> <20220713132044.GB1941@falbala.internal.home.lespocky.de> <20220713140703.GD1941@falbala.internal.home.lespocky.de> From: Michal Simek In-Reply-To: <20220713140703.GD1941@falbala.internal.home.lespocky.de> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 95bb0b49-78b3-465b-f37d-08da64da9cbb X-MS-TrafficTypeDiagnostic: BY5PR12MB3874:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: uEORfDgzp89V8+DlmAFqFzzMKh9+e9KXHop6T9VVtVyJ+K79Z3eFbj/Z8Ejb8EpsFiMkQmvrqu+y8JUSXOU5Qdy9iJc8RXgJoc2o2cECCPNvFv5LQXb6VrTF4kt3IHyNrltML9iAKmMJbbZtROh+RmedTYdMAUDdc1Dpbayrb5jL9ON0I8MOtWKObf8Qc2IOH1hcqJjiU8PZ4nkLqeTeZRmgKZ14Jx9bSgHkgYHh5W+OGN4TGxZbxeOoTbDz7Yg8JvlrihehZO2VHWgXy0VdhKw1JWV6tfx5UF/2XbDuHelVvjn7ezVD8td7SIvWBGoo6GyynvevqBEpzhs1SwojM2QC5M04z7WkWEYgQLyiXvo01FVdgcIPkKFU5B7HWIXtQHVlYumxjnerJ6YAr7u3MfBFkB19pttyTkYYAF5PLiyL/TxvueHBXAgCP3n8RdsjMemf3oVDYUjsFveQKQ7F3d2PzBxCcXm/yxd0uZfU73A0R/2pptI/VR0UPirnqqWyw3wZAA5BiV7l77iploShI8O0R8ycINZoPVx8M9HjgASIR4mV2EtJsruHHLbJJ6Wfd0XZyEkvDyOLAQi47dRXOHo02wQgljm1L2fxK1yYGAcY0AdBY9gbP0ZL1Vbn5XdWq2gdDbtyq6P6congq1amJUNVEYSnyitAlBX20APC1wQeMwPWXGU/5OQ+jLs0M0I7CaYXtopvjKkrHJVATCITENcZT4Ua82bctF4oxQSTSgWfZt2GI4O9vV8kAgeMh8+SrTvBFDlJSnzhio7sQuhZs8P87ZZVSLVpD2pcst8EtIEdVFvBLlpTQ0hf7hLDTOWkQq8dkcISEv16QWTmauUhyE4CxTjb+ZY3wxsNzDwphZSOWjx9OpjBJMDhz0C8SRrkLZKqGVmt+fFzcG8xhCpi5oWXaEwlxDobWJtIOXcM4T91p8nBFRAWWtQbynFFJyPJ X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230016)(4636009)(39860400002)(396003)(136003)(376002)(346002)(36840700001)(46966006)(40470700004)(70586007)(40480700001)(36860700001)(81166007)(26005)(31686004)(70206006)(54906003)(186003)(44832011)(16526019)(8676002)(4326008)(36756003)(5660300002)(6916009)(8936002)(2906002)(47076005)(40460700003)(426003)(82740400003)(86362001)(336012)(82310400005)(478600001)(83380400001)(53546011)(41300700001)(31696002)(2616005)(356005)(316002)(16576012)(36900700001)(43740500002); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jul 2022 14:18:52.0932 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 95bb0b49-78b3-465b-f37d-08da64da9cbb X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT045.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR12MB3874 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean On 7/13/22 16:07, Alexander Dahl wrote: > Hello Michal, > > On Wed, Jul 13, 2022 at 03:20:44PM +0200, Alexander Dahl wrote: >> Hello Michal, >> >> On Wed, Jul 13, 2022 at 02:56:08PM +0200, Michal Simek wrote: >>> >>> >>> On 7/13/22 14:32, Alexander Dahl wrote: >>>> From: Alexander Dahl >>>> >>>> After commit 8cca60a2cbf2 ("Kconfig: Remove some symbols from the >>>> whitelist") downstream builds failed for boards setting this in >>>> include/configs/… >>>> >>>> Two FPGA drivers consider this definition. >>> >>> 2? >>> board/astro/mcf5373l/fpga.c >>> drivers/fpga/ACEX1K.c >>> drivers/fpga/virtex2.c >> >> These are one board and two drivers. What is your question? >> >> Greets >> Alex > > I'm sorry, this was misleading. I added some more comments below and > forgot to remove this line indicating end of message. Considering > your answer I guess you stopped reading here? yes I did. >> >>> >>>> >>>> Signed-off-by: Alexander Dahl >>>> --- >>>> README | 3 --- >>>> drivers/fpga/Kconfig | 4 ++++ >>>> 2 files changed, 4 insertions(+), 3 deletions(-) >>>> >>>> diff --git a/README b/README >>>> index ff0df3797d..8c31e5c0e3 100644 >>>> --- a/README >>>> +++ b/README >>>> @@ -1346,9 +1346,6 @@ The following options need to be configured: >>>> If defined, a function that provides delays in the FPGA >>>> configuration driver. >>>> - CONFIG_SYS_FPGA_CHECK_CTRLC >>>> - Allow Control-C to interrupt FPGA configuration >>>> - >>>> CONFIG_SYS_FPGA_CHECK_ERROR >>>> Check for configuration errors during FPGA bitfile >>>> diff --git a/drivers/fpga/Kconfig b/drivers/fpga/Kconfig >>>> index 76719517f5..53d91676e0 100644 >>>> --- a/drivers/fpga/Kconfig >>>> +++ b/drivers/fpga/Kconfig >>>> @@ -91,4 +91,8 @@ config FPGA_ZYNQPL >>>> Enable FPGA driver for loading bitstream in BIT and BIN format >>>> on Xilinx Zynq devices. >>>> +config SYS_FPGA_CHECK_CTRLC >>>> + bool "Allow Control-C to interrupt FPGA configuration" >>>> + depends on FPGA >>> >>> Please write help message. >> >> Okay, I'll have to invent a new message here, if the prompt is not >> self explaining enough. Since this is not conversion, but adding a >> new message we did not have before, should this go into a separate >> patch? I can't see any reason to have it in separate patch. And maybe CTRL+C is better then Control-C >> >>> >>>> + >>>> endmenu >>> >>> >>> And can you please remove this code from drivers/fpga/virtex2.c >>> >>> 48 /* >>> 49 * Don't allow config cycle to be interrupted >>> 50 */ >>> 51 #ifndef CONFIG_SYS_FPGA_CHECK_CTRLC >>> 52 #undef CONFIG_SYS_FPGA_CHECK_CTRLC >>> 53 #endif >>> >>> it doesn't make any sense. >> >> I have no hardware to test this and this is out of scope of the >> conversion patch itself. likely none has virtex2 around to test it. When you are converting that symbol it is good to fix this. Separate patch is fine to get rid of this. >>> >>> And with 2/2 please also remove >>> drivers/fpga/spartan2.c:18:#undef CONFIG_SYS_FPGA_PROG_FEEDBACK >>> drivers/fpga/virtex2.c:44:#ifndef CONFIG_SYS_FPGA_PROG_FEEDBACK >>> drivers/fpga/virtex2.c:45:#define CONFIG_SYS_FPGA_PROG_FEEDBACK >>> >>> Thanks, >>> Michal >> >> I may be able to add an additional patch or two, but those are all >> FPGAs I have no experience with and I can not test those. This would >> be more or less guessing based on code reading. I can try next week, >> not able to do this currently. >> >> Thanks for your review. > > I'll look into all this next week again. None really has spartan2/virtex2 hw around. I personally started with Spartan3 but didn't power it up for a lot of years. It is just about that there is no reason to undefine something if we have Kconfig symbol for it. Just enable it or disable it. That's it. No need to test it on any HW. Thanks, Michal