From patchwork Fri Jun 25 19:51:40 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Rix X-Patchwork-Id: 12345825 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2F7C3C48BC2 for ; Fri, 25 Jun 2021 19:54:04 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E0D4461973 for ; Fri, 25 Jun 2021 19:54:03 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E0D4461973 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=MIOAW2aWZWoMltadRsqR1REPjHMuo2QoGtqnR2Z+5Ig=; b=1HfOBhggQ+OlSL 7JzPkqb4epEB3QXBJv8ohikPlWxEaHi2vzA3Iw3P53yV9ABJYVxAIQCPiHa3OF8gh+aGXyPSaUISk NMGI5C3UpaR6rr8C5NcaYqqtnvuyVB30OliXkPj2BTrwUiRrB51gkoMKff/cJV3MQB3tCs6ZIj7h/ /sVERwZdFDmSNJj+fGzkeXieITe5b2Z/GJcvGCaS6xMCQIUu0lLYzpfi/Onc4ZXyFY7r2gb+RKCL8 r/DGl4sFTGzw+FGRnTv+YHQLwfQwWsH3gK4BJPbRm52mM4VljGvqAwRPP2lX5+YfskkAaB6IqllQR KmFpQZKlXR/kDb6QFckA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lwrrz-002iVQ-Iv; Fri, 25 Jun 2021 19:52:07 +0000 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lwrrw-002iUs-By for linux-arm-kernel@lists.infradead.org; Fri, 25 Jun 2021 19:52:05 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1624650721; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Ef9qFAYdxrVH6/HlVHojSk640HF0K6FvgDiFwPqxu5U=; b=J4IQPxNhSaQNF2XeGfUUPD6htuf402/1+cITwdx/lJ4PWcvBcCUZKEKiCXCaNcS91BGY5k jX3FoNvyjgPHOm79THVQPSDL6/KGO2l/Be1H5/wI7qCmJGgsCiHm9KRAYzgwhfUe7W1YUa 2B3hI5P0bGcTIG+u91hppOP53LW8f1I= Received: from mail-ot1-f72.google.com (mail-ot1-f72.google.com [209.85.210.72]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-409-81-pY3u0OruFb1mSYEoK9w-1; Fri, 25 Jun 2021 15:52:00 -0400 X-MC-Unique: 81-pY3u0OruFb1mSYEoK9w-1 Received: by mail-ot1-f72.google.com with SMTP id i25-20020a9d4a990000b0290304f00e3e3aso6553309otf.15 for ; Fri, 25 Jun 2021 12:51:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Ef9qFAYdxrVH6/HlVHojSk640HF0K6FvgDiFwPqxu5U=; b=GjwGAK97IjG76jgi0cQfom7SIRHcQpBuabdtoZO4eJR1Zx7Z/x0q+dz2Ljo65zQGX5 9Xk3ZowcDJ0I26TLNgV2j08AcGV2mR0vTB3QtOPyxS1a4TqvtHfC0XoizLIWnwnmdHXi bOrDMSgTu2RWpQyJh6GXHcvpSr32T4Hf7hgoVSkyp3VsJU5SN5ReH29jzZz2YTfcJBBJ m1c5J+m/WuqZCdeCWNwr1DoHSuC4fTQ6VNGhVGpX1O74Cc6kspB14YG1n/Xz+7y2WA4P lPt16tdTuLhWgew1XyTCcxU7/aibNQe72ANWQckl2hh3DomAkUhMHcMzzlpebIvMlTMe rVUQ== X-Gm-Message-State: AOAM530ofb2XXTBGo5A5Lz9BTDmh3Koj7BLnnIZLd3d0s7N9+sMtOYic Db5ILGsMkLrDk0pCT+xnUpE61WxlL6kMSSEOCtil0DHdA6+T6rdc0q0cevOOZa++42KIXNLcPXM OQ6bqEYuSmKZ6vzF/g5kaH1o+/AQsIVriDWA= X-Received: by 2002:a9d:634d:: with SMTP id y13mr11285132otk.294.1624650719413; Fri, 25 Jun 2021 12:51:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz9SONxhvUh55/AyVb2xueMPq6ATJRY/MzaDu3zdxqWTtJLSpUkP8d50R9gFMFN0vLoTE02qw== X-Received: by 2002:a9d:634d:: with SMTP id y13mr11285114otk.294.1624650719191; Fri, 25 Jun 2021 12:51:59 -0700 (PDT) Received: from localhost.localdomain.com (075-142-250-213.res.spectrum.com. [75.142.250.213]) by smtp.gmail.com with ESMTPSA id o25sm1535446ood.20.2021.06.25.12.51.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Jun 2021 12:51:58 -0700 (PDT) From: trix@redhat.com To: hao.wu@intel.com, mdf@kernel.org, michal.simek@xilinx.com Cc: linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Tom Rix Subject: [PATCH v4 0/7] wrappers for fpga_manager_ops Date: Fri, 25 Jun 2021 12:51:40 -0700 Message-Id: <20210625195148.837230-1-trix@redhat.com> X-Mailer: git-send-email 2.26.3 MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=trix@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210625_125204_532909_7170CFC3 X-CRM114-Status: UNSURE ( 7.21 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Tom Rix As followup from https://lore.kernel.org/linux-fpga/06301910-10a1-0e62-45a0-d28ab5a787ed@redhat.com/ Boards should not be required to have noop functions. So improve or create fpga-mgr wrappers for the fpga_manager_ops. Remove the noop functions. Refactor fpga-mgr to use the wrappers. Changes from v1: commit subject,log v2: rebase to next-20210623 v3: remove mops check add write_sg wrapper drop 'fpga-mgr: collect wappers and change to inline' Tom Rix (7): fpga-mgr: wrap the write_init() op fpga-mgr: make write_complete() op optional fpga-mgr: wrap the write() op fpga-mgr: wrap the status() op fpga-mgr: wrap the state() op fpga-mgr: wrap the fpga_remove() op fpga-mgr: wrap the write_sg() op drivers/fpga/dfl-fme-mgr.c | 6 -- drivers/fpga/fpga-mgr.c | 111 +++++++++++++++++++++++------------ drivers/fpga/stratix10-soc.c | 6 -- drivers/fpga/ts73xx-fpga.c | 6 -- drivers/fpga/zynqmp-fpga.c | 7 --- 5 files changed, 75 insertions(+), 61 deletions(-)