Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp495848pxu; Sun, 25 Oct 2020 07:33:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwOvsO6SXpjgOcF3uqatYM2W+YBM/+jnDLFRDv0FlZ6+3Dt61G3smJIiiVSLqeMviBBK9vI X-Received: by 2002:aa7:d781:: with SMTP id s1mr11082884edq.122.1603636396975; Sun, 25 Oct 2020 07:33:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603636396; cv=none; d=google.com; s=arc-20160816; b=1A4OICxtgZiiYmFvqPEnqNvMOu8JUwrowtd7l7zy6xgNqm8lK8WIU5AXxxcfTfVFrg fYc3ctgaZfYz/kF6Mik11uSV+l0MynGMhT4YojQj7NSkTLvP9lYDJi6ny6tDQXvKFEF1 CYyuUknGORjMQdb97LKAuxILNze6VYkjNnNonEpMfOn30C6R+bj/iVAD51BEIJxQdu3G 1U+HZT4MFCdgBaCdCMqtDFWC8a1I0qzDyB9tAHfpgK1O8EKoBgEcw6F1uy7RaDOpWUw8 7DlVEPLACg+Ql8t4IULKL3rnetS0Fl/U+lLp+dGai7OIgAcTC7ph5jV9AaKBlHPXrW74 sUQQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=tTvY4335aoBPZyci6dgCoezUALg9f2+f8kAnWAVi94E=; b=dpevD/GufnLa1HUux48lbTToD4xr8gsZ8XMZNG5PJSLIrX354rptrhoxDCjQ+eZVVL 2CIygNcHqqfFkrknR3TYzXq6s66U8ZghszKgCFmqypXkB702LvJQWr/LyPXS16n3QnXT r0L5k9GZbIRL8K4XRa52F6DS3F8po1v040X0pEzfg0mpQNnCX8P+Mso5AHjPpunspYjv 7+eZ4cDQu7keGcKTh87OsvRBUYmZnZjMC506hN9uTqbe6Uua8Nks8GGCrzGNPXrwUFAn GqSKTFSpbDC1Zbdtl0rOIgOEFMkGZ9Fd8vo/E2bOaEA3nsmyPccA4d4xP2s6cRga4eeu 1fag== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y1si4608846edp.57.2020.10.25.07.32.55; Sun, 25 Oct 2020 07:33:16 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1415384AbgJYLSu (ORCPT + 99 others); Sun, 25 Oct 2020 07:18:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1415378AbgJYLSt (ORCPT ); Sun, 25 Oct 2020 07:18:49 -0400 Received: from hillosipuli.retiisi.eu (hillosipuli.retiisi.eu [IPv6:2a01:4f9:c010:4572::81:2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 41922C0613CE; Sun, 25 Oct 2020 04:18:49 -0700 (PDT) Received: from valkosipuli.localdomain (valkosipuli.retiisi.org.uk [IPv6:2a01:4f9:c010:4572::80:2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by hillosipuli.retiisi.eu (Postfix) with ESMTPS id 02001634C92; Sun, 25 Oct 2020 13:18:23 +0200 (EET) Received: from sailus by valkosipuli.localdomain with local (Exim 4.92) (envelope-from ) id 1kWe2b-0001Gy-4E; Sun, 25 Oct 2020 13:18:25 +0200 Date: Sun, 25 Oct 2020 13:18:25 +0200 From: Sakari Ailus To: Dan Scally Cc: linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linus.walleij@linaro.org, prabhakar.mahadev-lad.rj@bp.renesas.com, heikki.krogerus@linux.intel.com, dmitry.torokhov@gmail.com, laurent.pinchart+renesas@ideasonboard.com, kieran.bingham+renesas@ideasonboard.com, jacopo+renesas@jmondi.org, robh@kernel.org, davem@davemloft.net, linux@rasmusvillemoes.dk, andriy.shevchenko@linux.intel.com, sergey.senozhatsky@gmail.com, rostedt@goodmis.org, pmladek@suse.com, mchehab@kernel.org, tian.shu.qiu@intel.com, bingbu.cao@intel.com, sakari.ailus@linux.intel.com, yong.zhi@intel.com, rafael@kernel.org, gregkh@linuxfoundation.org, kitakar@gmail.com Subject: Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows Message-ID: <20201025111824.GB3774@valkosipuli.retiisi.org.uk> References: <20201019225903.14276-1-djrscally@gmail.com> <20201019225903.14276-10-djrscally@gmail.com> <20201024151458.GA3774@valkosipuli.retiisi.org.uk> <18a3661c-4bee-7421-9121-acd65401cf16@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <18a3661c-4bee-7421-9121-acd65401cf16@gmail.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Daniel, On Sat, Oct 24, 2020 at 09:28:07PM +0100, Dan Scally wrote: ... > >> +int cio2_bridge_build(struct pci_dev *cio2) > >> +{ > >> + struct fwnode_handle *fwnode; > >> + int ret; > >> + > >> + pci_dev_get(cio2); > > Could you check that this isn't used by more than one user? The current > > implementation assumes that. I'm not sure if there could be more instances > > of CIO2 but if there were, that'd be an issue currently. > > I can check; can't think of anything better than just failing out if it > turns out to be in use already though - any ideas or is that appropriate? A negative error code would be appropriate, e.g. -EBUSY. -- Regards, Sakari Ailus