Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp2317595ybh; Mon, 9 Mar 2020 03:33:32 -0700 (PDT) X-Google-Smtp-Source: ADFU+vvhi4ImmuYw3g9o5zS6JhQW1OPIq0Of6KRyE6bbcBEbLCRlcR2quDZiBZ849X75MmdAqX6g X-Received: by 2002:a9d:4b15:: with SMTP id q21mr3822789otf.84.1583750012461; Mon, 09 Mar 2020 03:33:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1583750012; cv=none; d=google.com; s=arc-20160816; b=0C9yMJ0jgHqibKCFuuZVg1X3k3WjDfOAmf2lEVGTfynrtnFNCOoz/elIcHGLvjvNE/ OGW7kboQ7C1i8W1+DqLePNdTeuvuCeENUjMDj59wZpuUkqdyWCIuLBG48PL1oWxwK0GZ 3rNNjuk6apRE99s2K7lFDf5yFQOh7/YEagoXphfwgP3dloH8cVSXKCM6aN8IydK4na9v X0AgmWXURB3CVG/fY1x6RqnZ0rNgqZRxBNXfkXTTfikCQIAZBKwdq8ts0BciuI18BNfI /xuJHpUWpOa0i8yQ3DRy+C4pPLcYMFT/IXch+U8T7Zln7WpSnxD1hSHeuHQfQWI3lH1x MFJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=imLkkJmpcpJP1b6FTKAZbkvPRgFoQ3PQxrCqId3VqLU=; b=bMP6yUM+dXAZxmy1Ql52BSYb2BlI+JRqBI9YiPwI678XjEo92F+kIAlV2+VQQgVFK0 DW420nJpIPI6ufUooOJa+1CwJqi2PiO0TuLWAJ/C3+uUoXtExiU4RlkxlowV26qgkWgN kKmXAp2B07t3DAdANd8VrNqZCiad+gcVN5WGTxAKCFH5m+lih3/v9mgk3OwzTYqrh3vX qIW5zWTZOf4n0eAS5nqgR8iLRQ7IIfU2y1NdwLGrpGi+ObDbZFs6EtjfuFjys+Ro0QZK dU2e1K/bMZirUnDNwcW7nPUaw37Sues+4H6GungA26h/P+O2EJKI/mVVT/Ol8g/BStxM 9Z2Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id h25si675826otq.53.2020.03.09.03.33.20; Mon, 09 Mar 2020 03:33:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1726793AbgCIKc2 (ORCPT + 99 others); Mon, 9 Mar 2020 06:32:28 -0400 Received: from mga01.intel.com ([192.55.52.88]:46817 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726545AbgCIKc2 (ORCPT ); Mon, 9 Mar 2020 06:32:28 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Mar 2020 03:32:16 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,532,1574150400"; d="scan'208";a="288655083" Received: from yilunxu-optiplex-7050.sh.intel.com ([10.239.159.141]) by FMSMGA003.fm.intel.com with ESMTP; 09 Mar 2020 03:32:14 -0700 From: Xu Yilun To: mdf@kernel.org, linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Xu Yilun , Luwei Kang , Wu Hao Subject: [PATCH 7/7] Documentation: fpga: dfl: add descriptions for interrupt related interfaces. Date: Mon, 9 Mar 2020 18:29:50 +0800 Message-Id: <1583749790-10837-8-git-send-email-yilun.xu@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1583749790-10837-1-git-send-email-yilun.xu@intel.com> References: <1583749790-10837-1-git-send-email-yilun.xu@intel.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch adds introductions of interrupt related interfaces for FME error reporting, port error reporting and AFU user interrupts features. Signed-off-by: Luwei Kang Signed-off-by: Wu Hao Signed-off-by: Xu Yilun --- Documentation/fpga/dfl.rst | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/Documentation/fpga/dfl.rst b/Documentation/fpga/dfl.rst index 094fc8a..3c4e150 100644 --- a/Documentation/fpga/dfl.rst +++ b/Documentation/fpga/dfl.rst @@ -89,6 +89,8 @@ The following functions are exposed through ioctls: - Program bitstream (DFL_FPGA_FME_PORT_PR) - Assign port to PF (DFL_FPGA_FME_PORT_ASSIGN) - Release port from PF (DFL_FPGA_FME_PORT_RELEASE) +- Get FME global error info (DFL_FPGA_FME_ERR_GET_INFO) +- Set interrupt trigger for FME error (DFL_FPGA_FME_ERR_SET_IRQ) More functions are exposed through sysfs (/sys/class/fpga_region/regionX/dfl-fme.n/): @@ -144,6 +146,10 @@ The following functions are exposed through ioctls: - Map DMA buffer (DFL_FPGA_PORT_DMA_MAP) - Unmap DMA buffer (DFL_FPGA_PORT_DMA_UNMAP) - Reset AFU (DFL_FPGA_PORT_RESET) +- Get port error info (DFL_FPGA_PORT_ERR_GET_INFO) +- Set interrupt trigger for port error(DFL_FPGA_PORT_ERR_SET_IRQ) +- Get User AFU interrupt(UINT) info (DFL_FPGA_PORT_UINT_GET_INFO) +- Set interrupt trigger for UINT (DFL_FPGA_PORT_UINT_SET_IRQ) DFL_FPGA_PORT_RESET: reset the FPGA Port and its AFU. Userspace can do Port @@ -378,6 +384,17 @@ The device nodes used for ioctl() or mmap() can be referenced through:: /sys/class/fpga_region///dev +Interrupt support +================= +Some FME and AFU private features are able to generate interrupts. As mentioned +above, users could call ioctl (DFL_FPGA_*_GET_INFO), query the nr_irqs field to +know whether or how many interrupts are supported for this private feature. +Drivers also implement an eventfd based interrupt handling mechanism for users +to get notified when interrupt happens. Users could set eventfds to driver via +ioctl (DFL_FPGA_*_SET_IRQ), and then poll/select on these eventfds waiting for +notification. + + Add new FIUs support ==================== It's possible that developers made some new function blocks (FIUs) under this -- 2.7.4