Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753847AbdCMUrH (ORCPT ); Mon, 13 Mar 2017 16:47:07 -0400 Received: from mail.kernel.org ([198.145.29.136]:45852 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753277AbdCMUq6 (ORCPT ); Mon, 13 Mar 2017 16:46:58 -0400 MIME-Version: 1.0 In-Reply-To: <1489174827-6033-2-git-send-email-matthew.gerlach@linux.intel.com> References: <1489174827-6033-1-git-send-email-matthew.gerlach@linux.intel.com> <1489174827-6033-2-git-send-email-matthew.gerlach@linux.intel.com> From: Moritz Fischer Date: Mon, 13 Mar 2017 13:46:53 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v5 1/4] fpga: add config complete timeout To: matthew.gerlach@linux.intel.com Cc: Alan Tull , linux-fpga@vger.kernel.org, Linux Kernel Mailing List , Devicetree List , Rob Herring , Mark Rutland , Anatolij Gustschin , Alan Tull Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1997 Lines: 49 On Fri, Mar 10, 2017 at 11:40 AM, wrote: > From: Alan Tull > > Adding timeout for maximum allowed time for FPGA to go to > operating mode after a FPGA region has been programmed. > > Signed-off-by: Alan Tull Acked-by: Moritz Fischer > --- > drivers/fpga/fpga-region.c | 3 +++ > include/linux/fpga/fpga-mgr.h | 3 +++ > 2 files changed, 6 insertions(+) > > diff --git a/drivers/fpga/fpga-region.c b/drivers/fpga/fpga-region.c > index 3222fdb..28401cb 100644 > --- a/drivers/fpga/fpga-region.c > +++ b/drivers/fpga/fpga-region.c > @@ -381,6 +381,9 @@ static int fpga_region_notify_pre_apply(struct fpga_region *region, > of_property_read_u32(nd->overlay, "region-freeze-timeout-us", > &info->disable_timeout_us); > > + of_property_read_u32(nd->overlay, "config-complete-timeout-us", > + &info->config_complete_timeout_us); > + > /* If FPGA was externally programmed, don't specify firmware */ > if ((info->flags & FPGA_MGR_EXTERNAL_CONFIG) && firmware_name) { > pr_err("error: specified firmware and external-fpga-config"); > diff --git a/include/linux/fpga/fpga-mgr.h b/include/linux/fpga/fpga-mgr.h > index 57beb5d..fd3f083 100644 > --- a/include/linux/fpga/fpga-mgr.h > +++ b/include/linux/fpga/fpga-mgr.h > @@ -76,11 +76,14 @@ enum fpga_mgr_states { > * @flags: boolean flags as defined above > * @enable_timeout_us: maximum time to enable traffic through bridge (uSec) > * @disable_timeout_us: maximum time to disable traffic through bridge (uSec) > + * @config_complete_timeout_us: maximum time for FPGA to switch to operating > + * status in the write_complete op. > */ > struct fpga_image_info { > u32 flags; > u32 enable_timeout_us; > u32 disable_timeout_us; > + u32 config_complete_timeout_us; > }; > > /** > -- > 2.7.4 >