Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp315030pxa; Wed, 5 Aug 2020 01:42:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyHUe7Y5Ul39xuZsOx+6Xn7r7KY4Zou5Pz2UVXDrfU40oN8KPKoNN6h4Kf2cCfWLWG/Kkp6 X-Received: by 2002:a17:906:b015:: with SMTP id v21mr2069101ejy.507.1596616933083; Wed, 05 Aug 2020 01:42:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596616933; cv=none; d=google.com; s=arc-20160816; b=PGjV3QbQHzyUulafN/MGnb59rpbZ63yTt5FYMUBceR22Pp6ikMB3vmmpwgKSa9Dhz3 UuetTmgsklZiMe/xBQ+KnPy2bGKJjA6b94FwSAJnw5UtJFAfUK+tE7L4t9LEWow3auQb O6MHIfNfTcOkAdQ5rbH86TuK98WuA9RqxGAU35ECHRO6m6fMfDrBQ5R91Zqx/mEv1ysO kAPCyEcfwjpbp4hiiIhm5ccNKjdxpVfS5DpbnyAegd/3E0bxOVtRd8+CRKu/V54nvgDN RN1JF6J+M0KTbfMjBq3y4j+R5idnD2S04nmUzj9+7liac/V8SPH55Scu4Nv1mMl7rvJV +IFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:ironport-sdr:ironport-sdr; bh=+N4JxGkuUcwSRGhORyxYlOqwFIAXV0axv2U/As9pSWo=; b=RVc0x+gVpobd9SPqyQUYFmM0jcALVa2XPf2K5t89Dnn6piHM+FXfXG2bxkW4Rc0Udc QbFTHdTs9K+5kFE4kY0mpfXTnlxZQoNIa6AKOJyXgKtkltTbTUubaNwF1+YIYPv4F1ju rMzeUXtTsLAmwA4rMPf+AgDeKES0xI46a6rvt3T/Mio47K+vLbhKI2Ayrx0zoiJPSeNO gFd4de0HLqSzzHyLK/XP3sC0r9uLhyCCimpFf2zOf92JmCJSn88ROCfAh327NbeniS3i Guywl+uH+z87FkPUOAtyw4RBUMZDr1E/GDhzBBPgltFXBnpUaJh8+w8bCTsalP006ZAW G6WA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b18si835020eds.208.2020.08.05.01.41.50; Wed, 05 Aug 2020 01:42:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726846AbgHEIjg (ORCPT + 99 others); Wed, 5 Aug 2020 04:39:36 -0400 Received: from mga12.intel.com ([192.55.52.136]:46257 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725963AbgHEIjf (ORCPT ); Wed, 5 Aug 2020 04:39:35 -0400 IronPort-SDR: PlVoAU24o2O+fqv2sX6CsxzlkFAx0E9IawDJLi+xqMyBJf5Y/TwrcR+Q5XQ9AmST6ztAY9zOWK Q5efib9/ZZLg== X-IronPort-AV: E=McAfee;i="6000,8403,9703"; a="132053318" X-IronPort-AV: E=Sophos;i="5.75,436,1589266800"; d="scan'208";a="132053318" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Aug 2020 01:39:34 -0700 IronPort-SDR: guzNlBMCBPFNVze+bJ3F+LvIMVtWCcor+lqNMrTXYz2j/SaFBkfDzuOlQZsPTvdakmfzW48qfb D+VxQmMPYeKQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,436,1589266800"; d="scan'208";a="315673885" Received: from yilunxu-optiplex-7050.sh.intel.com (HELO localhost) ([10.239.159.141]) by fmsmga004.fm.intel.com with ESMTP; 05 Aug 2020 01:39:33 -0700 Date: Wed, 5 Aug 2020 16:36:05 +0800 From: Xu Yilun To: Tom Rix Cc: mdf@kernel.org, linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org, lgoncalv@redhat.com, Wu Hao , Matthew Gerlach , Russ Weight Subject: Re: [PATCH v3 4/4] fpga: dfl: add support for N3000 nios private feature Message-ID: <20200805083605.GB20262@yilunxu-OptiPlex-7050> References: <1596524715-18038-1-git-send-email-yilun.xu@intel.com> <1596524715-18038-5-git-send-email-yilun.xu@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thanks for the word smith. I'll add these changes. Thanks, Yilun On Tue, Aug 04, 2020 at 11:45:33AM -0700, Tom Rix wrote: > Some minor edits. > > I have added definitions for fec, kr, and rs. > > Reviewed-by: Tom Rix > > Tom > > > --- /dev/null > > +++ b/Documentation/fpga/dfl-n3000-nios.rst > > @@ -0,0 +1,39 @@ > > +.. SPDX-License-Identifier: GPL-2.0 > > + > > +===================================== > > +DFL N3000 Nios Private Feature Driver > > +===================================== > > + > > +The dfl n3000 nios driver supports for the nios handshake private feature on > > +Intel N3000 FPGA Card. > > + > > +This private feature provides a handshake interface to FPGA NIOS firmware, > > +which receives the ethernet retimer configuration command from host and > > +do the configuration via an internal SPI master. When nios finished the > > does the configuration.. > > When nios finishes the .. > > > +configuration, host takes over the ownership of the SPI master to control an > > +Intel MAX10 BMC Chip on the SPI bus. > > + > > +So the driver does 2 major tasks on probe, requires NIOS firmware to configure > , uses the NIOS firmware to configure the ethernet retimer, and then .. > > +the ethernet retimer by operating the handshake interfaces, and then creates a > > +spi master platform device with the MAX10 device info in spi_board_info. > > + > > +Module Parameters > > +================= > > + > > +The dfl n3000 nios driver supports the following module parameters: > > + > > +* fec_mode: string > > + Require the NIOS firmware to set the FEC mode of the ethernet retimer on > the FEC (Forward Error Correction) mode > > + the PAC N3000 FPGA card. The possible values could be: > > + > > + - "rs": RS FEC mode (default) > - "rs" : Reed Solomon FEC (default) > > + - "kr": KR FEC mode > - "kr": Fire Code FEC > > + - "no": NO FEC mode > > + > > + The configuration could only be set once after the board powers up, the > The configuration can only be .. > > + firmware will not accept a second configuration afterward. So the fec mode > second configuration. > > + will not be changed if the module is reloaded with a different param value. > > + > > + The configured value of the fec mode could be queried from sysfs node: > > + > > + /sys/bus/dfl/devices/dfl-fme.X.X/fec_mode